[PATCH] [zorg] Support Windows/Linux Clang CMake builds with unified builder.

Rick Foos rfoos at codeaurora.org
Mon Jan 19 12:12:03 PST 2015


REPOSITORY
  rL LLVM

================
Comment at: zorg/buildbot/builders/ClangBuilder.py:508
@@ -453,1 +507,3 @@
 
+            # Phase 2 build with built Clang.
+            cmakeGenerator2='Ninja',     
----------------
rfoos wrote:
> gkistanova wrote:
> > rengolin wrote:
> > > rfoos wrote:
> > > > This is original behavior but allows the caller to pass an entire step 2 definition.
> > > > 
> > > > The only exception is the stage1/stage2 framework for the built compiler(s).
> > > Maybe better as a dictionary? Like:
> > > 
> > >     build { stage : 1, { cmd = "ninja", install = cmd + " install", check = cmd + " check-all" }
> > >               stage : 2, { cmd = "ninja", install = cmd + " install", check = cmd + " check-all" } }
> > > 
> > > or whatever Python would do for something like that. :)
> > Ordered list would do better, I think.
> >     [ 
> >     { name="stage 1", source=[<list of (components and directories tuples)>], cmd = "ninja", install = cmd + " install", check = cmd + " check-all" },
> >     { name="stage 2", cmd = "ninja", install = cmd + " install", check = cmd + " check-all" },
> >     ...
> >     ]
> > 
> > As a next re-factoring pass we shall standardize the build parameters names to have the dictionary as much common for all the builders as practical.
> > 
> I'll try the ordered list. It's a balance between easy for the caller, or too confusing to use.
Please Review:
Here's the list I'm implementing per comments.
Since it is a list of dictionaries, the caller will have to specify everything.
Selections, like useTwoStage, or testStage1 are specified by leaving or adding to the build list.

The key names in the dictionary describe actions for one or more cmake build, install, check steps.

    def getCMakeBuildFactory(
            build = [
            {'name': "stage 1",
            'source': ['svn-llvm','svn-clang'],
            'source_dir': 'llvm',
            'config': "Release",
            'slave_envCmd': None,
            'cmakeGenerator': 'Ninja',
            'cmakeProjectfile': 'build.ninja',
            'extra_cmake_args': [],
            'build_cmd': ['ninja'],
            'build_dir': 'stage1',
            'install_cmd': ['ninja', 'install'],
            'install_dir': None,
            'check_cmd': ['ninja', 'check-all'],
            'check_dir': None,
            },
            {'name': "stage 2",
            'config': "Release",
            'slave_envCmd': None,
            'cmakeGenerator': 'Ninja',
            'cmakeProjectfile': 'build.ninja',
            'extra_cmake_args': [],
            'build_cmd': ['ninja'],
            'build_dir': None,
            'install_cmd': ['ninja', 'install'],
            'install_dir': None,
            'check_cmd': ['ninja', 'check-all'],
            'check_dir': None,
            },
            ]
            ):
    return

http://reviews.llvm.org/D6866

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list