Closed GoogleCodeExporter closed 9 years ago
[deleted comment]
I'm experiencing the same issue (also as a first time user).
Ubuntu 10.10 64 bit
gcc 4.6.3
cmake 2.8.7 (generator: Unix Makefiles)
Exact reproduction steps:
svn checkout http://gamekit.googlecode.com/svn/trunk/ gamekit # revision 1086
cd gamekit
mkdir build
cd build
cmake .. # all external packages found
make
Relevant output:
[ 99%] Building CXX object
Engine/CMakeFiles/OgreKitCore.dir/__/Ogre-1.8rc/Bin/OgreKitCore/compile_OgreKitC
ore_1.cpp.o
In file included from
../Ogre-1.8rc/Bin/OgreKitCore/compile_OgreKitCore_1.cpp:27:0:
../Engine/LogicBricks/gkNearSensor.cpp: In member function ‘virtual bool
gkNearSensor::query()’:
../Engine/LogicBricks/gkNearSensor.cpp:66:29: error: cannot declare variable
‘exec’ to be of abstract type ‘gkAllContactResultCallback’
../Engine/./Physics/gkContactTest.h:33:7: note: because the following virtual
functions are pure within ‘gkAllContactResultCallback’:
../bullet/src/BulletCollision/CollisionDispatch/btCollisionWorld.h:424:20:
note: virtual btScalar
btCollisionWorld::ContactResultCallback::addSingleResult(btManifoldPoint&,
const btCollisionObjectWrapper*, int, int, const btCollisionObjectWrapper*,
int, int)
In file included from
../Ogre-1.8rc/Bin/OgreKitCore/compile_OgreKitCore_1.cpp:29:0:
../Engine/LogicBricks/gkRadarSensor.cpp: In member function ‘virtual bool
gkRadarSensor::query()’:
../Engine/LogicBricks/gkRadarSensor.cpp:88:29: error: cannot declare variable
‘exec’ to be of abstract type ‘gkAllContactResultCallback’
../Engine/./Physics/gkContactTest.h:33:7: note: since type
‘gkAllContactResultCallback’ has pure virtual functions
make[2]: ***
[Engine/CMakeFiles/OgreKitCore.dir/__/Ogre-1.8rc/Bin/OgreKitCore/compile_OgreKit
Core_1.cpp.o] Error 1
make[1]: *** [Engine/CMakeFiles/OgreKitCore.dir/all] Error 2
make: *** [all] Error 2
Original comment by bdakk...@gmail.com
on 7 Jun 2012 at 8:58
The last Bullet commit is huge and has caused issues. Downgrade to the previous
one until it's resolved:
cd bullet/src
svn update -r2538
Original comment by kungfoobar@gmail.com
on 8 Jun 2012 at 12:56
Alright, I got mine to compile after fixing the FromAngleAxis to FromAxisAngle
or vice-versa. The cpp/appgamekit demos run properly and everything. Now I just
need to figure how to use it, presumably by mulling around with the cpp demo as
there are no examples in the docs.
Is there an easy way (like just a different compiler command) to make an
ogrekit.dll instead of everything being statically linked?
Original comment by JacobWat...@gmail.com
on 8 Jun 2012 at 3:57
Yes, just make a directory inside gamekit (let's call it sharedlib), with a
file CMakeLists.txt, with this contents:
set(TargetName ogrekit)
include_directories(${OGREKIT_INCLUDE})
link_libraries(${OGREKIT_LIB})
add_library(${TargetName} SHARED)
Note that for compiling a 64 bits binary you will need to add -fPIC to
CMAKE_C_FLAGS and CMAKE_CXX_FLAGS (in linux at least, I don't know if that's
the case in windows).
Original comment by kungfoobar@gmail.com
on 8 Jun 2012 at 7:23
I forgot... add subdirs(sharedlib) at the end of gamekit CMakeFiles.txt
Original comment by kungfoobar@gmail.com
on 8 Jun 2012 at 7:24
I did what you said and it spat out a 21kb dll, so I presume I did something
wrong. All I had in the directory was the makefile. (I'm guessing I have to
have an actual source-code file so it adds the used functions to the dll? I
really have no idea what I'm doing if that wasn't clear :( )
Original comment by JacobWat...@gmail.com
on 9 Jun 2012 at 12:10
My bad, I didn't even check the file size.
After some investigations it seems OgreKit lacks a way for exporting/importing
symbols in a shared library, like Ogre itself has. Take a look at the file
Ogre-1.8rc/OgreMain/include/OgrePlatform.h lines 155-163 to see how Ogre does
it. It has a macro _OgreExport which evaluates either to __declspec(dllexport),
__declspec(dllimport) or nothing, depending on what and where are you
compiling. It seems all ogre plugins (and most dependencies) has its own export
macros.
Original comment by kungfoobar@gmail.com
on 9 Jun 2012 at 2:30
I have no idea what I'm doing, so I'm just going to statically link stuff I
guess.
Are there tutorials on using gamekit via C++, or should I look more at using
Blender or even tutorials for using the individual libraries?
If there's a better place to learn/discuss this stuff I'll go there.
Original comment by JacobWat...@gmail.com
on 9 Jun 2012 at 5:28
Yeah, the proper place is the forum: http://www.gamekit.org/
As for using the C++ API, the best resource is the code itself: the headers and
the samples. There's no documentation but classes and methods have very
descriptive names. There's documentation for the Lua API:
http://gamekit.org/forum/viewtopic.php?f=9&t=408&p=1312
Also, I've doing Python bindings for gamekit, and I'm also documenting it.
https://bitbucket.org/DiThi/pygamekit
Original comment by kungfoobar@gmail.com
on 9 Jun 2012 at 9:48
[deleted comment]
** Comment 3 by project member kungfoobar@gmail.com, Jun 8 (4 days ago)
The last Bullet commit is huge and has caused issues. Downgrade to the previous
one until it's resolved:
cd bullet/src
svn update -r2538
Does somebody work on that problem ?
Original comment by xelfes
on 13 Jun 2012 at 12:50
I've fixed it. Now it works with the latest Bullet trunk.
Original comment by kungfoobar@gmail.com
on 13 Jun 2012 at 4:09
Original issue reported on code.google.com by
JacobWat...@gmail.com
on 7 Jun 2012 at 5:29