[Insight-users] [CMake] cannot include txx files using CMake

Prathamesh Kulkarni prathameshmkulkarni at gmail.com
Wed Oct 20 12:19:56 EDT 2010


Okay, could you please suggest an alternative over this issue?

- Prathamesh

On Wed, Oct 20, 2010 at 11:16 AM, John Drescher <drescherjm at gmail.com>wrote:

> On Wed, Oct 20, 2010 at 12:05 PM, Prathamesh Kulkarni
> <prathameshmkulkarni at gmail.com> wrote:
> >
> > Hello all,
> >
> > I want to interface VTK and ITK. Hence I copied the required 4 files (2
> txx
> > and 2 cpp) in InsightApplications/Auxilliary/vtk to a common source
> > directory which I want to include in all my other project source
> > directories. In doing this, I am using the following CMake commands:
> >
> > SET(IMPORTED_SRCS
> >  ${Common1_SOURCE_DIR}/src/*.cpp
> >  ${Common2_SOURCE_DIR}/src/Common.cpp
> >  ${Common2_SOURCE_DIR}/src/*.txx
> >  )
> >
> >
> > SET(IMPORTED_HDRS
> >   ${Common1_SOURCE_DIR}/include/*.h
> >   ${Common2_SOURCE_DIR}/include/*.h
> >  )
> >
> >
> > FILE(GLOB SRCS "src/*.cpp" "src/*.c" "src/*.txx" ${IMPORTED_SRCS})
> > FILE(GLOB HDRS "include/*.h" ${IMPORTED_HDRS})
> >
> > ADD_EXECUTABLE(Project1 ${SRCS} ${HDRS})
> >
> >
> > However, this is not helping me to include Common2 source and header
> files
> > in Project1's respective files. What am I doing wrong here?
> >
>
> I would avoid using GLOB like this it causes more problems then it is
> worth.
>
> John
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20101020/9cb94ff8/attachment.htm>


More information about the Insight-users mailing list