how to build
Posted: Fri Sep 22, 2006 11:19 am
Hi guys,
I am trying the library and producing a .deb package at the same time.
With jam the library builds fine, but at installation time, jam doesnt seem to support the DESTDIR make variable or anything like it, so it doesnt allow to install in a place other than /usr
cmake should support DESTDIR (as it produces makefiles), but when I do
cmake .
make
it gives this error:
Linking CXX executable CcdPhysicsDemo
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::initPhysics()':
CcdPhysicsDemo.cpp:(.text+0x959): undefined reference to `DemoApplication::LocalCreatePhysicsObject(bool, float, SimdTransform const&, CollisionShape*)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `main':
CcdPhysicsDemo.cpp:(.text+0xd68): undefined reference to `DemoApplication::setCameraDistance(float)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::~CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoD0Ev[CcdPhysicsDemo::~CcdPhysicsDemo()]+0x17): undefined reference to `DemoApplication::~DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::~CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoD1Ev[CcdPhysicsDemo::~CcdPhysicsDemo()]+0x17): undefined reference to `DemoApplication::~DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoC1Ev[CcdPhysicsDemo::CcdPhysicsDemo()]+0xd): undefined reference to `DemoApplication::DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x10): undefined reference to `DemoApplication::updateCamera()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x1c): undefined reference to `DemoApplication::keyboardCallback(unsigned char, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x20): undefined reference to `DemoApplication::specialKeyboard(int, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x24): undefined reference to `DemoApplication::reshape(int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x28): undefined reference to `DemoApplication::mouseFunc(int, int, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x2c): undefined reference to `DemoApplication::mouseMotionFunc(int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x34): undefined reference to `DemoApplication::renderme()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTI14CcdPhysicsDemo[typeinfo for CcdPhysicsDemo]+0x8): undefined reference to `typeinfo for DemoApplication'
/home/pablob/bullet/bullet-2.0e/Demos/OpenGL/libLibOpenGLSupport.a(GlutStuff.o): In function `glutMoveAndDisplayCallback()':
GlutStuff.cpp:(.text+0x139): undefined reference to `DemoApplication::moveAndDisplay()'
/home/pablob/bullet/bullet-2.0e/Demos/OpenGL/libLibOpenGLSupport.a(GlutStuff.o): In function `glutmain(int, char**, int, int, char const*, DemoApplication*)':
GlutStuff.cpp:(.text+0x1a6): undefined reference to `DemoApplication::myinit()'
collect2: ld returned 1 exit status
make[2]: *** [Demos/CcdPhysicsDemo/CcdPhysicsDemo] Error 1
make[1]: *** [Demos/CcdPhysicsDemo/CMakeFiles/CcdPhysicsDemo.dir/all] Error 2
make: *** [all] Error 2
I dont know anything about cmake, so.. is this fixed on CVS?
Cheers
Pablo
I am trying the library and producing a .deb package at the same time.
With jam the library builds fine, but at installation time, jam doesnt seem to support the DESTDIR make variable or anything like it, so it doesnt allow to install in a place other than /usr
cmake should support DESTDIR (as it produces makefiles), but when I do
cmake .
make
it gives this error:
Linking CXX executable CcdPhysicsDemo
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::initPhysics()':
CcdPhysicsDemo.cpp:(.text+0x959): undefined reference to `DemoApplication::LocalCreatePhysicsObject(bool, float, SimdTransform const&, CollisionShape*)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `main':
CcdPhysicsDemo.cpp:(.text+0xd68): undefined reference to `DemoApplication::setCameraDistance(float)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::~CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoD0Ev[CcdPhysicsDemo::~CcdPhysicsDemo()]+0x17): undefined reference to `DemoApplication::~DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::~CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoD1Ev[CcdPhysicsDemo::~CcdPhysicsDemo()]+0x17): undefined reference to `DemoApplication::~DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o: In function `CcdPhysicsDemo::CcdPhysicsDemo()':
CcdPhysicsDemo.cpp:(.text._ZN14CcdPhysicsDemoC1Ev[CcdPhysicsDemo::CcdPhysicsDemo()]+0xd): undefined reference to `DemoApplication::DemoApplication()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x10): undefined reference to `DemoApplication::updateCamera()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x1c): undefined reference to `DemoApplication::keyboardCallback(unsigned char, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x20): undefined reference to `DemoApplication::specialKeyboard(int, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x24): undefined reference to `DemoApplication::reshape(int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x28): undefined reference to `DemoApplication::mouseFunc(int, int, int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x2c): undefined reference to `DemoApplication::mouseMotionFunc(int, int)'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTV14CcdPhysicsDemo[vtable for CcdPhysicsDemo]+0x34): undefined reference to `DemoApplication::renderme()'
CMakeFiles/CcdPhysicsDemo.dir/CcdPhysicsDemo.o:(.rodata._ZTI14CcdPhysicsDemo[typeinfo for CcdPhysicsDemo]+0x8): undefined reference to `typeinfo for DemoApplication'
/home/pablob/bullet/bullet-2.0e/Demos/OpenGL/libLibOpenGLSupport.a(GlutStuff.o): In function `glutMoveAndDisplayCallback()':
GlutStuff.cpp:(.text+0x139): undefined reference to `DemoApplication::moveAndDisplay()'
/home/pablob/bullet/bullet-2.0e/Demos/OpenGL/libLibOpenGLSupport.a(GlutStuff.o): In function `glutmain(int, char**, int, int, char const*, DemoApplication*)':
GlutStuff.cpp:(.text+0x1a6): undefined reference to `DemoApplication::myinit()'
collect2: ld returned 1 exit status
make[2]: *** [Demos/CcdPhysicsDemo/CcdPhysicsDemo] Error 1
make[1]: *** [Demos/CcdPhysicsDemo/CMakeFiles/CcdPhysicsDemo.dir/all] Error 2
make: *** [all] Error 2
I dont know anything about cmake, so.. is this fixed on CVS?
Cheers
Pablo