Why do you still program for DOS?

DOS specific questions.
xlucas
Posts: 334
Joined: May 09, 2014 21:19
Location: Argentina

Why do you still program for DOS?

Post by xlucas »

I am still interested in programming for DOS and if you're reading this thread, odds are that you are too. I am not surprised as, like I say, I do too, but I'm interested in knowing what makes you choose to program for DOS today and why you like it, because sometimes I ask myself that question too.

When I ask myself what desirable feature DOS has that new OSs do not, I can think of a few objective answers: direct access to hardware, independence (you don't have to be updating it or depending on the internet or 3rd party software), effectiveness (it's fast and simple as opposed to bloated). Do you see these same features as desirable? Do you have a different set of them?

Maybe you don't really like DOS that much, but you're required to supported because you need to make some very old software work in maybe some very old computer. Is that the case? Not mine, but could be yours.

The most confusing question I have in my mind is what really defines DOS. Say you take something that is clearly DOS, for example, you take a copy of FreeDOS 1.2 or maybe MS-DOS 6.22. Then, as many people do, you may feel it has some obsolete characteristics, that it can't be used so comfortably, it's incompatible with new hardware or whatever, so you want to make something modern, new, that is still DOS. Problem is, which features can you change so it will still be DOS? Does the command line intefrace have to be the same? Does the API (int 21h and others) have to operate the same way? Are even external things such as the BIOS interrupts and the segmented memory system of real mode Intel processors a part, in a way, of what we call DOS, or is it possible to separate them and still keep the name? Would a protected mode 32-bit DOS be DOS?

Anyway, this is mostly philosophy. No definite true can be obtained from answering these questions, but maybe we have to try to answer them if we love DOS and still have some future expectations for it. What do you guys think?

DOS haters, please refrain to comment :)
dasyar
Posts: 372
Joined: Dec 04, 2008 15:31

Re: Why do you still program for DOS?

Post by dasyar »

I don't. My curiosity about DOS was because of FreeBasic.

I have used Freebasic in Windows 10 and Linux, so far a Linux version combined with my favorite IDE, Geany, has been the best experience. So, I decided to see for myself how a DOS experience, running FreeBasic, would be.

First hurdle was remembering how DOS, FreeDOS, in my case, was supposed to work. Once you get past that, and get a FreeBasic installed, things started to get more familiar. My biggest surprise was the FreeDOS version of Edit. It is a very powerful editor considering it is a character based UI. Now, if there was an Edit program in a GUI format, and maybe include a FreeBasic plugin, …

Since I have been around since the DOS days, I was thinking what made me switch from a command line experience to a GUI experience, Windows. Maybe another question could be, would you be programming in DOS if it had a GUI front end. Since a lot of people keep referring to Linux, Linux is a kernel which is a command line format, just like DOS. Another interesting question, how many people program in the Linux command line setting.

At present the biggest draw back for DOS is 16bit, and the amount of memory it has available for a program size. That is strictly my observation, I am sure that others will disagree, vigorously.
marcov
Posts: 3454
Joined: Jun 16, 2005 9:45
Location: Netherlands
Contact:

Re: Why do you still program for DOS?

Post by marcov »

Nowadays I only do rare testing for freepascal, since I'm release manager. But that also will wane, since I did away most old PC hardware last january.

The fullscreen text applications I liked the most. On "modern" hardware (anything after P90) lightning fast screen update, and very fast reaction to the (mostly) keyboard controls.

I kept dos quite a while for my BBS/point software, which were all fullscreens apps(Frontdoor/sbbs/golded) till the fido areas were pretty much deserted r, and when I got my first fixed internet(done right, directly glassfiber in '2000) I mostly stopped with fido. Strangely, for several years after that, the only groups I was active in were mostly mirrorred from newsgroups over fido. IOW I used a fido to news bridge, while I could use news directly. The software was simply superior IMHO.

I also worked with the FPC go32v2 textmode IDE for a while (1998-2003/4), which contrary to older stuff was fully lfn aware etc, and could copy and paste to windows (via int 2F). Then the Win2k and later XP got the upper hand, and my primary system shifted to 2000/XP, and my dos work abruptly died. But fullscreen textmode didn't really work very well, so mostly you worked in a window, and it was always what sluggish.

Linux and *nix in general with its ncurses based terminal is quite limited and hopelessly fragmented due to terminal types (try to get e.g. key combos like ctrl-alt-f9 on a console, an xterm, and a gno terminal or so, good luck!). Good enough for a quick job, but not the same. Not even close.

I've kept working with the win32 textmode IDE till about 5 years ago, when a variety of factors made me switch to the GUI lazarus. I think the core was that textmode IDE has little automated source navigation (jump to identifier definition etc), and I have gotten addicted to that.

As for hardware interfacing, back in the eighties and nineties everything was so #$%##!@ expensive, but every PC had a parallel port you trigger some simple circuits or relays with, and there was enough software and examples to DIY on a budget.

So, like everybody I toggled some leds and relays, and that experience was useful when later there was some cooperation between the local computer club and a modeltrains club. It might even have been the early days of my embedded work, that is now a small part (10%) of my job.

But nowadays stuff like rpi and arduino is so cheap and diverse, and all kinds of USB connected electronics do it for you, so you don't really need an overly complicated (and power hungry!) PC for your control jobs any more and risk frying your expensive PC. Also doing it via dos isn't as common and straightforward any more, and some types of hardware are impossible or constrained. Time has moved on.

(*) the go32v2 IDE was much faster under win9x than the win32 IDE. While the win32 IDE is functionally the same or better, it was more sluggish on the same hardware. The last real win9x/dos dual boot machine was a K6-2 500 Mhz. While the go32v2 IDE worked on w2k, it was very slow, there the win32 was faster.
Last edited by marcov on Oct 19, 2019 11:24, edited 2 times in total.
rugxulo
Posts: 219
Joined: Jun 30, 2006 5:31
Location: Usono (aka, USA)
Contact:

Re: Why do you still program for DOS?

Post by rugxulo »

marcov wrote: I also worked with the FPC go32v2 textmode IDE for a while (1998-2003/4), which contrary to older stuff was fully lfn aware etc
LFNs were never intended for raw MS-DOS 7, only under the GUI (Win9x) itself. You have to use third-party drivers for that (e.g. DOSLFN). Well, or ROM DOS 7 (still sold online!), but I never tried that. (There's also a TSR/DLL combo for old NT 4's DOS/NTVDM.)
marcov wrote: and could copy and paste to windows (via int 2F). Then the Win2k and later XP got the upper hand, and my primary system shifted to 2000/XP, and my dos work abruptly died.
There's a TSR/DLL combo for DOS clipboard access under NT/XP. Actually, there's a DOS TSR clipboard emulation that works in pure DOS, too.
marcov wrote: But fullscreen textmode didn't really work very well, so mostly you worked in a window, and it was always what sluggish.
NT didn't support literally all DOS-related things, so it had quite a few bugs and regressions. Honestly, it got worse and worse. I know you don't understand this, but they just didn't care to be compatible with competitors (yes, even things they invented themselves, they didn't want to support irrelevant, second-tier, redundant tech that other companies already supported, they wanted to do everything new and incompatibly).
marcov wrote: I've kept working with the win32 textmode IDE till about 5 years ago, when a variety of factors made me switch to the GUI lazarus. I think the core was that textmode IDE has little automated source navigation (jump to identifier definition etc), and I have gotten addicted to that.
Exuberant Ctags has some partial support for Pascal (e.g. VILE or JED or VIM).

BTW, Lazarus is "Community Choice" Project of the Month at Sourceforge.net again.
marcov wrote: (*) the go32v2 IDE was much faster under win9x than the win32 IDE. While the win32 IDE is functionally the same or better, it was more sluggish on the same hardware. The last real win9x/dos dual boot machine was a K6-2 500 Mhz. While the go32v2 IDE worked on w2k, it was very slow, there the win32 was faster.
You couldn't even resize NTFS until Vista. So you'd have to pre-emptively install (or dual boot) DOS on those machines, but nobody ever did. NTVDM was buggy as hell. VT-X barely existed (or couldn't be found).

Yeah, I know, "other tech is better", "nobody cares", "time is money". Whatever. It's just sad that so much working code was literally thrown away.
marcov
Posts: 3454
Joined: Jun 16, 2005 9:45
Location: Netherlands
Contact:

Re: Why do you still program for DOS?

Post by marcov »

rugxulo wrote:
marcov wrote: I also worked with the FPC go32v2 textmode IDE for a while (1998-2003/4), which contrary to older stuff was fully lfn aware etc
LFNs were never intended for raw MS-DOS 7, only under the GUI (Win9x) itself.
MS-Dos7 was only a rescue system for win9x. So for real apps, it was never meant to run without GUI :-)
You have to use third-party drivers for that (e.g. DOSLFN). Well, or ROM DOS 7 (still sold online!), but I never tried that. (There's also a TSR/DLL combo for old NT 4's DOS/NTVDM.)
People that refused to move on with times ;_)
rugxulo wrote:
marcov wrote: and could copy and paste to windows (via int 2F). Then the Win2k and later XP got the upper hand, and my primary system shifted to 2000/XP, and my dos work abruptly died.
There's a TSR/DLL combo for DOS clipboard access under NT/XP. Actually, there's a DOS TSR clipboard emulation that works in pure DOS, too.
Yes. But as said the win32 version was more responsive under NT. For applications that you could switch between Dos and Windows, that was an easy choice. That said, I kept a few dos applications simply because recompiling with win32 was an hassle(*) till the x64 move made that impossible.

