Error building Release dll in VS express 2015 - need help

Moderators: GSH, VSMIT, Red Devil, Commando

User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Error building Release dll in VS express 2015 - need help

Post by coxxon »

Okay my dll coding has hit a snag. I’m using VS express 2015, and when I got the isdf14.dll to work, I built it for Debug. Then I just took the “d” out of the dll name, and ran the file in the game. It worked, even after making multiple revisions.

Now though, I can’t seem to get other rebuilt dlls to work with this method; even for simple things like changing the amount of player starting scrap. It’s as if the mission is ignoring my dll.

All I can figure is that my first success was a fluke, and that building as a Debug and fixing the filename isn’t the right way to go. ?

BUT, when I try to build a dll as a Release (for x86), I get the below error in every dll I’ve tried to rebuild:
Severity: Error
Code: LNK1117
Description: syntax error in option 'pdbpath:none'
Project: scion07
File: C:\StoredMisc\bzII patch-2012\BZ2 1.3b89 Dll Source Code\Missions\scion07\LINK
Line: 1

Line 1 of text is:
#include "..\Shared\SPMission.h"

SPMission.h is listed in the “External Dependencies” list of files in the Solution Explorer panel. Nor does anything appear wrong with how its written, so I figure it's more than just a simple syntax error.

So, my questions be:
1 – A - Are you supposed to build as debug and then change the dll name (which sounds strange anyway)?
B - And if so, then why aren’t simple changes (player starting scrap) working?
2 – Are there any additional things I’m supposed to set on the files to get a Release build to work so the above error doesn’t occur?
Beyond what Nate put in the readme, which I assume I followed correctly.
User avatar
Red Devil
Recycler
Posts: 4398
Joined: Fri Feb 18, 2011 5:10 pm
Location: High in the Rocky Mountains

Re: Error building Release dll in VS express 2015 - need help

Post by Red Devil »

do you select Release in the pulldown up at the top?

not using VS 2015 here.

Did you set the debug database directories and name in the Linker section? (Linker/Debugging)
If given the truth, the people can be depended upon to meet any national crisis. The great point is to bring them the real facts - and beer.
Abraham Lincoln

Battlestrat, FE, G66, In The Shadows, Starfleet, Uler, & ZTV

Lifetime member of JBS and NRA
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

Yes, Release and Debug are in a dropdown list to choose from.
I rebuilt on Debug setting. I then noticed that I was receiving the following two warnings, which mention the Linker.
I also don’t see any Linker/Debugging option on my main screen. Is there some other way to access it?

1--------------------------
TargetPath(C:\StoredMisc\bzII patch-2012\BZ2 1.3b89 Dll Source Code\Missions\scion07\..\..\Debug\missions\scion07.dll) does not match the Linker's OutputFile property value (C:\StoredMisc\bzII patch-2012\BZ2 1.3b89 Dll Source Code\Debug\missions\scion07d.dll). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
2 ---------------------------
TargetName(scion07) does not match the Linker's OutputFile property value (scion07d). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
-----------------------------

Now I gotta run off and get shot ..er get a shot.
User avatar
GSH
Patch Creator
Posts: 2485
Joined: Fri Feb 18, 2011 4:55 pm
Location: USA
Contact:

Re: Error building Release dll in VS express 2015 - need help

Post by GSH »

You may need to disable that option if using VS2012 (2010?) or higher. Look under the advanced settings for the linker, in the text box where you can enter text.

I don't recommend using other VS versions arbitrarily -- the runtime may not be installed on everyone's box. I'd stick to Visual 2005 or 2008 for anything released for 1.3.6.5 -- those two runtimes are installed by the 1.3.6.x installer. And if you're in the private betas, what I'm using these days should be more obvious.

-- GSH
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

GSH wrote:You may need to disable that option if using VS2012 (2010?) or higher. Look under the advanced settings for the linker, in the text box where you can enter text.
I don't recommend using other VS versions arbitrarily -- the runtime may not be installed on everyone's box. I'd stick to Visual 2005 or 2008 for anything released for 1.3.6.5 -- those two runtimes are installed by the 1.3.6.x installer. And if you're in the private betas, what I'm using these days should be more obvious.
-- GSH
Is there any way to get a hold of a legal VS2008, for free?
Amazon has 2 copies each for ~$900 and Ebay, is still over a hundred.
User avatar
GSH
Patch Creator
Posts: 2485
Joined: Fri Feb 18, 2011 4:55 pm
Location: USA
Contact:

Re: Error building Release dll in VS express 2015 - need help

