I'm trying to compile bullet on QT Creator because I would like to start my project from GLC_Player or Ogitor.
I have tested some solutions but it doesn't work.
I'm just trying to compile this example:
Code: Select all
#include <btBulletDynamicsCommon.h>
#include <iostream>
int main(int argc, char *argv[])
{
std::cout << "Hello world!\r\n";
for(int i=0; i<1000; i++)
{
std::cout << "test " << i << "\n";
}
std::cout << std::flush;
return 0;
}
Code: Select all
#-------------------------------------------------
#
# Project created by QtCreator 2010-12-06T10:43:21
#
#-------------------------------------------------
QT += core
QT -= gui
TARGET = testbullet
CONFIG += console
CONFIG -= app_bundle
TEMPLATE = app
SOURCES += main.cpp
INCLUDEPATH += "C:/libs/bullet-2.77/src"
Code: Select all
tmp/obj/debug_shared/main.o:c:/libs/bullet-2.77/src/./LinearMath/btAlignedAllocator.h:87: undefined reference to `btAlignedFreeInternal(void*)'
Code: Select all
:: error: collect2: ld returned 1 exit status
If I just include "btAlignedAllocator.h". The compilation is Ok!!!
So I manually add all files of bullets physics engine into my project but the compilation doesn't work because Qt tries to compile some softbody*DX11.h files...
I tried to compile with CMAKE but CMake-Gui doesn't know my compiler.
Any ideas are welcome!