(*) 16-bit topspeed Modula2
marcov wrote: But fullscreen textmode didn't really work very well, so mostly you worked in a window, and it was always what sluggish.
NT didn't support literally all DOS-related things, so it had quite a few bugs and regressions. Honestly, it got worse and worse. I know you don't understand this, but they just didn't care to be compatible with competitors (yes, even things they invented themselves, they didn't want to support irrelevant, second-tier, redundant tech that other companies already supported, they wanted to do everything new and incompatibly).
I simply describe as it was. It is an observation, period.
marcov wrote: I've kept working with the win32 textmode IDE till about 5 years ago, when a variety of factors made me switch to the GUI lazarus. I think the core was that textmode IDE has little automated source navigation (jump to identifier definition etc), and I have gotten addicted to that.
Exuberant Ctags has some partial support for Pascal (e.g. VILE or JED or VIM).
Those hacks never matched a real IDE. And those editors are not worth mentioning anyway (and I'm still a bit in dubio if VI(m) is an editor at all)
BTW, Lazarus is "Community Choice" Project of the Month at Sourceforge.net again.
I know, I voted for it :-) Seems that Lazarus and Free Pascal are some of the largest projects that haven't left SF, so they generally win the elections they are featured in (no more elections against "smplayer" or other very popular but non development tools).
marcov wrote: (*) the go32v2 IDE was much faster under win9x than the win32 IDE. While the win32 IDE is functionally the same or better, it was more sluggish on the same hardware. The last real win9x/dos dual boot machine was a K6-2 500 Mhz. While the go32v2 IDE worked on w2k, it was very slow, there the win32 was faster.
You couldn't even resize NTFS until Vista.
Well, there was always partition magic :-)

But I thought you could extend, but not shrink before.
So you'd have to pre-emptively install (or dual boot) DOS on those machines, but nobody ever did. NTVDM was buggy as hell. VT-X barely existed (or couldn't be found).
When WiNT became my primary OS (2003-2005), the dos work that was left moved to the second, win98 machine, or ran within NTVDM (the point software).
Yeah, I know, "other tech is better", "nobody cares", "time is money". Whatever. It's just sad that so much working code was literally thrown away.
Was it the right choice, if 15 years later there is still no real successor to win9x dos?
rugxulo
Posts: 219
Joined: Jun 30, 2006 5:31
Location: Usono (aka, USA)
Contact:

Re: Why do you still program for DOS?

Post by rugxulo »

marcov wrote:
Exuberant Ctags has some partial support for Pascal (e.g. VILE or JED or VIM).
Those hacks never matched a real IDE. And those editors are not worth mentioning anyway (and I'm still a bit in dubio if VI(m) is an editor at all)
I assume you mean that regex isn't as good as a full language parser. You're right, of course, and double-checking shows Pascal support as very weak (funcs/procs only, although support is much much better for some other languages).

Vi came from *BSD (Bill Joy), the "visual" part of ex (improved ed). I'm sure you knew that. Vi is quite nice, IMHO, but admittedly VIM is a huge behemoth monstrosity (albeit powerful and extremely popular).

EDIT: Oh, other editors support tags, too: SETEDIT and Mined (for instance, so it's not only vi or emacsen).
marcov wrote:
BTW, Lazarus is "Community Choice" Project of the Month at Sourceforge.net again.
I know, I voted for it :-) Seems that Lazarus and Free Pascal are some of the largest projects that haven't left SF, so they generally win the elections they are featured in (no more elections against "smplayer" or other very popular but non development tools).
Seems FPC was Dec. 2018. (I'm backlogged on emails, so I didn't notice.) But even FreeDOS was Sep. 2016, so you're in "good" company. :-)
marcov wrote:
You couldn't even resize NTFS until Vista.
Well, there was always partition magic :-)

But I thought you could extend, but not shrink before.
GParted supposedly worked but was scary (to me). My point is that, unless you had separate machines or were willing to reinstall from scratch, it was very inconvenient. Thus, most lowly end users like myself never had native DOS (anymore) because they didn't want to ruin their current Windows install. Of course, DOS is a security risk, I suppose, but I feel like that's still a copout. Then again, most people don't have the software archaeological curiosity that I do (even if I'm far from exhaustive). People find one thing and stick to it. I tend to wander around, trying various things.
marcov wrote:
So you'd have to pre-emptively install (or dual boot) DOS on those machines, but nobody ever did. NTVDM was buggy as hell. VT-X barely existed (or couldn't be found).
When WiNT became my primary OS (2003-2005), the dos work that was left moved to the second, win98 machine, or ran within NTVDM (the point software).
NTVDM had several bugs, even on XP (which was mostly acceptable). Even Win9x wasn't immune from bugs. Certainly Vista (et al.) had many.

