summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Dombrowski <stefan@uni-bonn.de>2010-08-16 18:00:44 +0200
committerJared Adams <jaxad0127@gmail.com>2010-08-17 09:02:04 -0600
commit2497269351b9ac46d4f0852f52244df7aa4d211b (patch)
tree6036ddc9297c2c95f1b13bf4657468ef86488790
parent2b676bbf6fcf7dfd45cb33f06dacd2ca5bce19fe (diff)
downloadmana-2497269351b9ac46d4f0852f52244df7aa4d211b.tar.gz
mana-2497269351b9ac46d4f0852f52244df7aa4d211b.tar.bz2
mana-2497269351b9ac46d4f0852f52244df7aa4d211b.tar.xz
mana-2497269351b9ac46d4f0852f52244df7aa4d211b.zip
Add missing include and add enet files to codeblocks
The missing include generated compiler error on windows. Because of compiler warnings generated by enet, warnings are switched of for: * unknown #pragmas, which are for MSVC compiler * enumeration with missing case Reviewed-by: Bertram
-rw-r--r--mana.cbp24
-rw-r--r--src/log.cpp8
2 files changed, 24 insertions, 8 deletions
diff --git a/mana.cbp b/mana.cbp
index 0f6e06c1..459a660c 100644
--- a/mana.cbp
+++ b/mana.cbp
@@ -15,6 +15,8 @@
<Compiler>
<Add option="-O3" />
<Add option="-Wall" />
+ <Add option="-Wno-switch" />
+ <Add option="-Wno-unknown-pragmas" />
<Add option="-DUSE_OPENGL" />
<Add option="-DNOGDI" />
<Add option="-DENABLE_NLS" />
@@ -41,10 +43,8 @@
<Add library="physfs" />
<Add library="curl.dll" />
<Add library="intl" />
- <Add library="enet" />
<Add library="ws2_32" />
<Add library="winmm" />
- <Add directory="E:\Programme\CodeBlocks\include\SDL" />
</Linker>
</Target>
<Target title="Unix">
@@ -76,7 +76,6 @@
<Add library="SDL_ttf" />
<Add library="SDL_gfx" />
<Add library="png" />
- <Add library="enet" />
</Linker>
</Target>
</Build>
@@ -88,10 +87,29 @@
<Add directory="include" />
<Add directory="include\libxml2" />
<Add directory="include\SDL" />
+ <Add directory="libs\enet\include" />
</Compiler>
<Linker>
<Add directory="lib" />
</Linker>
+ <Unit filename="libs\enet\include\enet\callbacks.h" />
+ <Unit filename="libs\enet\callbacks.c" />
+ <Unit filename="libs\enet\compress.c" />
+ <Unit filename="libs\enet\include\enet\enet.h" />
+ <Unit filename="libs\enet\host.c" />
+ <Unit filename="libs\enet\include\enet\list.h" />
+ <Unit filename="libs\enet\list.c" />
+ <Unit filename="libs\enet\packet.c" />
+ <Unit filename="libs\enet\peer.c" />
+ <Unit filename="libs\enet\include\enet\protocol.h" />
+ <Unit filename="libs\enet\protocol.c" />
+ <Unit filename="libs\enet\include\enet\time.h" />
+ <Unit filename="libs\enet\include\enet\types.h" />
+ <Unit filename="libs\enet\include\enet\unix.h" />
+ <Unit filename="libs\enet\unix.c" />
+ <Unit filename="libs\enet\include\enet\utility.h" />
+ <Unit filename="libs\enet\include\enet\win32.h" />
+ <Unit filename="libs\enet\win32.c" />
<Unit filename="src\SDLMain.h" />
<Unit filename="src\SDLMain.m" />
<Unit filename="src\animatedsprite.cpp" />
diff --git a/src/log.cpp b/src/log.cpp
index 435b2da0..5880e108 100644
--- a/src/log.cpp
+++ b/src/log.cpp
@@ -19,9 +19,6 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include <iostream>
-#include <sstream>
-
#include "log.h"
#include "gui/widgets/chattab.h"
@@ -30,11 +27,12 @@
#include <windows.h>
#elif __APPLE__
#include <Carbon/Carbon.h>
-#elif __linux__ || __linux
-#include <stdlib.h>
#endif
#include <sys/time.h>
+#include <iostream>
+#include <sstream>
+#include <stdlib.h>
Logger::Logger():
mLogToStandardOut(true),