Mail Archives: djgpp/1994/04/11/12:29:17
DJ answered to my previous mail:
>
> > (1) During the making of 'stubedit.exe' a new version of
> > 'crt0.o' is created. This new 'crt0.o' is then used
> > when linking 'stubedit.exe' which I think is not meant
> > that way (yet). See below for details.
> > I renamed the new 'crt0.o' to 'crt0_200.o' in the makefile,
> > and reinstalled 'crt0.o' from dj111m3.zip.
>
> sample.exe should be linked with the V2.0 crt0.o and libc.a. No other
> program in V2.0 should use these (at the moment). These two should
> always go together - you can't mix and match.
>
> > (2) _go32_dpmi_exception_setup() and npxsetup() seem to be
> > missing, but I understand that V2.0 is under development.
>
> Perhaps same as (1) ?
>
> > (3) With supplied dummies for the two routines in (2) the sample
> > program 'sample.c' only outputs some newlines, i.e. printf()
> > doesn't show the arguments given to the program 'sample.exe'.
> > (I have a Dell PC with S3 graphics)
>
> Probably the wrong libc.a.
You are right (ofcourse)!
I was too impatient to get the whole thing ('sample.exe') up-and-running:
I forgot to compile to whole set of libraries (including 'libc.a') !!!
I only ran the makefiles in \DJGPP\STUB and \DJGPP\SAMPLE. Stupid...
I now also have executed 'MAKE.BAT' in \DJGPP\LIBSRC.
To help others trying to do the same I hereby have some more observations:
(Maybe others can learn from my mistakes ;-)
(1) I had the switch '2r1' in my GO32 environment variable in order
to redirect output for 'stderr' to 'stdout'. As has been noted by
others on this list before, this can cause problems during compilation
when the C preprocessor (cpp) outputs error messages !
I had such an occasion with 'malloc.c'.
The cpp-warning 'NULL redefined (line 45)' (previous definition
on line 223 in <stddef.h>) gave a compilation error for this file.
After removing '2r1' from the GO32 environment 'malloc.c' compiled fine.
(2) In the file 'LIBSRC\MAKE.BAT' forward slashes are used in the
CD commands (e.g. 'cd ../gcc') which make my MS-DOS 6.0 puke...
Changing these to backward slashes solved this.
(3) I had an error during linking of 'sample.exe' that '_handlemode'
was an unresolved external (from 'findiop.c').
It turned out that I had included in 'libc.a' the wrong version
of 'open.o' since both 'open.s' (old) and 'open.c' were present
in 'LIBSRC\C\SYS'.
The same holds for a couple of other files (chdir.o etc.)
After having removed the '.s' versions of these sources
and remaking of libc.a this problem was resolved as well.
(4) I used the included version of MAKE this time. I normally
use Borland MAKE but since we are in the 'no-nonsense' era now
I decided it was a good moment to switch to GNU make ;-)
I didn't have copies of 'mv' and 'rm' yet (which are invoked
during making of the various libraries) but where to obtain these
must be definitely a FAQ !
Are they also included somewhere in the DJGPP *.zip distribution ?
(5) Finally, I got 'sample.exe' compiled, linked and running ! Hooray !
Three out of four test suites worked fine, only the 'show_dpmi()'
routine was unresolved at link time. Perhaps a part still under
development, or yet another not-yet-correctly-compiled library ?!?
Pardon me for my ignorance...
(6) For those of you interested: 'sample.exe' (with the first test
enabled) was 113522 bytes (unstripped), and 63488 when stripped.
(This is not a concern to me because I mainly develop a few
already-large-themselves programs.)
(7) One of my own (big) applications linked with the V2.0 libraries
gave a 'general protection fault' inside the Windows DOS box,
so this is where my own contributions to V2.0 could start !
(8) One last question to you, DJ. Is it alright to use the same
(new, V2.0) include files for both V2.0 compilations as well
as the standard 1.11m4 compilations ?
Regards,
.^^^^^^^^ _____________________________________
| | / Pieter Kunst (P.J.) \
| _ _| / Philips Research Laboratories, \
.--(o)(o) / Building WY3, Prof. Holstlaan 4, \
|@ _) / 5656 AA Eindhoven, The Netherlands. |
| ,___| / e-mail: kunst AT prl DOT philips DOT nl /
| / \_______________________________________________/
/____\
- Raw text -