[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: gcc-3.4 updates for powerpc64 support



On Tue, Mar 15, 2005 at 07:04:47PM +0100, Bastian Blank wrote:
> The attached patch makes it possible to build powerpc64 biarch compiler,

I fixed java support.

Bastian

-- 
We have phasers, I vote we blast 'em!
		-- Bailey, "The Corbomite Maneuver", stardate 1514.2
=== debian/rules.patch
==================================================================
--- debian/rules.patch   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/rules.patch   (/gcc-3.4/trunk)   (revision 53)
@@ -106,8 +106,8 @@
 ifeq ($(DEB_TARGET_GNU_CPU)-$(biarch),i386-yes)
   debian_patches += i386-biarch
 endif
-ifeq ($(DEB_TARGET_GNU_CPU),powerpc)
-  debian_patches += #powerpc-config-ml powerpc-biarch
+ifeq ($(DEB_TARGET_GNU_CPU)-$(biarch),powerpc-yes)
+  debian_patches += powerpc-biarch powerpc-config-ml
 endif
 ifeq ($(DEB_TARGET_GNU_CPU)-$(biarch),s390-yes)
   debian_patches += s390-biarch s390-config-ml
=== debian/rules2
==================================================================
--- debian/rules2   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/rules2   (/gcc-3.4/trunk)   (revision 53)
@@ -967,14 +967,6 @@
 	rm -rf $(d)
 	mkdir -p $(d)/$(libdir) $(d)/$(PF)
 
-ifeq ($(DEB_TARGET_GNU_CPU), $(findstring $(DEB_TARGET_GNU_CPU),powerpc64))
-	: # link lib to lib64 and usr/lib to usr/lib64
-	: # (this works when CONFARGS contains '--disable-multilib')
-	ln -s lib $(d)/lib64
-	mkdir -p $(d)/usr/lib
-	ln -s lib $(d)/usr/lib64
-endif
-
 	: # Install everything
 	PATH=$(PWD)/bin:$$PATH \
 	  $(MAKE) -C $(builddir) \
=== debian/patches/powerpc-config-ml.dpatch
==================================================================
--- debian/patches/powerpc-config-ml.dpatch   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/patches/powerpc-config-ml.dpatch   (/gcc-3.4/trunk)   (revision 53)
@@ -23,21 +23,21 @@
 				    
 --- config-ml.in	2004-01-05 00:41:14.000000000 +0000
 +++ config-ml.in~	2004-11-14 14:13:30.409034784 +0000
-@@ -489,6 +489,36 @@
+@@ -489,6 +489,49 @@
  	    esac
  	  done
  	fi
++	echo "**********************************************************************************************"
++	echo "ml_realsrcdir: $ml_realsrcdir"
++	echo "multidirs: $multidirs"
 +	case " $multidirs " in
 +	*" 64 "*)
-+	  # We will not be able to create libraries with -mabi=64 if
++	  # We will not be able to create libraries with -m64 if
 +	  # we cannot even link a trivial program.  It usually
 +	  # indicates the 64bit libraries are missing.
-+	  echo Check ${CC-gcc} -m64 ...
 +	  if echo 'main() {}' > conftest.c &&
-+	     ${CC-gcc} -v -m64 conftest.c -o conftest; then
-+	    :
-+	  else
-+	    echo Could not link program with -m64, disabling it.
++	     ${CC-gcc} -m64 conftest.c -o conftest; then
++	    echo Enable only libstdc++.
 +	    old_multidirs="${multidirs}"
 +	    multidirs=""
 +	    for x in ${old_multidirs}; do
@@ -49,14 +49,27 @@
 +			*"libiberty" ) multidirs="${multidirs} ${x}" ;;
 +			*"zlib" ) multidirs="${multidirs} ${x}" ;;
 +			*) : ;;
-+		     esac ;;
++		     esac 
++		     ;;
 +	      *) multidirs="${multidirs} ${x}" ;;
 +	      esac
 +	    done
++	  else
++	    echo Could not link program with -m64, disabling it.
++	    old_multidirs="${multidirs}"
++	    multidirs=""
++	    for x in ${old_multidirs}; do
++	      case "$x" in
++	      *64* ) : ;;
++	      *) multidirs="${multidirs} ${x}" ;;
++	      esac
++	    done
 +	  fi
 +	  rm -f conftest.c conftest
 +	  ;;
 +	esac
++	echo "multidirs: $multidirs"
++	echo "**********************************************************************************************"
  	;;
  sparc*-*-*)
  	case " $multidirs " in
