[zorg] r272331 - Removed few obsolete builder modules.

Galina Kistanova via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 9 15:51:55 PDT 2016


Author: gkistanova
Date: Thu Jun  9 17:51:54 2016
New Revision: 272331

URL: http://llvm.org/viewvc/llvm-project?rev=272331&view=rev
Log:
Removed few obsolete builder modules.

Removed:
    zorg/trunk/zorg/buildbot/builders/ChrootSetup.py
    zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py
    zorg/trunk/zorg/buildbot/builders/KLEEBuilder.py
    zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py
    zorg/trunk/zorg/buildbot/builders/gccSuiteBuilder.py

Removed: zorg/trunk/zorg/buildbot/builders/ChrootSetup.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/ChrootSetup.py?rev=272330&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/ChrootSetup.py (original)
+++ zorg/trunk/zorg/buildbot/builders/ChrootSetup.py (removed)
@@ -1,123 +0,0 @@
-import buildbot
-from buildbot.steps.shell import ShellCommand
-from buildbot.process.properties import WithProperties
-
-def addDarwinChrootSetup(f, build_root_images=[],
-                         build_root_name="BuildRoot", clean_build_root=False,
-                         dirs_to_clean=[]):
-    # Destroy the old build root, if requested.
-    if clean_build_root:
-        f.addStep(ShellCommand(name="rm.buildroot",
-                               command=["sudo", "rm", "-rf", build_root_name],
-                               haltOnFailure=False,
-                               description="rm build root",
-                               workdir="."))
-
-    # Clear out any requested directories.
-    for i,name in enumerate(dirs_to_clean):
-        f.addStep(ShellCommand(name="rm.buildroot_dir.%d" % i,
-                               command=["sudo", "rm", "-rf", name],
-                               description=["rm build root",repr(name)],
-                               haltOnFailure=True,
-                               workdir=build_root_name))
-
-    # Unmount /dev, so we don't try to restore it.
-    #
-    # FIXME: This shouldn't fail, except that it might not exist.
-    f.addStep(ShellCommand(name="chroot.init.umount.devfs",
-                           command=["sudo", "umount", "dev"],
-                           warnOnFailure=True,
-                           flunkOnFailure=False,
-                           haltOnFailure=False,
-                           description="umount devfs",
-                           workdir=build_root_name))
-
-    # For each image...
-    for i,image_info in enumerate(build_root_images):
-        # If this image is (image, package name) then assume this is a dmg with
-        # a package inside, which we should install.
-        if isinstance(image_info, tuple):
-            image,package_to_install = image_info
-        else:
-            image,package_to_install = image_info,None
-
-        # Setup the build root we will build projects in.
-        f.addStep(ShellCommand(
-                name="attach.buildroot",
-                command=("hdiutil attach -readonly -noverify "
-                         "-plist -mountrandom . %s | "
-                         "tee mount_info.plist") % image,
-                description="attach build root image",
-                haltOnFailure=True,
-                workdir="mounts"))
-
-        mount_point_property = "mount_point.%d" % i
-        f.addStep(buildbot.steps.shell.SetProperty(
-                name="get.mount_point.%d" % i,
-                property=mount_point_property,
-                command=["python", "-c", """\
-import plistlib
-data = plistlib.readPlist(open("mount_info.plist"))
-items = [i['mount-point'] for i in data.get('system-entities',[])
-         if 'mount-point' in i]
-if len(items) != 1:
-  raise SystemExit,'unable to determine mount point!'
-print items[0]
-"""],
-                description="get mount point",
-                haltOnFailure=True,
-                workdir="mounts"))
-
-        # Check whether we are install the package, or restoring the disk
-        # directly.
-        if package_to_install:
-            cmd = ["sudo", "installer", "-verboseR", "-pkg",
-                   WithProperties("%%(%s)s/%s" % (mount_point_property,
-                                                  package_to_install)),
-                   "-target",
-                   WithProperties("%%(builddir)s/%s" % build_root_name)]
-        else:
-            # Restore the build root.
-            cmd = ["sudo", "rsync", "-arv"]
-            if i == 0:
-                cmd.append("--delete")
-            cmd.extend(["--exclude", "/dev"])
-            cmd.extend([WithProperties("%%(%s)s/" % mount_point_property),
-                        "./"])
-        f.addStep(ShellCommand(
-                name="init.buildroot.%d" % i,
-                command=cmd,
-                haltOnFailure=True,
-                description="init build root",
-                workdir=build_root_name))
-
-        # Unmount the image.
-        f.addStep(ShellCommand(
-                name="detach.buildroot.%d" % i,
-                command=["hdiutil", "detach",
-                         WithProperties("%%(%s)s" % mount_point_property)],
-                warnOnFailure=True,
-                flunkOnFailure=False,
-                haltOnFailure=False,
-                description="detach build root image",
-                workdir="."))
-
-    # Remove the buildroot shared cache.
-    f.addStep(ShellCommand(name="chroot.init.rm.cache",
-                           command=["sudo", "rm", "-rf", "var/db/dyld"],
-                           haltOnFailure=True,
-                           description="rm chroot shared cache",
-                           workdir=build_root_name))
-
-    # Initialize /dev/.
-    f.addStep(ShellCommand(name="chroot.init.mkdir.dev",
-                           command=["sudo", "mkdir", "-p", "dev"],
-                           haltOnFailure=True,
-                           description="mkdir /dev",
-                           workdir=build_root_name))
-    f.addStep(ShellCommand(name="chroot.init.mount.devfs",
-                           command=["sudo", "mount", "-t", "devfs",
-                                    "devfs", "dev"],
-                           haltOnFailure=True,
-                           description="mount devfs",
-                           workdir=build_root_name))