Seriously, many projects abandoned DOS because of lousy support under Windows. Sad, really, but I'll admit it's not easy to be fully compatible sometimes.
marcov wrote:
Yeah, I know, "other tech is better", "nobody cares", "time is money". Whatever. It's just sad that so much working code was literally thrown away.
Was it the right choice, if 15 years later there is still no real successor to win9x dos?
Successor for whom? Nobody needs or wants it. Most people are very myopic and don't need compatibility at all. Might as well use a Mac! (And they do!)

I would say Linux + DOSEMU is the only obvious successor nowadays. Although, as mentioned, you can still buy OS/2 (Arca Noae). Also, DR-DOS is (was?) still sold online, too.

Novell is the one who bought DR-DOS and made it multitask. They were the ones trying to compete, but they gave up (sold off) when they learned that Win95 would come bundled with MS-DOS. Eventually Caldera won a lawsuit over that.

Face it, nothing matters. All tech will be obsolete "eventually" (sooner than later) and die off. It happens. People are overzealous and like throwing things away. In ten years everything will be ("mostly") different ... again.
rugxulo
Posts: 219
Joined: Jun 30, 2006 5:31
Location: Usono (aka, USA)
Contact:

Re: Why do you still program for DOS?

Post by rugxulo »

xlucas wrote: When I ask myself what desirable feature DOS has that new OSs do not, I can think of a few objective answers: direct access to hardware, independence (you don't have to be updating it or depending on the internet or 3rd party software), effectiveness (it's fast and simple as opposed to bloated). Do you see these same features as desirable? Do you have a different set of them?
It's not so much uniquely available features but rather familiarity (and fun, curiosity, zeal for improvements) that pushes me to use DOS. I've been using it for years now, so it's very comfortable, even if I'm no low-level expert. As one guy suggested on this very forum years ago (so I guess he's almost right), it's like resurrecting the dead, trying to see what can be done with the leftover scraps. (Perhaps "software archaeology" is a better description!) I enjoy trying to help FreeDOS rebuild, fix, improve, recover, gain new things, etc. So that's a different mindset (FOSS, which can be great but burdensome) rather than just end-user, consumer banality.

Honestly, DOS has fewer tools than ever since most stuff is abandoned or impossible to find. But it still has some good stuff, but even most (yet not all) of that is available on other OSes. There's no denying that other OSes are more popular. But that doesn't mean DOS is totally useless.

Obviously many smart people got plenty of "real work" done "back in the day" using DOS. "A poor carpenter blames his tools." To badly paraphrase Dennis Ritchie, "DOS is very simple, it just needs a genius to understand its simplicity." Also, "DOS is quirky, flawed, and an enormous success."
xlucas wrote: Maybe you don't really like DOS that much, but you're required to supported because you need to make some very old software work in maybe some very old computer. Is that the case? Not mine, but could be yours.
No, I don't use it professionally, nor am I trained in computers. Just a hobbyist / amateur.

All of my family still prefers Windows, but I've made a few USB jump (pen) drives with Linux over the years that I've rarely used to help solve certain problems, even for myself. Rarely have I used DOS for anybody else because nobody else needs (or wants) it. Clearly, Linux is more useful overall (depending on the distro), and certainly it's more free/libre, no cost, and easier (IMHO) than Windows. It doesn't mean I can't still use DOS for "some" things, but you can't always use only one tool for every job. (DOS is like *nix "sed", limited but useful. Sometimes you don't need bloated Perl when tiny sed will suffice.)
xlucas wrote: The most confusing question I have in my mind is what really defines DOS. Say you take something that is clearly DOS, for example, you take a copy of FreeDOS 1.2 or maybe MS-DOS 6.22. Then, as many people do, you may feel it has some obsolete characteristics, that it can't be used so comfortably, it's incompatible with new hardware or whatever, so you want to make something modern, new, that is still DOS. Problem is, which features can you change so it will still be DOS? Does the command line intefrace have to be the same? Does the API (int 21h and others) have to operate the same way? Are even external things such as the BIOS interrupts and the segmented memory system of real mode Intel processors a part, in a way, of what we call DOS, or is it possible to separate them and still keep the name? Would a protected mode 32-bit DOS be DOS?
Yes, a 32-bit DOS supporting DPMI would still be DOS (or at least "DOS compatible"). We've already had that with DR-DOS 7, Win9x, OS/2, and DOSEMU. I think the big point would be binary compatibility over anything else, even if only partial. That's one goal that FreeDOS (and ReactOS) support, but FSF hates such a goal. Then again, I see zero gains in trying to be incompatible for incompatibility's sake. The worst part of DOS is that so much good stuff is abandoned yet nobody writes new stuff. It's hard to get people encouraged, even with excellent development tools (ahem).

Honestly, it's no small feat replicating old software (e.g. FreeDOS vs. MS-DOS or FreeBASIC vs. QuickBASIC). Let's not lament what we haven't done (or can't do) but rather enjoy what we have. It's amazing what already works!
marcov
Posts: 3454
Joined: Jun 16, 2005 9:45
Location: Netherlands
Contact:

Re: Why do you still program for DOS?

Post by marcov »

(vi(m)/ctags)
rugxulo wrote: I assume you mean that regex isn't as good as a full language parser. You're right, of course, and double-checking shows Pascal support as very weak (funcs/procs only, although support is much much better for some other languages).
I also want to popup only relevant identifiers on a . or ^. (. or -> in C). I do most my C work in MP Lab X (a NetBeans derivative), and some C++ work (wrapping DLLs mostly) in VIsual Studio. Having a free and capable visual studio edition is quite nice. I usually need to run VS on varying systems (for varying camera drivers that don't like eachother)
Vi came from *BSD (Bill Joy), the "visual" part of ex (improved ed). I'm sure you knew that. Vi is quite nice, IMHO, but admittedly VIM is a huge behemoth monstrosity (albeit powerful and extremely popular).
I always considered vi and derived tools works of the devil. Can't get used to the modes, and the fact that if you accidentally leave the editing mode, normal keys are suddenly editor commands.

Probably this is all due to limited terminal key support (can't use ctrl-alt key combos like grown up editors do), but knowing that doesn't make it any easier either.

I use joe for the most minimal work, and lazarus for the rest.

GParted supposedly worked but was scary (to me). My point is that, unless you had separate machines or were willing to reinstall from scratch, it was very inconvenient. Thus, most lowly end users like myself never had native DOS (anymore) because they didn't want to ruin their current Windows install. Of course, DOS is a security risk, I suppose, but I feel like that's still a copout. Then again, most people don't have the software archaeological curiosity that I do (even if I'm far from exhaustive). People find one thing and stick to it. I tend to wander around, trying various things.
Same. Never let gparted with critical data (though a session two years ago during SSD migration mostly went ok. Just couldn't get the thing to boot after transfering HD to SSD, in the end just reinstalled win10.
So you'd have to pre-emptively install (or dual boot) DOS on those machines, but nobody ever did. NTVDM was buggy as hell. VT-X barely existed (or couldn't be found).
It was sluggish(though admittedly that was the below 500MHz era experience). After a while most FPC based tools worked fine or even better with win32 (better lfn, access to network locations etc. In recent years, add unicode)

And of course the 64MB limit.
NTVDM had several bugs, even on XP (which was mostly acceptable). Even Win9x wasn't immune from bugs. Certainly Vista (et al.) had many.
Vista was my first 64-bit windows (though I had a 32-bit too). With Win 8 release I upgraded every license I had to 64-bit win8.0. Originally to get rid of Vista, but when I found out I could upgrade 32-bit licenses to 64-bit, I upgraded them for all sane PCs.
Seriously, many projects abandoned DOS because of lousy support under Windows. Sad, really, but I'll admit it's not easy to be fully compatible sometimes.
Well and users disappearing :-) The whole of FPC go32v2 has been a labour of love since say 2003.
Yeah, I know, "other tech is better", "nobody cares", "time is money". Whatever. It's just sad that so much working code was literally thrown away.
Apparently not that valuable, otherwise there would have been more successors.
Was it the right choice, if 15 years later there is still no real successor to win9x dos?
Successor for whom? Nobody needs or wants it. Most people are very myopic and don't need compatibility at all. Might as well use a Mac! (And they do!)
[/quote]

I'm not talking about the great masses, I can remember fellow students already moving to win3.11 (and never quitting it ) because of Word. I think I only moved from WP6 to Word after 2000 (though I have to admit in the period 1998-2002 I didn't do much coursework)

