From: Godmar Back (gback@cs.utah.edu)
Date: Wed Jan 13 1999 - 11:50:27 EST
>
> On Jan 11, 1999, Godmar Back <gback@cs.utah.edu> wrote:
>
> > Alexandre, could you address the question I had about how to
> > give customized link lines or how to add libraries to a link line
> > from within config.frag (Look at i386/oskit/config.frag for an
> > example)
>
> STD_LIBRARIES no longer exists, use LIBS instead. Set it like this:
>
> LIBS="-lfoo -lbar $LIBS"
>
> Do you mean anything else with `customized link lines'? LDFLAGS?
>
Right now, it looks like this:
STD_LIBRARIES="\
-loskit_startup \
-loskit_threads \
-loskit_svm -loskit_amm \
-loskit_bootp \
-loskit_freebsd_net \
-loskit_linux_dev -loskit_dev \
-loskit_kern -loskit_lmm \
-loskit_netbsd_fs \
-loskit_freebsd_c_r \
-loskit_diskpart -loskit_fs -loskit_com \
-loskit_threads \
"
This link order is carefully crafted, believe it or not.
In particular, we cannot do things like "-lc -lm -lc -lm -lc -lm -lc"
in the OSKit because we use library overriding a lot (it's totally
error prone, and I am totally opposed to it, but that's the way it is).
Secondly, we use a shell-script as a cross-compiler which drives the
actual compiler with a special gcc .spec file. This file contains
such things as the equivalent of -Ttext switches, plus it also adds
libraries and -Ddefines and so on.
These scripts may not be 100% compatible with gcc, as they're somewhat
hacked up manually, but they did work fine if invoked with
$(CC) -o Kaffe main.o -lkaffevm $(STD_LIBRARIES)
We will probably get to testing the automake setup soon; I'll wait however
until Kaffe's FreeBSD port runs again.
Look at ~gback/oskit/unsupported/scripts/
gcc-driver-script.specs has the spec file
gcc-driver-script.in the driver script, which is simply:
GCC_EXEC_PREFIX=@prefix@/ @CC@ ${1+"$@"}
- Godmar
This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:57:40 EDT