Hello,

I have a CMake build system that includes a subdirectory that builds a python 
interface using SWIG.  I would like to run make with a target specified such 
that the swig command is called but the resulting wrapper file is not compiled. 
 The CMakeLists.txt file that controls this part of the build is in

    packages/PyTrilinos/src

and the build directory where the python interface gets built is

    BUILD/packages/PyTrilinos/src

After hunting around for the Makefile target that defines how to call swig, I 
found one in

   BUILD/packages/PyTrilinos/src/CMakeFiles/TriUtils.dir/build.make

which uses a relative path relative to the BUILD directory to define the target:

    packages/PyTrilinos/src/TriUtilsPYTHON_wrap.cpp: 
../packages/PyTrilinos/src/TriUtils.i
        ...

My problem is I cannot figure out how to invoke this.  Since the paths are 
relative to the BUILD directory, I tried it from there:

    $ cd BUILD
    $ make packages/PyTrilinos/src/TriUtilsPYTHON_wrap.cpp
    make: *** No rule to make target 
`packages/PyTrilinos/src/TriUtilsPYTHON_wrap.cpp'.  Stop.

Any other directory to call it from doesn't make sense to me, given how the 
paths are specified.  I probably need to use 'make -f', but it is not even 
clear which Makefile to reference.  Does anyone have any advice on how to get 
this to work?

Thanks

** Bill Spotz                                              **
** Sandia National Laboratories  Voice: (505)845-0170      **
** P.O. Box 5800                 Fax:   (505)284-0154      **
** Albuquerque, NM 87185-0370    Email: [email protected] **


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to