I mean for the people that initially stuck to dos and/or win9x. There is no real dominant successor platform based on newer software (and often even hardware) , something which other retro communities (like Amiga) did seem to have managed.
I would say Linux + DOSEMU is the only obvious successor nowadays.
Does it provide lfn, how is performance ? One can download ready to boot win9x images for virtualbox.
Last edited by marcov on Apr 16, 2019 17:36, edited 1 time in total.
rugxulo
Posts: 219
Joined: Jun 30, 2006 5:31
Location: Usono (aka, USA)
Contact:

Re: Why do you still program for DOS?

Post by rugxulo »

marcov wrote:(vi(m)/ctags)
rugxulo wrote: I assume you mean that regex isn't as good as a full language parser. You're right, of course, and double-checking shows Pascal support as very weak (funcs/procs only, although support is much much better for some other languages).
I also want to popup only relevant identifiers on a . or ^. (. or -> in C). I do most my C work in MP Lab X (a NetBeans derivative), and some C++ work (wrapping DLLs mostly).
The support for C/C++ is better (see here) because they are more popular.
marcov wrote: I always considered vi and derived tools works of the devil. Can't get used to the modes, and the fact that if you accidentally leave the editing mode, normal keys are suddenly editor commands.
vi vi vi ... the number of the ... j/k. IIRC, "Using a free/libre vi clone isn't a sin but rather a penance." Also, "Emacs is hard on the hand, but vi is hard on the brain!" (GNU Emacs used to support vi emulation, too. VILE is actually a heavily-modified MicroEmacs.)

