[CMake] Question about CMakeLists.txt with regards to installation

Andy Cedilnik andy.cedilnik at kitware.com
Tue Oct 12 17:09:50 EDT 2004


Hi Jeremy,

Try:

SET(files 
  foo.h
  bar.h
  ...
)

INSTALL_FILES(/include/vtk .h ${files})

			Andy

On Tue, 2004-10-12 at 16:10, Jeremy Strange wrote:
> I've been trying to find out how to do the same thing that I used to do
> in automake in cmake.
> 
> I have a static library, and I got my CMakeLists.txt to build it fine,
> and I saw some points about how to install the physical binary libraries
> using INSTALL_TARGETS (I think that's what i should be using), however I
> can't find any information about how to deal with my headers.
> 
> What I want is the library to go to "/usr/local/lib/libname" and my
> headers to go to "/usr/local/include/libname" (I realize /usr/local is
> the default prefix, but just written out here for simplicity).  I have
> all my headers in one directory, with the main one being accessed by
> client programs which then in turn accesses its sublevel (hidden)
> headers.
> 
> I have no idea how to do this kind of thing in CMake, but I really want
> to learn how since automake has been a pain in the butt for me to use
> and configure, and cmake seems like such an ideal solution for me.




More information about the CMake mailing list