The MASM Forum Archive 2004 to 2012

General Forums => The Workshop => Topic started by: StarsInTheSky on December 31, 2006, 09:47:01 AM

Title: Porting question
Post by: StarsInTheSky on December 31, 2006, 09:47:01 AM
Ok, noob question,

How hard is it to port windows native code, to one particular linux OS native? Are there any porter software that can do porting on the fly?

How would it be like, if we didnt need windows, installed another OS, and then took any windows binary, ported it to our OS in 5 minutes and used it? Would that ever be possible?
Title: Re: Porting question
Post by: Tedd on January 02, 2007, 01:13:49 PM
That's largely the intention of the WINE project http://www.winehq.org/ - it provides a set of wrapper functions with the windows names which redirect to the appropriate linux functions.

To patch a windows binary so it will work natively under linux is a little more difficult - not least because their binaries are in different formats. Ignoring that problem, it would require replacing the calls to windows' api functions (which is usually done through a table of addresses) with the linux syscalls - in other words square-peg, round-hole :bdg And that's not to mention that you can't usually do a like-for-like replacement.
So, short answer: it's not that simple :P
Title: Re: Porting question
Post by: StarsInTheSky on January 02, 2007, 01:20:42 PM
I'm thinking the same way microsoft sells windows oem with computers, someone should start selling computers with linux and software such as winhq to give an alternative to windows vista very soon.
Title: Re: Porting question
Post by: Cobra on January 04, 2007, 02:46:54 AM
There are some system makers, not many thought, that sell computers with *nix installed. I don't think the large OEMs will offer *nix becuase it's too cumbersome for the majority of PC users. It's not that *nix is hard to learn, because it's not but many people simply won't like it because things are not generally done automatically for them or in just a few clicks as it is in Windows or they get used to doing certain things certain ways. Hence the cumbersome remark.
Title: Re: Porting question
Post by: StarsInTheSky on January 04, 2007, 07:30:21 AM
I think there should be an open source OS for the main stream easy click customers. Opposed to os2 and mac who competed with windows, if it could use windows binary, it would succeed to become a real alternative.
Title: Re: Porting question
Post by: u on January 04, 2007, 03:51:39 PM
It has been around for quite a while : http://www.reactos.org/en/index.html
Title: Re: Porting question
Post by: StarsInTheSky on January 04, 2007, 05:21:56 PM
Cool !

Hope it gets into beta soon, and somehow makes its way to the computer shops :)
Title: Re: Porting question
Post by: stanhebben on January 05, 2007, 05:51:57 PM
If it weren't for my games, I'd be running linux with wine. Wine is a great project, but doesn't run everything.

Linux is currently finding it's way in governments and offices. Half of businesses will switch to Linux (http://www.theinquirer.net/default.aspx?article=36678)

I think vista will be microsoft's greatest mistake ever, and push users towards alternate operating systems, mainly linux. Linux is now also easier to install and use, though there are still problems.