Most sane clones always tell you what mode you're in (command or whatever). Besides, you have (limited) undo. Yeah, this is why users press Esc a lot.
marcov wrote: I use joe for the most minimal work, and lazarus for the rest.
JOE never had good DOS ports. There were two (ancient!) ones, but I never used them much. The only "modern" JOE port I'm aware of is JUPP (2.x for DOS, 3.x for *nix), but I haven't used that much either.

Normally I prefer TDE since decades, but it lacks some stuff and has keyboard issues in some rare environments (where I often use VILE instead). Actually, ten years ago I was more enthusiastic and tried a ton of editors, but it was just curiosity. There's too many features, and I truly don't need them all every single day. So TDE it is.

(TDE and FTE partially share a common code base. TDE was based upon DTE by Doug Thomson, which was a Wordstar clone written in C meant to be used atop *nix with a Pascal compiler. I guess they wanted to partially mimic TP even there. Yup, meant to be mostly modeless across serial line [users connected to terminals?] way back in 1991.)
marcov wrote:
GParted supposedly worked but was scary (to me). My point is that, unless you had separate machines or were willing to reinstall from scratch, it was very inconvenient.
Same. Never let gparted with critical data (though a session two years ago during SSD migration mostly went ok. Just couldn't get the thing to boot after transfering HD to SSD, in the end just reinstalled win10.
You were recommended to defrag first (or last?) and hope that XP wouldn't have a problem with the resized NTFS. It's not Linux's fault that NTFS was undocumented and proprietary, of course. Still, annoying. (Better hypervisors and bootable jump drives have made that less crucial nowadays. Well, and native resizing.)

Reinstalling Windows is annoying, but I've not done it much either. They make it harder than it has to be. In many ways Linux truly is easier (for me, but I'm no Windows guru).
marcov wrote:
So you'd have to pre-emptively install (or dual boot) DOS on those machines, but nobody ever did. NTVDM was buggy as hell. VT-X barely existed (or couldn't be found).
It was sluggish(though admittedly that was the below 500MHz era experience). After a while most FPC based tools worked fine or even better with win32 (better lfn, access to network locations etc. In recent years, add unicode)

And of course the 64MB limit.
It's been ages since I used Win9x, but no, there was no 64 MB DPMI limit (AFAIK). (I assume that's what you mean here?) I think you should set it to "auto" or "-1" (I forget). Clearly 64 MB was never enough for many things (e.g. DJGPP) except in the extreme old days. Even the Vista (and 2k3) limit was 32 MB, but that was a bug, AFAIK (although people still found a way to defend it, ugh), fixed in SP1 (but not at all in 2k3, supposedly) with ugly, undocumented registry hack. It felt really stupid to be limited to 32 MB on a 1 GB laptop (3%).

DJGPP was well-supported on Win9x (despite a few bugs, e.g. descriptor leaks requiring restarting the console). It had native LFN support since 1996 (v2.00) and was even bundled on CD for FSF/GNU fundraising. That was before Cygwin and MinGW, of course. DJGPP was relatively popular in the '90s. In fact, IMHO, it was still "good" even on XP. Ironically, plain DOS (roughly speaking) outlived NTVDM (which doesn't work in Win10 anymore, last I heard).
marcov wrote: The whole of FPC go32v2 has been a labour of love since say 2003.
The FreeDOS book was literally a labor of love, too. But that was back in 1996, when DOS was more popular. It's strange how what was once lauded is now shunned. I know I'm naive, but why does everything have to break? (You're right, HLLs are more "long-lasting" than assembly. I just never got into them until much later [2007? 2010], even though I weakly tried once or twice [1998, 2005]. But even there, portability is a nightmare.)

I only mention that because, indeed, being too specific to a certain cpu or OS is asking for trouble in the long run. It's better to do things universally, portably, simply rather than relying on an overly-specific machine or a single vendor (don't put all your eggs in one basket). Still, not even "standards" or FOSS can protect us from things breaking, being deprecated, being replaced with "newer" tech. (Sticking to plain C or even C++ might be barely sane, but ....)
marcov wrote:
Yeah, I know, "other tech is better", "nobody cares", "time is money". Whatever. It's just sad that so much working code was literally thrown away.
Apparently not that valuable, otherwise there would have been more successors.
Copyright lasts too long for software, so just from that alone, it must still be "valuable". Who protects something worthless with their life?

