Yiv 321 Posted September 23, 2014 Share Posted September 23, 2014 Dear community, I'm actually having some trouble compiling my gamecore. I changed nothing important just added some features (but even without I'm now receiving these errors!) and I get these at compiling on FreeBSD: linking ../game_r126_dev_PET.... linking ../test /usr/lib/crt1.o: In function `_start1': crt1_c.c:(.text+0xa6): undefined reference to `main' /usr/lib/crt1.o: In function `_start1': crt1_c.c:(.text+0xa6): undefined reference to `main' OBJDIR/desc.o: In function `DESC::ProcessOutput()': /eos_src/game/src/desc.cpp:406: undefined reference to `max_bytes_written' /eos_src/game/src/desc.cpp:408: undefined reference to `total_bytes_written' /eos_src/game/src/desc.cpp:409: undefined reference to `current_bytes_written' /eos_src/game/src/desc.cpp:406: undefined reference to `max_bytes_written' OBJDIR/desc.o: In function `DESC::ProcessOutput()': /eos_src/game/src/desc.cpp:406: undefined reference to `max_bytes_written' /eos_src/game/src/desc.cpp:408: undefined reference to `total_bytes_written' /eos_src/game/src/desc.cpp:409: undefined reference to `current_bytes_written' /eos_src/game/src/desc.cpp:406: undefined reference to `max_bytes_written' OBJDIR/event.o: In function `event_process(int)': /eos_src/game/src/event.cpp:135: undefined reference to `ContinueOnFatalError()' OBJDIR/event.o: In function `event_process(int)': /eos_src/game/src/event.cpp:135: undefined reference to `ContinueOnFatalError()' OBJDIR/input.o: In function `CInputProcessor::Pong(DESC*)': /eos_src/game/src/input.cpp:187: undefined reference to `Metin2Server_IsInvalid()' /eos_src/game/src/input.cpp:190: undefined reference to `g_bShutdown' OBJDIR/input.o: In function `CInputProcessor::Pong(DESC*)': /eos_src/game/src/input.cpp:187: undefined reference to `Metin2Server_IsInvalid()' /eos_src/game/src/input.cpp:190: undefined reference OBJDIR/input_auth.o: In function `CInputAuth::LoginOpenID(DESC*, char const*)': /eos_src/game/src/input_auth.cpp:246: undefined reference to `Metin2Server_IsInvalid()' OBJDIR/input_auth.o: In function `CInputAuth::Login(DESC*, char const*)': /eos_src/game/src/input_auth.cpp:115: undefined reference to `Metin2Server_IsInvalid()' to `g_bShutdown' OBJDIR/input_auth.o: In function `CInputAuth::LoginOpenID(DESC*, char const*)': /eos_src/game/src/input_auth.cpp:246: undefined reference to `Metin2Server_IsInvalid()' OBJDIR/input_auth.o: In function `CInputAuth::Login(DESC*, char const*)': /eos_src/game/src/input_auth.cpp:115: undefined reference to `Metin2Server_IsInvalid()' OBJDIR/input_db.o: In function `CInputDB::P2P(char const*)': /eos_src/game/src/input_db.cpp:1356: undefined reference to `main_fdw' OBJDIR/input_db.o: In function `CInputDB::P2P(char const*)': /eos_src/game/src/input_db.cpp:1356: undefined reference to `main_fdw' OBJDIR/marriage.o: In function `marriage::TMarriage::Logout(unsigned int)': /eos_src/game/src/marriage.cpp:299: undefined reference to `g_bShutdown' /eos_src/game/src/marriage.cpp:316: undefined reference to `g_bShutdown' /eos_src/game/src/marriage.cpp:316: undefined reference to `g_bShutdown' OBJDIR/marriage.o: In function `marriage::TMarriage::Logout(unsigned int)': /eos_src/game/src/marriage.cpp:299: undefined reference to `g_bShutdown' /eos_src/game/src/marriage.cpp:316: undefined reference to `g_bShutdown' /eos_src/game/src/marriage.cpp:316: undefined reference to `g_bShutdown' gmake: *** [../test] Error 1 gmake: *** Waiting for unfinished jobs.... gmake: *** [../game_r126_dev_PET] Error 1 I returned my changes and I did them again (step by step always checking if I really did it right!). On windows I can compile without any problems. Someone can help me out? Regards Link to comment Share on other sites More sharing options...
Night 367 Posted September 23, 2014 Share Posted September 23, 2014 those are declared in main.cpp : /eos_src/game/src/desc.cpp:406: undefined reference to `max_bytes_written' /eos_src/game/src/desc.cpp:408: undefined reference to `total_bytes_written' /eos_src/game/src/desc.cpp:409: undefined reference to `current_bytes_written' and Metin2Server_IsInvalid() is a good for nothing function (exept if you are using it for per-complied game core) Link to comment Share on other sites More sharing options...
Yiv 321 Posted September 23, 2014 Author Share Posted September 23, 2014 Well, yeah, those are declared but what should I change? I'm using the Metin2Server_IsInvalid() because I use the variable g_isInvalidServer in an other way Regards Link to comment Share on other sites More sharing options...
Night 367 Posted September 24, 2014 Share Posted September 24, 2014 i dont know where is the problem but i know where it start from /usr/lib/crt1.o: In function `_start1': crt1_c.c:(.text+0xa6): undefined reference to `main' /usr/lib/crt1.o: In function `_start1': crt1_c.c:(.text+0xa6): undefined reference to `main' Link to comment Share on other sites More sharing options...
Yiv 321 Posted September 25, 2014 Author Share Posted September 25, 2014 Well, I know that, too, but I don't know how to fix :S Regards 1 Link to comment Share on other sites More sharing options...
Night 367 Posted September 25, 2014 Share Posted September 25, 2014 well it is a undefained refernce to 'main' i think its makefile error c++ must get the function (main()) to start reading maybe you delete it or something ...... anyway this is how it looks like : MAINOBJ = $(OBJDIR)/main.o MAINCPP = main.cpp Link to comment Share on other sites More sharing options...
Yiv 321 Posted September 25, 2014 Author Share Posted September 25, 2014 Yeah, I already thought about that and I know that. Since there's no compiling error in visual studio (windows) everything's fine with the cpp's. I also checked the Makefile if there's the error but for me it looks okay (compared with some others but nothing important is different just the version management I mean the thing with rXXX). The main.cpp is compiling (I mean I just get the error at the end at linking things and I can see that it's compiled). Regards 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now