How do I compile AI's for the current release?

How do I compile AI's for the current release?

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
colorblind
Spring Developer
Posts: 374
Joined: 14 Mar 2005, 12:32

How do I compile AI's for the current release?

Post by colorblind »

How do I compile AI's for the current release? If I check out the 0.71b1 branch from SVN and compile my group AI against that with MinGW on Win2k, the regular 0.71b1 release just crashes if I attempt to use the dll.

I'm guessing the release has been compiled with VS7/8, and doesn't like dll's from MinGW. If that is the case, I would like to suggest that future releases be also compiled with MinGW, as that platform is readily available.

But I might be completely wrong. Can someone tell me what the story is?
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

You're right. Because the AI interface is C++ and uses STL, you need to use an ABI compatible compiler and ABI compatible STL. In this case this means use MSVC7, any other compiler will crash spring.

To get something like a sufficient compatible AI interface ever, one needs to make a C only wrapper around it.
colorblind
Spring Developer
Posts: 374
Joined: 14 Mar 2005, 12:32

Post by colorblind »

So what you're telling me is that either

* I have to get MSVC
or
* I have to wait untill someone makes the interface compatible for MinGW

before I can actually enjoy my own groupAI's in-game?
Then plz let some be so kind to fix the latter one, as I'm not too keen on MSVC ...
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Or get the free microsoft enterprise compiler

Or get microsoft VS express 2005 for free

Or compile with gcc for use under linux.

The problem is that things like UnitDef etc are shared by the AI's and the engine rather than duplicated into engine copy and C standardized Interface copy.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

AF wrote:Or get the free microsoft enterprise compiler

Or get microsoft VS express 2005 for free

Or compile with gcc for use under linux.

The problem is that things like UnitDef etc are shared by the AI's and the engine rather than duplicated into engine copy and C standardized Interface copy.
Read my post. That won't work. The problem is C++.

Well, VC 2005 might work, but I've heard they use a different STL, so it could cause crashes anyway.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Krogothe uses vc 2005, it works, you just need an STL hack to gt STL structure to show up correctly in debug
Post Reply

Return to “Engine”