include(ExternalProject)
ExternalProject_Add(
WIN32DEPSV2
PREFIX ${CMAKE_CURRENT_BINARY_DIR}/WIN32DEPSV2
DOWNLOAD_DIR .
STAMP_DIR ./stamps
SOURCE_DIR WIN32DEPSV2
GIT_REPOSITORY g...@numagit.numalliance.com:THIRD_PARTIES/WIN32DEPS.git
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
BUILD_IN_SOURCE 1
INSTALL_COMMAND ""
)
add_library(your_other_target ...)
add_dependencies(your_other_target WIN32DEPSV2)
find_package(Freetype REQUIRED QUIET)
Launching cmake does not clone the git folder , but continues and fails
with the find_package command
CMake Error at
/usr/local/cmake-3.10.3-Linux-x86_64/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137
(message):
Could NOT find Freetype (missing: FREETYPE_LIBRARY FREETYPE_INCLUDE_DIRS)
Call Stack (most recent call first):
/usr/local/cmake-3.10.3-Linux-x86_64/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:378
(_FPHSA_FAILURE_MESSAGE)
/usr/local/cmake-3.10.3-Linux-x86_64/share/cmake-3.10/Modules/FindFreetype.cmake:157
(find_package_handle_standard_args)
FOX64/CMakeLists.txt:919 (find_package)
Le 02/05/2018 à 09:32, Kai Wolf a écrit :
You probably need to manually add a dependency from your
ExternalProject to your target that needs the libraries.
For instance
ExternalProject_Add(fetch_win32_libs ...)
add_library(your_other_target ...)
Greetings
Kai Wolf
http://kai-wolf.me/
kai.w...@gmail.com <mailto:kai.w...@gmail.com>
2018-05-02 8:47 GMT+02:00 Stéphane Ancelot <sance...@numalliance.com
<mailto:sance...@numalliance.com>>:
Hi,
I have got some win32 libraries dependencies stored in a project .
Then I added ExternalProject_Add at beginning of my cmakelists
file in order to clone this dependency to be available.
and then provide the root path as follow:
SET(CMAKE_FIND_ROOT_PATH /usr/i586-mingw32msvc
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/JPEGLIB/jpegsrc-9c
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/zlib-1.2.3-lib
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/libpng-1.2.37-lib
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/ftgl-binary
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/freetype-dev_2.4.2-1
${CMAKE_CURRENT_SOURCE_DIR}/WIN32DEPS/iconv-1.9.2.1
)
unfortunately, the project is not cloned when cmake is launched
and the next dependencies don't find the packages :-(
What Can I do ?
Regards,
S.Ancelot
--
Powered by www.kitware.com <http://www.kitware.com>
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>
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
<http://cmake.org/cmake/help/support.html>
CMake Consulting: http://cmake.org/cmake/help/consulting.html
<http://cmake.org/cmake/help/consulting.html>
CMake Training Courses: http://cmake.org/cmake/help/training.html
<http://cmake.org/cmake/help/training.html>
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
<http://www.kitware.com/opensource/opensource.html>
Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake
<https://cmake.org/mailman/listinfo/cmake>
--
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:
https://cmake.org/mailman/listinfo/cmake