How to compile the DLL

One of the warnings when building the latest source (which whizzes up the screen) is

"module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance"

Right click the project, select Properties and change the setting as shown to remove this
 

Attachments

  • ltcg.jpg
    ltcg.jpg
    56 KB · Views: 205
How to compile the BNK SDK with VS2012?

At a guess the same way as you do for VS2008/VS2010 (as Firaxis supply the project config files for VS2012, and fixed the major issues in the last patch with the project config files for VS2010)

If it's not compiling/building for you, we're going to need specific error messages.
 
At a guess the same way as you do for VS2008/VS2010 (as Firaxis supply the project config files for VS2012, and fixed the major issues in the last patch with the project config files for VS2010)

If it's not compiling/building for you, we're going to need specific error messages.

You need VS 2008 installed to have the toolset needed to compile the project (which is a 2008 VC++ project regardless of the solution).
 
IMHO impossible ... as it's impossible to define "bug fix".

Look at CivUP, a lot of stuff in there was/is "bug fixes" ... but only if you believe the "feature" to be broken in the first place, which in a strategy game with players of very different skill levels will always be subjective. One player's "bug fix" will usually be another player's "bug"

I don't see a problem with all or most DLL modders sharing a single project on an open source site, provided we all make any functional changes (i.e., changes beyond just creating a new event) able to be toggled on or off via the DB or LUA so other modders can control whether they want to use each individual change or not at run time.
 
Do the source files in CvGameCoreDLL and CvGameCoreDLL_Expansion1 have any effect if there's a same-name source file in CvGameCoreDLL_Expansion2?

Basically, which of the three folders should I be making changes to? Do I need to modify them all?
 
Only the files from the folder you want to compile. (CvGameCoreDLL = vanilla civ5, CvGameCoreDLL_Expansion1 = G+K, CvGameCoreDLL_Expansion2 = BNW)

If your making a DLL for G+K, make your change in CvGameCoreDLL_Expansion1.

If later you want to make a DLL for BNW, any feature you've added in your G+K's DLL will have to be ported in the files in CvGameCoreDLL_Expansion2.

13.
Find the new DLL in "CvGameCoreSource\BuildOutput". Add it to the root directory of your mod, and set the "Import into VFS" property to true.

BTW, now you can (must ?) use "OnGetDLLPath/SetDLLPatch" action, your DLL can then have any name and the "Import into VFS" property set to true is not needed.
 
BTW, now you can (must ?) use "OnGetDLLPath/SetDLLPatch" action, your DLL can then have any name and the "Import into VFS" property set to true is not needed.

It's probably a good idea to use the DLLPath settings but you don't have to, the old VFS way still works.
 
BTW, now you can use "OnGetDLLPath/SetDLLPatch" action, your DLL can then have any name and the "Import into VFS" property set to true is not needed.

How does it differentiate which DLL is for Vanilla, G&K or BNW - or does this only work for one DLL in a mod?
 
How does it differentiate which DLL is for Vanilla, G&K or BNW - or does this only work for one DLL in a mod?

Only one DLL in a mod set this way. That DLL will be loaded whatever expansion is used.

So, good for total conversion, but yeah, the VFS = true method is still the only way for one mod including DLLs for each version of the game.
 
What happens if a mod loads a BNW DLL into an install that doesn't have BNW? Surely there are missing functions or extra function calls that will cause crashes?

It would. But the mod should be setting the correct "dependant on" associations to avoid this situation
 
What happens if a mod loads a BNW DLL into an install that doesn't have BNW? Surely there are missing functions or extra function calls that will cause crashes?

It crashes, but from missing tables/entries in the Database IIRC.
The .exe and all other DLL are common to all versions of the game.
 
It crashes, but from missing tables/entries in the Database IIRC.
The .exe and all other DLL are common to all versions of the game.

The game core API (both in methods available and signatures) differ across all three versions
 
The game core API (both in methods available and signatures) differ across all three versions

oh, my bad :o

But now I'm curious, how does it works ?
 
You need VS 2008 installed to have the toolset needed to compile the project (which is a 2008 VC++ project regardless of the solution).

Anyone have specifics regarding the required toolset and the dependency for a successful compilation? Seems that fresh install of VS2010 or VS2012 should be able to do the job with at most an add-on tool install. Guess I just don't like having to install an older VS just to get the newer VS to work properly. Additionally, to read that the installation order matters [Thanks whoward] just seems ridiculous though not shocking considering it's from MS. So far in my software development life I've managed to stay away from having to use VS and be thrust into MS's version of common sense. ;)
 
Anyone have specifics regarding the required toolset and the dependency for a successful compilation? Seems that fresh install of VS2010 or VS2012 should be able to do the job with at most an add-on tool install. Guess I just don't like having to install an older VS just to get the newer VS to work properly. Additionally, to read that the installation order matters [Thanks whoward] just seems ridiculous though not shocking considering it's from MS. So far in my software development life I've managed to stay away from having to use VS and be thrust into MS's version of common sense. ;)

The actual c++ project is a VC2008 vcxproj file, even though there are solutions for VS 2008, 2010, and 2012 (the 2012 one works in 2013 as well). So you need the VC2008 toolchain to compile it.
 
Top Bottom