configure.host revision 38889
133965Sjdp# This is the linker host specific file.  This is invoked by the
233965Sjdp# autoconf generated configure script.  Putting it in a separate shell
333965Sjdp# file lets us skip running autoconf when modifying host specific
433965Sjdp# information.
533965Sjdp
633965Sjdp# This file sets the following shell variables:
733965Sjdp#  HDEFINES		host specific compiler flags
833965Sjdp#  HOSTING_CRT0		crt0.o file used for bootstrapping
933965Sjdp#  HOSTING_LIBS		libraries used for bootstrapping
1033965Sjdp#  NATIVE_LIB_DIRS	library directories to search on this host
1133965Sjdp
1233965SjdpHDEFINES=
1333965SjdpHOSTING_CRT0=/lib/crt0.o
1433965SjdpHOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc'
1533965SjdpNATIVE_LIB_DIRS=
1633965Sjdp
1733965Sjdpcase "${host}" in
1833965Sjdp
1938889Sjdpalpha*-*-linux-gnu*)
2038889Sjdp  HOSTING_CRT0='-dynamic-linker `egrep "ld[^ ]*\.so" \`gcc --print-file-name=specs\` | sed -e "s,.*-dynamic-linker[ 	][ 	]*\(.*/ld[^ ]*.so..\).*,\1,"` `gcc --print-file-name=crt1.o` `gcc --print-file-name=crti.o` `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc --print-file-name=crtbegin.o; fi`'
2138889Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -L`dirname \`gcc --print-file-name=libc.so\`` -lc `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc --print-file-name=crtend.o; fi` `gcc --print-file-name=crtn.o`'
2238889Sjdp  ;;
2338889Sjdp
2438889Sjdpalpha*-*-netbsd*)
2538889Sjdp  # The new BSD `make' has a bug: it doesn't pass empty arguments in
2638889Sjdp  # shell commands.  So we need to make this value non-empty in order
2738889Sjdp  # for the genscripts.sh call to work.  There's nothing magic about
2838889Sjdp  # the value `/lib'; it's just a dummy.
2938889Sjdp  NATIVE_LIB_DIRS=/lib
3033965Sjdp  HOSTING_CRT0=/usr/lib/crt0.o
3133965Sjdp  ;;
3233965Sjdp
3338889Sjdpalpha*-*-*)
3433965Sjdp  HOSTING_CRT0=/usr/ccs/lib/crt0.o
3533965Sjdp  NATIVE_LIB_DIRS=/usr/ccs/lib
3633965Sjdp  ;;
3733965Sjdp
3833965Sjdpi[3456]86-*-bsd* | i[3456]86-*-freebsd* | i[3456]86-*-netbsd*)
3933965Sjdp  # The new BSD `make' has a bug: it doesn't pass empty arguments in
4033965Sjdp  # shell commands.  So we need to make this value non-empty in order
4133965Sjdp  # for the genscripts.sh call to work.  There's nothing magic about
4233965Sjdp  # the value `/lib'; it's just a dummy.
4333965Sjdp  NATIVE_LIB_DIRS=/lib
4433965Sjdp  HOSTING_CRT0=/usr/lib/crt0.o
4533965Sjdp  ;;
4633965Sjdp
4733965Sjdpi[3456]86-*-sysv4*)
4833965Sjdp  HOSTING_CRT0='/usr/ccs/lib/crt1.o /usr/ccs/lib/crti.o /usr/ccs/lib/values-Xa.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
4933965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi` /usr/ccs/lib/crtn.o'
5033965Sjdp  NATIVE_LIB_DIRS=/usr/ccs/lib
5133965Sjdp  ;;
5233965Sjdp
5333965Sjdpi[3456]86-sequent-ptx* | i[3456]86-sequent-sysv*)
5433965Sjdp  HOSTING_CRT0='/lib/crt0.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
5533965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi`'
5633965Sjdp  ;;
5733965Sjdp
5833965Sjdpi[3456]86-*-sysv*)
5933965Sjdp  HOSTING_CRT0='/lib/crt1.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; fi`'
6033965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; fi` /lib/crtn.o'
6133965Sjdp  ;;
6233965Sjdp
6333965Sjdpi[3456]86-*-solaris*)
6433965Sjdp  HOSTING_CRT0='`if [ -f ../gcc/crt1.o ]; then echo ../gcc/crt1.o; else gcc -print-file-name=crt1.o; fi` `if [ -f ../gcc/crti.o ]; then echo ../gcc/crti.o; else gcc -print-file-name=crti.o; fi` /usr/ccs/lib/values-Xa.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
6533965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi` `if [ -f ../gcc/crtn.o ]; then echo ../gcc/crtn.o; else gcc -print-file-name=crtn.o; fi`'
6633965Sjdp  NATIVE_LIB_DIRS=/usr/ccs/lib
6733965Sjdp  ;;
6833965Sjdp
6933965Sjdpi[3456]86-*-sco* | i[3456]86-*-isc*)
7033965Sjdp  # In some configurations gcc does not use crtbegin.o and crtend.o.
7133965Sjdp  # In that case gcc -print-file-name=crtbegin.o will simply print
7233965Sjdp  # crtbegin.o.  We create dummy crtbegin.o and crtend.o files to
7333965Sjdp  # handle this.
7433965Sjdp  echo "int dummy_crtbegin () { return 0; }" > crtbegin.c
7533965Sjdp  ${CC} -c crtbegin.c -o crtbegin.o
7633965Sjdp  rm -f crtbegin.c
7733965Sjdp  echo "int dummy_crteng () { return 0; }" > crtend.c
7833965Sjdp  ${CC} -c crtend.c -o crtend.o
7933965Sjdp  rm -f crtend.c
8033965Sjdp  HOSTING_CRT0='/lib/crt1.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
8133965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi` /lib/crtn.o'
8233965Sjdp  ;;
8333965Sjdp
8433965Sjdpi[3456]86-*-linux*aout* | i[3456]86-*-linuxoldld)
8533965Sjdp  HOSTING_CRT0=/usr/lib/crt0.o
8633965Sjdp  ;;
8733965Sjdp
8838889Sjdpi[3456]86-*-linux*libc1*)
8933965Sjdp  HOSTING_CRT0='-dynamic-linker /lib/ld-linux.so.1 /usr/lib/crt1.o /usr/lib/crti.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; elif [ -f /usr/lib/crtbegin.o ]; then echo /usr/lib/crtbegin.o; else gcc --print-file-name=crtbegin.o; fi`'
9033965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; elif [ -f /usr/lib/crtend.o ]; then echo /usr/lib/crtend.o; else gcc --print-file-name=crtend.o; fi` /usr/lib/crtn.o'
9133965Sjdp  ;;
9233965Sjdp
9338889Sjdpi[3456]86-*-linux-gnu*)
9438889Sjdp  HOSTING_CRT0='-dynamic-linker `fgrep ld-linux.so \`gcc --print-file-name=specs\` | sed -e "s,.*-dynamic-linker[ 	][ 	]*\(.*/ld-linux.so..\).*,\1,"` `gcc --print-file-name=crt1.o` `gcc --print-file-name=crti.o` `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc --print-file-name=crtbegin.o; fi`'
9538889Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -L`dirname \`gcc --print-file-name=libc.so\`` -lc `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc --print-file-name=crtend.o; fi` `gcc --print-file-name=crtn.o`'
9638889Sjdp  ;;
9738889Sjdp
9833965Sjdpi[3456]86-*-lynxos*)
9933965Sjdp  HOSTING_CRT0=/lib/init1.o
10033965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc -lm /lib/initn.o'
10133965Sjdp  ;;
10233965Sjdp
10333965Sjdpmips*-dec-bsd*)
10433965Sjdp  HOSTING_CRT0=/usr/lib/crt0.o
10533965Sjdp  ;;
10633965Sjdp
10733965Sjdpmips*-sgi-irix4*)
10833965Sjdp  HOSTING_CRT0=/usr/lib/crt1.o
10933965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc /usr/lib/crtn.o'
11033965Sjdp  ;;
11133965Sjdp
11233965Sjdpmips*-sgi-irix[56]*)
11333965Sjdp  HOSTING_CRT0=/usr/lib/crt1.o
11433965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc /usr/lib/crtn.o'
11533965Sjdp  ;;
11633965Sjdp
11733965Sjdpm68*-*-linux*aout*)
11833965Sjdp  HOSTING_CRT0=/usr/lib/crt0.o
11933965Sjdp  ;;
12033965Sjdp
12138889Sjdpm68*-*-linux*libc1*)
12233965Sjdp  HOSTING_CRT0='-dynamic-linker /lib/ld-linux.so.1 /usr/lib/crt1.o /usr/lib/crti.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; elif [ -f /usr/lib/crtbegin.o ]; then echo /usr/lib/crtbegin.o; else gcc --print-file-name=crtbegin.o; fi`'
12333965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; elif [ -f /usr/lib/crtend.o ]; then echo /usr/lib/crtend.o; else gcc --print-file-name=crtend.o; fi` /usr/lib/crtn.o'
12433965Sjdp  ;;
12533965Sjdp
12638889Sjdpm68*-*-linux-gnu*)
12738889Sjdp  HOSTING_CRT0='-dynamic-linker /lib/ld.so.1 /usr/lib/crt1.o /usr/lib/crti.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc --print-file-name=crtbegin.o; fi`'
12838889Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc --print-file-name=crtend.o; fi` /usr/lib/crtn.o'
12938889Sjdp  ;;
13038889Sjdp
13133965Sjdpm68*-*-lynxos*)
13233965Sjdp  HOSTING_CRT0=/lib/init1.o
13333965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc -lm /lib/initn.o'
13433965Sjdp  ;;
13533965Sjdp
13633965Sjdpm68*-motorola-sysv)
13733965Sjdp  HOSTING_CRT0='`if [ -f ../gcc/crt0.o ]; then echo ../gcc/crt0.o; elif [ -f \`gcc -print-file-name=\`crt0.o ]; then echo \`gcc -print-file-name=\`crt0.o; else echo /lib/crt0.o; fi`'
13833965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc881 `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi`'
13933965Sjdp  ;;
14033965Sjdp
14133965Sjdpm68*-sun-*)
14233965Sjdp  HOSTING_CRT0='/usr/lib/crt0.o /usr/lib/Fcrt1.o -L/usr/lib/fsoft.o'
14333965Sjdp  ;;
14433965Sjdp
14533965Sjdpm88*-*-dgux*)
14633965Sjdp  HDEFINES=-D__using_DGUX
14733965Sjdp  HOSTING_CRT0='/lib/crt0.o -X'
14833965Sjdp  HOSTING_LIBS=/usr/sde/m88kbcs/lib/libc.a
14933965Sjdp  ;;
15033965Sjdp
15133965Sjdpm88*-motorola-sysv3)
15233965Sjdp  HOSTING_CRT0='/lib/crt0.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
15333965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi` `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi`'
15433965Sjdp  ;;
15533965Sjdp
15633965Sjdpromp-*-*)
15733965Sjdp  HDEFINES=-DNO_VARARGS
15833965Sjdp  ;;
15933965Sjdp
16033965Sjdpsparc*-*-solaris2*)
16133965Sjdp  HOSTING_CRT0='`if [ -f ../gcc/crt1.o ]; then echo ../gcc/crt1.o; else gcc -print-file-name=crt1.o; fi` `if [ -f ../gcc/crti.o ]; then echo ../gcc/crti.o; else gcc -print-file-name=crti.o; fi` /usr/ccs/lib/values-Xa.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; else gcc -print-file-name=crtbegin.o; fi`'
16233965Sjdp  HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else gcc -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else gcc -print-file-name=crtend.o; fi` `if [ -f ../gcc/crtn.o ]; then echo ../gcc/crtn.o; else gcc -print-file-name=crtn.o; fi`'
16333965Sjdp  NATIVE_LIB_DIRS=/usr/ccs/lib
16433965Sjdp  ;;
16533965Sjdp
16633965Sjdpesac
167