Removed: zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py?rev=272330&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py (removed)
@@ -1,610 +0,0 @@
-import buildbot
-import buildbot.process.factory
-from buildbot.steps.source import SVN
-from buildbot.steps.shell import Configure, ShellCommand
-from buildbot.steps.shell import WarningCountingShellCommand
-from buildbot.process.properties import WithProperties
-from zorg.buildbot.commands.LitTestCommand import LitTestCommand
-from zorg.buildbot.commands.NightlyTestCommand import NightlyTestCommand
-
-def getCCSetting(gcc, gxx):
-  cc_settings = []
-  if gcc is not None:
-    cc_settings += [WithProperties('CC=' + gcc)]
-  if gxx is not None:
-    cc_settings += [WithProperties('CXX=' + gxx)]
-  return cc_settings
-
-def extractSearchPaths(rc, stdout, stderr):
-  mapping = {}
-  for l in stdout.split('\n'):
-    vals = l.split(': =', 1)
-    if len(vals) == 2:
-      mapping['gcc_' + vals[0]] = vals[1]
-  return mapping
-
-def getDragonEggBootstrapFactory(gcc_repository, extra_languages=[],
-                                 extra_gcc_configure_args=[],
-                                 extra_llvm_configure_args=[],
-                                 check_llvm=True, check_dragonegg=True,
-                                 clean=True, env={}, jobs='%(jobs)s',
-                                 timeout=20):
-    # Add gcc configure arguments required by the plugin.
-    gcc_configure_args = extra_gcc_configure_args + ['--enable-plugin',
-      '--enable-lto', ','.join(['--enable-languages=c,c++'] + extra_languages)]
-
-    llvm_configure_args = extra_llvm_configure_args
-
-    f = buildbot.process.factory.BuildFactory()
-
-    # Determine the build directory.
-    f.addStep(buildbot.steps.shell.SetProperty(name='get_builddir',
-                                               command=['pwd'],
-                                               property='builddir',
-                                               description='set build dir',
-                                               workdir='.', env=env))
-
-    # Checkout LLVM sources.
-    llvm_src_dir = 'llvm.src'
-    f.addStep(SVN(name='svn-llvm', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/llvm/',
-                  defaultBranch='trunk', workdir=llvm_src_dir, env=env))
-
-    # Checkout DragonEgg sources.
-    dragonegg_src_dir = 'dragonegg.src'
-    f.addStep(SVN(name='svn-dragonegg', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/dragonegg/',
-                  defaultBranch='trunk', workdir=dragonegg_src_dir, env=env))
-
-    # Checkout GCC.  This is usually a specific known good revision (supplied by
-    # appending @revision to the URL).  The SVN step can't handle that.  As it
-    # provides no mechanism at all for checking out a specific revision, just
-    # run the command directly here.
-    gcc_src_dir = 'gcc.src'
-    svn_co = ['svn', 'checkout', gcc_repository, gcc_src_dir]
-    f.addStep(ShellCommand(name='svn-gcc',
-                           command=svn_co,
-                           haltOnFailure=True,
-                           workdir='.', env=env))
-
-    gcc_install_dir = 'gcc.install'     # Names are embedded in object files, so
-    llvm_install_dir = 'llvm.install'   # would cause bootstrap comparison fails
-                                        # if they were different for each stage.
-
-    # Remove any install directories hanging over from a previous run.
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % gcc_install_dir,
-                               command=['rm', '-rf', gcc_install_dir],
-                               haltOnFailure=True,
-                               description=['rm install dir', 'gcc'],
-                               workdir='.', env=env))
-        f.addStep(ShellCommand(name='rm-%s' % llvm_install_dir,
-                               command=['rm', '-rf', llvm_install_dir],
-                               haltOnFailure=True,
-                               description=['rm install dir', 'llvm'],
-                               workdir='.', env=env))
-
-    # Do the boostrap.
-    cur_env = env
-    prev_gcc = None     # C compiler built during the previous stage.
-    prev_gxx = None     # C++ compiler built during the previous stage.
-    prev_plugin = None  # Plugin built during the previous stage.
-    for stage in 'stage1', 'stage2', 'stage3':
-
-      # Build and install GCC.
-      gcc_obj_dir = 'gcc.obj.%s' % stage
-      if clean:
-          f.addStep(ShellCommand(name='rm-%s' % gcc_obj_dir,
-                                 command=['rm', '-rf', gcc_obj_dir],
-                                 haltOnFailure=True,
-                                 description=['rm build dir', 'gcc', stage],
-                                 workdir='.', env=cur_env))
-      f.addStep(Configure(name='configure.gcc.%s' % stage,
-                          command=(['../' + gcc_src_dir + '/configure',
-                                    WithProperties('--prefix=%%(builddir)s/%s' % gcc_install_dir)] +
-                                   gcc_configure_args + getCCSetting(prev_gcc, prev_gxx)),
-                          haltOnFailure=True,
-                          description=['configure', 'gcc', stage],
-                          workdir=gcc_obj_dir, env=cur_env))
-      f.addStep(WarningCountingShellCommand(name='compile.gcc.%s' % stage,
-                                            command=['nice', '-n', '10',
-                                                     'make', WithProperties('-j%s' % jobs)],
-                                            haltOnFailure=True,
-                                            description=['compile', 'gcc', stage],
-                                            workdir=gcc_obj_dir, env=cur_env,
-                                            timeout=timeout*60))
-      f.addStep(WarningCountingShellCommand(name='install.gcc.%s' % stage,
-                                            command=['nice', '-n', '10',
-                                                     'make', 'install'],
-                                            haltOnFailure=True,
-                                            description=['install', 'gcc', stage],
-                                            workdir=gcc_obj_dir, env=cur_env))
-
-      # From this point on build everything using the just built GCC.
-      prev_gcc = '%(builddir)s/'+gcc_install_dir+'/bin/gcc'
-      prev_gxx = '%(builddir)s/'+gcc_install_dir+'/bin/g++'
-
-      # The built libstdc++ and libgcc may well be more recent than the system
-      # versions.  Set the library path so that programs compiled with the just
-      # built GCC will start successfully, rather than failing due to missing
-      # shared library dependencies.
-      f.addStep(buildbot.steps.shell.SetProperty(name='gcc.search.paths.%s' % stage,
-                                                 command=[WithProperties(prev_gcc),
-                                                          '-print-search-dirs'],
-                                                 extract_fn=extractSearchPaths,
-                                                 haltOnFailure=True,
-                                                 description=['gcc', 'search paths',
-                                                              stage], env=cur_env))
-      cur_env = cur_env.copy();
-      if 'LIBRARY_PATH' in env:
-        cur_env['LIBRARY_PATH'] = WithProperties('%(gcc_libraries)s'+':'+env['LIBRARY_PATH'])
-      else:
-        cur_env['LIBRARY_PATH'] = WithProperties('%(gcc_libraries)s')
-      if 'LD_LIBRARY_PATH' in env:
-        cur_env['LD_LIBRARY_PATH'] = WithProperties('%(gcc_libraries)s'+':'+env['LD_LIBRARY_PATH'])
-      else:
-        cur_env['LD_LIBRARY_PATH'] = WithProperties('%(gcc_libraries)s')
-
-      # Build everything using the DragonEgg plugin from the previous stage.
-      if prev_plugin is not None:
-        prev_gcc += ' -fplugin=' + prev_plugin
-        prev_gxx += ' -fplugin=' + prev_plugin
-
-      # Build LLVM with the just built GCC and install it.
-      llvm_obj_dir = 'llvm.obj.%s' % stage
-      if clean:
-          f.addStep(ShellCommand(name='rm-%s' % llvm_obj_dir,
-                                 command=['rm', '-rf', llvm_obj_dir],
-                                 haltOnFailure=True,
-                                 description=['rm build dir', 'llvm', stage],
-                                 workdir='.', env=cur_env))
-      f.addStep(Configure(name='configure.llvm.%s' % stage,
-                          command=(['../' + llvm_src_dir + '/configure',
-                                    WithProperties('--prefix=%%(builddir)s/%s' % llvm_install_dir)] +
-                                    llvm_configure_args + getCCSetting(prev_gcc, prev_gxx)),
-                          haltOnFailure=True,
-                          description=['configure', 'llvm', stage],
-                          workdir=llvm_obj_dir, env=cur_env))
-      f.addStep(WarningCountingShellCommand(name='compile.llvm.%s' % stage,
-                                            command=['nice', '-n', '10',
-                                                     'make', WithProperties('-j%s' % jobs)],
-                                            haltOnFailure=True,
-                                            description=['compile', 'llvm', stage],
-                                            workdir=llvm_obj_dir, env=cur_env,
-                                            timeout=timeout*60))
-
-      # Optionally run the LLVM testsuite.
-      if check_llvm:
-        f.addStep(LitTestCommand(name='check.llvm.%s' % stage,
-                                   command=['nice', '-n', '10', 'make',
-                                            WithProperties('LIT_ARGS=-v -j%s' % jobs),
-                                            'check-all'
-                                            ],
-                                   description=['test', 'llvm', stage],
-                                   haltOnFailure=True, workdir=llvm_obj_dir,
-                                   env=cur_env, timeout=timeout*60))
-
-      f.addStep(WarningCountingShellCommand(name='install.llvm.%s' % stage,
-                                            command=['nice', '-n', '10',
-                                                     'make', 'install'],
-                                            haltOnFailure=True,
-                                            description=['install', 'llvm', stage],
-                                            workdir=llvm_obj_dir, env=cur_env))
-
-      # Build dragonegg with the just built LLVM and GCC.
-      dragonegg_pre_obj_dir = 'dragonegg.obj.pre.%s' % stage
-      if clean:
-          f.addStep(ShellCommand(name='rm-%s' % dragonegg_pre_obj_dir,
-                                 command=['rm', '-rf', dragonegg_pre_obj_dir],
-                                 description=['rm build dir', 'dragonegg pre', stage],
-                                 haltOnFailure=True, workdir='.', env=cur_env))
-      f.addStep(WarningCountingShellCommand(
-              name='compile.dragonegg.pre.%s' % stage,
-              command=['nice', '-n', '10',
-                       'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                       WithProperties('-j%s' % jobs),
-                       WithProperties('GCC=%(builddir)s/'+gcc_install_dir+'/bin/gcc'),
-                       WithProperties('LLVM_CONFIG=%(builddir)s/'+llvm_install_dir+'/bin/llvm-config'),
-                       WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir)
-                       ] + getCCSetting(prev_gcc, prev_gxx),
-              haltOnFailure=True,
-              description=['compile', 'dragonegg pre', stage],
-              workdir=dragonegg_pre_obj_dir, env=cur_env,
-              timeout=timeout*60))
-      prev_gcc = '%(builddir)s/'+gcc_install_dir+'/bin/gcc -fplugin=%(builddir)s/'+dragonegg_pre_obj_dir+'/dragonegg.so'
-      prev_gxx = '%(builddir)s/'+gcc_install_dir+'/bin/g++ -fplugin=%(builddir)s/'+dragonegg_pre_obj_dir+'/dragonegg.so'
-
-      # Now build dragonegg again using the just built dragonegg.  The build is
-      # always done in the same directory to ensure that object files built by
-      # the different stages should be the same (the build directory name ends
-      # up in object files via debug info), then moved to a per-stage directory.
-      dragonegg_bld_dir = 'dragonegg.obj' # The common build directory.
-      dragonegg_obj_dir = 'dragonegg.obj.%s' % stage # The per-stage directory.
-      f.addStep(ShellCommand(name='rm-%s' % dragonegg_obj_dir,
-                             command=['rm', '-rf', dragonegg_bld_dir,
-                                      dragonegg_obj_dir],
-                             description=['rm build dirs', 'dragonegg', stage],
-                             haltOnFailure=True, workdir='.', env=cur_env))
-      f.addStep(WarningCountingShellCommand(
-              name='compile.dragonegg.%s' % stage,
-              command=['nice', '-n', '10',
-                       'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                       'DISABLE_VERSION_CHECK=1',
-                       WithProperties('-j%s' % jobs),
-                       WithProperties('GCC=%(builddir)s/'+gcc_install_dir+'/bin/gcc'),
-                       WithProperties('LLVM_CONFIG=%(builddir)s/'+llvm_install_dir+'/bin/llvm-config'),
-                       WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir)
-                       ] + getCCSetting(prev_gcc, prev_gxx),
-              description=['compile', 'dragonegg', stage], haltOnFailure=True,
-              workdir=dragonegg_bld_dir, env=cur_env, timeout=timeout*60))
-      f.addStep(ShellCommand(name='mv-%s' % dragonegg_obj_dir,
-                             command=['mv', dragonegg_bld_dir,
-                                      dragonegg_obj_dir],
-                             description=['mv build dir', 'dragonegg', stage],
-                             haltOnFailure=True, workdir='.', env=cur_env))
-
-      # Optionally run the dragonegg testsuite.
-      if check_dragonegg:
-        f.addStep(LitTestCommand(name='check.dragonegg.%s' % stage,
-                                   command=['nice', '-n', '10',
-                                            'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                                            WithProperties('GCC=%(builddir)s/'+gcc_install_dir+'/bin/gcc'),
-                                            WithProperties('LLVM_CONFIG=%(builddir)s/' +
-                                                           llvm_install_dir + '/bin/llvm-config'),
-                                            WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir),
-                                            WithProperties('LIT_ARGS=-v -j%s' % jobs),
-                                            'check'
-                                            ],
-                                   description=['test', 'dragonegg', stage],
-                                   haltOnFailure=True, workdir=dragonegg_obj_dir,
-                                   env=cur_env, timeout=timeout*60))
-
-      # Ensure that the following stages use the just built plugin.
-      prev_plugin = '%(builddir)s/'+dragonegg_obj_dir+'/dragonegg.so'
-      prev_gcc = '%(builddir)s/'+gcc_install_dir+'/bin/gcc -fplugin=' + prev_plugin
-      prev_gxx = '%(builddir)s/'+gcc_install_dir+'/bin/g++ -fplugin=' + prev_plugin
-
-    # Check that the dragonegg objects didn't change between stages 2 and 3.
-    f.addStep(ShellCommand(name='compare.stages',
-                           command=['sh', '-c', 'for O in *.o ; do cmp ' +
-                                    '../dragonegg.obj.stage2/$O ' +
-                                    '../dragonegg.obj.stage3/$O || exit 1 ; ' +
-                                    'done'],
-                           haltOnFailure=True,
-                           description='compare stages 2 and 3',
-                           workdir='dragonegg.obj.stage3', env=cur_env))
-
-    return f
-
-
-def getDragonEggNightlyTestBuildFactory(gcc='gcc', gxx='g++',
-                                        llvm_configure_args=[],
-                                        testsuite_configure_args=[],
-                                        xfails=[], clean=True, env={},
-                                        jobs='%(jobs)s', timeout=20):
-    f = buildbot.process.factory.BuildFactory()
-
-    # Determine the build directory.
-    f.addStep(buildbot.steps.shell.SetProperty(name='get_builddir',
-                                               command=['pwd'],
-                                               property='builddir',
-                                               description='set build dir',
-                                               workdir='.', env=env))
-
-    # Checkout LLVM sources.
-    llvm_src_dir = 'llvm.src'
-    f.addStep(SVN(name='svn-llvm', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/llvm/',
-                  defaultBranch='trunk', workdir=llvm_src_dir, env=env))
-
-    # Checkout DragonEgg sources.
-    dragonegg_src_dir = 'dragonegg.src'
-    f.addStep(SVN(name='svn-dragonegg', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/dragonegg/',
-                  defaultBranch='trunk', workdir=dragonegg_src_dir, env=env))
-
-    # Checkout the test-suite sources.
-    testsuite_src_dir = 'test-suite.src'
-    f.addStep(SVN(name='svn-test-suite', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/test-suite/',
-                  defaultBranch='trunk', workdir=testsuite_src_dir, env=env))
-
-    # Build and install LLVM.
-    llvm_obj_dir = 'llvm.obj'
-    llvm_install_dir = 'llvm.install'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % llvm_obj_dir,
-                               command=['rm', '-rf', llvm_obj_dir,
-                                        llvm_install_dir],
-                               description='rm build dir llvm',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(Configure(name='configure.llvm',
-                        command=(['../' + llvm_src_dir + '/configure',
-                                  WithProperties('--prefix=%%(builddir)s/%s' % llvm_install_dir)] +
-                                 llvm_configure_args),
-                        description='configuring llvm',
-                        descriptionDone='configure llvm',
-                        haltOnFailure=True, workdir=llvm_obj_dir, env=env))
-    f.addStep(WarningCountingShellCommand(name='compile.llvm',
-                                          command=['nice', '-n', '10',
-                                                   'make', WithProperties('-j%s' % jobs)],
-                                          haltOnFailure=True,
-                                          description='compiling llvm',
-                                          descriptionDone='compile llvm',
-                                          workdir=llvm_obj_dir, env=env,
-                                          timeout=timeout*60))
-    f.addStep(WarningCountingShellCommand(name='install.llvm',
-                                          command=['nice', '-n', '10',
-                                                   'make', 'install'],
-                                          haltOnFailure=True,
-                                          description='installing llvm',
-                                          descriptionDone='install llvm',
-                                          workdir=llvm_obj_dir, env=env))
-
-    # Build dragonegg with the just built LLVM.
-    dragonegg_obj_dir = 'dragonegg.obj'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % dragonegg_obj_dir,
-                               command=['rm', '-rf', dragonegg_obj_dir],
-                               description='rm build dir dragonegg',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(WarningCountingShellCommand(
-            name='compile.dragonegg',
-            command=['nice', '-n', '10',
-                     'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                     WithProperties('-j%s' % jobs),
-                     WithProperties('GCC=' + gcc),
-                     WithProperties('LLVM_CONFIG=%(builddir)s/' +
-                                    llvm_install_dir + '/bin/llvm-config'),
-                     WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir)
-                     ],
-            haltOnFailure=True,
-            description='compiling dragonegg',
-            descriptionDone='compile dragonegg',
-            workdir=dragonegg_obj_dir, env=env, timeout=timeout*60))
-
-    # Pretend that DragonEgg is llvm-gcc by creating llvm-gcc and llvm-g++
-    # scripts that dispatch to gcc with dragonegg and g++ with dragonegg.
-    if clean:
-        f.addStep(ShellCommand(name='rm-bin',
-                               command=['rm', '-rf', 'bin'],
-                               description='rm bin dir',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(ShellCommand(name='create.llvm-gcc.script',
-                           command=WithProperties('echo "#!/bin/sh" > llvm-gcc'
-                             '; echo "exec ' + gcc + ' -fplugin=%(builddir)s/' +
-                             dragonegg_obj_dir + '/dragonegg.so \\"\$@\\"" >> llvm-gcc'
-                             '; chmod a+x llvm-gcc'),
-                           description='create llvm-gcc script',
-                           haltOnFailure=True, workdir='bin', env=env))
-    f.addStep(ShellCommand(name='create.llvm-g++.script',
-                           command=WithProperties('echo "#!/bin/sh" > llvm-g++'
-                             '; echo "exec ' + gxx + ' -fplugin=%(builddir)s/' +
-                             dragonegg_obj_dir + '/dragonegg.so \\"\$@\\"" >> llvm-g++'
-                             '; chmod a+x llvm-g++'),
-                           description='create llvm-g++ script',
-                           haltOnFailure=True, workdir='bin', env=env))
-
-    # Configure the test-suite.
-    testsuite_obj_dir = 'test-suite.obj'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % testsuite_obj_dir,
-                               command=['rm', '-rf', testsuite_obj_dir],
-                               description='rm test-suite build dir',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(Configure(name='configure.test-suite',
-                        command=['../' + testsuite_src_dir + '/configure',
-                                 WithProperties('--with-llvmsrc=%(builddir)s/' + llvm_src_dir),
-                                 WithProperties('--with-llvmobj=%(builddir)s/' + llvm_obj_dir),
-                                 WithProperties('--with-llvmgccdir=%(builddir)s/'),
-                                 '--with-llvmcc=llvm-gcc', 'CC=' + gcc, 'CXX=' + gxx] +
-                                 testsuite_configure_args,
-                        description='configuring nightly test-suite',
-                        descriptionDone='configure nightly test-suite',
-                        haltOnFailure=True, workdir=testsuite_obj_dir, env=env))
-
-    # Build and test.
-    f.addStep(ShellCommand(name='rm.test-suite.report',
-                           command=['rm', '-rf', testsuite_obj_dir + '/report',
-                                    testsuite_obj_dir + '/report.nightly.raw.out',
-                                    testsuite_obj_dir + '/report.nightly.txt'],
-                           description='rm test-suite report',
-                           haltOnFailure=True, workdir='.', env=env))
-    f.addStep(NightlyTestCommand(name='make.test-suite',
-                                 command=['make', WithProperties('-j%s' % jobs),
-                                          'ENABLE_PARALLEL_REPORT=1',
-                                          'DISABLE_CBE=1', 'DISABLE_JIT=1',
-                                          'RUNTIMELIMIT=%s' % (timeout*60),
-                                          'TEST=nightly', 'report'],
-                                 logfiles={'report' : 'report.nightly.txt'},
-                                 description='running nightly test-suite',
-                                 descriptionDone='run nightly test-suite',
-                                 haltOnFailure=True, xfails=xfails,
-                                 timeout=timeout*60,
-                                 workdir=testsuite_obj_dir, env=env))
-
-    return f
-
-
-def getDragonEggTestBuildFactory(gcc='gcc', svn_testsuites=[],
-                                 llvm_configure_args=[], xfails=[],
-                                 clean=True, env={}, jobs='%(jobs)s',
-                                 timeout=20):
-    f = buildbot.process.factory.BuildFactory()
-
-    # Determine the build directory.
-    f.addStep(buildbot.steps.shell.SetProperty(name='get_builddir',
-                                               command=['pwd'],
-                                               property='builddir',
-                                               description='set build dir',
-                                               workdir='.', env=env))
-
-    # Checkout LLVM sources.
-    llvm_src_dir = 'llvm.src'
-    f.addStep(SVN(name='svn-llvm', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/llvm/',
-                  defaultBranch='trunk', workdir=llvm_src_dir, env=env))
-
-    # Checkout DragonEgg sources.
-    dragonegg_src_dir = 'dragonegg.src'
-    f.addStep(SVN(name='svn-dragonegg', mode='update',
-                  baseURL='http://llvm.org/svn/llvm-project/dragonegg/',
-                  defaultBranch='trunk', workdir=dragonegg_src_dir, env=env))
-
-    # Checkout victims for the compilator.
-    compilator_dir = dragonegg_src_dir + '/test/compilator'
-
-    # Checkout testsuites held in subversion repositories.  These are usually
-    # specified using a known good revision (supplied by appending @revision to
-    # the URL).  The SVN step can't handle that.  As it provides no mechanism at
-    # all for checking out a specific revision, run the command directly here.
-    for svn_testsuite in svn_testsuites:
-        url = svn_testsuite[0]
-        name = svn_testsuite[1]
-        if url is None:
-            f.addStep(ShellCommand(name='rm-%s' % name,
-                                   command=['rm', '-rf', name],
-                                   description=['rm', name], haltOnFailure=True,
-                                   workdir=compilator_dir, env=env))
-        else:
-            svn_co = ['svn', 'checkout', url, name]
-            f.addStep(ShellCommand(name=name, command=svn_co,
-                                   haltOnFailure=True, workdir=compilator_dir,
-                                   env=env))
-
-    # Checkout miscellaneous testsuites.
-
-    # LAPACK.
-    f.addStep(ShellCommand(name='wget.lapack',
-                           command='wget -N http://www.netlib.org/lapack/lapack-3.4.0.tgz',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='unpack.lapack',
-                           command='tar xzf lapack-3.4.0.tgz',
-                           haltOnFailure=True, workdir=compilator_dir,
-                           env=env))
-
-    # Nist Fortran 77 test suite.
-    f.addStep(ShellCommand(name='wget.nist',
-                           command='wget -N http://www.itl.nist.gov/div897/ctg/suites/fcvs21.tar.Z',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='unpack.nist',
-                           command='tar xzf ../fcvs21.tar.Z',
-                           haltOnFailure=True, workdir=compilator_dir+'/fcvs21/',
-                           env=env))
-
-    # Polyhedron.
-    f.addStep(ShellCommand(name='wget.polyhedron',
-                           command='wget -N http://www.polyhedron.com/web_images/documents/pb11.zip',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='unpack.polyhedron',
-                           command='unzip -o pb11.zip',
-                           haltOnFailure=True, workdir=compilator_dir,
-                           env=env))
-
-    # Large single compilation-unit C programs.
-    f.addStep(ShellCommand(name='wget.bzip2',
-                           command='wget -N http://people.csail.mit.edu/smcc/projects/single-file-programs/bzip2.c',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='wget.gzip',
-                           command='wget -N http://people.csail.mit.edu/smcc/projects/single-file-programs/gzip.c',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='fix.gzip',
-                           command='sed -i "s/^static char \*$/char */" gzip.c',
-                           haltOnFailure=True, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='wget.oggenc',
-                           command='wget -N http://people.csail.mit.edu/smcc/projects/single-file-programs/oggenc.c',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='wget.gcc',
-                           command='wget -N http://people.csail.mit.edu/smcc/projects/single-file-programs/gcc.c.bz2',
-                           haltOnFailure=False, workdir=compilator_dir,
-                           env=env))
-    f.addStep(ShellCommand(name='unpack.gcc',
-                           command='bunzip2 -f -k gcc.c.bz2',
-                           haltOnFailure=True, workdir=compilator_dir,
-                           env=env))
-
-    # Build and install LLVM.
-    llvm_obj_dir = 'llvm.obj'
-    llvm_install_dir = 'llvm.install'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % llvm_obj_dir,
-                               command=['rm', '-rf', llvm_obj_dir,
-                                        llvm_install_dir],
-                               description='rm build dir llvm',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(Configure(name='configure.llvm',
-                        command=(['../' + llvm_src_dir + '/configure',
-                                  WithProperties('--prefix=%%(builddir)s/%s' % llvm_install_dir)] +
-                                 llvm_configure_args),
-                        description='configuring llvm',
-                        descriptionDone='configure llvm',
-                        haltOnFailure=True, workdir=llvm_obj_dir, env=env))
-    f.addStep(WarningCountingShellCommand(name='compile.llvm',
-                                          command=['nice', '-n', '10',
-                                                   'make', WithProperties('-j%s' % jobs)],
-                                          haltOnFailure=True,
-                                          description='compiling llvm',
-                                          descriptionDone='compile llvm',
-                                          workdir=llvm_obj_dir, env=env,
-                                          timeout=timeout*60))
-    f.addStep(WarningCountingShellCommand(name='install.llvm',
-                                          command=['nice', '-n', '10',
-                                                   'make', 'install'],
-                                          haltOnFailure=True,
-                                          description='installing llvm',
-                                          descriptionDone='install llvm',
-                                          workdir=llvm_obj_dir, env=env))
-
-    # Build dragonegg with the just built LLVM.
-    dragonegg_obj_dir = 'dragonegg.obj'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % dragonegg_obj_dir,
-                               command=['rm', '-rf', dragonegg_obj_dir],
-                               description='rm build dir dragonegg',
-                               haltOnFailure=True, workdir='.', env=env))
-    f.addStep(WarningCountingShellCommand(
-            name='compile.dragonegg',
-            command=['nice', '-n', '10',
-                     'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                     WithProperties('-j%s' % jobs),
-                     WithProperties('GCC=' + gcc),
-                     WithProperties('LLVM_CONFIG=%(builddir)s/' +
-                                    llvm_install_dir + '/bin/llvm-config'),
-                     WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir)
-                     ],
-            haltOnFailure=True,
-            description='compiling dragonegg',
-            descriptionDone='compile dragonegg',
-            workdir=dragonegg_obj_dir, env=env, timeout=timeout*60))
-
-    # Run the dragonegg testsuite.
-    testsuite_output_dir = dragonegg_obj_dir + '/test/Output'
-    if clean:
-        f.addStep(ShellCommand(name='rm-%s' % testsuite_output_dir,
-                               command=['rm', '-rf', testsuite_output_dir],
-                               description='rm test-suite output directory',
-                               haltOnFailure=True, workdir='.', env=env))
-
-    f.addStep(LitTestCommand(name='make.check',
-                               command=['nice', '-n', '10',
-                                        'make', '-f', '../' + dragonegg_src_dir + '/Makefile',
-                                        WithProperties('GCC=' + gcc),
-                                        WithProperties('LLVM_CONFIG=%(builddir)s/' +
-                                                       llvm_install_dir + '/bin/llvm-config'),
-                                        WithProperties('TOP_DIR=%(builddir)s/' + dragonegg_src_dir),
-                                        WithProperties('LIT_ARGS=-v -j%s' % jobs),
-                                        'check'
-                                        ],
-                               description='running test-suite',
-                               descriptionDone='run test-suite',
-                               haltOnFailure=True, workdir=dragonegg_obj_dir,
-                               env=env, timeout=timeout*60))
-
-    return f

