User forums > Help

fatal error LNK1104: cannot open file 'game.def'

(1/7) > >>

THE_SUFFERER:
I am trying to compile a gamex86.dll for a 1999 game. My compiler is Microsoft Visual ToolKit 2003.
Firstly the compilation gave me a lot of errors like "cannot open .lib\.h file".
Then after settings all "Linker settings" and "Search directories" they stopped to appear. Now I still have a similar error but this time .def file can't be opened. I don't know what to do cause it's not either .lib or .h, it's a different thing.

LINK : fatal error LNK1104: cannot open file 'game.def' >:(

At the same time I mentioned it in the paths, too, but Code::Block still doesn't want to cooperate with me... :'(

oBFusCATed:
I'd start with the stuff depicted here: http://wiki.codeblocks.org/index.php/FAQ-Compiling_(errors)#Q:_How_do_I_troubleshoot_a_compiler_problem.3F

Do you have a def file? Do you really need to use it? Modern compilers/linkers don't need those, I think, but I might be wrong, because I'm not actively using windows any more.

THE_SUFFERER:
I have read the page you gave me. There's no word about .def file missing, only about .lib, .h and so on.

Well, if my game sdk requires this game.def file, then it's needed for some reason.

oBFusCATed:
The link has generic instructions and some examples.
Have you checked every command C::B executes?
Have you checked that the game.def file is passed to the correct executable and the command line flags are correct? (this is depicted in the link  8) )

And if you don't post the full build log we can't do much. Even if you post it some of the problems can be resolved only by executing some tools (like objdump and nm) on your local files.

THE_SUFFERER:
The fact of the matter is that actually there hasn't to be any necessity to check something in the code itself because what I am compiling wasn't written by me. It's SDK from the game developers. They just gave it to public. So, it should work and all code which is inside is correct.

Moreover, I was doing everything due to the instruction - https://kingpin.info/?p=compiling-with-codeblocks

The problem is the author of the article says he has no errors - just foolow the instruction and compilations goes perfctly. When I try doing the same, I have some problems. Firstly, I had issues with missing .lib and .h files, now I solved it by adding some additional paths. I guess this error (game.def) can be solved with a few mouse clicks, too but I don't know what it can be. Neither does the author himself cause he doens't have an idea why I am dealing with all of this stuff while he isn't...

If you want you can try following that instruction, too, I can give that SDK that contains those .c and .h files for compilation. If it works for you perfectly - the problem is at my side. If you have some troubles, the guide is broken.

Attaching the build log and build messages.

Navigation

[0] Message Index

[#] Next page

Go to full version