OSDN Git Service

Patch from Richard Henderson to fix alpha-linux support.
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 27 Aug 1997 23:02:19 +0000 (23:02 +0000)
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 27 Aug 1997 23:02:19 +0000 (23:02 +0000)
* alpha/elf.h (LINK_SPEC): Conditionalize on USE_GNULIBC_1.
* config.guess: Recognize alpha-linux-gnulibc1.
* configure.in (alpha-*-linux-gnulibc1): New target.
(alpha-*-linux-gnu*): Don't build crtbegin/end.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@14974 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config.guess
gcc/config/alpha/elf.h
gcc/configure.in

index 93a2c91..281d6fa 100644 (file)
@@ -1,3 +1,10 @@
+Wed Aug 27 15:49:12 1997  Richard Henderson  <rth@cygnus.com>
+
+       * alpha/elf.h (LINK_SPEC): Conditionalize on USE_GNULIBC_1.
+       * config.guess: Recognize alpha-linux-gnulibc1.
+       * configure.in (alpha-*-linux-gnulibc1): New target.
+       (alpha-*-linux-gnu*): Don't build crtbegin/end.
+
 Wed Aug 27 11:52:58 1997  Jim Wilson  <wilson@cygnus.com>
 
        * m68k.md (iorsi3_internal): Readd ! TARGET_5200 check lost in
index ee2742b..1448103 100755 (executable)
@@ -506,6 +506,7 @@ EOF
                ret \$31,(\$26),1
                .end main
 EOF
+               LIBC=""
                ${CC-cc} dummy.s -o dummy 2>/dev/null
                if test "$?" = 0 ; then
                        ./dummy
@@ -516,10 +517,16 @@ EOF
                        2)      
                                        UNAME_MACHINE="alphaev56"
                                ;;      
-               esac    
-         fi    
-         rm -f dummy.s dummy
-         echo ${UNAME_MACHINE}-unknown-linux-gnu ; exit 0
+                       esac    
+
+                       objdump --private-headers dummy | \
+                         grep ld.so.1 > /dev/null
+                       if test "$?" = 0 ; then
+                               LIBC="libc1"
+                       fi
+               fi      
+               rm -f dummy.s dummy
+               echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} ; exit 0
        elif test "${UNAME_MACHINE}" = "mips" ; then
          cat >dummy.c <<EOF
 main(argc, argv)
index 0506b59..63c9f1b 100644 (file)
@@ -39,6 +39,15 @@ Currently only Linux uses this. */
 -Asystem(linux) -Acpu(alpha) -Amachine(alpha) -D__ELF__"
 
 #undef LINK_SPEC
+#ifdef USE_GNULIBC_1
+#define LINK_SPEC "-m elf64alpha -G 8 %{O*:-O3} %{!O*:-O1}     \
+  %{shared:-shared}                                            \
+  %{!shared:                                                   \
+    %{!static:                                                 \
+      %{rdynamic:-export-dynamic}                              \
+      %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}         \
+    %{static:-static}}"
+#else
 #define LINK_SPEC "-m elf64alpha -G 8 %{O*:-O3} %{!O*:-O1}     \
   %{shared:-shared}                                            \
   %{!shared:                                                   \
@@ -46,6 +55,7 @@ Currently only Linux uses this. */
       %{rdynamic:-export-dynamic}                              \
       %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}}   \
     %{static:-static}}"
+#endif
 
 /* Output at beginning of assembler file.  */
 
index 510018b..c99c7be 100644 (file)
@@ -273,15 +273,25 @@ for machine in $build $host $target; do
                fixincludes=Makefile.in
                gas=yes gnu_ld=yes
                ;;
+       alpha*-*-linux-gnulibc1*)
+               tm_file="${tm_file} alpha/linux.h alpha/elf.h"
+               xm_file="${xm_file} alpha/xm-linux.h"
+               target_cpu_default="MASK_GAS"
+               tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux"
+               xmake_file=none
+               fixincludes=Makefile.in
+               gas=yes gnu_ld=yes
+               if [[ x$enable_threads = xyes ]]; then
+                       thread_file='posix'
+               fi
+               ;;
        alpha*-*-linux-gnu*)
                tm_file="${tm_file} alpha/linux.h alpha/elf.h"
                xm_file="${xm_file} alpha/xm-linux.h"
                target_cpu_default="MASK_GAS"
-               gas=no
                tmake_file="t-linux alpha/t-linux"
                xmake_file=none
                fixincludes=Makefile.in
-               extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
                gas=yes gnu_ld=yes
                if [[ x$enable_threads = xyes ]]; then
                        thread_file='posix'