=== debian/patches/powerpc-biarch.dpatch
==================================================================
--- debian/patches/powerpc-biarch.dpatch   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/patches/powerpc-biarch.dpatch   (/gcc-3.4/trunk)   (revision 53)
@@ -34,43 +34,7 @@
 -	tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h"
 -	tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm"
 +	tm_file="rs6000/biarch64.h ${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux64.h"
-+	tmake_file="t-slibgcc-elf-ver t-linux rs6000/t-ppccomm"
++	tmake_file="rs6000/t-fprules t-slibgcc-elf-ver t-linux rs6000/t-ppccomm rs6000/t-linux64"
  	;;
  powerpc-*-gnu-gnualtivec*)
  	tm_file="${cpu_type}/${cpu_type}.h elfos.h svr4.h freebsd-spec.h gnu.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxaltivec.h rs6000/gnu.h"
---- gcc/config/rs6000/t-linux64~	2004-03-17 22:18:42.000000000 +0100
-+++ gcc/config/rs6000/t-linux64	2004-04-03 09:26:04.000000000 +0200
-@@ -8,30 +8,10 @@
- 
- SHLIB_MAPFILES += $(srcdir)/config/rs6000/libgcc-ppc64.ver
- 
--MULTILIB_OPTIONS        = m64/m32 msoft-float
--MULTILIB_DIRNAMES       = 64 32 nof
-+MULTILIB_OPTIONS        = m64/m32
-+MULTILIB_DIRNAMES       = 64 32
- MULTILIB_EXTRA_OPTS     = fPIC mstrict-align
--MULTILIB_EXCEPTIONS     = m64/msoft-float
--MULTILIB_EXCLUSIONS     = m64/!m32/msoft-float
--MULTILIB_OSDIRNAMES	= ../lib64 ../lib nof
--MULTILIB_MATCHES        = $(MULTILIB_MATCHES_FLOAT)
--
--# We want fine grained libraries, so use the new code to build the
--# floating point emulation libraries.
--# fp-bit is only to be used by 32-bit multilibs
--FPBIT = fp-bit32.c
--DPBIT = dp-bit32.c
--
--dp-bit32.c: $(srcdir)/config/fp-bit.c
--	( echo '#ifndef __powerpc64__'; \
--	  cat $(srcdir)/config/fp-bit.c; \
--	  echo '#endif' ) > dp-bit32.c
--
--fp-bit32.c: $(srcdir)/config/fp-bit.c
--	( echo '#ifndef __powerpc64__'; \
--	  echo '#define FLOAT'; \
--	  cat $(srcdir)/config/fp-bit.c; \
--	  echo '#endif' ) > fp-bit32.c
-+MULTILIB_OSDIRNAMES	= ../lib64 ../lib
- 
- # Hack to use -mlong-double-128 just for compiling 64 bit libgcc
- mklibgcc: bispecs
=== debian/rules.defs
==================================================================
--- debian/rules.defs   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/rules.defs   (/gcc-3.4/trunk)   (revision 53)
@@ -568,12 +568,10 @@
 endif
 
 # powerpc64 build --------------------
-ifeq ($(DEB_TARGET_GNU_CPU),XXXpowerpcXXX)
+ifeq ($(DEB_TARGET_GNU_CPU),powerpc)
   biarch := yes
   with_lib64gcc := yes
-  ifeq ($(TARGET_ALIAS),powerpc-linux)
-    TARGET_ALIAS := powerpc64-linux
-  endif
+  with_lib64cxx	:= yes
 endif
 
 # sparc64 build --------------------
=== debian/changelog
==================================================================
--- debian/changelog   (/gcc-3.4/debian/current)   (revision 53)
+++ debian/changelog   (/gcc-3.4/trunk)   (revision 53)
@@ -1,3 +1,15 @@
+gcc-3.4 (3.4.3-12.0powerpc64.2) local; urgency=low
+
+  * Fix java.
+
+ -- Bastian Blank <waldi@debian.org>  Thu, 17 Mar 2005 12:29:32 +0000
+
+gcc-3.4 (3.4.3-12.0powerpc64.1) local; urgency=low
+
+  * Add powerpc64 support.
+
+ -- Bastian Blank <waldi@debian.org>  Mon, 14 Mar 2005 19:54:44 +0000
+
 gcc-3.4 (3.4.3-12) unstable; urgency=medium
 
   * Fix libunwind tarball name, fixing FTBFS on ia64.

Attachment: signature.asc
Description: Digital signature


Reply to: