Frictional Games Forum (read-only)
Unable to compile - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Open Source Collaboration (https://www.frictionalgames.com/forum/forum-27.html)
+--- Forum: HPL1 Engine (https://www.frictionalgames.com/forum/forum-28.html)
+--- Thread: Unable to compile (/thread-5885.html)



Unable to compile - Red Hot Hoshi - 12-25-2010

Running Arch Linux x64, fully updated, and I hit an error when I try and compile the engine

Code:
1%] Building CXX object CMakeFiles/HPL.dir/sources/impl/PhysicsBodyNewton.cpp.o
In file included from /home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:23:0:
/home/hoshi/HPL1Engine/include/impl/PhysicsMaterialNewton.h:61:18: error: ‘NewtonContact’ does not name a type
/home/hoshi/HPL1Engine/include/impl/PhysicsMaterialNewton.h:61:33: error: ISO C++ forbids declaration of ‘apContact’ with no type
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In constructor ‘hpl::cPhysicsBodyNewton::cPhysicsBodyNewton(const hpl::tString&, hpl::iPhysicsWorld*, hpl::iCollideShape*)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:56:68: error: invalid conversion from ‘void (*)(const NewtonBody*)’ to ‘void (*)(const NewtonBody*, float, int)’
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:56:68: error:   initializing argument 2 of ‘void NewtonBodySetForceAndTorqueCallback(const NewtonBody*, void (*)(const NewtonBody*, float, int))’
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:57:67: error: invalid conversion from ‘void (*)(const NewtonBody*, const float*)’ to ‘void (*)(const NewtonBody*, const float*, int)’
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:57:67: error:   initializing argument 2 of ‘void NewtonBodySetTransformCallback(const NewtonBody*, void (*)(const NewtonBody*, const float*, int))’
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::AddImpulse(const hpl::cVector3f&)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:303:68: error: ‘NewtonAddBodyImpulse’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:307:72: error: ‘NewtonAddBodyImpulse’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::AddImpulseAtPosition(const hpl::cVector3f&, const hpl::cVector3f&)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:312:58: error: ‘NewtonAddBodyImpulse’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::SetEnabled(bool)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:320:55: error: ‘NewtonWorldUnfreezeBody’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:322:53: error: ‘NewtonWorldFreezeBody’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual bool hpl::cPhysicsBodyNewton::GetEnabled() const’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:326:49: error: ‘NewtonBodyGetSleepingState’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::SetAutoDisable(bool)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:333:58: error: ‘NewtonBodySetAutoFreeze’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual bool hpl::cPhysicsBodyNewton::GetAutoDisable() const’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:337:46: error: ‘NewtonBodyGetAutoFreeze’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::SetAutoDisableLinearThreshold(float)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:346:56: error: ‘NewtonBodySetFreezeTreshold’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::SetAutoDisableAngularThreshold(float)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:359:56: error: ‘NewtonBodySetFreezeTreshold’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::SetAutoDisableNumSteps(int)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:372:56: error: ‘NewtonBodySetFreezeTreshold’ was not declared in this scope
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp: In member function ‘virtual void hpl::cPhysicsBodyNewton::RenderDebugGeometry(hpl::iLowLevelGraphics*, const hpl::cColor&)’:
/home/hoshi/HPL1Engine/sources/impl/PhysicsBodyNewton.cpp:434:63: error: ‘NewtonBodyForEachPolygonDo’ was not declared in this scope
make[2]: *** [CMakeFiles/HPL.dir/sources/impl/PhysicsBodyNewton.cpp.o] Error 1
make[1]: *** [CMakeFiles/HPL.dir/all] Error 2
make: *** [all] Error 2

From what I can tell, it looks like none of these functions exist in the version of Newton that it's trying to use. I have the latest Newton Dynamics from the AUR installed. I'm a bit stuck as to what I should try next. Any help would be greatly appreciated.


RE: Unable to compile - Urkle - 12-25-2010

The code is written for newton 1.53 which is included in the dependencies.zip. Also note that that version of newton only works in 32bit so you have to compile a 32bit executable.