[CMake] Relative path when referencing SWIG files?

Nicholas Yue yue.nicholas at gmail.com
Sat Sep 15 08:54:07 EDT 2007


Hi,

  I am trying to organise my SWIG files into a central location as there are
multiple langauges that I am supporting.

  I have found that introducing relative path breaks my build

  CMake complains that it cannot find the generated source file and that the
expected location would be in "../utils"

  How do I tell CMake to find the *.i files in location that is not in the
current directory, I am using symbolic link as a work around at the moment
but want to avoid that as symlinks is not supported by SVN on Windows.

--working version--
SET_SOURCE_FILES_PROPERTIES ( RIBClient.i PROPERTIES CPLUPLUS ON )
 SET_SOURCE_FILES_PROPERTIES ( RIBClient.i PROPERTIES SWIG_FLAGS
"-includeall" )

SWIG_ADD_MODULE ( ribclient python RIBClient.i ParameterList.cpp )

--not working version--
 SET_SOURCE_FILES_PROPERTIES ( ../utils/RIBClient.i PROPERTIES CPLUPLUS ON )
 SET_SOURCE_FILES_PROPERTIES ( ../utils/RIBClient.i PROPERTIES SWIG_FLAGS
"-includeall" )

SWIG_ADD_MODULE ( ribclient python ../utils/RIBClient.i ParameterList.cpp )

Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20070915/1dbe2142/attachment.htm


More information about the CMake mailing list