Compiling for Project Chrono Works Without Building Demos on Linux Machine

17 views
Skip to first unread message

Freya the Goddess

unread,
May 20, 2022, 9:18:55 AM5/20/22
to ProjectChrono
Hi all,

sorry I start new mail, I want to show from my attached ccmake setting
picture and the building of Project Chrono that is successful.

Unfortunately, this has a cost that I cannot use build demo when
building Project Chrono with ccmake.

I try to compile a demo example under ../chrono/src/demos

For example:
at ../chrono/src/demos/vehicle/test_rigs
I type:
gcc demo_VEH_TireTestRig.cpp

Is there any other way to create a binary file out of the .cpp file of
the Project Chrono demos? Because I cannot build the demos with cmake.

Thank You.
--
С наилучшими пожеланиями, Богиня Фрейя
Atenciosamente, Freya the Goddess
Meilleurs voeux, Freya the Goddess
Liebe Grüße, Freya the Goddess
Best wishes, Freya the Goddess
よろしくお願いします、Freya the Goddess
最好的祝福,Freya the Goddess
Matakwa mema, Freya the Goddess
مع أطيب التمنيات ، فريا الإلهة
2.png
1.png

Radu Serban

unread,
May 20, 2022, 9:42:30 AM5/20/22
to ProjectChrono
I don't understand, why did you disable the building of demos (set BUILD_DEMOS to OFF) during ccmake configuration? That is how you configure and build the demos.

Note that the vehicle demos (as the name suggests) will require you to enable and build the Chrono::Vehicle module. In general, the Chrono cmake system will take care of configuring and building all demos for optional modules that have been enabled.

Please follow the configuration and build instructions on the project's documentation website (https://api.projectchrono.org/tutorial_table_of_content_install.html). As I already indicated previously, all Chrono demos are built using the top-level CMakeLists.txt file. You cannot just go in a subdirectory and invoke cmake, or make, or the compiler there, as the required dependencies would not be set.

Please get it built following the instructions on our website first. Once you get that working, you can look into building your own demo as a separate project (linking to the Chrono libraries) by looking at the page I mentioned to you before: https://api.projectchrono.org/tutorial_install_project.html

--Radu
--
You received this message because you are subscribed to the Google Groups "ProjectChrono" group.
To unsubscribe from this group and stop receiving emails from it, send an email to projectchron...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/projectchrono/CALUh_%2B05U1n1Ym80KoAn040uh2zjLJEdwZNjqFBFi0CNADvZ1A%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages