Linked by Thom Holwerda on Wed 20th Feb 2008 00:11 UTC, submitted by irbis
Thread beginning with comment 301698
To view parent comment, click here.
To read all comments associated with this story, please click here.
To view parent comment, click here.
To read all comments associated with this story, please click here.
RE[5]: Comment by merkoth
by Doc Pain on Wed 20th Feb 2008 18:57
in reply to "RE[4]: Comment by merkoth"
I have DOS .exe files, Wind32 and Win16 .exe files and Mono .exe files on my Debian box right now.
When I "just click them" the appropriate thing happens and they run. DOS apps open in DOSBox (I could have used dosemu, too, but dosbox was simpler), Windows apps open via Wine and Mono apps are run with mono.
When I "just click them" the appropriate thing happens and they run. DOS apps open in DOSBox (I could have used dosemu, too, but dosbox was simpler), Windows apps open via Wine and Mono apps are run with mono.
What are OS/2 .exe files run with? :-)
But, if you wanted to spend a few extra minutes you could work out the magic for DOS .exes, too.
Or you simply look at the system's magic database. :-)
RE[6]: Comment by merkoth
by zizban on Wed 20th Feb 2008 19:10
in reply to "RE[5]: Comment by merkoth"
RE[6]: Comment by merkoth
by sorpigal on Wed 20th Feb 2008 19:16
in reply to "RE[5]: Comment by merkoth"







Member since:
2005-11-02
Not necessarily.
Users could have file associations that link .exe files to Wine, so they can run Windows applications by "clicking them". "
I have DOS .exe files, Wind32 and Win16 .exe files and Mono .exe files on my Debian box right now.
When I "just click them" the appropriate thing happens and they run. DOS apps open in DOSBox (I could have used dosemu, too, but dosbox was simpler), Windows apps open via Wine and Mono apps are run with mono.
There's no reason distributions couldn't set this to happen by default and (this is the important bit!) none of it needs to rely on file extension! It only took me ten minutes to learn enough about binfmts to make this work.
Basically it's easy, but accurate detection of DOS exes would require knowing magic I don't care to learn. My answer was to grep .exe files not grabbed by Wine or Mono magic and pass them to a trivial shell script which runs file(1) and decides whether it's DOS or not. But, if you wanted to spend a few extra minutes you could work out the magic for DOS .exes, too.
This really should all be set up by your distribution; It's so trivial I find it offensive that they don't just *do* it.
Edited 2008-02-20 18:10 UTC