Installing and using the SDK

I got the following error:

Error: Setup was started in a non-native or WoW environment.

Please run the setup package that is appropriate for your operating system installation.

Update:
Running a different version of the PSDK, I finished the steps, got the missing windows.h problem, resolved that by importing my VC++ includes and lib directly into the project in Code::Blocks rather than in the general settings, now stalled at a missing Sal.h file and totally stumped on it.

If someone could point me to a Vista-specific guide with working links to the files I need, I would appreciate it. I'm an ok amateur coder but I'm a total dunce when it comes to general computer management stuff, and I'm totally stuck right now :(
 
Here's how Grey Fox solved the sal.h problem...

C:\Program Files\Microsoft SDKs\Windows\v7.0\Include\specstrings.h|11|fatal error C1083: Cannot open include file: 'sal.h': No such file or directory|

I get that when I try to compile in Windows 7, with the SDK for windows7 as the example describes.

Tried to use VS2008 C++ Express but I couldn't find where to change the path to the \Microsoft Visual C++ Toolkit 2003\ which isn't "Program Files" but "Program Files (x86)". But I'd prefer if I could get Code::Blocks working :/

EDIT:
Ok, I just copied the Visual c++ toolkit to Program Files instead and it seems to work now. :P
 
That's not the problem - I checked, and Sal.h actually doesn't exist in my platform SDK.

Ugh. Guess I'll go try and find another one. I think I have a computer in storage with a copy of XP installed that I can get out.

Tried Visual C++ 2008 Express Edition, no luck. Trying a different computer now.
 
For an update, I switched to an XP machine, and followed the instructions in the OP exactly, and it seems to be working. Unfortunately, my (3.5 year old) XP machine is a massive downgrade from my (< 6 month old quad core maxed out) vista machine, so builds are going to take freaking forever relatively speaking, but it seems to be working.

If someone has or writes an up-to-date guide for getting this thing running on either Vista or Windows 7, I would very much like to see it.
 
I'm currently working on porting the SDK into VS 2005 without using c++ toolkit. I have my laptop with VS 2003, but I can't run Civ IV there. My desktop, however, can run Civ IV but I can't install VS 2003 because its on a 64-bit system. So I have a VS 2005 installed there. After tweaking the SDK, removing all the errors, I got the CvGameCore v 3.19 to compile successfully.

Now, the problem comes when I run CivIV where it crashes every time. My question is, does the main "Civ4BeyondSword.exe" have to be compiled under VS 2005 as well? For the meantime I'll try to figure out why the program keeps crashing.
 
you don't need to compile any exe file. The easiest solution to your problem i can think of is to compile on your laptop and transfer the compiled file to your desktop every time you want to test.
 
If anyone had a slow Code::Blocks like me, the fix is easy:
1) Go to Plugins

2) Click on Code completion plugin

3) CLICK DISABLE

:)
 
Are you folks having trouble with the Platform SDK running 64-bit Vista? I just upgraded to 64-bit Windows 7 and had the same issue ('non-native or WoW environment'). There's an AMD64 version on Microsoft's page for the SDK, though, which worked fine. AFAIK, it's exactly the same one apart for being 64-bit.
 
Running a different version of the PSDK, I finished the steps, got the missing windows.h problem, resolved that by importing my VC++ includes and lib directly into the project in Code::Blocks rather than in the general settings, now stalled at a missing Sal.h file and totally stumped on it.

I'm getting this problem - can someone explain to me what he's on about here?
 
This thread is obsolete, it really should be unstickied.

Unfortunately the moderators of this forum don't know much about modding, so despite being asked they have left it up here anyway.

Here is where you should look for directions on how to compile a gamecore:

http://modiki.civfanatics.com/index.php/How_to_Install_the_SDK
 
I actually found this thread quite useful when I started dabbling in SDK merges.

I think it would be better if Kael edited the OP to say that the source is now included in the game though.
 
No, this guide teaches people an obsolete way to compile the SDK. Code Blocks cannot make a debug dll, plus the instructions are hard to follow. Refar's guide is superior in literally every aspect. All this guide does is teach new modders a less efficient, and more complex way of doing things, when there is a viable alternative right there. Also the guide is obsolete, so you have to refer to other guides if you have no idea how to do it and are actually trying to learn. It's like giving somebody directions to a store that's closed down; if you know the store is closed, sure it seems sort of relevant as it might put you in the right area, but if you're unfamiliar with the place you're just liable to get lost.

The fact this thread is stickied does more harm then good.
 
Some people like to use as many free (as in free speech) tools as possible. Visual C++ is free, but not open source. Code::Blocks is open source.
 
And some people, as in myself and those who care about new prospective modders, think that a stickied guide should be up to date, useful, and be apt at showing a new user how to do stuff. This guide is wrong, as in it gives wrong information about where to find the source, and how to set things up; you need a new guide. If you've already compiled a gamecore, then that's fine, but then you wouldn't be using this thread.

Also I don't think open source really matters when we are discussing a compiler, are you really going to dig into the functionality of the assembler :rolleyes:

Further, this guide can't make a debug dll, one of the most useful tools in modding.

So, it doesn't work out of the box, it confuses new modders, and it's not as functional as other guides available. And your only argument is some abstract idea that hinges on the evilness of Microsoft (not necessarily an incorrect premise, just irrelevant as MSV 2008 express is perfectly free and easily downloadable).

Forgive me for not being moved.
 
Oh, I agree that at the very least this thing needs to be updated, but I don't think it is necessary to change it to a Visual Studio focused guide. Perhaps have both guides present (The guide currently in the wiki and an updated C::B guide).

I don't use open source things because they give me the code. I use open source things because I know that no matter I do with it, there is never any possibility of breaking licence terms. While this is not as much of an issue with a mod, since mods generally can't be made commercial due to the game's licence terms, it is a general user philosophy I like to adhere to.
 
No, this guide teaches people an obsolete way to compile the SDK. Code Blocks cannot make a debug dll, plus the instructions are hard to follow. Refar's guide is superior in literally every aspect. All this guide does is teach new modders a less efficient, and more complex way of doing things, when there is a viable alternative right there. Also the guide is obsolete, so you have to refer to other guides if you have no idea how to do it and are actually trying to learn. It's like giving somebody directions to a store that's closed down; if you know the store is closed, sure it seems sort of relevant as it might put you in the right area, but if you're unfamiliar with the place you're just liable to get lost.

The fact this thread is stickied does more harm then good.

The other guides require a makefile however. I'm trying to make a minor change in one .cpp file (CvTeamAI) in a mod called Rhye's and Fall of Civilization, and in order to compile his mod I need a makefile specific to his game. However, he didn't use a makefile (I think it's because he used Visual Studio) and he didn't include the .obj files with the download. Plus, I don't know how to tailor the BTS makefile to RFC, so I'm stuck. Or is there something else out there I don't know about that could solve my problem?

I could download the Visual Studio trial, but I wouldn't know what to do if I got it.
 
Back
Top Bottom