Compiling OpenTTD for Windows

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

Post Reply
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Compiling OpenTTD for Windows

Post by BlackyJack »

Hi,

is there anybody, who knows all the way to successfully compile OpenTTD 1.4.1 for Windows 32bit?

I followed this: https://wiki.openttd.org/Compiling_on_W ... _2008/2010 , but ended with a lot of errors and unable to compile it.


Thanx
User avatar
planetmaker
OpenTTD Developer
OpenTTD Developer
Posts: 9432
Joined: 07 Nov 2007 22:44
Location: Sol d

Re: Compiling OpenTTD for Windows

Post by planetmaker »

I read your error "description" but ended also with a lot of errors: error: no description of the actual problem and errors encountered.

What exactly did you do? which OpenTTD version? Die you patch it? If so: did you try without patch before? Did that work? What *exactly*, word-by-word did you see? Paste the full output here, don't be shy. What did you expect to see instead? How does that output differ?
User avatar
kamnet
Moderator
Moderator
Posts: 8585
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Compiling OpenTTD for Windows

Post by kamnet »

Unless you have a specific need to compile it yourself, there's already a pre-compiled version: http://binaries.openttd.org/releases/1. ... -win32.exe
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

planetmaker wrote:I read your error "description" but ended also with a lot of errors: error: no description of the actual problem and errors encountered.
Ah ah made me laugh :lol:
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

I dowloaded and installed Visual C++ 2010 Express.Installed without SQL server.
Instalation of Microsoft® DirectX SDK - August 2007 or earlier (only needed for DirectX Music, otherwise can be skipped. More later on.), ended with errors: Microsoft XAudio2 - This pre-release version of XAudio2 has expired; please upgrade to the latest version. (2 messageboxes)

Downloaded http://binaries.openttd.org/extra/opent ... .1-win.zip and unpacked to C:\useful\
Downloaded http://binaries.openttd.org/releases/1. ... source.zip and upacked to C:\source

Opened openttd_vs100.sln in Visual.

Next, I should "Go to Tools -> Options, then to Projects and Solutions -> VC++ Directories. Add the following lines:"

But I can't find way to add it to VS2010.

If you try to compile it, it fails, log contains i.e. c:\source\src\language.h(17): fatal error C1083: Cannot open include file: 'unicode/coll.h': No such file or directory.


My goal is to be able to make some changes, but for start I need to be able to compile source as is. I developed some apps in C#: It is more simple to change runable code, than solve compilation problems and set up project by tutorial, that could be out of date.
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

I can give you remote desktop access, I have it on virtual PC to make it "clean". Maybe it would be better than try to describe it.
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

Digitalfox wrote:Did you try to follow?

https://wiki.openttd.org/Compiling_on_W ... ual_Studio
Thanx, I'll try it. It looks like newer tutorial :-)
Eddi
Tycoon
Tycoon
Posts: 8271
Joined: 17 Jan 2007 00:14

Re: Compiling OpenTTD for Windows

Post by Eddi »

this error means it didn't find your unpacked useful.zip
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

Eddi wrote:this error means it didn't find your unpacked useful.zip
Yep and I remember that when I first started to compile in VS2010 2 or 3 years a go it happen to me, I remember being something that 2010 wiki didn't explain properly (at least for someone who wasn't compiling for a while or never even before, it should make things even more helpful), my bad I should had then edited the Wiki :\

But now I'm in VS 2013, so a bit different!
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

So, new problem.

VS 2013

warning MSB8003: Could not find WindowsSDKDir variable from the registry. TargetFrameworkVersion or PlatformToolSet may be set to an invalid version number.

error MSB6006: CL.exe exited with code -1073741515.


Trying to google it...
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

Digitalfox wrote:
Eddi wrote:this error means it didn't find your unpacked useful.zip
Yep and I remember that when I first started to compile in VS2010 2 or 3 years a go it happen to me, I remember being something that 2010 wiki didn't explain properly (at least for someone who wasn't compiling for a while or never even before, it should make things even more helpful), my bad I should had then edited the Wiki :\

But now I'm in VS 2013, so a bit different!
So, can you describe a successfull way to compile it in VS 2013?
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

BlackyJack wrote:
Digitalfox wrote:
Eddi wrote:this error means it didn't find your unpacked useful.zip
Yep and I remember that when I first started to compile in VS2010 2 or 3 years a go it happen to me, I remember being something that 2010 wiki didn't explain properly (at least for someone who wasn't compiling for a while or never even before, it should make things even more helpful), my bad I should had then edited the Wiki :\

But now I'm in VS 2013, so a bit different!
So, can you describe a successfull way to compile it in VS 2013?
Ok, first I only compile nightly builds.

So if you're compiling any 1.4.* versions I can't help you with errors.

Second I don't apply patch's.

Third that wiki page I gave you works if you follow it, but I don't install the SDK (I don't play with sound).

Fourth have you looked at this:

http://helgeklein.com/blog/2010/01/visu ... -variable/
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

Ok, last try on clean Win 7. Which version of VS is working for you?
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

BlackyJack wrote:Ok, last try on clean Win 7. Which version of VS is working for you?
For example VS 2013 Express (it's free).

But don't do the SDK part on the wiki, just first put it to compile properly then if you really want try to install and configure the SDK, take easy steps...
BlackyJack
Engineer
Engineer
Posts: 8
Joined: 06 Jul 2014 23:48

Re: Compiling OpenTTD for Windows

Post by BlackyJack »

Finally!

I goes by this https://wiki.openttd.org/Compiling_on_W ... 2B%2B_2012

Used Win 8
VS 2013 Ultimate
Useful 5.1
Source 4.1
User avatar
Digitalfox
Chief Executive
Chief Executive
Posts: 708
Joined: 28 Oct 2004 04:42
Location: Catch the Fox if you can... Almost 20 years and counting!

Re: Compiling OpenTTD for Windows

Post by Digitalfox »

BlackyJack wrote:Finally!

I goes by this https://wiki.openttd.org/Compiling_on_W ... 2B%2B_2012

Used Win 8
VS 2013 Ultimate
Useful 5.1
Source 4.1
Cool :)
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 16 guests