Kaynağa Gözat

fixes for windows, some things like getopt where missing (added them …
…to CMakeLists.txt, found via codeproject: http://www.codeproject.com/Articles/157001/Full-getopt-Port-for-Unicode-and-Multibyte-Microso) and an "Entity" inside PolyPhysicsSceneEntity was ambigous.

Also, some windows headers are defining far & near, so they had to be undefined by the create_lua_library.py script.
Added an inline "round" function in polyglobals for _WINDOWS and changed some usings of "M_PI" to "PI", as they also could not be found by the compiler (even, if math was included).

lunatix 12 yıl önce
ebeveyn
işleme
3c51a5b2a5

+ 5 - 3
Tools/Contents/polyimport/Source/polyimport.cpp

@@ -3,7 +3,12 @@
 #include "OSBasics.h"
 
 #include "physfs.h"
+#ifdef WIN32
 #include "getopt.h"
+#define getopt getopt_a
+#else
+#include <unistd.h>
+#endif
 
 using namespace Polycode;
 
@@ -20,9 +25,6 @@ bool writeBoneWeights = false;
 bool writeUVs = false;
 bool writeSecondaryUVs = false;
 
-#ifdef WIN32
-#define getopt getopt_a
-#endif
 
 unsigned int addBone(aiBone *bone) {
 	for(int i=0; i < bones.size(); i++) {