{section: Introduction } This wiki page contains information regarding build modernization and consolidation. {section: Goals and Objectives } The goal of updating the condor build mechanism is far more reaching then using the latest wiz-bang tool to build code, and is meant to address the following issues: *: _Build consistency across platforms (Including Windows):_ Currently Imake does a good job for build consistency across *nix variants, however there is an entirely different set of mechanics for dealing with builds on Windows, which few people really understand. To make matters a bit more confusing, is that the mechanism by which we build & test on Windows is quite non-standard which presents an issue as condor becomes a more open source project. This plurality causes several issues in maintaining two desperate build files, with completely different mechanisms. It would be in the best interests for the group in the long run to employ a single build mechanism which has support on all condor platforms. *: _Support for unit testing within the build:_ For the purposes of testing it is advantageous to have a build tool which supports running automated unit tests as part of a "unit" build. *: _Packaging:_ Many build systems provide automated packaging for it's native environment. This can be highly useful as it eliminates and automates custom build steps and scripts and makes it easier to maintain. Having this requirement can reduce the {section: Possible Options } If we use the afore mentioned goals as hard requirements, then it eliminates a lot of possible choices, and only a couple remain: *: _SCons:_ SCons is a fairly powerful tool build atop of a python, which allows you to pretty much do anything. The only major disadvantage is the issue of packaging, and size of adoption within the open source community. There are also issues when dealing with exiting auto-tools style builds. *: _bjam:_ Created as a replacement/extension to perforce JAM it has it's own syntax and supports numerous platforms, it also does not provide flexible packaging features, and lacks the transition glue to move from an auto-tools style build. *: *CMake - winner:* CMake is widely adopted in the open source community as a x-platform replacement for auto-tools style builds. It has it's own Macro-style syntax, but unlike the afore mentioned tools it is a generator similar to Imake. Therefore it {section: Plan and phases} *[Completed] Stage 1: Feasibility* 9/25/09 Estimated: ~1 Month - likely less Time Elapsed: ~1.2 Months X - Setup existing environment build and analyze. X - Create full configuration (autoconf-cmake) X - Build for linux and Windows X - Simplify build files (done through cmake macros and updated file extensions .unix .linux .window) X - Develop plan for dealing with externals - Currently the plan is to stage uw-externals prior to building and update include and link paths to this loc by default. (everything is external) - This greatly simplifies the build process and cleans up the questions of who does "what" "when" X - Build all code with c++ compiler cleanup non-ansi C-code X - Analyze packaging options CPack will likely meet our needs and eliminate separate steps X - Eliminate unnecessary linkage where possible. tools ... daemons procd ... libs ccb cedar classad_analysis classad.old daemon_client daemon_core privsep procapi sysapi tt utils tests include scripts examples ... Analysis: I was surprised at the levels of "over complexity" within the builds and code dependencies. So in my work going forwards, my primary goal is to simplify. I believe that a cleaner structure would help for future open source progress. IMHO it should easy for a developer / researcher to obtain the source, build, and install a package. Also the directory structure should be easily to follow and navigate. ----- *[On Hold per 7.4.0] Stage 2:* Evaluation, Adoption, & Continuation (~1 - ? Months) X Cleanup and cruft and provide tracking branch for UW. (origin/CMAKE) X Setup an wiki page - Have an evaluation with UW and RedHat folks - Try to gain critical feedback. - Continued conversion, and merge out regularly - Establish auto-builds (either through NMI or hudson) ----- *Stage 3:* Full Parallel Build, Test, and Packaging (Last Month) - Full build and test should be able to run from parallel branch. (Propose switch over.) - Establish full unit testing examples along-side, you pretty much get this for free (CTest + boost::test) - Establish packaging using CPack for *all platforms. - Windows may have multiple forms of distribution according to GregT (.zip .exe .msi ...) - Do we "need" to support .msi? why? ------ *Stage 4:* Proper cleanup (optional) - start to move the code so #ifdef's are isolated to a bottom layer. The code should never have #ifdef's above a certain point as it simply should not care. This eliminates deps, and allows for easier code refactoring. {section: Getting Started } 1.) You will need to obtain CMake 2.6 or > for the target platform you are working on. 2.) Checkout origin/CMAKE 3.) Because the build expects that you have certain pre-reqs installed and defaults to a clipped build (atm). You will likely need to install the default set of clipped && proper libraries. 4.) Navigate to CONDOR_SRC/src/new_build 5.) cmake ./CMakeLists.txt 6.) make || open the visual studio project. {section: Links}