i used
Code: Select all
cmake -DBUILD_SHARED_LIBS=ON
make
I had the following issues:
Code: Select all
ld: common symbols not allowed with MH_DYLIB output format with the -multi_module option
Code: Select all
cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_SHARED_LINKER_FLAGS=-single_module
make
Code: Select all
../bullet-2.75-RC5b/src/BulletMultiThreaded/PosixThreadSupport.cpp: In function 'sem_t* createSem(const char*)':
../bullet-2.75-RC5b/src/BulletMultiThreaded/PosixThreadSupport.cpp:61: error: ISO C++ forbids comparison between pointer and integer
Code: Select all
if (tempSem != SEM_FAILED)
[\code]
to
[code]
if (tempSem == reinterpret_cast<sem_t *>(SEM_FAILED))
[\code]
then you get (and there you start at least to grin)
[code]
[ 85%] Building CXX object src/BulletMultiThreaded/CMakeFiles/BulletMultiThreaded.dir/MiniCLTask/MiniCLTask.o
Linking CXX shared library libBulletMultiThreaded.dylib
ld: Undefined symbols:
_btGpu_computeGridSize
/usr/bin/libtool: internal link edit command failed
make[2]: *** [src/BulletMultiThreaded/libBulletMultiThreaded.dylib] Error 1
[\code]
you solve it using the patch at
[url]http://code.google.com/p/bullet/issues/detail?id=246[/url]
and apply it:
[code]
cd src/BulletMultiThreaded/
patch -p 2 <~/Desktop/missing-_btGpu_computeGridSize-PROPER.diff
[\code]
now you can install
everything using
[code]
sudo make install
[\code]
and test everything with the demo called helloworld