Dear friends,
I am a new user to bullet library. I had installed it successfully and I need to use its static collision detection. After trying my hands on one or two exemplary codes, when i started integrating bullet functions with my codes, it was going fine in the beginning. But now just after doing little work, it has suddenly started giving some undefined reference problem as below. As I had not gone so far, I just tried commenting all my new changes made for integration and found that even the problem remains even if just one bullet header file including statement remains. I mean, there the one statement remains related to bullet, in my code is #include "btBulletCollisionCommon.h". What a pity! I am stuck. Is there anything concern to cache memory or so? Please help me out as I am unable to move ahead.
********************************************************************************
CMakeFiles/CoDRoS_PUMA_robot_example.dir/example_PUMA_robot.cpp.o: In function `btAlignedAllocator<btHashInt, 16u>::deallocate(btHashInt*)':
example_PUMA_robot.cpp:(.text._ZN18btAlignedAllocatorI9btHashIntLj16EE10deallocateEPS0_[btAlignedAllocator<btHashInt, 16u>::deallocate(btHashInt*)]+0xd): undefined reference to `btAlignedFreeInternal(void*)'
CMakeFiles/CoDRoS_PUMA_robot_example.dir/example_PUMA_robot.cpp.o: In function `btAlignedAllocator<btTriangleInfo, 16u>::deallocate(btTriangleInfo*)':
example_PUMA_robot.cpp:(.text._ZN18btAlignedAllocatorI14btTriangleInfoLj16EE10deallocateEPS0_[btAlignedAllocator<btTriangleInfo, 16u>::deallocate(btTriangleInfo*)]+0xd): undefined reference to `btAlignedFreeInternal(void*)'
CMakeFiles/CoDRoS_PUMA_robot_example.dir/example_PUMA_robot.cpp.o: In function `btAlignedAllocator<int, 16u>::deallocate(int*)':
example_PUMA_robot.cpp:(.text._ZN18btAlignedAllocatorIiLj16EE10deallocateEPi[btAlignedAllocator<int, 16u>::deallocate(int*)]+0xd): undefined reference to `btAlignedFreeInternal(void*)'
collect2: ld returned 1 exit status
make[2]: *** [CoDRoS_PUMA_robot_example] Error 1
make[1]: *** [CMakeFiles/CoDRoS_PUMA_robot_example.dir/all] Error 2
make: *** [all] Error 2
********************************************************************************************************************************
Thank you
undefined reference to `btAlignedFreeInternal(void*)'
-
esingla
- Posts: 8
- Joined: Sat Mar 13, 2010 8:00 am
-
Erwin Coumans
- Site Admin
- Posts: 4221
- Joined: Sun Jun 26, 2005 6:43 pm
- Location: California, USA
Re: undefined reference to `btAlignedFreeInternal(void*)'
Please try to link statically (no install, dynamic library, frameworks), and make sure the order of linking is correct:
bulletmultithreaded, bulletsoftbody, bulletdynamics, bulletcollision, linearmath
Do the demos compile/link and run fine? If so, please compare your project with the demos.
Thanks,
Erwin
bulletmultithreaded, bulletsoftbody, bulletdynamics, bulletcollision, linearmath
Do the demos compile/link and run fine? If so, please compare your project with the demos.
Thanks,
Erwin