You are not logged in.

#1 2009-10-31 06:47:02

unregistered
Member
Registered: 2008-04-09
Posts: 134

programming windows programs in arch linux

Language used is C/C++ so I would need to include <windows.h>, what tools do I install to program and test such programs?
Any help appreciated.

Offline

#2 2009-10-31 07:18:23

namegame
Member
Registered: 2008-07-29
Posts: 31

Re: programming windows programs in arch linux

You'd probably need to look into the mingw cross compiler

Offline

#3 2009-10-31 08:29:50

wu.soldier
Member
From: Poland
Registered: 2006-12-19
Posts: 22

Re: programming windows programs in arch linux

I've never tried windows programming under Linux, but I think you could try using native windows mingw (try Dev-C++) under Wine.

Offline

#4 2009-10-31 08:54:11

jac
Member
From: /home/jac
Registered: 2009-05-19
Posts: 431
Website

Re: programming windows programs in arch linux

I never really did much with it, but the last time I did anything like this I followed the tutorial on the Code::Blocks wiki. It's here:
http://wiki.codeblocks.org/index.php?ti … _Compilers
From looking at it, it is really outdated. I followed it a year or two ago, on Ubuntu. I'm pretty sure it worked OK though. It looks like it sums up to "Install MinGW and use it and its headers and libs in place of your current compiler and its stuff" I've never included windows.h, so I have no idea where you would get that from, or why you even need it.

Offline

#5 2009-10-31 12:06:03

Lich
Member
Registered: 2009-09-13
Posts: 437

Re: programming windows programs in arch linux

I suggest that you make a virtual machine and install Windows in that. If your apps need to be for Windows, and not crossplatform necesarelly, then this would be the best and way to do it (It's what I do anyway, and has served me good)


Archlinux | ratpoison + evilwm | urxvtc | tmux

Offline

#6 2009-10-31 14:39:36

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: programming windows programs in arch linux

Lich wrote:

I suggest that you make a virtual machine and install Windows in that. If your apps need to be for Windows, and not crossplatform necesarelly, then this would be the best and way to do it (It's what I do anyway, and has served me good)

+1 to that. My tool of choice for virtualization is VirtualBox wink


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#7 2009-10-31 16:21:42

Ranguvar
Member
Registered: 2008-08-12
Posts: 2,549

Re: programming windows programs in arch linux

MinGW is what you want.  Works great, and then you can test with Wine smile

Offline

#8 2009-10-31 20:13:16

wuischke
Member
From: Suisse Romande
Registered: 2007-01-06
Posts: 630

Re: programming windows programs in arch linux

MinGW is what you want.  Works great, and then you can test with Wine

I've done this (added mingw builds and wine tests to my development process for a cross-plattform app) and you should be aware of limitations. Your app might run fine on wine, but crash horribly when running on a real windows. (Or just not work as intended.)

My recommendation: Get yourself a vm and install a evaluation copy of server 2008 (/7/vista) on it (free Windows for ~ half a year! ;-) ), install VS express and make sure it runs on windows and builds on VS without warnings regularly. In my experience the best way to make sure your code actually works on Windows.

I usually test it on Solaris and OpenBSD, too, but hopefully you won't have to entertain such a diverse ecosystem. (IRIX will do things again a bit different, but then almost nobody uses it anymore. I fortunately never encountered HP-UX and similar.)

Offline

#9 2009-10-31 23:07:38

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: programming windows programs in arch linux

Question: do you need to take advantage of Windows extensions?  It may/probably will make your job simpler if you write portable code to begin with, so you don't have to jump through hoops to compile it on Linux.  For that matter, if you're writing Windows-specific apps, why would you use Linux in the first place?

Just wondering.

Offline

#10 2009-10-31 23:09:47

Ranguvar
Member
Registered: 2008-08-12
Posts: 2,549

Re: programming windows programs in arch linux

I'd still test on Wine anyways, so just in case other GNU/Linux aficionado later gets hold of your app, they'll have success using Wine with it wink
And, since MinGW/Wine is faster development-wise than even a VM, you might just want to do that and test under Real Windows(TM) only every few weeks or whatever -- would like to here your experiences if you choose this, as to how good Wine actually is in its implementation and how often you had to fix stuff for Windows, etc. smile

Offline

Board footer

Powered by FluxBB