Is there a way to compile Windows daily on Linux?

User avatar
yohoho
Member
 
Posts: 13
Joined: Tue Nov 27, 2012 17:47

Is there a way to compile Windows daily on Linux?

by yohoho » Sun Dec 02, 2012 22:42

As the title asks, is there a way to compile the daily unstable for Windows while on Linux? If so could someone give me the instructions? Thank you.
 

User avatar
Leroy
Member
 
Posts: 258
Joined: Thu Oct 18, 2012 23:43

by Leroy » Sun Dec 02, 2012 23:48

The only way is on Wine or VM
UBUNTU BRO!
 

Roflo
Member
 
Posts: 51
Joined: Sun Nov 06, 2011 16:31

by Roflo » Mon Dec 03, 2012 00:37

In theory, you should be able to Cross-Compile.
But it's been ages since I last did that, so I don't think I remember enough to walk you through it.

http://en.wikipedia.org/wiki/Cross_compiler


A quick search returned these 2 results. I gave them a quick glance and they sound right:
http://stackoverflow.com/questions/182408/manual-for-cross-compile-a-c-application-from-linux-to-windows
http://forums.codeblocks.org/index.php?topic=3343.0

And in case you get stuck...
...when I last did it, I downloaded some extras from DJGPP:
http://www.delorie.com/djgpp/

From Delori'es install page (Using Zip-picker):
Using DJGPP as a unix-to-dos cross compiler is tricky. You'll need to get, build, and install binutils and gcc with ./configure --target=i586-pc-msdosdjgpp (install binutils before configuring gcc - gcc needs the cross-assembler). You may need this patch.

djcrx comes with sources for stubify, which you'll have to build and install manually.

So that's the short version:
1. You have to build binutils and gcc (for your target).
1.1. You might need something like the stubify (to get proper W32 binaries).
2. When you have the above, you'll need to specify a --target when compiling.
3. Have fun compiling just about everything (libraries/dependencies).

And do let us know if you managed to do it.
Last edited by Roflo on Mon Dec 03, 2012 00:54, edited 1 time in total.
Unless otherwise specified: I use linux and run (and compile) the latest dev.
 

User avatar
kaeza
Member
 
Posts: 2141
Joined: Thu Oct 18, 2012 05:00
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza

by kaeza » Mon Dec 03, 2012 03:46

Leroy wrote:The only way is on Wine or VM

False. You can also use the mingw32-binutils package (available from your favorite package manager or from the usual MinGW sites).

yohoho, take a look at the CMake docs in particular to the CMAKE_TOOLCHAIN_FILE variable. You should get all the info you need there; if not, just post again. Thanks.
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal | BTC: 1DFZAa5VtNG7Levux4oP6BuUzr1e83pJK2
 

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Mon Dec 03, 2012 16:33

Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 


Return to Minetest General

Who is online

Users browsing this forum: No registered users and 19 guests

cron