There's a different attitude with FOSS rather than consumerism. I'm no great programmer, but I like creating things (or fixing, porting, testing, whatever). I've not done much, but FOSS is more universally useful than just buying (or downloading or archiving) pre-existing old software (with bugs, limits, licensing restrictions). We're a rare breed, dare I say, since it's far easier (but less useful) to just consume. So, most people aren't much help when it comes to (re)creating things in specific environments.
marcov wrote:
I would say Linux + DOSEMU is the only obvious successor nowadays.
Does it provide lfn, how is performance ? One can download ready to boot win9x images for virtualbox.
Downloading Win9x is (mostly) irrelevant, esp. due to licensing nonsense. But yes, DOSEMU supports LFNs. Still, it has some bugs. (DOSEMU2 [Linux only] is the modern version, but even it's unfinalized and somewhat buggy, for now. (I don't think it likes FPC!) It's very complicated! Only a handful of people in the world can hack on it, and that's not me!) On 32-bit Linux, it uses V86 mode. On x64 Linux, it uses several techniques (even VT-X nowadays). So 32-bit DJGPP stuff is normally fine and full speed, even atop x64, even without VT-X. It's only the slow, 16-bit (emulated) stuff that is annoying (again, only atop x64, but I haven't successfully tried with VT-X yet). Normally I prefer VBox, but that doesn't really support LFNs as well. (DOSLFN is slow, and some things still don't work. Most people who need LFNs, e.g. DJGPP, rely too heavily on old NTVDM, which is a shame.)

Yeah, so nothing's perfect. We should keep trying to improve anyways.
rugxulo
Posts: 219
Joined: Jun 30, 2006 5:31
Location: Usono (aka, USA)
Contact:

Re: Why do you still program for DOS?

Post by rugxulo »

rugxulo wrote: The FreeDOS book was literally a labor of love, too. But that was back in 1996, when DOS was more popular. It's strange how what was once lauded is now shunned. I know I'm naive, but why does everything have to break? (You're right, HLLs are more "long-lasting" than assembly.)
I never even bought that book until Pat died. I still haven't read it. I'm no kernel hacker, nor are most people. Linus himself says userland is "easy", but that's relative. It's still quite a pain, and most people don't even care to try to help.

Ironically, part of the big deal with FreeDOS (aka, DOS-C) was that it was written in C and (initially) portable. (And "free/libre" and binary compatible, of course.) Okay, DOS-NT (or whatever it was called) was the portable predecessor. A lot of portability had to be sacrificed, allegedly, just to make it more compatible with the full MS-DOS. I'm sure you could do "partial" compatibility portably (or maybe almost all, like DOSBox, which would be slow and a lot of work), but I think it was easier for them to not do that. In fact, choosing a kernel written in C was "easier" for the devs than choosing one written in assembly (e.g. RxDOS).

But a lot of OSes are mostly written in C (e.g. Linux or FreeBSD), so what's the problem? Most modern C compilers don't support 16-bit. Granted, you'd think that could be worked around, but it wasn't. The big breakthrough came with OpenWatcom (2003), which is OSI certified (Sybase v1, but everyone else, e.g. FSF, hates it, ironically). "Good enough" ... but not fully. So it wasn't until recently that anyone even attempted to get 16-bit support in GCC (IA-16 ELF) and port the kernel and shell to it (still unfinished). (There's video of the Mentor Graphics dude at GNU Cauldron 2017. There's also FOSDEM 2018 video of other DOSEMU dude.) FreeDOS 1.3 RC1 is from late January 2019, but work has slowed. N.B. Even ReactOS has (incomplete) NTVDM since 2014 or such.

Would a DOS kernel in assembly be horrible to maintain and read? Not necessarily. Did it save a lot of effort being written in C? Not necessarily. I'm not complaining, just lamenting the difficulty in trying to do all things for all people. Sometimes I think people are too short-sighted or stubborn to understand their own weaknesses. Things should definitely be simpler (to build, maintain, use), but it takes a literal genius to find a simple solution that works in all use cases!

I'm no genius, but this part was obvious (to me). Just FYI. But I don't expect any miracles. Still, DOS can be useful in the right circumstances (DJGPP/GCC, FPC, FBC, OpenWatcom, NASM, FASM, sed, AWK, REXX, etc).
Last edited by rugxulo on Apr 04, 2019 17:37, edited 1 time in total.
marcov
Posts: 3454
Joined: Jun 16, 2005 9:45
Location: Netherlands
Contact:

Re: Why do you still program for DOS?

Post by marcov »

rugxulo wrote: vi vi vi ... the number of the ... j/k. IIRC, "Using a free/libre vi clone isn't a sin but rather a penance." Also, "Emacs is hard on the hand, but vi is hard on the brain!" (GNU Emacs used to support vi emulation, too. VILE is actually a heavily-modified MicroEmacs.)
Emacs is a fun OS! Pity that the editor sucks so much :)
JOE never had good DOS ports. There were two (ancient!) ones, but I never used them much. The only "modern" JOE port I'm aware of is JUPP (2.x for DOS, 3.x for *nix), but I haven't used that much either.
I didn't use any Unix editors on Dos period. Back in the day mostly qedit or just edit.
You were recommended to defrag first (or last?) and hope that XP wouldn't have a problem with the resized NTFS. It's not Linux's fault that NTFS was undocumented and proprietary
[/quote]

