Hi,
In revision 2701 the following lines were added to CMakeLists.txt (starting at line 433):
+configure_file ( ${CMAKE_SOURCE_DIR}/BulletConfig.cmake.in
+ ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake
+ @ONLY ESCAPE_QUOTES
+ )
+install ( FILES ${CMAKE_SOURCE_DIR}/UseBullet.cmake
+ ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake
+ DESTINATION ${BULLET_CONFIG_CMAKE_PATH}
+ )
This breakes including the project in another cmake build (at least for me, on linux) via add_subdirectory.
Changing ${CMAKE_SOURCE_DIR} to ${CMAKE_CURRENT_SOURCE_DIR} fixes it.
${CMAKE_SOURCE_DIR} erroneously gives the top level directory of my build,
${CMAKE_CURRENT_SOURCE_DIR} gives the bullet directory.
Any chance this change could make it into svn?
Many thanks,
keep up the good work
Small cmake change request
-
- Posts: 31
- Joined: Mon Nov 04, 2013 10:58 am
Re: Small cmake change request
I just stumbled over the same issue, replacing 2.81 by 2.82 here.
You should use <bullet_project_name>_SOURCE_DIR rather than CMAKE_SOURCE_DIR, that's for sure.
You should use <bullet_project_name>_SOURCE_DIR rather than CMAKE_SOURCE_DIR, that's for sure.
-
- Posts: 2
- Joined: Sat Nov 16, 2013 1:20 pm
Re: Small cmake change request
You're right, ${BULLET_PHYSICS_SOURCE_DIR} is the correct variable to use.
-
- Site Admin
- Posts: 4221
- Joined: Sun Jun 26, 2005 6:43 pm
- Location: California, USA
Re: Small cmake change request
If you have a cmake patch, please submit it to the googlecode issue tracker at http://bullet.googlecode.com
Thanks,
Erwin
Thanks,
Erwin