* Include . in the include path for compiling.
* Make CLog support user logging through stdout.
//\r
//////////////////////////////////////////////////////////////////////\r
\r
+#include <stdarg.h>\r
+#include "porting.h"\r
#include "engine.h"\r
#include "Log.h"\r
\r
#ifdef WIN32\r
MessageBox(NULL,(LPCTSTR)szBuf,L"Message",MB_OK);\r
#else\r
-#error User-level logging is not implemented for this platform.\r
+ std::cout << szBuf << "\n";\r
#endif\r
}\r
va_end(args);\r
-all: main.o
+CFLAGS:=-I.
+OBJS:=main.o Engine/Log.o
+
+all: $(OBJS)
%.o: %.cpp
- g++ -c $< -o $@
+ g++ $(CFLAGS) -c $< -o $@
clean:
- rm -f *.o
+ rm -f *.o Engine/*.o
--- /dev/null
+#ifndef WIN32
+ #define vsprintf_s vsnprintf
+#endif // !WIN32