You could use: BUILD_COMMAND nmake /f makefile.vc BUILD_IN_SOURCE 1
in your ExternalProject_Add call. "nmake" is already available from within the Visual Studio environment. Of course, if your project is cross-platform, you'll have to conditionalize this so that it only happens when using a Visual Studio or NMake generator. HTH, David On Sat, Jun 16, 2012 at 5:11 PM, Brian J. Davis <[email protected]> wrote: > > Since I do not see a FindNmake or the likes, is there a way to call Nmake > from a CMakeLists.txt file? > > The root CMakeList.txt file contains: > > set( LIBTIFF_CONFIGURE_FILE ${TOP}/CMake/libtiff/**CMakeLists.txt.config ) > configure_file( ${LIBTIFF_CONFIGURE_FILE} > ${SOURCE_DIR}/libtiff/**CMakeLists.txt.config > ) > > externalproject_add( > libtiff > URL > http://download.osgeo.org/**libtiff/tiff-4.0.2.zip<http://download.osgeo.org/libtiff/tiff-4.0.2.zip> > DOWNLOAD_DIR ${DOWNLOAD_DIR} > SOURCE_DIR ${SOURCE_DIR}/libtiff > INSTALL_DIR ${INSTALL_DIR} > > ) > > Where the configure_file dumps a CMakeLists.txt file wich is generated > form CMakeLists.txt.config into the libtiff source directory so that > ExternalProject_Add has a CMakeLIsts.txt file. It is in this > CMakeLists.txt file that I need to spawn the build for libtiff such as: > > nmake /f makefile.vc > > Though CMake does not seem to support nmake calls from CMakeLists.txt > files configured to generate VisualStudio Build Files. Basically I want a > visual studio target to build libtiff using nmake. How does one do this? > > I have been able to do this for zlib, and libpng > > There are a myriad of projects all with their each flavor of building > their source which I need to build. it's a regular potpourii of source > build scents and not in a good way. > > -- > > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/** > opensource/opensource.html<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<http://www.cmake.org/Wiki/CMake_FAQ> > > Follow this link to subscribe/unsubscribe: > http://www.cmake.org/mailman/**listinfo/cmake<http://www.cmake.org/mailman/listinfo/cmake> >
-- 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
