ftp.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/07/24/16:44:02

From: "Juan Manuel Guerrero" <ST001906 AT HRZ1 DOT HRZ DOT TU-Darmstadt DOT De>
Organization: Darmstadt University of Technology
To: JT Williams <jeffw AT darwin DOT sfbr DOT org>
Date: Tue, 24 Jul 2001 22:08:20 +0200
MIME-Version: 1.0
Subject: Re: ANNOUNCE: DJGPP port of GNU Sed 3.02.80 uploaded
CC: djgpp AT delorie DOT com
X-mailer: Pegasus Mail for Windows (v2.54DE)
Message-ID: <243A027727B@HRZ1.hrz.tu-darmstadt.de>
Reply-To: djgpp AT delorie DOT com

On Tue, 24 Jul 2001 12:23:20, JT Williams wrote:
> -: This is a port of GNU Sed 3.02.80 to MSDOS/DJGPP.
>
> % unzip -l 3.02/sed302b.zip | grep sed.exe
>     98304  04-20-00 02:03   bin/sed.exe
>
> % unzip -l 3.02.80/sed3028b.zip | grep sed.exe
>    682752  07-22-01 02:03   bin/sed.exe
>
> What happened!?

Two things happened:
1) I have compiled using the GNU regex implementation included
   in the sed sources and not the DJGPP libc regex. GNU regex is
   superior to the DJGPP regex. If you inspect the sed302b.zip
   package you will find a second sed binary called gsed.exe.
   That one is the out-of-the-box compiled sed binary. That sed
   program has been compiled with GNU regex and that binary must
   be compared with the sed binary from sed3028b.zip.
   The sed.exe from sed302b.zip has been created by Eli using
   the regex functions from DJGPP 2.03.
2) I have compiled with NLS support. This means that lintl.a (functions
   used to translate english strings to other languages) and liconv.a
   (functions needed for on-the-fly recoding from unix charsets to dos
   codepages) are linked to the binary. Binaries with NLS are always
   bigger than binaries without NLS.

The real size of sed.exe is around 1.5MB (compiled with -O2 -g). I have stripped
(strip -gsxX sed.exe) the binary und compressed with upx (upx --best sed.exe) to
get the actual size. If you know that DJGPP's regex implementation is good enough
for your purposes (it has never been for my purposes), then I would suggest to
reconfigure and recompile the package. Install the sources and run the following
command sequence:
  make distclean
  djgpp\config no-NLS --with-regex=libc.a
  make
  make check
  make install

Please note that I have never tested this. But it should work.
Hope this helps.

Regards,
Juan M. Guerrero

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019