https://www.amazon.com/Inside-Windows-N ... 155615660X

I had that book in 2001.
Gablea
Posts: 1104
Joined: Apr 06, 2010 0:05
Location: Northampton, United Kingdom
Contact:

Re: Why do you still program for DOS?

Post by Gablea »

I try to use DOS in my commercial projects but Im starting to hit a brick wall when it comes to database support, I wish someone who is a lot smarter then me could port the MySQL library to dos.

The commercial projects I do are epos systems and I find dos is ideal for this as being a single user single app (sort of) operating system it can run the PoS application fully and at full speed.

I’m just struggling with keeping the date and time correct onscreen (as sometimes a function does not update the screen)
RockTheSchock
Posts: 252
Joined: Mar 12, 2006 16:25

Re: Why do you still program for DOS?

Post by RockTheSchock »

Ten years ago we still used a factura program / database based on OpenAccess4. It was so fast.. with only 2 or 3 key strokes you could be in any subprogram in less than a second. It did run well on Windows 32 bit.

In DOS there is often only one way to do things UI wise. That makes it simpler after getting into it.

Sometimes I look into my old programs for DOS I have written many years ago.
caseih
Posts: 2157
Joined: Feb 26, 2007 5:32

Re: Why do you still program for DOS?

Post by caseih »

I think the reason you don't see any modern compilers running on 16-bit DOS is that the memory model of the 16-bit x86 is so strange and complex compared to the modern flat models, or even the memory models of classic 8 and 16-bit systems. Pure 16-bit systems never had this problem but the 8086 and 8088 were 16-bit CPUs that worked with a 20-bit address bus. The only way to address 20 bits of memory space with 16-bit registers is to use segmentation. This means support for segmentation has to be in the entire toolchain (compiler, linker, etc). Combine this with the quirky nature of MS-DOS means it's probably not worth the effort. The 286 also had segmentation, even in protected mode. Because of that I doubt you can find any native 286 code at all these days. Unix was ported to it, but the flat model of the 386 made the 286 completely pointless to support.

The problem isn't that DOS is old or that it's only 16-bit. The problem is it's really an odd architecture. Modern compilers have no problem running on 8-bit and 16-bit microcontrollers, for example.

I still look on MS-DOS with fondness, but that's mostly out of a sense of nostalgia, not out of any sense of it being useful to me today. I still maintain a copy of my hard drive's file tree with all my apps and files, that I sometimes boot up in dosbox for kicks. WP 6.1 for DOS was absolutely the best word processor I ever used on DOS. And probably would be useful even now. My old Turbo BASIC and PowerBASIC source code projects live on for me in Linux now because of FreeBASIC. Sorry to wax nostalgic.
Last edited by caseih on Apr 10, 2020 20:40, edited 5 times in total.
caseih
Posts: 2157
Joined: Feb 26, 2007 5:32

Re: Why do you still program for DOS?

Post by caseih »

Years ago I had a friend who ran OS/2 2.x but he used a non-graphical shell with it to exclusively multitask MS-DOS programs (16-bit real mode I assume). I believe it was called TSHELL. It was super slick and multitasking DOS programs was very cool and super useful. OS/2's insane config.sys files always scared me away. That and OS/2 was expensive.

At Uni I remember people joking that you could identify a computer novice because his computer ran Windows 3.1 from autoexec.bat. Power users only ran win.com when absolutely required.
Post Reply