Removed: zorg/trunk/zorg/buildbot/builders/KLEEBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/KLEEBuilder.py?rev=272330&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/KLEEBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/KLEEBuilder.py (removed)
@@ -1,83 +0,0 @@
-import os
-
-import buildbot
-import buildbot.process.factory
-from buildbot.steps.source import SVN
-from buildbot.steps.shell import Configure, ShellCommand
-from buildbot.steps.shell import WarningCountingShellCommand
-from buildbot.process.properties import WithProperties
-
-import ClangBuilder
-import LLVMBuilder
-reload(LLVMBuilder)
-import LLVMBuilder
-from Util import getConfigArgs
-
-from zorg.buildbot.commands.DejaGNUCommand import DejaGNUCommand
-
-def getKLEEBuildFactory(triple, jobs='%(jobs)d', llvm_branch='trunk',
-                        config_name='Release+Asserts', clean=True, llvmgccdir=None,
-                        *args, **kwargs):
-    if False:
-        f = buildbot.process.factory.BuildFactory()
-
-        # Determine the build directory.
-        f.addStep(buildbot.steps.shell.SetProperty(name="get_builddir",
-                                                   command=["pwd"],
-                                                   property="builddir",
-                                                   description="set build dir",
-                                                   workdir="."))
-    else:
-        # If we are building from trunk, we need to build Clang as
-        # well so we have access to an LLVM capable compiler.
-        if llvm_branch == 'trunk':
-            f = ClangBuilder.getClangBuildFactory(triple, jobs=jobs,
-                                                  stage1_config=config_name, extra_configure_args=['--with-built-clang',
-                                                                                                   '--enable-targets=host',
-                                                                                                   '--with-llvmcc=clang'],
-                                                  clean=clean, test=False, *args, **kwargs)
-        else:
-            f = LLVMBuilder.getLLVMBuildFactory(triple, jobs=jobs, defaultBranch=llvm_branch,
-                                                config_name=config_name, llvmgccdir=llvmgccdir,
-                                                enable_targets='x86', clean=clean, test=False,
-                                                *args, **kwargs)
-
-    # Checkout sources.
-    f.addStep(SVN(name='svn-klee',
-                  mode='update', baseURL='http://llvm.org/svn/llvm-project/klee/',
-                  defaultBranch='trunk', workdir='klee'))
-
-    # Configure.
-    configure_args = ["./configure", WithProperties("--with-llvm=%(builddir)s/llvm")]
-    configure_args += getConfigArgs(config_name)
-    if triple:
-        configure_args += ['--build=%s' % triple,
-                           '--host=%s' % triple,
-                           '--target=%s' % triple]
-    f.addStep(Configure(command=configure_args, workdir='klee',
-                        description=['configure','klee',config_name]))
-
-    # Clean, if requested.
-    if clean:
-        f.addStep(WarningCountingShellCommand(name="clean-klee",
-                                              command=['make', 'clean'],
-                                              haltOnFailure=True,
-                                              description="clean klee",
-                                              workdir='klee'))
-
-    # Compile.
-    f.addStep(WarningCountingShellCommand(name="compile",
-                                          command=['nice', '-n', '10',
-                                                   'make', WithProperties("-j%s" % jobs)],
-                                          haltOnFailure=True, description="compile klee",
-                                          workdir='klee'))
-
-    # Test.
-    f.addStep(DejaGNUCommand(name="test",
-                             command=['nice', '-n', '10',
-                                      'make', 'check'],
-                             haltOnFailure=True, description="test klee",
-                             workdir='klee',
-                             logfiles={ 'dg.sum' : 'test/testrun.sum' }))
-
-    return f

