extras-buildsys/builder builder.py,1.20,1.21

Daniel Williams (dcbw) fedora-extras-commits at redhat.com
Mon Jul 18 21:26:26 UTC 2005


Author: dcbw

Update of /cvs/fedora/extras-buildsys/builder
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv18535/builder

Modified Files:
	builder.py 
Log Message:
2005-07-18  Dan Williams <dcbw at redhat.com>

    * builder/builder.py
      common/ArchUtils.py
      server/PackageJob.py
        - Allow the server and builder to actually build "sub" arches
            like i486/sparcv9/etc, which broke after the the builder
            changes on 2005-07-16




Index: builder.py
===================================================================
RCS file: /cvs/fedora/extras-buildsys/builder/builder.py,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- builder.py	18 Jul 2005 21:11:26 -0000	1.20
+++ builder.py	18 Jul 2005 21:26:24 -0000	1.21
@@ -30,6 +30,7 @@
 import fcntl
 import urllib
 import errno
+from plague import ArchUtils
 from plague import FileDownloader
 from plague import AuthedXMLRPCServer
 from plague import lighttpdManager
@@ -629,10 +630,21 @@
             print "Unrecognized config %s, ignoring." % cfg_name
             continue
         if distro == config_opts['distro_name'] and repo == config_opts['repo_name']:
+            # 'arch' is by definition the "master" arch, ie i386 or x86_64,
+            # not i486/i586/ia32e/etc.  We want to add on the "sub" arches
+            # that this builder supports to its list of arches it can build
+            # for this target
             if arch in allowed_arches:
                 if not target_arches.has_key(target):
                     target_arches[target] = []
                 target_arches[target].append(arch)
+                
+                # Add applicable "sub" arches, like i486, sparcv9, etc
+                for sub_arch in allowed_arches:
+                    if ArchUtils.sub_arches.has_key(sub_arch) and ArchUtils.sub_arches[sub_arch] == arch:
+                        if not sub_arch in target_arches[target]:
+                            target_arches[target].append(sub_arch)
+
     return target_arches
 
 




More information about the scm-commits mailing list