[Cmake] headers in project files?

Klaas Holwerda kholwerd at xs4all.nl
Thu Jan 23 18:08:53 EST 2003


Bill, .

Should it also work with this ??

INCLUDE_DIRECTORIES( ${docview_SOURCE_DIR}/include )
AUX_SOURCE_DIRECTORY( ${docview_SOURCE_DIR}/include/docview includes )
ADD_LIBRARY( ${DOCVIEW_LIB_NAME} docviewref.cpp  includes   )

When i add one of the header files in there, like down here,  it is oke

${docview_SOURCE_DIR}/include/docview/docviewref.h

The problem is that the header files are in a different directory then 
the source files.
I will get a very long "ADD_LIBRARY"   line, with long paths.

Or is there a better solution for this?

Thanks,

Klaas
 

Bill Hoffman wrote:

>Actually, I think what Klaas wants is the visual studio project to have
>the header files in it.   This is very simple, you just add them as
>source files for the library or executable that you are building.
>
>Something like this:
>ADD_LIBRARY(foobar foobar.h foobar.cxx)
>




More information about the CMake mailing list