Removed: zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py?rev=272330&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py (removed)
@@ -1,107 +0,0 @@
-import buildbot
-from buildbot.steps.shell import WarningCountingShellCommand, SetProperty
-from buildbot.process.properties import WithProperties
-
-def getScriptedBuildFactory(
-                      source_code  = [],   # List of source code check out commands.
-                      launcher     = None, # Build script launcher name.
-                      build_script = None, # Build script name or common prefix.
-                      extra_args   = [],   # Extra args common for all steps.
-                      build_steps  = [],   # List of step commands.
-                      env          = {},   # Environmental variables for all steps.
-                      timeout      = 20):  # Timeout if no activity seen (minutes).
-
-    # Validate input parameters
-    if not launcher:
-      raise ValueError,"Must specify launcher."
-
-    f = buildbot.process.factory.BuildFactory()
-
-    # Determine the build directory.
-    f.addStep(
-      buildbot.steps.shell.SetProperty(
-        name        = "get.builddir",
-        command     = ["pwd"],
-        property    = "builddir",
-        description = "set build dir",
-        workdir     = "."))
-
-    # Common for all steps arguments
-    scripted_step_common_args = list()
-    # build_script is optional but must go first if given.
-    if build_script:
-      scripted_step_common_args.append(WithProperties(build_script))
-
-    # Get all the source code directories we need for this build.
-    for checkout in source_code:
-      # Store the list of source code directories in the original order for later use.
-      # Note: We require all spaces and special characters already escaped.
-      try:
-        src_dir = checkout.workdir
-        if src_dir:
-          scripted_step_common_args.append(WithProperties(src_dir))
-      except AttributeError:
-        # workdir property is missing. Skip it.
-        pass
-
-      # Get the source code from version control system
-      f.addStep(checkout)
-
-    # The last common arg is build directory
-    scripted_step_common_args.append(WithProperties("%(builddir)s"))
-
-    # Run build script for each requested step
-    for step_params in build_steps:
-      # TODO: Validate type step_params is dict 
-
-      # Handle some of the parameters here.
-      scripted_step_name            = step_params.pop('name',            None)
-      scripted_step_type            = step_params.pop('type',            WarningCountingShellCommand)
-      scripted_step_description     = step_params.pop('description',     None)
-      scripted_step_descriptionDone = step_params.pop('descriptionDone', None)
-      scripted_step_extra_args      = step_params.pop('extra_args',      [])
-      scripted_step_env             = step_params.pop('env',             {})
-      # The rest will pass through.
-
-      assert 'command' not in step_params, "Command is generated, please do not specify it."
-
-      # scripted_step_extra_args must be a list
-      if isinstance(scripted_step_extra_args, str):
-          scripted_step_extra_args = [scripted_step_extra_args]
-
-      # Combine together common env and step-specific env
-      scripted_step_env.update(env)
-      step_params['env'] = scripted_step_env
-
-      f.addStep(
-        scripted_step_type(
-          name            = "run.build.step." + scripted_step_name,
-          description     = scripted_step_description,
-          descriptionDone = scripted_step_descriptionDone,
-          command = (
-            [WithProperties("%(builddir)s/"      + launcher)] +
-            scripted_step_common_args            +  # Common args
-            [WithProperties(scripted_step_name)] +  # The requested step name
-            scripted_step_extra_args             +  # Step-specific extra args 
-            extra_args                              # Common extra args
-          ),
-          **step_params))
-
-    if len(build_steps) == 0: # If no steps were defined.
-
-      # Run the build_script once
-      f.addStep(
-          WarningCountingShellCommand(
-            name="run.build.script",
-            command=(
-              [WithProperties("%(builddir)s/"    + launcher)] +
-              scripted_step_common_args          +  # Common args
-              extra_args                            # Common extra args
-            ),
-            haltOnFailure = True,
-            description   = "Run build script",
-            workdir       = ".",
-            env           = env,
-            timeout       = timeout*60))
-
-    return f

