[llvm-commits] [zorg] r96939 - in /zorg/trunk: buildbot/osuosl/master/config/builders.py buildbot/osuosl/master/config/slaves.py zorg/buildbot/builders/DragonEggBuilder.py
Daniel Dunbar
daniel at zuster.org
Tue Feb 23 03:37:45 PST 2010
Author: ddunbar
Date: Tue Feb 23 05:37:45 2010
New Revision: 96939
URL: http://llvm.org/viewvc/llvm-project?rev=96939&view=rev
Log:
Sketch initial cut at DragonEgg builder.
Added:
zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py
Modified:
zorg/trunk/buildbot/osuosl/master/config/builders.py
zorg/trunk/buildbot/osuosl/master/config/slaves.py
Modified: zorg/trunk/buildbot/osuosl/master/config/builders.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/buildbot/osuosl/master/config/builders.py?rev=96939&r1=96938&r2=96939&view=diff
==============================================================================
--- zorg/trunk/buildbot/osuosl/master/config/builders.py (original)
+++ zorg/trunk/buildbot/osuosl/master/config/builders.py Tue Feb 23 05:37:45 2010
@@ -1,5 +1,9 @@
from zorg.buildbot.builders import ClangBuilder, LLVMBuilder, LLVMGCCBuilder
+from zorg.buildbot.builders import DragonEggBuilder
+reload(DragonEggBuilder)
+from zorg.buildbot.builders import DragonEggBuilder
+
# Plain LLVM builders.
def _get_llvm_builders():
return [
@@ -111,7 +115,8 @@
verbose=True,
env={ 'PATH' : '/cross-tools/bin:/usr/bin:/bin:/usr/sbin:/sbin' },
),
- 'category':'llvm-gcc.exp'},
+ 'category':'llvm-gcc'},
+
{'name' : "clang-x86_64-darwin10-selfhost-rel",
'slavenames' : ["dunbar-darwin10"],
'builddir' : "clang-x86_64-darwin10-selfhost-rel",
@@ -120,6 +125,12 @@
stage1_config='Release',
stage2_config='Release'),
'category' : 'clang.exp' },
+
+ {'name' : 'dragonegg-x86_64-linux',
+ 'slavenames' : ['baldrick2'],
+ 'builddir' : 'dragonegg-x86_64-linux',
+ 'factory' : DragonEggBuilder.getBuildFactory(triple='x86_64-pc-linux-gnu'),
+ 'category' : 'dragonegg.exp' },
]
def get_builders():
Modified: zorg/trunk/buildbot/osuosl/master/config/slaves.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/buildbot/osuosl/master/config/slaves.py?rev=96939&r1=96938&r2=96939&view=diff
==============================================================================
--- zorg/trunk/buildbot/osuosl/master/config/slaves.py (original)
+++ zorg/trunk/buildbot/osuosl/master/config/slaves.py Tue Feb 23 05:37:45 2010
@@ -46,6 +46,10 @@
# Win XP SP2, Intel Core2 Duo 2.99GHz -E6850, 2.93 GB
create_slave("adobe1", properties={'jobs' : 2}, max_builds=1),
+ # GCC Farm Slaves, for DragonEgg
+ create_slave("baldrick1", properties={'jobs' : 2}, max_builds=1),
+ create_slave("baldrick2", properties={'jobs' : 4}, max_builds=1),
+
# Defunct.
#create_slave("osu2", properties={'jobs' : 4}, max_builds=2),
#create_slave("andrew1"),
Added: zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py?rev=96939&view=auto
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py (added)
+++ zorg/trunk/zorg/buildbot/builders/DragonEggBuilder.py Tue Feb 23 05:37:45 2010
@@ -0,0 +1,144 @@
+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
+
+def getBuildFactory(triple, clean=True,
+ jobs='%(jobs)s'):
+ # FIXME: Move out.
+ env = {}
+ configure_args = ["--enable-lto", "--enable-languages=c,c++", "--disable-bootstrap",
+ "--disable-multilib", "--enable-checking",
+ "--with-mpfr=/opt/cfarm/mpfr-2.4.1", "--with-gmp=/opt/cfarm/gmp-4.2.4",
+ "--with-mpc=/opt/cfarm/mpc-0.8", "--with-libelf=/opt/cfarm/libelf-0.8.12"]
+
+ 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="."))
+
+ # Checkout LLVM sources.
+ f.addStep(SVN(name='svn-llvm',
+ mode='update', baseURL='http://llvm.org/svn/llvm-project/llvm/',
+ defaultBranch='trunk',
+ workdir='llvm.src'))
+
+ # Checkout DragonEgg sources.
+ f.addStep(SVN(name='svn-dragonegg',
+ mode='update', baseURL='http://llvm.org/svn/llvm-project/dragonegg/',
+ defaultBranch='trunk',
+ workdir='dragonegg.src'))
+
+ # Revert any DragonEgg patches.
+ f.addStep(ShellCommand(name='patch.revert.gcc',
+ command=['svn','revert','-R','gcc'],
+ workdir='gcc.src',
+ haltOnFailure=False))
+
+ # Checkout GCC sources.
+ #
+ # FIXME: This is going to mess up revision numbers.
+ f.addStep(SVN(name='svn-gcc',
+ mode='update', baseURL='svn://gcc.gnu.org/svn/gcc/',
+ defaultBranch='trunk',
+ workdir='gcc.src'))
+
+ # Apply patch.
+ #
+ # FIXME: Eliminate this.
+ f.addStep(ShellCommand(name='patch.gcc',
+ command="patch -p1 < ../dragonegg.src/gcc-patches/i386_static.diff",
+ workdir='gcc.src'))
+
+ # Build and install GCC.
+ if clean:
+ f.addStep(ShellCommand(name="rm-gcc.obj.stage1",
+ command=["rm", "-rf", "gcc.1.obj"],
+ haltOnFailure = True,
+ description=["rm build dir", "gcc"],
+ workdir=".", env=env))
+ # Create the gcc.1.obj dir. FIXME: This shouldn't be necessary, old buildbot or something.
+ f.addStep(ShellCommand(command="mkdir gcc.1.obj",
+ workdir='.'))
+ f.addStep(Configure(name='configure.gcc.stage1',
+ command=(["../gcc.src/configure",
+ WithProperties("--prefix=%(builddir)s/gcc.1.install")] +
+ configure_args),
+ haltOnFailure = True,
+ description=["configure", "gcc", "(stage 1)"],
+ workdir="gcc.1.obj", env=env))
+ f.addStep(WarningCountingShellCommand(name = "compile.gcc.stage1",
+ command = ["nice", "-n", "10",
+ "make", WithProperties("-j%s" % jobs)],
+ haltOnFailure = True,
+ description=["compile", "gcc", "(stage 1)"],
+ workdir="gcc.1.obj", env=env))
+ f.addStep(WarningCountingShellCommand(name = "install.gcc.stage1",
+ command = ["nice", "-n", "10",
+ "make", "install"],
+ haltOnFailure = True,
+ description=["install", "gcc", "(stage 1)"],
+ workdir="gcc.1.obj", env=env))
+
+ # Build LLVM (stage 1) with the GCC (stage 1).
+ if clean:
+ f.addStep(ShellCommand(name="rm-llvm.obj.stage1",
+ command=["rm", "-rf", "llvm.1.obj"],
+ haltOnFailure = True,
+ description=["rm build dir", "llvm"],
+ workdir=".", env=env))
+ # Create the llvm.1.obj dir. FIXME: This shouldn't be necessary, old buildbot or something.
+ f.addStep(ShellCommand(command="mkdir llvm.1.obj",
+ workdir='.'))
+ f.addStep(Configure(name='configure.llvm.stage1',
+ command=(["../llvm.src/configure",
+ WithProperties("CC=%(builddir)s/gcc.1.install/bin/gcc"),
+ WithProperties("CXX=%(builddir)s/gcc.1.install/bin/g++"),
+ WithProperties("--prefix=%(builddir)s/llvm.1.install")] +
+ configure_args),
+ haltOnFailure = True,
+ description=["configure", "llvm", "(stage 1)"],
+ workdir="llvm.1.obj", env=env))
+ f.addStep(WarningCountingShellCommand(name = "compile.llvm.stage1",
+ command = ["nice", "-n", "10",
+ "make", WithProperties("-j%s" % jobs)],
+ haltOnFailure = True,
+ description=["compile", "llvm", "(stage 1)"],
+ workdir="llvm.1.obj", env=env))
+ f.addStep(WarningCountingShellCommand(name = "install.llvm.stage1",
+ command = ["nice", "-n", "10",
+ "make", WithProperties("-j%s" % jobs),
+ "install"],
+ haltOnFailure = True,
+ description=["install", "llvm", "(stage 1)"],
+ workdir="llvm.1.obj", env=env))
+
+ # Clean DragonEgg.
+ if clean:
+ f.addStep(ShellCommand(name="clean.dragonegg.stage1",
+ command=["make", "clean"],
+ haltOnFailure = True,
+ description=["make clean",
+ "(dragonegg)"],
+ workdir="dragonegg.src", env=env))
+ f.addStep(WarningCountingShellCommand(
+ name = "compile.dragonegg.stage1",
+ command = ["nice", "-n", "10",
+ "make", WithProperties("-j%s" % jobs),
+ WithProperties("CC=%(builddir)s/gcc.1.install/bin/gcc"),
+ WithProperties("GXX=%(builddir)s/gcc.1.install/bin/g++"),
+ WithProperties("GCC=%(builddir)s/gcc.1.install/bin/gcc"),
+ WithProperties("LLVM_CONFIG=%(builddir)s/llvm.1.obj/Debug/bin/llvm-config"),
+ ],
+ haltOnFailure = True,
+ description=["compile", "dragonegg", "(stage 1)"],
+ workdir="dragonegg.src", env=env))
+
+ return f
+
More information about the llvm-commits
mailing list