Author Topic: fatal error LNK1104: cannot open file 'game.def'  (Read 10564 times)

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #15 on: January 14, 2020, 04:55:51 pm »
Moreover, I was doing everything due to the instruction - https://kingpin.info/?p=compiling-with-codeblocks

No you didn't. The author of that "guide" doesn't seem to know what he is really doing and therefor offers some random try-and-error advices how to fix things because he did them wrong in the first place.

One of these advices is to try different path specifications to that def file. That seems to be the problem in your case, that file is not in the working directory of the compiler which should be the directory of the CodeBlocks project file. Determine the relative path to the def file starting at the directory of the project file and add that to the compiler settings, then it will be found.

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #16 on: January 14, 2020, 05:10:32 pm »
Please paste a full text build log if you still want help.
http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

Tim S.

I am running Code::Blocks version 17.2 on Windows 7 Service Pack1. The compiler I use is Microsoft Visual C++ ToolKit 2003

When I try to create a.dll file following this instruction - https://kingpin.info/?p=compiling-with-codeblocks I have a lot of problems like "Cannot open .h file"\"Cannot open .lib file" and so on. That can be fixed by adding the "include" and "lib" paths of Codeblocks, Toolkit 2003, Platform SDK to the "Linkers", "Searcing Directories" and others.

