summaryrefslogtreecommitdiffstats
path: root/Modules/ExternalProject.cmake
Commit message (Collapse)AuthorAgeFilesLines
* ExternalProject: Add Mercurial (hg) repository supportBrad King2012-08-161-1/+127
| | | | | | | Add options HG_REPOSITORY and HG_TAG to specify an external project hosted in a Mercurial repository. Teach ExternalProject to clone the repository and update from it. Extend the ExternalProject test to try a Mercurial repository when hg is available.
* Remove CMake-language block-end command argumentsKitware Robot2012-08-131-27/+27
| | | | | | | | | | | | | | | | | Ancient versions of CMake required else(), endif(), and similar block termination commands to have arguments matching the command starting the block. This is no longer the preferred style. Run the following shell code: for c in else endif endforeach endfunction endmacro endwhile; do echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/' done >convert.sed && git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' | egrep -z -v '^(Utilities/cm|Source/kwsys/)' | egrep -z -v 'Tests/CMakeTests/While-Endwhile-' | xargs -0 sed -i -f convert.sed && rm convert.sed
* ExternalProject: Fix 'make' builds with Ninja (#13159)Matt McCormick2012-05-211-2/+6
| | | | | | Fix the build command when Ninja is the CMake Generator, but the external project is created for a project that does not use CMake but does use "make".
* ExternalProject: Avoid repeated git clone operations (#12564)David Cole2012-04-281-1/+26
| | | | | | | By tracking a stamp file within the git clone script itself. Avoids a 2nd git clone operation after switching from Debug to Release builds in Visual Studio, or vice-versa.
* ExternalProject: Refactor repeated code into function (#12564)David Cole2012-04-281-27/+39
| | | | | | | | Add "private/internal-use-only" function _ep_get_step_stampfile to get the name of the stamp file for a given step. The functionality provided by this commit should be identical to its parent commit.
* ExternalProject: Avoid unnecessary git clones (#12564)David Cole2012-04-251-1/+7
| | | | | | | | | | | | | In the case of git, only track the repository in the repository info dependency tracking file. Not the tag. The download step should only re-run if the repository changes. The download step should NOT re-run if the tag changes. The update step is an 'always' re-running step, and so should already re-run, unless it's been eliminated by use of UPDATE_COMMAND ""
* ExternalProject: Add missing COMMAND keywordDavid Cole2012-04-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | Commit f67139ae added running a verify script in between running the download and extract scripts. Since then, it has always been missing the COMMAND keyword added in this commit. It worked anyway (semi-accidentally) by running a command line like: cmake -P script1.cmake cmake -P script2.cmake CMake, when running -P scripts on the command line, runs them in order, and apparently ignores spurious arguments in between (the middle "cmake" in the above example) and so, all appeared to work as intended. This commit adds the missing keyword and the commands that run are now two separate sequential cmake invocations like: cmake -P script1.cmake cmake -P script2.cmake ...which was the original intent of commit f67139ae
* Ninja: Add the Ninja generatorPeter Collingbourne2012-02-021-2/+17
|
* ExternalProject: Update copyright yearBrad King2012-01-101-1/+1
|
* ExternalProject: Fix git.cmd version detectionBrad King2012-01-101-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | When GIT_EXECUTABLE points at ".../Git/cmd/git.cmd" in an msysGit installation we previously failed to detect the version number in a subtle case. The "git.cmd" assumes 'chcp' is in PATH. It is typically available at "C:\Windows\System32\chcp.com". On 64-bit Windows the File System Redirector maps this location to "C:\Windows\SysWOW64\chcp.com" for 32-bit processes. However, some Windows installations fail to provide chcp.com at this path. Whenever git.cmd runs in a 32-bit command shell, as it does under a 32-bit CMake binary, it reports 'chcp' is not recognized as an internal or external command, operable program or batch file. on stderr. Capture stderr separately so it does not affect parsing of the version number. See also msysGit issue 358: http://code.google.com/p/msysgit/issues/detail?id=358 Note that FindGit prefers "git.cmd" over "git.exe" because it sets up the proper HOME environment variable necessary for Git ssh connections to work the same as they do from the Git bash prompt.
* ExternalProject: Always use --non-interactive with svnDavid Cole2011-04-181-4/+4
| | | | | | | | | The previous commit added --non-interactive as a "side effect" of turning on SVN_TRUST_CERT. While reviewing that commit, we decided all ExternalProject svn usage should be non-interactive. That way, if there's any sort of problem, svn will return an error right away rather than hang forever waiting for input...
* ExternalProject: Add SVN_TRUST_CERT argumentDavid Cole2011-04-111-2/+11
| | | | | | | | | | | | Which adds --non-interactive and --trust-server-cert to the svn checkout and update command lines. This allows ExternalProject clients to pull from an https:// based svn server even though the server may not have a valid or trusted certificate. Caveat emptor: I would NOT recommend using this except as a short-term work-around. Rather, the server should have a valid, trusted certificate, or the client should be using "http" instead of "https".
* ExternalProject: Extract file names from more urlsDavid Cole2011-03-041-4/+9
| | | | Notably, downloads from sourceforge.net and gitweb snapshots.
* ExternalProject: Replace location tags in CMAKE_CACHE_ARGSDavid Cole2011-01-071-10/+22
| | | | | | When we added CMAKE_CACHE_ARGS, we did not try it with any <SOURCE_DIR> or <INSTALL_DIR> references. This commit fixes that accidental omission.
* Merge branch 'ep-log-output-under-vs' into ep-fix-substitutionsDavid Cole2011-01-071-1/+2
|\
| * ExternalProject: Avoid bleed-through output when logging.David Cole2011-01-061-1/+2
| | | | | | | | | | | | | | | | | | | | | | Unset VS_UNICODE_OUTPUT when executing a command whose output is being logged to a file. Previously, running Microsoft tools in sub-processes of Visual Studio would send their output to the Visual Studio output pipe named by this environment variable. Unsetting it forces the output back to the normal stdout and stderr channels where cmake can intercept it and direct it to the appropriate log files.
* | Fixed bug where last entry would be lost.Marcus D. Hanwell2010-12-131-0/+5
| | | | | | | | | | The code to build up a list was missing the final entry in an initial cache.
* | Escape file write expansion, and build up lists.Marcus D. Hanwell2010-12-111-12/+25
| | | | | | | | | | | | | | | | Escaped the @var@ in the file writes - this was being expanded at file write and so not causing a reconfigure at the right time. I also took care of build up lists of lists in the variables, especially important for things like MPI_EXTRA_LIBRARY. Added some error checking, and use the tmp_dir for initial cache file.
* | Added CMAKE_CACHE_ARGS to ExternalProject.Marcus D. Hanwell2010-12-101-0/+33
| | | | | | | | | | | | | | | | | | | | | | On Windows the limit for command line arguments is 8192 characters, and this was limiting longer paths with some of our more nested projects such as Library. Placing the -D arguments into CMAKE_CACHE_ARGS will write out an initial cache file, that will be passed to CMake with a -C argument as the initial cache. By forcing the cache variables we preserve the existing behavior with -D, to change the values of cache variables in our inner projects.
* | BUG 11451 - pass CMAKE_EXTRA_GENERATOR down.Marcus D. Hanwell2010-11-131-1/+6
|/ | | | | This patch fixes the behavior of external projects with respect to generators using the CMAKE_EXTRA_GENERATOR variable.
* Merge topic 'fix-11173'David Cole2010-10-281-2/+16
|\ | | | | | | | | 6e1282f ExternalProject: No svn --username if empty (#11173)
| * ExternalProject: No svn --username if empty (#11173)David Cole2010-10-221-2/+16
| | | | | | | | Nor --password. But please do if non-empty. Thank you.
* | Fixed parallel build for generators with EXTRA.Marcus D. Hanwell2010-10-221-2/+1
|/ | | | | | Fixed parallel build for projects using generators that have the CMAKE_EXTRA_GENERATOR as well as CMAKE_GENERATOR. Thanks to Bill Hoffman for helping me to track this one down, I missed parallel builds.
* Add STEP_TARGETS to ExternalProject module.David Cole2010-08-231-2/+68
| | | | | | | | | | | | | | | | This commit introduces the ability to add custom targets that correspond to individual ExternalProject steps. The main motivation behind this new feature is to drive sub-project based dashboard steps as external projects with separate targets for update, configure, build and test output. This makes it easy to construct a ctest -S script to drive such a dashboard. With no STEP_TARGETS defined, there are no additional custom targets introduced, to minimize the chatter in the target name space. Clients may define STEP_TARGETS on a per-ExternalProject_Add basis, or at the directory level by setting the EP_STEP_TARGETS directory property.
* Modules: Fix spelling 'To distributed' -> 'To distribute'Todd Gamblin2010-08-091-1/+1
|
* Merge topic 'ExternalProject-cygwin-make'Brad King2010-08-031-0/+20
|\ | | | | | | | | ed43ea6 ExternalProject: Fix $(MAKE) with cygpath on Windows
| * ExternalProject: Fix $(MAKE) with cygpath on WindowsBrad King2010-08-021-0/+20
| | | | | | | | | | In non-cygwin builds using Cygwin's make tool, use cygpath to transform the value of $(MAKE) to something Windows understands.
* | Merge topic 'fix-issue-11034'Brad King2010-08-031-10/+2
|\ \ | |/ |/| | | | | 9fa49dc ExternalProject: Remove 'unknown keyword' warning (#11034)
| * ExternalProject: Remove 'unknown keyword' warning (#11034)David Cole2010-07-281-10/+2
| | | | | | | | | | | | The intent was to warn about misspelled keyword arguments, but the effect was to warn about valid argument values far too often. Let's stop annoying and confusing people.
* | ExternalProject: Use $(MAKE) whenever possible.David Cole2010-07-231-3/+5
|/ | | | | | ExternalProject_Add calls that did not explicitly request a CMAKE_GENERATOR would not get recursive parallel make behavior. This commit fixes that issue.
* Merge topic 'external-project-launcher'Brad King2010-07-131-0/+137
|\ | | | | | | | | | | b2634b6 Detect CMake warnings and errors in build output. 012c986 ExternalProject: Add LOG_* options to hide step output
| * Detect CMake warnings and errors in build output.David Cole2010-07-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Fix niggly in ExternalProject that would inadvertently create a log file of output when a command was explicitly set to the empty string. Also, increase the default value for showing context around build errors to 10 lines, up from 6. Also add the ability to customize this setting so that users can put it back to 6 or even lower if they want, or show more if they want.
| * ExternalProject: Add LOG_* options to hide step outputBrad King2010-06-211-0/+137
| | | | | | | | | | | | Optionally hide the output of each external project build step by wrapping its command in a launcher script. Make output available in log files instead. This simplifies the output of external project builds.
* | Qualify name of extraction location with ExternalProject name.David Cole2010-06-231-5/+4
|/ | | | | | | Avoid issues with two external projects trying to extract two separate trees at the same time into the same location. Should fix the sporadically failing ExternalProject test on the dashboards for parallel builds.
* Fix issue #10346. Error if SOURCE_DIR is empty.David Cole2010-06-091-1/+14
| | | | | | | | | | | | | | | See http://public.kitware.com/Bug/view.php?id=10346. The proposed patch for the issue could not be applied as is because the SOURCE_DIR always exists for an ExternalProject_Add call by the time we get to the place to emit the potential error. The fix is to emit the error only if the source dir is empty. By which, I mean devoid of files and subdirectories. If SOURCE_DIR is used by itself, without any DOWNLOAD_COMMAND or repository info, then it implies that the SOURCE_DIR is ready to build as-is without need for a download step. Clearly, if it is empty, then it is not ready to build as is. So complain if the SOURCE_DIR is empty.
* Merge branch 'improve-file-download'Brad King2010-06-071-11/+68
|\ | | | | | | | | Conflicts: Modules/ExternalProject.cmake
| * Improve FILE(DOWNLOAD) and ExternalProject.David Cole2010-05-271-11/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Improve FILE(DOWNLOAD ...): - Add percent complete progress output to the FILE DOWNLOAD command. This progress output is off by default to preserve existing behavior. To turn it on, pass SHOW_PROGRESS as an argument. - Add EXPECTED_MD5 argument. Verify that the downloaded file has the expected md5 sum after download is complete. - Add documentation for SHOW_PROGRESS and EXPECTED_MD5. When the destination file exists already and has the expected md5 sum, then do not bother re-downloading the file. ("Short circuit" return.) Also, add a test that checks for the status output indicating that the short circuit behavior is actually occurring. Use a binary file for the test so that the md5 sum is guaranteed to be the same on all platforms regardless of "shifting text file line ending" issues. Improve ExternalProject: - Add argument URL_MD5. - Add verify step that compares md5 sum of .tar.gz file before extracting it. - Add md5 check to download step, too, to prevent unnecessary downloads. - Emit a warning message when a file is not verified. Indicate that the file may be corrupt or that no checksum was specified.
* | Merge branch 'add-git-to-ExternalProject'Brad King2010-06-071-0/+128
|\ \ | | | | | | | | | | | | Conflicts: Modules/ExternalProject.cmake
| * | Add FindGit module.David Cole2010-06-031-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use it from ExternalProject and the ExternalProject test's CMakeLists file rather than having duplicate find_program calls. Add logic so that we do not try to use *.cmd variants of git programs when using the MSYS Makefiles generator. Should fix the last remaining dashboard issue with the new ExternalProject git support additions. Also, correct minor problem regarding placement of the local git repo during test execution. On clean builds, it was being placed incorrectly because of the ../.. relative reference. Use an absolute path to place the local git repo in the proper directory, and only use the relative reference when referring to it.
| * | Add git support to ExternalProject.David Cole2010-06-021-0/+129
| |/ | | | | | | | | Requires at least version 1.6.5 of a git client for git submodule update --recursive use.
* | Merge branch 'more-formats-in-ExternalProject'Brad King2010-06-071-9/+9
|\ \
| * | Add .zip and .tar.bz2 extraction to ExternalProject.David Cole2010-05-311-9/+9
| |/ | | | | | | | | | | | | | | | | Add archives of these file types and add to the test cases covered in the ExternalProject test. Also add an "Example" directory in the Tests/ExternalProject directory containing the canonical simplest example of ExternalProject usage.
* | Merge branch 'use-rename-not-copy-ExternalProject'Brad King2010-06-071-9/+10
|\ \
| * | Use RENAME, not COPY, to extract .tar.gz files.David Cole2010-05-261-9/+10
| |/ | | | | | | | | | | Use ABSOLUTE file name for the RENAME operation. (Thanks to Marcus for figuring out that it doesn't work on Linux without the ABSOLUTE bit.)
* | Merge branch 'ExternalProject-fixes'Brad King2010-06-071-1/+12
|\ \
| * | Fix issue #10258: re-configure if args change.David Cole2010-05-261-1/+12
| |/ | | | | | | | | | | | | | | Fixes issue http://public.kitware.com/Bug/view.php?id=10258 Also, fix complaint that DOWNLOAD_COMMAND cannot contain arguments consisting entirely of upper case letters. It validly does when, for example, you construct a custom cvs command line and the module name is all upper case, like VTK.
* | Add svn user name and password to ExternalProject.David Cole2010-05-261-3/+11
|/ | | | Thanks to JCFR for the leg work.
* -revert the previous unintended commitAlex Neundorf2010-04-101-2/+0
| | | | Alex
* -no change, don't know why git wants to commit somethingAlex Neundorf2010-04-101-0/+2
| | | | | | | | | | (I accidentially removed ExternalProject.cmake from git by doing mv ExternalProject.cmake ExternalProject.cmake.save git checkout master which I hoped would basically do a revert as it does with svn and cvs, but it deleted the file from git) Alex
* Fix issue #9764 - add TIMEOUT arg to ExternalProject_Add so that callers ↵David Cole2009-12-111-5/+12
| | | | have explicit control over the amount of time they are willing to wait for a download step. Default to no timeout, which means just run download for however long it takes.