Possible to do a "one-click" spring build?

Possible to do a "one-click" spring build?

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
User avatar
SpliFF
Posts: 1224
Joined: 28 Jul 2008, 06:51

Possible to do a "one-click" spring build?

Post by SpliFF »

I'm building spring through Code::Blocks IDE in Windows rather than the command-line. After I generate a "CodeBlocks - MinGW" project through CMake and open the project I get a long list of make targets. Several of these have names like "install-spring", "install-spring-default" etc and I've been selecting one of these in the build targets dropdown and clicking the "Build" button.

This process creates a spring.exe in my target directory but it doesn't run because of missing files like "fonts/FreeSansBold.ttf". It will find these files if I copy them from another Spring install but is there a way I can create the correct directory structure from CodeBlocks itself? That is: A simple process that gives me a working portable Spring in my build directory without copying content manually or doing a make install in a CMD prompt?

I've tried the targets "install", "install/local", "install-spring" and "install-spring-default". None of these seem to create a working spring "install".

Maybe I have the wrong idea about what these targets are supposed to do, for all I know it's a limitation of codeblocks. Either way an explanation of the purpose behind these "install" targets would be nice.

Note: By "working" I simply mean the ability to get to the pre-game selection menu in spring.exe. Obviously I'll have no maps, mod or lobby until I have a valid data directory.

UPDATE: Nevermind. I just noticed something in my build log that explains everything:

Code: Select all

-- Installing: C:/Program Files (x86)/Spring/.
So I'm running the wrong spring.exe. I should be using the one under Program Files, not the build directory.
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: Possible to do a "one-click" spring build?

Post by abma »

fixed: https://github.com/spring/spring/commit ... 20746a1af3


should be possible now to run it without installing (again).

note: it seems still to partly fail, because some lua files are not found, because spring doesn't search in cont/ for them
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: Possible to do a "one-click" spring build?

Post by abma »

this should completely fix it:

https://github.com/spring/spring/commit ... c2f151774c

but not sure if jk sees problems with my commit i didn't see: https://github.com/spring/spring/commit ... 20746a1af3 for details
Post Reply

Return to “Engine”