Nevertheless on the th erros doesn't have any cure. At least I haven't found it. The UBER error is "cannot open .def file". .def isn't .lib, .h etc. So, I don't know how exactly I have to mention it in the settings so that it's found. I tried to add its parth everywhere I could but no happiness was received by me :'(

Build log:
Code
Paste full build log here. (It is found in the 'Build log' tab). Please make always a 'rebuild' (Menu: Build->Rebuild) or a 'clean' and 'build' before you copy the full build log. 

Crash report:
Code

-------------- Build: Release in Gamex86 (compiler: Microsoft Visual C++ Toolkit 2003)---------------

link.exe /dll /nologo /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Source\game.def /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Source\GAME.def /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\MinGW\lib /LIBPATH:"D:\KingpinDev\Code\Platform SDK\Lib" /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\lib /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Source\GAME.def /out:bin\Release\Gamex86.dll Source\NavLib\NavLib.lib user32.lib obj\Release\Source\AI_BITCH.obj obj\Release\Source\ai_bum_sit.obj obj\Release\Source\AI_DOG.obj obj\Release\Source\AI_PUNK.obj obj\Release\Source\AI_RUNT.obj obj\Release\Source\ai_shorty.obj obj\Release\Source\ai_skinny.obj obj\Release\Source\AI_THUG.obj obj\Release\Source\ai_thug_sit.obj obj\Release\Source\AI_WHORE.obj obj\Release\Source\EP_ALL.obj obj\Release\Source\ep_crystalpalace.obj obj\Release\Source\EP_LOG.obj obj\Release\Source\ep_posionville.obj obj\Release\Source\ep_radiocity.obj obj\Release\Source\ep_shipyards.obj obj\Release\Source\ep_skidrow.obj obj\Release\Source\ep_steeltown.obj obj\Release\Source\ep_trainyard.obj obj\Release\Source\G_AI.obj obj\Release\Source\g_ai_ents.obj obj\Release\Source\g_ai_fight.obj obj\Release\Source\g_ai_memory.obj obj\Release\Source\G_CAST.obj obj\Release\Source\G_CHASE.obj obj\Release\Source\G_cmds.obj obj\Release\Source\G_combat.obj obj\Release\Source\G_FOG.obj obj\Release\Source\G_FUNC.obj obj\Release\Source\G_items.obj obj\Release\Source\g_joe_misc.obj obj\Release\Source\G_main.obj obj\Release\Source\G_MISC.obj obj\Release\Source\G_PAWN.obj obj\Release\Source\G_PHYS.obj obj\Release\Source\G_save.obj obj\Release\Source\G_spawn.obj obj\Release\Source\G_SVCMDS.obj obj\Release\Source\G_TARGET.obj obj\Release\Source\g_teamplay.obj obj\Release\Source\g_trigger.obj obj\Release\Source\G_UTILS.obj obj\Release\Source\G_WEAPON.obj obj\Release\Source\M_BBOX.obj obj\Release\Source\M_MOVE.obj obj\Release\Source\P_client.obj obj\Release\Source\P_HUD.obj obj\Release\Source\P_TRAIL.obj obj\Release\Source\P_VIEW.obj obj\Release\Source\P_WEAPON.obj obj\Release\Source\Q_SHARED.obj obj\Release\Source\VEHICLES.obj obj\Release\Source\VOICE.obj obj\Release\Source\voice_bitch.obj obj\Release\Source\voice_punk.obj  D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Gamex86\Source\GAME.def D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Gamex86\Source\GAME.def D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Source\GAME.def
LINK : fatal error LNK1181: cannot open input file 'D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Gamex86\Source\GAME.def'
Process terminated with status 1181 (0 minute(s), 0 second(s))
1 error(s), 0 warning(s) (0 minute(s), 0 second(s))

I have already tried to add this file to all other paths I mentioned in the settings, reinstall CodeBlocks, follow that guide again thinking maybe I did some mistake in the middle or something but nothing works. Life is sad :'(

Offline sodev

  • Regular
  • ***
  • Posts: 497
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #17 on: January 14, 2020, 05:13:55 pm »
Everywhere except the only location that matters: The file is specified as direct linker option, all these search directories settings are pointless.

Go to Linker Settings -> Other linker options and fix the path in the option /def:game.def

Update: You get this new error because you actually broke that linker setting, it now looks like a regular input file for the linker which in fact it is not.
« Last Edit: January 14, 2020, 05:18:06 pm by sodev »

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #18 on: January 14, 2020, 06:10:14 pm »
Everywhere except the only location that matters: The file is specified as direct linker option, all these search directories settings are pointless.

Go to Linker Settings -> Other linker options and fix the path in the option /def:game.def

Update: You get this new error because you actually broke that linker setting, it now looks like a regular input file for the linker which in fact it is not.

Which "Linker Settings"? There are some in "Compiler" and some in "Build Options". Well, I changed them both.

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #19 on: January 14, 2020, 06:11:11 pm »
Everywhere except the only location that matters: The file is specified as direct linker option, all these search directories settings are pointless.

Go to Linker Settings -> Other linker options and fix the path in the option /def:game.def

Update: You get this new error because you actually broke that linker setting, it now looks like a regular input file for the linker which in fact it is not.

And the result is the same ;D

Offline sodev

  • Regular
  • ***
  • Posts: 497
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #20 on: January 14, 2020, 06:36:25 pm »
Stop posting screenshots!
Seriously, this does not only waste storage on the server, these pictures don't get indexed and you cannot quote or copy the text.

As can be seen your command line looks like
Quote
link.exe ... /def:game.def D:\KingpinDev\Code\CodeBlock\CodeBlocks\Projects\Gamex86\Gamex86\Source\GAME.def /def:game.def

So you managed to break your settings even more! You still pass in the def file as regular linker input plus two times as mapping file with the still wrong path. And no, these settings don't go to the global compiler settings unless you want to use this def file for every project you compile...

I have some advice for you, you don't seem to know what you are doing and fail at even the most basic tasks, whatever you are doing, stop it. It won't work. Save yourself and us a lot of pain.

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #21 on: January 14, 2020, 07:33:22 pm »
Well, I kinda need it all. So, stopping won't bring me to success. I cleaned all other paths. Now it's exactly "game.def" that cannot be opened. I guess this is a step to the positive ending.
I can send a screenshot with the "game.def" compilation log, not with that long path but as I understood you didn't like me screens. I still hope you can help me because I am not going to stop. If not this forum, it will be a different one. I have to solve this thing. There's no other option for me.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #22 on: January 14, 2020, 07:39:46 pm »
Well, I kinda need it all. So, stopping won't bring me to success. I cleaned all other paths. Now it's exactly "game.def" that cannot be opened. I guess this is a step to the positive ending.
I can send a screenshot with the "game.def" compilation log, not with that long path but as I understood you didn't like me screens. I still hope you can help me because I am not going to stop. If not this forum, it will be a different one. I have to solve this thing. There's no other option for me.

Why did you tell Code::Blocks to compile or link a def file?

Edit2: Why do you resist copy and pasting the build log?

Tim S.
« Last Edit: January 14, 2020, 07:41:23 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #23 on: January 14, 2020, 07:43:53 pm »
Please copy and paste the build log. You can do this by going to the log tab select all, like you would select a text in the editor, then hit ctrl+C or right mouse button->copy selected text.
Following instructions helps us help you and we can be quicker to help you. Posting 100 screenshots with missing information does not help, and makes everything more agressive and complicated...

As sodev pointed out, you have to add the option
Code
 /def:game.def
to the linker settings. To fix this in this project there is only one place to do this:
Project->Build options->Select your project name at the left->Linker settings->Other linker options->Add
Code
 /def:game.def

You probably have to rebuild your project (Build->Rebuild)

If you still have a problem please post the full build log as text

greetins

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #24 on: January 14, 2020, 07:44:45 pm »
@THE_SUFFERER: Please do the following steps:
1. Restore everything as it was in the beginning of the thread.
2. Do a full rebuild
3. Go to the build log
4. Right click -> copy to clipboard.
5. Paste the result using \[code\] tags in a new post.

Until you do the above we cannot help you and you can only troll you.
Also post a screenshot of Project -> Properties -> Build options -> your target!
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline sodev

  • Regular
  • ***
  • Posts: 497
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #25 on: January 14, 2020, 07:52:54 pm »
Why did you tell Code::Blocks to compile or link a def file?

I am not in a good mood but i try to say it in the most polite way: your first-level-support-like questions don't help here.

As sodev pointed out, you have to add the option
Code
 /def:game.def

As i said multiple times now, that path is wrong! The file must be somewhere else, but i don't want to write something like

Code
/def:my\file\is\here\game.def

because im afraid that will end up as-is in the next screenshots.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #26 on: January 14, 2020, 08:14:36 pm »
sodev:

So you waste your time on the person who seems to do things at random.

If any of you really want to fix the problem; we need a full rebuild log or we can ask the Help Vampire to leave.

I will delete my help since I am not good enough for you.

Won't brother posting a likely good cbp file.

https://github.com/stahta01/KingpinSDK

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #27 on: January 14, 2020, 08:38:07 pm »
I've made the rebuild. The full log is

Code

-------------- Clean: Release in Gamex86 (compiler: Microsoft Visual C++ Toolkit 2003)---------------

Cleaned "Gamex86 - Release"

-------------- Build: Release in Gamex86 (compiler: Microsoft Visual C++ Toolkit 2003)---------------

cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_BITCH.C /Foobj\Release\Source\AI_BITCH.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ai_bum_sit.c /Foobj\Release\Source\ai_bum_sit.obj
AI_BITCH.C
ai_bum_sit.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_DOG.C /Foobj\Release\Source\AI_DOG.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_PUNK.C /Foobj\Release\Source\AI_PUNK.obj
AI_DOG.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_RUNT.C /Foobj\Release\Source\AI_RUNT.obj
AI_PUNK.C
AI_RUNT.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ai_shorty.c /Foobj\Release\Source\ai_shorty.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ai_skinny.c /Foobj\Release\Source\ai_skinny.obj
ai_shorty.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_THUG.C /Foobj\Release\Source\AI_THUG.obj
ai_skinny.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ai_thug_sit.c /Foobj\Release\Source\ai_thug_sit.obj
AI_THUG.C
ai_thug_sit.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\AI_WHORE.C /Foobj\Release\Source\AI_WHORE.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\EP_ALL.C /Foobj\Release\Source\EP_ALL.obj
AI_WHORE.C
EP_ALL.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_crystalpalace.c /Foobj\Release\Source\ep_crystalpalace.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\EP_LOG.C /Foobj\Release\Source\EP_LOG.obj
ep_crystalpalace.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_posionville.c /Foobj\Release\Source\ep_posionville.obj
EP_LOG.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_radiocity.c /Foobj\Release\Source\ep_radiocity.obj
ep_posionville.c
ep_radiocity.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_shipyards.c /Foobj\Release\Source\ep_shipyards.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_skidrow.c /Foobj\Release\Source\ep_skidrow.obj
ep_shipyards.c
ep_skidrow.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_steeltown.c /Foobj\Release\Source\ep_steeltown.obj
ep_steeltown.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\ep_trainyard.c /Foobj\Release\Source\ep_trainyard.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_AI.C /Foobj\Release\Source\G_AI.obj
G_AI.C
ep_trainyard.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_ai_ents.c /Foobj\Release\Source\g_ai_ents.obj
g_ai_ents.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_ai_fight.c /Foobj\Release\Source\g_ai_fight.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_ai_memory.c /Foobj\Release\Source\g_ai_memory.obj
g_ai_fight.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_CAST.C /Foobj\Release\Source\G_CAST.obj
g_ai_memory.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_CHASE.C /Foobj\Release\Source\G_CHASE.obj
G_CAST.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_cmds.c /Foobj\Release\Source\G_cmds.obj
G_CHASE.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_combat.c /Foobj\Release\Source\G_combat.obj
G_cmds.c
G_combat.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_FOG.C /Foobj\Release\Source\G_FOG.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_FUNC.C /Foobj\Release\Source\G_FUNC.obj
G_FOG.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_items.c /Foobj\Release\Source\G_items.obj
G_FUNC.C
G_items.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_joe_misc.c /Foobj\Release\Source\g_joe_misc.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_main.c /Foobj\Release\Source\G_main.obj
G_main.c
g_joe_misc.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_MISC.C /Foobj\Release\Source\G_MISC.obj
G_MISC.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_PAWN.C /Foobj\Release\Source\G_PAWN.obj
G_PAWN.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_PHYS.C /Foobj\Release\Source\G_PHYS.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_save.c /Foobj\Release\Source\G_save.obj
G_PHYS.C
G_save.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_spawn.c /Foobj\Release\Source\G_spawn.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_SVCMDS.C /Foobj\Release\Source\G_SVCMDS.obj
G_spawn.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_TARGET.C /Foobj\Release\Source\G_TARGET.obj
G_SVCMDS.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_teamplay.c /Foobj\Release\Source\g_teamplay.obj
G_TARGET.C
g_teamplay.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\g_trigger.c /Foobj\Release\Source\g_trigger.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_UTILS.C /Foobj\Release\Source\G_UTILS.obj
g_trigger.c
G_UTILS.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\G_WEAPON.C /Foobj\Release\Source\G_WEAPON.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\M_BBOX.C /Foobj\Release\Source\M_BBOX.obj
G_WEAPON.C
M_BBOX.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\M_MOVE.C /Foobj\Release\Source\M_MOVE.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\P_client.c /Foobj\Release\Source\P_client.obj
M_MOVE.C
P_client.c
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\P_HUD.C /Foobj\Release\Source\P_HUD.obj
P_HUD.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\P_TRAIL.C /Foobj\Release\Source\P_TRAIL.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\P_VIEW.C /Foobj\Release\Source\P_VIEW.obj
P_TRAIL.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\P_WEAPON.C /Foobj\Release\Source\P_WEAPON.obj
P_VIEW.C
P_WEAPON.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\Q_SHARED.C /Foobj\Release\Source\Q_SHARED.obj
Q_SHARED.C
Source\Q_SHARED.C(1297) : warning C4013: 'strcasecmp' undefined; assuming extern returning int
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\VEHICLES.C /Foobj\Release\Source\VEHICLES.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\VOICE.C /Foobj\Release\Source\VOICE.obj
VEHICLES.C
VOICE.C
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\voice_bitch.c /Foobj\Release\Source\voice_bitch.obj
cl.exe /nologo  /Ox /Og /W3 /DBUILD_DLL /DNDEBUG  /Ox /W3   /I"D:\KingpinDev\Code\Platform SDK\Include" /ID:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\include /c Source\voice_punk.c /Foobj\Release\Source\voice_punk.obj
voice_bitch.c
link.exe /dll /nologo /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\MinGW\lib /LIBPATH:"D:\KingpinDev\Code\Platform SDK\Lib" /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\lib /out:bin\Release\Gamex86.dll Source\NavLib\NavLib.lib user32.lib obj\Release\Source\AI_BITCH.obj obj\Release\Source\ai_bum_sit.obj obj\Release\Source\AI_DOG.obj obj\Release\Source\AI_PUNK.obj obj\Release\Source\AI_RUNT.obj obj\Release\Source\ai_shorty.obj obj\Release\Source\ai_skinny.obj obj\Release\Source\AI_THUG.obj obj\Release\Source\ai_thug_sit.obj obj\Release\Source\AI_WHORE.obj obj\Release\Source\EP_ALL.obj obj\Release\Source\ep_crystalpalace.obj obj\Release\Source\EP_LOG.obj obj\Release\Source\ep_posionville.obj obj\Release\Source\ep_radiocity.obj obj\Release\Source\ep_shipyards.obj obj\Release\Source\ep_skidrow.obj obj\Release\Source\ep_steeltown.obj obj\Release\Source\ep_trainyard.obj obj\Release\Source\G_AI.obj obj\Release\Source\g_ai_ents.obj obj\Release\Source\g_ai_fight.obj obj\Release\Source\g_ai_memory.obj obj\Release\Source\G_CAST.obj obj\Release\Source\G_CHASE.obj obj\Release\Source\G_cmds.obj obj\Release\Source\G_combat.obj obj\Release\Source\G_FOG.obj obj\Release\Source\G_FUNC.obj obj\Release\Source\G_items.obj obj\Release\Source\g_joe_misc.obj obj\Release\Source\G_main.obj obj\Release\Source\G_MISC.obj obj\Release\Source\G_PAWN.obj obj\Release\Source\G_PHYS.obj obj\Release\Source\G_save.obj obj\Release\Source\G_spawn.obj obj\Release\Source\G_SVCMDS.obj obj\Release\Source\G_TARGET.obj obj\Release\Source\g_teamplay.obj obj\Release\Source\g_trigger.obj obj\Release\Source\G_UTILS.obj obj\Release\Source\G_WEAPON.obj obj\Release\Source\M_BBOX.obj obj\Release\Source\M_MOVE.obj obj\Release\Source\P_client.obj obj\Release\Source\P_HUD.obj obj\Release\Source\P_TRAIL.obj obj\Release\Source\P_VIEW.obj obj\Release\Source\P_WEAPON.obj obj\Release\Source\Q_SHARED.obj obj\Release\Source\VEHICLES.obj obj\Release\Source\VOICE.obj obj\Release\Source\voice_bitch.obj obj\Release\Source\voice_punk.obj  /def:game.def
voice_punk.c
LINK : fatal error LNK1104: cannot open file 'game.def'
LINK : fatal error LNK1141: failure during build of exports file
Process terminated with status 1141 (0 minute(s), 9 second(s))
2 error(s), 1 warning(s) (0 minute(s), 9 second(s))
 


Plus attatching that screen which you asked. By "your target" it was meant to add that "/def:game.def"? Because I didn't find any "targets" in "Build options". Any way adding that didn't help.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #28 on: January 14, 2020, 08:46:19 pm »
Code
/def:Source\game.def

C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline THE_SUFFERER

  • Multiple posting newcomer
  • *
  • Posts: 20
Re: fatal error LNK1104: cannot open file 'game.def'
« Reply #29 on: January 14, 2020, 09:07:59 pm »
After "/def:Source\game.def" I get such an error:

Code

-------------- Build: Release in Gamex86 (compiler: Microsoft Visual C++ Toolkit 2003)---------------

link.exe /dll /nologo /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\MinGW\lib /LIBPATH:"D:\KingpinDev\Code\Platform SDK\Lib" /LIBPATH:D:\KingpinDev\Code\CodeBlock\CodeBlocks\ToolKit\lib /out:bin\Release\Gamex86.dll Source\NavLib\NavLib.lib user32.lib obj\Release\Source\AI_BITCH.obj obj\Release\Source\ai_bum_sit.obj obj\Release\Source\AI_DOG.obj obj\Release\Source\AI_PUNK.obj obj\Release\Source\AI_RUNT.obj obj\Release\Source\ai_shorty.obj obj\Release\Source\ai_skinny.obj obj\Release\Source\AI_THUG.obj obj\Release\Source\ai_thug_sit.obj obj\Release\Source\AI_WHORE.obj obj\Release\Source\EP_ALL.obj obj\Release\Source\ep_crystalpalace.obj obj\Release\Source\EP_LOG.obj obj\Release\Source\ep_posionville.obj obj\Release\Source\ep_radiocity.obj obj\Release\Source\ep_shipyards.obj obj\Release\Source\ep_skidrow.obj obj\Release\Source\ep_steeltown.obj obj\Release\Source\ep_trainyard.obj obj\Release\Source\G_AI.obj obj\Release\Source\g_ai_ents.obj obj\Release\Source\g_ai_fight.obj obj\Release\Source\g_ai_memory.obj obj\Release\Source\G_CAST.obj obj\Release\Source\G_CHASE.obj obj\Release\Source\G_cmds.obj obj\Release\Source\G_combat.obj obj\Release\Source\G_FOG.obj obj\Release\Source\G_FUNC.obj obj\Release\Source\G_items.obj obj\Release\Source\g_joe_misc.obj obj\Release\Source\G_main.obj obj\Release\Source\G_MISC.obj obj\Release\Source\G_PAWN.obj obj\Release\Source\G_PHYS.obj obj\Release\Source\G_save.obj obj\Release\Source\G_spawn.obj obj\Release\Source\G_SVCMDS.obj obj\Release\Source\G_TARGET.obj obj\Release\Source\g_teamplay.obj obj\Release\Source\g_trigger.obj obj\Release\Source\G_UTILS.obj obj\Release\Source\G_WEAPON.obj obj\Release\Source\M_BBOX.obj obj\Release\Source\M_MOVE.obj obj\Release\Source\P_client.obj obj\Release\Source\P_HUD.obj obj\Release\Source\P_TRAIL.obj obj\Release\Source\P_VIEW.obj obj\Release\Source\P_WEAPON.obj obj\Release\Source\Q_SHARED.obj obj\Release\Source\VEHICLES.obj obj\Release\Source\VOICE.obj obj\Release\Source\voice_bitch.obj obj\Release\Source\voice_punk.obj  /def:Source\game.def
   Creating library bin\Release\Gamex86.lib and object bin\Release\Gamex86.exp
Q_SHARED.obj : error LNK2019: unresolved external symbol _strcasecmp referenced in function _Q_stricmp
bin\Release\Gamex86.dll : fatal error LNK1120: 1 unresolved externals
Process terminated with status 1120 (0 minute(s), 0 second(s))
2 error(s), 0 warning(s) (0 minute(s), 0 second(s))