Removed: zorg/trunk/zorg/buildbot/builders/gccSuiteBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/gccSuiteBuilder.py?rev=272330&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/gccSuiteBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/gccSuiteBuilder.py (removed)
@@ -1,27 +0,0 @@
-import os
-import buildbot
-from zorg.buildbot.util.phasedbuilderutils import getBuildDir, setProperty
-from zorg.buildbot.util.artifacts import GetCompilerArtifacts
-import zorg.buildbot.builders.ClangBuilder as ClangBuilder
-
-def gccRunSuite(languages):
-    f = buildbot.process.factory.BuildFactory()
-    # Determine the build directory.
-    getBuildDir(f)
-    # Download compiler from upstream builder.
-    GetCompilerArtifacts(f)
-    # Load the ignore set.
-    #
-    # FIXME: This is lame, it is only loaded at startup.
-    ignores = ClangBuilder.getClangTestsIgnoresFromPath(
-        os.path.expanduser('~/public/clang-tests'),
-        'clang-x86_64-darwin10')
-    # Convert languages to GCC style names.
-    languages = [{'c' : 'gcc', 'c++' : 'g++', 'obj-c' : 'objc',
-                  'obj-c++' : 'obj-c++'}[l]
-                 for l in languages]
-    # Run gcc test suite.
-    ClangBuilder.addClangGCCTests(f, ignores,
-                                  install_prefix = '%(builddir)s/host-compiler',
-                                  languages = languages)
-    return f




More information about the llvm-commits mailing list