Post by GSH »

VS2008 Express is probably somewhere hidden on MS's servers. Try the links mentioned in this question

You do not need VS2008 Standard/Pro. Express has enough stuff to make BZ2's DLLs.

-- GSH
User avatar
General BlackDragon
Flying Mauler
Posts: 2408
Joined: Sat Feb 19, 2011 6:37 am
Contact:

Re: Error building Release dll in VS express 2015 - need help

Post by General BlackDragon »

VS 2008 here: viewtopic.php?f=4&t=2355&p=40617&hilit= ... dio#p40737

1: Yes, you need to build using "Release" or "ReleaseEditor" (both if u want the DLL to work in BZ2Edit.exe)
2: Make sure the properties > output directory has a folder in it named "Redist". Don't ask me why VS needs this, it just does.

3: Get with me on Skype if u need further help.
Battlezone Classic Public Forums
*****General BlackDragon*****
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

Red Devil wrote:do you select Release in the pulldown up at the top?
not using VS 2015 here.
Did you set the debug database directories and name in the Linker section? (Linker/Debugging)
Okay, found the Linker stuff. I just needed to do some more Rt-clicking on the particular files. :) I didn't change anything though. I believe it is still properly set up.
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

GSH wrote:VS2008 Express is probably somewhere hidden on MS's servers. Try the links mentioned in this question
You do not need VS2008 Standard/Pro. Express has enough stuff to make BZ2's DLLs.
-- GSH
Thanks, got it, tried it, seems to work, but now if I can figure out how to get it show me an actual error window.
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

General BlackDragon wrote:VS 2008 here: viewtopic.php?f=4&t=2355&p=40617&hilit= ... dio#p40737
1: Yes, you need to build using "Release" or "ReleaseEditor" (both if u want the DLL to work in BZ2Edit.exe)
2: Make sure the properties > output directory has a folder in it named "Redist". Don't ask me why VS needs this, it just does.
3: Get with me on Skype if u need further help.
Yup, that definitely helps to know. I added in the Redist folder, which stopped the Release error.
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

And after all of the above, I also seemed to need to add an actual "mission" folder in my addon folder for the campaign mission dll to work. So after all of that the re-edited dll worked in game.
I tentatively hope this means all is back on track again. But I'm still amateur programmer, and know even less about the workings of VS, so I may be back with more cries of woe and whoa.
Thanks all
User avatar
Red Devil
Recycler
Posts: 4398
Joined: Fri Feb 18, 2011 5:10 pm
Location: High in the Rocky Mountains

Re: Error building Release dll in VS express 2015 - need help

Post by Red Devil »

coxxon wrote:
GSH wrote:VS2008 Express is probably somewhere hidden on MS's servers. Try the links mentioned in this question
You do not need VS2008 Standard/Pro. Express has enough stuff to make BZ2's DLLs.
-- GSH
Thanks, got it, tried it, seems to work, but now if I can figure out how to get it show me an actual error window.
the build errors, after you click on Build/Build <ProjectName>?

if so, in Tools/Options/Projects and Solutions/General, select Show Output window when build starts.
If given the truth, the people can be depended upon to meet any national crisis. The great point is to bring them the real facts - and beer.
Abraham Lincoln

Battlestrat, FE, G66, In The Shadows, Starfleet, Uler, & ZTV

Lifetime member of JBS and NRA
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

Red Devil wrote:the build errors, after you click on Build/Build <ProjectName>?if so, in Tools/Options/Projects and Solutions/General, select Show Output window when build starts.
Thanks. Actually I was already getting an output window, and in options I did find an 'always show error list ...' so I turned that on.
It did show an (intended) error in the output window. Though I guess I've been spoiled by VS2015 which has a separate error window which is easier to read.
User avatar
General BlackDragon
Flying Mauler
Posts: 2408
Joined: Sat Feb 19, 2011 6:37 am
Contact:

Re: Error building Release dll in VS express 2015 - need help

Post by General BlackDragon »

Intended error? !?

Blasphamy!
Battlezone Classic Public Forums
*****General BlackDragon*****
User avatar
coxxon
Sabre
Posts: 210
Joined: Wed Jul 27, 2011 1:57 pm
Location: North Carolina

Re: Error building Release dll in VS express 2015 - need help

Post by coxxon »

General BlackDragon wrote:Intended error? !? Blasphamy!
Yup, but ya need a little blasphemy every now and then. :twisted: Plus it was the only way to see what kind of error response VS8 would give me. ;)
Post Reply