Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Mon Aug 20, 2018 1:06 am

All times are UTC




Post new topic  Reply to topic  [ 6 posts ] 
Author Message
PostPosted: Sun Apr 15, 2018 9:07 pm 
Offline
Engineer
Engineer
User avatar

Joined: Sat Nov 01, 2014 5:24 am
Posts: 31
Location: São José dos Campos, Brazil
Salutations fellas. In my old Windows 7 computer I had managed to compile OpenTTD using MS Visual C++ 2008. Now I have acquired a new PC with Windows 10 and don't have MS Visual C++ anymore.

I decided it is time to compile OpenTTD with MinGW + MSYS, so I wouldn't depend on MS C++. The only experience I have compiling C/C++ code is from small apps when I learned programming at the university. Nowadays I mostly use Python. So I am pretty much lost in here.

I followed the tutorial at the wiki and after installing the libraries, zlib and lzma weren't found during ./configure of OpenTTD

MSYS messages:
[+] Spoiler
Code:
$ ./configure
checking awk... awk
detecting OS... MINGW
checking build system type... mingw32
checking host system type... mingw32
checking universal build... no
checking build cc... gcc
checking host cc... gcc
checking build c++... g++
checking host c++... g++
checking host windres... windres
checking strip... disabled
checking builtin depend... yes
checking makedepend... disabled
detecting cpu-type... 32 bits
detecting SSE... found
checking static... yes
checking unicode... yes
using debug level... no
using desync debug level... no
using link time optimization... no
checking OSX sysroot... not OSX, skipping
checking allegro... not found
checking sdl... not found
checking COCOA... not OSX, skipping
checking GDI video driver... found
checking dedicated... not selected
checking console application... disabled (only used when forced)
checking network... found
checking squirrel... found
checking translator... no
checking assert... enabled
checking zlib... not found
checking liblzma... not found
WARNING: lzma was not detected or disabled
WARNING: OpenTTD doesn't require lzma, but it does mean that many features
WARNING: (like loading most savegames/scenarios and joining most servers)
WARNING: will be disabled.
 If you want to compile without lzma use --without-lzma as parameter


While trying to search for a solution (haven't got anywhere) I've also stumbled upon MinGW-w64 fork.

Basically I have three questions:
1. What is the most up-to-date software to compile OpenTTD for Windows 10 (x64)? Is it MinGW-w64?

2. Assuming MinGW being used (and considering the attached code), how can I solve the 'not found' libraries issue? I checked in C:\MinGW\bin folder and they are there.

3. Should I still be using MSYS?


Top
   
PostPosted: Sun Apr 15, 2018 11:23 pm 
Offline
Director
Director
User avatar

Joined: Wed Dec 10, 2008 4:08 pm
Posts: 550
Location: tile 0x0000
Check out MSYS2

I managed to compile with that.

Or make dual-boot with Linux Mint.
And develop on Linux.

_________________
Chunnel , Distance between ships , Playing with Heightmaps , Signals tunnel , Waypoint air , Everest , Tunnel end


Top
   
PostPosted: Wed Apr 18, 2018 3:56 am 
Offline
Engineer
Engineer
User avatar

Joined: Sat Nov 01, 2014 5:24 am
Posts: 31
Location: São José dos Campos, Brazil
Awwwyeah, got something HackaLittleBit. It took me a while (as wasn't just as straightforward as installing MSYS2 and running the compiling tutorial), but using the MSYS2 MinGW 64-bit Shell (mingw64.exe) I have managed to compile with almost all except liblzo2, which I think does not have the 64-bit version (
Quote:
pacman -S mingw-w64-x86_64-lzo2
didn't work, but
Quote:
pacman -S mingw-w64-{i686,x86_64}-lzo2
did).

I will try to compile the 32-bit version tomorrow, but I must ask:

Is my conclusion over liblzo2 not being able to be compiled under 64-bit version correct?


Top
   
PostPosted: Wed Apr 18, 2018 7:29 am 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Sun Sep 09, 2007 5:03 am
Posts: 4656
Location: home
fwiw, my linux system says
Code:
$ file /usr/lib64/liblzo2.so.2.0.0
/usr/lib64/liblzo2.so.2.0.0: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=25978afab54c3ac11d456243a56076f995e27e7e, stripped
So it seems I have a compiled 64 bit lzo2 library.

_________________
Being a OpenTTD developer does not mean I know what I am doing.
Also, other OpenTTD developers may have different opinions.


Top
   
PostPosted: Wed Apr 18, 2018 9:48 pm 
Offline
Director
Director
User avatar

Joined: Wed Dec 10, 2008 4:08 pm
Posts: 550
Location: tile 0x0000
GuilhermeJK wrote:
Is my conclusion over liblzo2 not being able to be compiled under 64-bit version correct?


If I remember correct, I also was not able to compile that one.
So I switched to 32bit
The program was written by Oberhumer (possible member ottd)

_________________
Chunnel , Distance between ships , Playing with Heightmaps , Signals tunnel , Waypoint air , Everest , Tunnel end


Top
   
PostPosted: Sun Apr 29, 2018 2:37 pm 
Offline
Transport Coordinator
Transport Coordinator
User avatar

Joined: Wed Jan 08, 2003 11:09 pm
Posts: 371
Location: Denmark
For compiling on Windows, you should probably get MS Visual Studio 2017 Community Edition. It's a full version, free of charge for hobby and open source work.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000-2018 phpBB Limited

Copyright © Owen Rudge/The Transport Tycoon Forums 2001-2018.
Hosted by Zernebok Hosting.