Merged ppc.py and ppc64.py into powerpc.py and merged sparc.py and sparc64.py into...
authorChris Gianelloni <wolf31o2@gentoo.org>
Wed, 6 Feb 2008 23:36:22 +0000 (23:36 +0000)
committerChris Gianelloni <wolf31o2@gentoo.org>
Wed, 6 Feb 2008 23:36:22 +0000 (23:36 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1280 d1e1f19c-881f-0410-ab34-b69fee027534

ChangeLog
arch/powerpc.py [new file with mode: 0644]
arch/ppc.py [deleted file]
arch/ppc64.py [deleted file]
arch/sparc.py
arch/sparc64.py [deleted file]

index ac488a2eaab6aba8df54b3ecdb61cbd089079f69..1fab2dd182dc416c3341586b77275ad72f82a7e3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,11 @@
 # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
 # $Id: $
 
+  06 Feb 2008; Chris Gianelloni <wolf31o2@gentoo.org> +arch/powerpc.py,
+  -arch/ppc.py, -arch/ppc64.py, arch/sparc.py, -arch/sparc64.py:
+  Merged ppc.py and ppc64.py into powerpc.py and merged sparc.py and
+  sparc64.py into sparc.py, so we have a cleaner set of arch files.
+
   06 Feb 2008; Chris Gianelloni <wolf31o2@gentoo.org> arch/amd64.py,
   arch/x86.py:
   Did a little cleanup on the x86.py to remove some redundant entries and
diff --git a/arch/powerpc.py b/arch/powerpc.py
new file mode 100644 (file)
index 0000000..fff7c85
--- /dev/null
@@ -0,0 +1,125 @@
+
+import os,builder
+from catalyst_support import *
+
+class generic_ppc(builder.generic):
+       "abstract base class for all 32-bit powerpc builders"
+       def __init__(self,myspec):
+               builder.generic.__init__(self,myspec)
+               self.settings["CHOST"]="powerpc-unknown-linux-gnu"
+               if self.settings["buildarch"]=="ppc64":
+                       if not os.path.exists("/bin/linux32") and not os.path.exists("/usr/bin/linux32"):
+                               raise CatalystError,"required executable linux32 not found (\"emerge setarch\" to fix.)"
+                       self.settings["CHROOT"]="linux32 chroot"
+                       self.settings["crosscompile"] = False;
+               else:
+                       self.settings["CHROOT"]="chroot"
+
+class generic_ppc64(builder.generic):
+       "abstract base class for all 64-bit powerpc builders"
+       def __init__(self,myspec):
+               builder.generic.__init__(self,myspec)
+               self.settings["CHROOT"]="chroot"
+
+class arch_970(arch_ppc64):
+       "builder class for 970 aka G5 under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=970 -mtune=970"
+               self.settings["HOSTUSE"]=["altivec"]
+
+class arch_cell(arch_ppc64):
+       "builder class for cell under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=cell -mtune=cell"
+               self.settings["HOSTUSE"]=["altivec","ibm"]
+
+class arch_g3(generic_ppc):
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=G3 -mtune=G3 -fno-strict-aliasing -pipe"
+
+class arch_g4(generic_ppc):
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -fno-strict-aliasing -pipe"
+               self.settings["HOSTUSE"]=["altivec"]
+
+class arch_g5(generic_ppc):
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=G5 -mtune=G5 -maltivec -mabi=altivec -fno-strict-aliasing -pipe"
+               self.settings["HOSTUSE"]=["altivec"]
+
+class arch_power(generic_ppc):
+       "builder class for generic power"
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=power -mtune=power -fno-strict-aliasing -pipe"
+
+class arch_power_ppc(generic_ppc):
+       "builder class for generic powerpc/power"
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=common -mtune=common -fno-strict-aliasing -pipe"
+
+class arch_power3(arch_ppc64):
+       "builder class for power3 under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power3 -mtune=power3"
+               self.settings["HOSTUSE"]=["ibm"]
+
+class arch_power4(arch_ppc64):
+       "builder class for power4 under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power4 -mtune=power4"
+               self.settings["HOSTUSE"]=["ibm"]
+
+class arch_power5(arch_ppc64):
+       "builder class for power5 under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power5 -mtune=power5"
+               self.settings["HOSTUSE"]=["ibm"]
+
+class arch_power6(arch_ppc64):
+       "builder class for power6 under ppc64"
+       def __init__(self,myspec):
+               arch_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power6 -mtune=power6"
+               self.settings["HOSTUSE"]=["altivec","ibm"]
+
+class arch_ppc(generic_ppc):
+       "builder class for generic powerpc"
+       def __init__(self,myspec):
+               generic_ppc.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=powerpc -mtune=powerpc -fno-strict-aliasing -pipe"
+
+class arch_ppc64(generic_ppc64):
+       "builder class for generic ppc64"
+       def __init__(self,myspec):
+               generic_ppc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -pipe"
+               self.settings["CHOST"]="powerpc64-unknown-linux-gnu"
+
+def register():
+       "Inform main catalyst program of the contents of this plugin."
+       return ({
+               "970"           : arch_970,
+               "cell"          : arch_cell,
+               "g3"            : arch_g3,
+               "g4"            : arch_g4,
+               "g5"            : arch_g5,
+               "power"         : arch_power,
+               "power-ppc"     : arch_power_ppc,
+               "power3"        : arch_power3,
+               "power4"        : arch_power4,
+               "power5"        : arch_power5,
+               "power6"        : arch_power6,
+               "ppc"           : arch_ppc,
+               "ppc64"         : arch_ppc64
+       }, ("ppc","ppc64","powerpc","powerpc64"))
+
diff --git a/arch/ppc.py b/arch/ppc.py
deleted file mode 100644 (file)
index 7afd8b0..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-
-import os,builder
-from catalyst_support import *
-
-# gcc-3.3.3 is required to do G5 optimizations
-# install a 32bit kernel personality changer (that works) before building on a
-# ppc64 host new gcc optimization feature requires -fno-strict-aliasing needed,
-# otherwise code complains use the experimental thing for nptl builds
-
-class generic_ppc(builder.generic):
-       "abstract base class for all ppc builders"
-       def __init__(self,myspec):
-               builder.generic.__init__(self,myspec)
-               self.settings["CHOST"]="powerpc-unknown-linux-gnu"
-               if self.settings["buildarch"]=="ppc64":
-                       if not os.path.exists("/bin/linux32") and not os.path.exists("/usr/bin/linux32"):
-                               raise CatalystError,"required executable linux32 not found (\"emerge setarch\" to fix.)"
-                       self.settings["CHROOT"]="linux32 chroot"
-                       self.settings["crosscompile"] = False;
-               else:
-                       self.settings["CHROOT"]="chroot"
-
-class arch_power_ppc(generic_ppc):
-       "builder class for generic powerpc/power"
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=common -mtune=common -fno-strict-aliasing -pipe"
-
-class arch_ppc(generic_ppc):
-       "builder class for generic powerpc"
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=powerpc -mtune=powerpc -fno-strict-aliasing -pipe"
-
-class arch_power(generic_ppc):
-       "builder class for generic power"
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=power -mtune=power -fno-strict-aliasing -pipe"
-
-class arch_g3(generic_ppc):
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=G3 -mtune=G3 -fno-strict-aliasing -pipe"
-
-class arch_g4(generic_ppc):
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -fno-strict-aliasing -pipe"
-               self.settings["HOSTUSE"]=["altivec"]
-
-class arch_g5(generic_ppc):
-       def __init__(self,myspec):
-               generic_ppc.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=G5 -mtune=G5 -maltivec -mabi=altivec -fno-strict-aliasing -pipe"
-               self.settings["HOSTUSE"]=["altivec"]
-
-def register():
-       "Inform main catalyst program of the contents of this plugin."
-       return ({"ppc":arch_ppc,"power":arch_power,"power-ppc":arch_power_ppc,"g3":arch_g3,"g4":arch_g4,"g5":arch_g5}, 
-       ("ppc","powerpc"))
-
diff --git a/arch/ppc64.py b/arch/ppc64.py
deleted file mode 100644 (file)
index 4075034..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-
-import builder
-
-class generic_ppc64(builder.generic):
-       "abstract base class for all ppc64 builders"
-       def __init__(self,myspec):
-               builder.generic.__init__(self,myspec)
-               self.settings["CHROOT"]="chroot"
-
-class arch_ppc64(generic_ppc64):
-       "builder class for generic ppc64"
-       def __init__(self,myspec):
-               generic_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe"
-               self.settings["CHOST"]="powerpc64-unknown-linux-gnu"
-
-class arch_970(arch_ppc64):
-       "builder class for 970 aka G5 under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=970 -mtune=970"
-               self.settings["HOSTUSE"]=["altivec"]
-
-class arch_cell(arch_ppc64):
-       "builder class for cell under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=cell -mtune=cell"
-               self.settings["HOSTUSE"]=["altivec"]
-
-class arch_power3(arch_ppc64):
-       "builder class for power3 under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power3 -mtune=power3"
-
-class arch_power4(arch_ppc64):
-       "builder class for power4 under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power4 -mtune=power4"
-
-class arch_power5(arch_ppc64):
-       "builder class for power5 under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power5 -mtune=power5"
-
-class arch_power6(arch_ppc64):
-       "builder class for power6 under ppc64"
-       def __init__(self,myspec):
-               arch_ppc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -pipe -mcpu=power6 -mtune=power6"
-               self.settings["HOSTUSE"]=["altivec"]
-
-def register():
-       "Inform main catalyst program of the contents of this plugin."
-       return ({
-               "ppc64":        arch_ppc64,
-               "970":          arch_970,
-               "cell":         arch_cell,
-               "power3":       arch_power3,
-               "power4":       arch_power4,
-               "power5":       arch_power5,
-               "power6":       arch_power6
-       }, ("ppc64","powerpc64"))
-
-
index adde6cdb366f53b146170564b1a39e4873c883dd..5eb5344cf03ec9ca83780da543eb0a6a3bcbe364 100644 (file)
@@ -14,14 +14,29 @@ class generic_sparc(builder.generic):
                else:
                        self.settings["CHROOT"]="chroot"
 
+class generic_sparc64(builder.generic):
+       "abstract base class for all sparc64 builders"
+       def __init__(self,myspec):
+               builder.generic.__init__(self,myspec)
+               self.settings["CHROOT"]="chroot"
+
 class arch_sparc(generic_sparc):
        "builder class for generic sparc (sun4cdm)"
        def __init__(self,myspec):
                generic_sparc.__init__(self,myspec)
                self.settings["CFLAGS"]="-O2 -pipe"
-               self.settings["CXXFLAGS"]="-O2 -pipe"
+               self.settings["CHOST"]="sparc-unknown-linux-gnu"
+
+class arch_sparc64(generic_sparc64):
+       "builder class for generic sparc64 (sun4u)"
+       def __init__(self,myspec):
+               generic_sparc64.__init__(self,myspec)
+               self.settings["CFLAGS"]="-O2 -mcpu=ultrasparc -pipe"
                self.settings["CHOST"]="sparc-unknown-linux-gnu"
 
 def register():
        "Inform main catalyst program of the contents of this plugin."
-       return ({"sparc":arch_sparc}, ("sparc", ))
+       return ({
+               "sparc"         : arch_sparc,
+               "sparc64"       : arch_sparc64
+       }, ("sparc","sparc64", ))
diff --git a/arch/sparc64.py b/arch/sparc64.py
deleted file mode 100644 (file)
index df8b8e9..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-
-import builder,os
-from catalyst_support import *
-
-class generic_sparc64(builder.generic):
-       "abstract base class for all sparc64 builders"
-       def __init__(self,myspec):
-               builder.generic.__init__(self,myspec)
-               self.settings["CHROOT"]="chroot"
-
-class arch_sparc64(generic_sparc64):
-       "builder class for generic sparc64 (sun4u)"
-       def __init__(self,myspec):
-               generic_sparc64.__init__(self,myspec)
-               self.settings["CFLAGS"]="-O2 -mcpu=ultrasparc -pipe"
-               self.settings["CXXFLAGS"]="-O2 -mcpu=ultrasparc -pipe"
-               self.settings["CHOST"]="sparc-unknown-linux-gnu"
-
-def register():
-       "Inform main catalyst program of the contents of this plugin."
-       return ({"sparc64":arch_sparc64}, ("sparc64", ))