[CMake] Calling Python Setuptools (setup.py) from CMake.

Nima Talebi nima at it.net.au
Sat Feb 21 00:12:29 EST 2009


Hi All,
I've been using CMake for a little while now, but not with python.

I have something like this in my CMakeLists.txt file...

message(STATUS " ${III} Loading FUNCWIRE_MINION...")

if(ENABLE_FUNCWIRE_MINION)
  message(STATUS "   ${GGG} Python build...")
  execute_process(COMMAND cd ${CMAKE_SOURCE_DIR}/funcwire-minion/ &&
${PYTHON} setup.py build)
endif(ENABLE_FUNCWIRE_MINION)

install(CODE "EXECUTE_PROCESS(COMMAND cd
${CMAKE_SOURCE_DIR}/funcwire-minion/ && ${PYTHON} setup.py install)")

...however it doesn't quite work, before putting too much work into finding
what the problem is, could someone point out if I'm even on the right track,
or if there is a better way to do this?

Nima

-- 
Nima Talebi
http://ai.autonomy.net.au/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20090221/10e0e1f3/attachment.htm>


More information about the CMake mailing list