[CMake] copying the contents of a directory with cpack
Olivier Delannoy
olivier.delannoy at gmail.com
Tue Sep 18 09:56:28 EDT 2007
How could I define a custom target of name install_doxygen which is
going to use INSTALL ? I haven't seen any way to do partial
installation so far. I am missing something ?
I have a doxygen target and I would like to be able to add the output
of doxygen to the install target. But I don't want to create the
doxygen documentation each time I execute the install target. So I am
wondering how I could create a set of file that is installed only if
previously generated.
I hope you will understand what I mean
On 9/18/07, Bill Hoffman <bill.hoffman at kitware.com> wrote:
> Alan W. Irwin wrote:
> > On 2007-09-17 20:31-0400 Bill Hoffman wrote:
> >
> >> Niall Dalton wrote:
> >>> Hi,
> >>>
> >>> I have a custom target that creates doxygen documentation from my C
> >>> header files. I'd like, as part of my cpack configuration in my main
> >>> CMakeLists.txt, to copy the directory containing the doxygen output
> >>> into the .tar.gz package.
> >>>
> >>> What is the simplest way to do this?
> >> Basically, cpack just uses whatever make install does. So, you would
> >> need to use the install commands in cmake. Once those are working
> >> cpack should work.
> >
> > That advice is correct for generating binary distributions with "make
> > package", but in case you wanted to include the doxygen output in a
> > source
> > distribution with the "make package_source" command, then all you have
> > to do
> > is make your build tree a subdirectory of your source tree or copy the
> > doxygen output from the build tree to the source tree. By default, "make
> > package_source" packages everything in the source tree, and you use a
> > regex
> > expression variable called CPACK_SOURCE_IGNORE_FILES to ignore
> > anything you
> > do not want. To see how to set this up, have a look at the top-level
> > CMakeLists.txt file of CMake itself.
> Since doxygen is output from running the build, a source package would
> not be
> a good idea. I would add custom commands to run doxygen and create the
> docs,
> then add rules to install them, and then cpack should install them as well.
>
> -Bill
>
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>
More information about the CMake
mailing list