[GEM Development] GEMini - a GUI file commander for FreeDOS

Ben A L Jemmett ben.jemmett at ukonline.co.uk
Thu Oct 9 14:04:33 PDT 2003


Hmm.  I just tried it here (was wondering why it was so large, actually, but
more on that in a moment).  Under Windows 2000 it crashes, with an error
from Windows about not being able to open COM3.  Before you say it's a
Windows problem, it isn't because this is the first time I've had problems
starting GEM on this setup.

On closer inspection, you're trying to load the mouse driver you bundled
with it.  You appear to check for various Win9x modules to stop that but
nothing for Win2k.  For reference, MEM /C on a fresh CMD.EXE session here
reads:

-- top
Conventional Memory :

  Name                Size in Decimal       Size in Hex
-------------      ---------------------   -------------
  MSDOS              12528      ( 12.2K)       30F0
  KBD                 3280      (  3.2K)        CD0
  HIMEM               1248      (  1.2K)        4E0
  COMMAND             3744      (  3.7K)        EA0
  DOSX               34720      ( 33.9K)       87A0
  KB16                6096      (  6.0K)       17D0
  FREE                 112      (  0.1K)         70
  FREE                 928      (  0.9K)        3A0
  FREE              592480      (578.6K)      90A60

Total  FREE :       593520      (579.6K)

Upper Memory :

  Name                Size in Decimal       Size in Hex
-------------      ---------------------   -------------
  SYSTEM            196592      (192.0K)      2FFF0
  DOSX                 128      (  0.1K)         80
  MOUSE              12528      ( 12.2K)       30F0
  MSCDEXNT             464      (  0.5K)        1D0
  REDIR               2672      (  2.6K)        A70
  FREE                 928      (  0.9K)        3A0
  FREE               48704      ( 47.6K)       BE40

Total  FREE :        49632      ( 48.5K)

Total bytes available to programs (Conventional+Upper) :      643152
(628.1K)
Largest executable program size :                             592480
(578.6K)
Largest available upper memory block :                         48704   (
47.6K)

   1048576 bytes total contiguous extended memory
         0 bytes available contiguous extended memory
    941056 bytes available XMS memory
           MS-DOS resident in High Memory Area
-- bottom

Sorted that out and it runs OK.

Now then, about the size.  580KB seems a lot for a simple Desktop-only
setup, even allowing for a bit of growth from GEM/2 to GEM/3 and FreeGEM.
Why do I say that?  Because a favourite trick on the Amstrad PCs was to fit
the GEM/2 Desktop on a single bootable 360KB floppy.  Looking at what you
install, you have OUTPUT.*, PDEHI9.EPS and MDGEM9.SYS (totalling 156KB) that
you can get rid of -- the PDEHI9 and MSGEM9 files are the Epson printer
driver and the GEM metafile driver, neither of which are much use to the
Desktop, and GEM Output isn't really very useful on a file manager -- the
Print Spooler handles text files and if you have GEM documents lying around
to print you might as well use a full GEM system which probably comes with a
better printer driver!  :)

Since you only include a VGA driver (SDPSC9) the Desktop is never going to
use the low-res icon set, so you can save 12KB by removing DESKLO.ICN.
DESKTOP.DFN (2.mumble KB) is the definitions file for the resources -- you
don't need to include that at all, except as part of the source.  The BANNER
program mucks up my display, I'm not sure what it does but it doesn't do it
very well -- it changes the video mode and various settings before it opens
the c:\openinit.raw file.  That file doesn't exist here so it fails, resets
the video mode, but doesn't do it properly (at least here, the display ends
up scrambled) and exits.  On the other hand, the program is 891 bytes, so
hey.  BLACKOUT.EXE isn't called from anywhere that I can see, so that's 711
bytes.

Now then, that gets us down to 343KB.  Not too shabby.  The VDI+AES here
amount to 182.3KB in RAM, and I don't use LHGEM -- I can see why you might
leave that in, though.  The LHCONFIG program is nearly 10 times the size of
LHGEM itself, though, so you could replace that with two copies of LHGEM -- 
one for DR-DOS, one for MS-DOS.  Call them LHGEM and HIGEM, and then choose
the right one in GEM.EXE -- DR-DOS can be spotted through an environment
variable I believe.  Just a thought, not a biggie though.  That gets it down
to 335KB.  Not much smaller it can be got without removing the FAQ, UPXing
some of the binaries or shaving bits here and there -- 137 bytes off GEM.BAT
is one trivial mod (replace the IF %OS%== stuff with a FOR loop over the
list of OSes), and there are plenty of redundant ECHO OFFs in it.

Don't take the size criticism too seriously though; it's still pretty small,
and my Quick N' Dirty FreeGEM Distribution
(http://www.deltasoft.com/downloads/qfgdist.zip) was about the same size,
but did include a full set of screen fonts and the Settings application.

Regards,
Ben A L Jemmett.
(http://web.ukonline.co.uk/ben.jemmett/, http://www.deltasoft.com/)



More information about the gem-dev mailing list