[CMake] making Nightly builds easier to setup
Martin Apel
martin.apel at simpack.de
Tue Nov 11 03:46:37 EST 2008
Hi all,
writing the CMakeCache.txt in advance works fine, thanks. Anyway, I
haven't been able to get some things to work which work for my
experimental setup,
which uses old-style CTest scripts. Memory checking and coverage tests
do not work anymore. I searched through the sources of CMake a bit, but
I could not get
it to work yet. As I currently do not have the time to fiddle around
with all these undocumented changes, I will stay with my old setup for
the time being.
When the documentation of this new-style scripting improves, I will give
it another try.
Regards,
Martin
David Cole wrote:
> The variable CTEST_INITIAL_CACHE is ignored in new-style
> (CTEST_BUILD() command based) ctest scripts.
>
> Instead, you should use:
>
> FILE(WRITE "${CTEST_BINARY_DIRECTORY}/CMakeCache.txt" "
> MAKECOMMAND:STRING=nmake -i
> CMAKE_MAKE_PROGRAM:FILEPATH=nmake
> CMAKE_GENERATOR:INTERNAL=NMake Makefiles
> BUILDNAME:STRING=Win32-nmake71
> SITE:STRING=VOGON.kitware
> CVSCOMMAND:FILEPATH=C:/cygwin/bin/cvs.exe
> ")
>
> (But only on a clean build, after calling
> CTEST_EMPTY_BINARY_DIRECTORY("${CTEST_BINARY_DIRECTORY}"), or perhaps
> only if the CMakeCache.txt does not exist in the first place...)
>
> HTH,
> David
>
>
> On Mon, Nov 10, 2008 at 5:33 AM, Martin Apel <martin.apel at simpack.de
> <mailto:martin.apel at simpack.de>> wrote:
>
> Eric Noulard wrote:
> > 2008/11/9 Alexander Neundorf <a.neundorf-work at gmx.net
> <mailto:a.neundorf-work at gmx.net>>:
> > [...]
> >
> >
> >> commands can be executed.
> >>
> >> IMO this can make setting up Nightly builds much easier.
> >>
> >
> > Looks interesting, I didn't ever thought ctest scripting was
> done for that.
> > I did shell scripts for that and was wondering how to do it on
> Windows :-)
> >
> > Now I know.
> >
> >
> >> What do you think ?
> >> One thing which is still missing is a way how to get variables
> predefined into
> >> the cmake-configure run during ctest_configure().
> >> Does this have to be done by writing an initial CMakeCache.txt ?
> >>
> >
> > This seems possible using "CTEST_INITIAL_CACHE"
> > as shown here:
> > http://www.vtk.org/Wiki/CMake_Scripting_Of_CTest
> <http://www.vtk.org/Wiki/CMake_Script-disableding_Of_CTest>
> >
> > # this is the initial cache to use for the binary tree, be
> careful to escape
> > # any quotes inside of this string if you use it
> > SET (CTEST_INITIAL_CACHE "
> > MAKECOMMAND:STRING=nmake -i
> > CMAKE_MAKE_PROGRAM:FILEPATH=nmake
> > CMAKE_GENERATOR:INTERNAL=NMake Makefiles
> > BUILDNAME:STRING=Win32-nmake71
> > SITE:STRING=VOGON.kitware
> > CVSCOMMAND:FILEPATH=C:/cygwin/bin/cvs.exe
> > ")
> >
> I recently played around with nightly builds as well. I used to have a
> setup for experimental builds, but never could get the svn checkout to
> run. With the approach described above, I was finally able
> to run checkout from svn from within ctest. Unfortunately it seems
> that
> some variables are not used anymore with this approach of
> generating builds.
> I found that CTEST_INITIAL_CACHE as well as CTEST_ENVIRONMENT seem
> to be
> ignored, when using CTEST_BUILD etc. For the environment variables I
> could get it to work by setting
> the environment variables explicitly, e.g. 'SET (ENV{CC} "gcc-4.2")'.
> That means that the approach proposed above does not work, at
> least not
> for me.
>
> After all I'm somewhat confused about this new approach ignoring
> some of
> the variables. Maybe someone with a deeper knowledge of ctest could
> explain, what's going on here.
>
> Regards,
>
> Martin
> ____________
> Virus checked by G DATA AntiVirus
> Version: AVF 19.138 from 09.11.2008
>
>
> _______________________________________________
> CMake mailing list
> CMake at cmake.org <mailto:CMake at cmake.org>
> http://www.cmake.org/mailman/listinfo/cmake
>
>
____________
Virus checked by G DATA AntiVirus
Version: AVF 19.140 from 10.11.2008
More information about the CMake
mailing list