Hi, 

I’m using ExternalProject, but the documentation does not really reflect what I 
am witnessing

I have a Project X which is included through ExternalProject in Project A

Project X has no PREFIX set in its CMakeLists

I include project X like this:
  
  include(ExternalProject)
  ExternalProject_Add(x
    PREFIX x
    URL ${CMAKE_CURRENT_SOURCE_DIR}/externals/x
  )

Now according to the documentation the installed files should be available in 
the top of the prefix-dir, in this case ${CMAKE_BINARY_DIR}/x/ [installed 
files], though I can only see the src dir of ‘x’ and when looking at the output 
of the make of ‘x’ I can see its trying to install to default directories in 
this case '/usr/local’.

In the documentation, doesn’t the install_dir not mean the same as the install 
directory where project ‘x’ will install its files? Because one would think so 
because BINARY_DIR does have these semantics.

For reference from the documentation:

  The *_DIR options specify directories for the project, with default 
directories computed as follows. If the PREFIX option is given to 
ExternalProject_Add() or the EP_PREFIX directory property is set, then an 
external project is built and installed under the specified prefix:

  TMP_DIR      = <prefix>/tmp
  STAMP_DIR    = <prefix>/src/<name>-stamp
  DOWNLOAD_DIR = <prefix>/src
  SOURCE_DIR   = <prefix>/src/<name>
  BINARY_DIR   = <prefix>/src/<name>-build
  INSTALL_DIR  = <prefix>


-- 

Powered by www.kitware.com

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

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

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

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to