From a84eef8431a24af47d7d68fd34956fd8b26255d3 Mon Sep 17 00:00:00 2001 From: Emil Laine Date: Mon, 12 Sep 2016 21:33:38 +0300 Subject: [PATCH] Remove femain.cpp This is made to simplify linking on MinGW. For more info, see: https://github.com/emlai/ivan/pull/3#issuecomment-246200091 --- FeLib/Source/femain.cpp | 61 ---------------------------------------- Main/Source/main.cpp | 3 +- igor/Source/igor.cpp | 2 +- igordj.mak | 2 +- ivandj.mak | 2 +- mihail/Source/mihail.cpp | 2 +- mihaildj.mak | 2 +- 7 files changed, 6 insertions(+), 68 deletions(-) delete mode 100644 FeLib/Source/femain.cpp diff --git a/FeLib/Source/femain.cpp b/FeLib/Source/femain.cpp deleted file mode 100644 index 71607cb28..000000000 --- a/FeLib/Source/femain.cpp +++ /dev/null @@ -1,61 +0,0 @@ -/* - * - * Iter Vehemens ad Necem (IVAN) - * Copyright (C) Timo Kiviluoto - * Released under the GNU General - * Public License - * - * See LICENSING which should be included - * along with this file for more details - * - */ - -#ifdef __DJGPP__ -#include -#include "graphics.h" -#endif - -#ifdef WIN32 -#include -#else -#include -#endif - -#ifdef USE_SDL -#include "SDL.h" -#endif - -#include - -#include "error.h" - -int Main(int, char**); - -int main(int argc, char* argv[]) -{ - /*try - {*/ - return Main(argc, argv); - /*} - catch(...) - { - cchar* Msg = "Fatal Error: Unknown exception thrown."; -#ifdef WIN32 - ShowWindow(GetActiveWindow(), SW_HIDE); - char Buffer[256]; - strcpy(Buffer, Msg); - strcat(Buffer, globalerrorhandler::GetBugMsg()); - MessageBox(NULL, Buffer, "Program aborted!", MB_OK|MB_ICONEXCLAMATION); -#endif -#ifdef UNIX - std::cout << Msg << globalerrorhandler::GetBugMsg() << std::endl; -#endif -#ifdef __DJGPP__ - graphics::DeInit(); - std::cout << Msg << globalerrorhandler::GetBugMsg() << std::endl; -#endif - exit(3); - } - - exit(0);*/ -} diff --git a/Main/Source/main.cpp b/Main/Source/main.cpp index 6e88cc81a..2ea458e2b 100644 --- a/Main/Source/main.cpp +++ b/Main/Source/main.cpp @@ -28,10 +28,9 @@ #include "script.h" #include "message.h" #include "proto.h" - #include "audio.h" -int Main(int argc, char **argv) +int main(int argc, char** argv) { if(argc > 1 && festring(argv[1]) == "--version") { diff --git a/igor/Source/igor.cpp b/igor/Source/igor.cpp index 4adfc65d7..bd69411a9 100644 --- a/igor/Source/igor.cpp +++ b/igor/Source/igor.cpp @@ -14,7 +14,7 @@ #define TILE_SIZE 16 cv2 TILE_V2(TILE_SIZE, TILE_SIZE); -int Main(int, char**) +int main(int, char**) { festring OldDirectory; std::ifstream IConfigFile("igor.cfg"); diff --git a/igordj.mak b/igordj.mak index 6ca383e1b..b0d12961d 100644 --- a/igordj.mak +++ b/igordj.mak @@ -5,7 +5,7 @@ AR = ar rs CC = gxx -o FeLibDIR = FeLib -FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/colorbit.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femain.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o +FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/colorbit.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o IGORDIR = Igor IGORBIN = IGOR.exe IGOROBJ = $(IGORDIR)/Source/igor.o diff --git a/ivandj.mak b/ivandj.mak index c74124937..28e18268f 100644 --- a/ivandj.mak +++ b/ivandj.mak @@ -4,7 +4,7 @@ CC = gxx -o FeLibDIR = FeLib -FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/config.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femain.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/fetime.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/rawbit.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o +FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/config.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/fetime.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/rawbit.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o IVANDIR = Main IVANBIN = IVAN.exe IVANOBJ = $(IVANDIR)/Source/actset.o $(IVANDIR)/Source/areaset.o $(IVANDIR)/Source/charset.o $(IVANDIR)/Source/charsset.o $(IVANDIR)/Source/command.o $(IVANDIR)/Source/coreset.o $(IVANDIR)/Source/dataset.o $(IVANDIR)/Source/dungeon.o $(IVANDIR)/Source/game.o $(IVANDIR)/Source/godset.o $(IVANDIR)/Source/iconf.o $(IVANDIR)/Source/id.o $(IVANDIR)/Source/igraph.o $(IVANDIR)/Source/itemset.o $(IVANDIR)/Source/levelset.o $(IVANDIR)/Source/main.o $(IVANDIR)/Source/materset.o $(IVANDIR)/Source/message.o $(IVANDIR)/Source/object.o $(IVANDIR)/Source/roomset.o $(IVANDIR)/Source/script.o $(IVANDIR)/Source/slotset.o $(IVANDIR)/Source/trapset.o $(IVANDIR)/Source/wmapset.o $(IVANDIR)/Source/wskill.o diff --git a/mihail/Source/mihail.cpp b/mihail/Source/mihail.cpp index f707fd4a8..4bc02c57c 100644 --- a/mihail/Source/mihail.cpp +++ b/mihail/Source/mihail.cpp @@ -21,7 +21,7 @@ truth DebugDraw(festring Filename); int OutputHTML(festring); -int Main(int argc, char** argv) +int main(int argc, char** argv) { if(argc == 3) { diff --git a/mihaildj.mak b/mihaildj.mak index 5b4586cd3..ab0ccfa6b 100644 --- a/mihaildj.mak +++ b/mihaildj.mak @@ -5,7 +5,7 @@ AR = ar rs CC = gxx -o FeLibDIR = FeLib -FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/colorbit.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femain.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o +FeLibOBJ = $(FeLibDIR)/Source/bitmap.o $(FeLibDIR)/Source/colorbit.o $(FeLibDIR)/Source/error.o $(FeLibDIR)/Source/feio.o $(FeLibDIR)/Source/felist.o $(FeLibDIR)/Source/femath.o $(FeLibDIR)/Source/festring.o $(FeLibDIR)/Source/graphics.o $(FeLibDIR)/Source/hscore.o $(FeLibDIR)/Source/save.o $(FeLibDIR)/Source/whandler.o MIHAILDIR = MIHAIL MIHAILBIN = MIHAIL.exe MIHAILOBJ = $(MIHAILDIR)/Source/mihail.o