CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.1k stars 4.1k forks source link

Windows builds broken #1856

Closed NaturesWitness closed 11 years ago

NaturesWitness commented 11 years ago

Trying to compile in cobeblocks Item_factory.cpp undefined reference to 'libintl_gettext' I installed gettext already and I can't even figure out where cata is calling for it in the first place, it occurs NOWHERE in cata's code. I'm stumped here help a newb plz!

l0master commented 11 years ago

Yeah, haven't been able to compile under MinGW since fire fixes some two days ago. Dear God, please make the next build successfuly compile. Amen.

yobbobanana commented 11 years ago

gettext is included from the new "translations.h" header, and called using the new "_" alias (for example in main_menu.cpp and disease.cpp). I know it's been compiled successfully with Cygwin, MinGW and VS2012... but i have no idea how... For example #1836.

The wiki could really use some updated build instructions if anyone knows exactly what's necessary.

btw for codeblocks, there's an unmerged commit that might be relevant in #1833.

NaturesWitness commented 11 years ago

Finally got this working again I think didn't I have gettext set up right. Mostly I just flung the files for gettext and SDL anywhere I could think of ;) Here's some links I found that helped. http://www.learncpp.com/cpp-tutorial/a3-using-libraries-with-codeblocks/ http://smf.cataclysmdda.com/index.php?topic=2122.msg26790#msg26790

Hope this helps everyone I'm still not sure what I did to fix it so I can't really describe it.
I think it was the instructions in the learn c++ link though.

l0master commented 11 years ago

NatureWitness, it would be more helpful if you posted links to the libraries you flung.

NaturesWitness commented 11 years ago

D'oh sorry about that. Link for gettext is http://ftp.gnome.org/pub/gnome/binaries/win32/dependencies/ Get the gettext runtime and the gettext runtime dev (I went with version 17-1) Put libintl.dll in your folder with cataclysm.exe. Look at the learn c++ link for instructions on the other files, it describes what to do better than I can.

Hope this helps some people avoid the major headache I got figuring this out, I get the feeling a lot of the big cata coders overestimate the programming knowledge of a lot of us newbs who are just getting into this kind of thing for the first time ;)

yobbobanana commented 11 years ago

Personally my knowledge is null when it comes to compiling on windows. I've been hoping some helpful person would update the wiki with however they got it to work.

Guess I'll open an issue for that.

~~> #1892

l0master commented 11 years ago

My mingw ain't got no "compiler settings" so i'm at a loss here. Simply stuffing libs kindly provided by NatureWitness into my MinGw libs folder didn't help.

NaturesWitness commented 11 years ago

And it quit working again, now it's something about autopickup. I can't deal with this, I'm going to wait until someone else figures this I out before I do anymore coding. This is so depressing :(

l0master commented 11 years ago

Ok, i've switched from Mingw to Code::Blocks and it compiles just fine now. NatureWitness i suggest you do the same.

NaturesWitness commented 11 years ago

I am using codeblocks, still can't make it work. I may try uninstalling everything and starting from scratch, maybe I've screwed up my install somewhere. Thanks for saying you got it working in CB, gives me a little hope :)

l0master commented 11 years ago

Check this thread, especialy guidlines by Musu http://smf.cataclysmdda.com/index.php?topic=2141.0 That's what helped me

NaturesWitness commented 11 years ago

Why can't I make this work?? I've tried downloading libintl, i've tried downloading gettext, i've pointed codeblocks to to the libs and the headers, and it just won't work. I get a huge pile of undefined reference errors every time. If I can't get this working soon, I think I'm going to have a nervous breakdown :(

NaturesWitness commented 11 years ago

Okay some progress, downloaded the entire gettext thing from here
http://gnuwin32.sourceforge.net/packages/gettext.htm

Installed it, copied EVERYTHING in it and dumped it into the MinGW folder.

That seemed to reduce the number of errors from like a gazillion to six, all the same one. obj\Release\action.o:action.cpp|| undefined reference to _imp__libintl_gettext'| obj\Release\action.o:action.cpp|| undefined reference to_implibintl_gettext'| obj\Release\action.o:action.cpp|| undefined reference to `_implibintl_gettext'| obj\Release\action.o:action.cpp|| undefined reference to_imp__libintl_gettext'| obj\Release\action.o:action.cpp|| undefined reference to_implibintl_gettext'| obj\Release\action.o:action.cpp|| more undefined references to`_implibintl_gettext' follow| ||=== Build finished: 6 errors, 0 warnings (0 minutes, 1 seconds) ===|

I have no idea what I'm doing anymore, can someone clue me in?? What is a `_imp__libintl_gettext'| anyway, and why does it hate me so?