Merge pull request #1045 from ajshort/patch-1

Use CMake to build Eigen3
This commit is contained in:
Alexander Karatarakis 2017-05-10 13:22:18 -07:00 committed by GitHub
commit 4e9e62f6ef
2 changed files with 6 additions and 14 deletions

View File

@ -1,3 +1,3 @@
Source: eigen3
Version: 3.3.3
Version: 3.3.3-1
Description: C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms.

View File

@ -8,20 +8,12 @@ vcpkg_download_distfile(ARCHIVE
)
vcpkg_extract_source_archive(${ARCHIVE})
file(GLOB_RECURSE GARBAGE ${SOURCE_PATH}/Eigen/CMakeLists.* ${SOURCE_PATH}/unsupported/Eigen/CMakeLists.*)
if(GARBAGE)
file(REMOVE ${GARBAGE})
endif()
vcpkg_configure_cmake(SOURCE_PATH ${SOURCE_PATH})
vcpkg_install_cmake()
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug)
# Put the licence file where vcpkg expects it
file(COPY ${SOURCE_PATH}/COPYING.README DESTINATION ${CURRENT_PACKAGES_DIR}/share/eigen3)
file(RENAME ${CURRENT_PACKAGES_DIR}/share/eigen3/COPYING.README ${CURRENT_PACKAGES_DIR}/share/eigen3/copyright)
# Copy the eigen header files
file(COPY ${SOURCE_PATH}/Eigen ${SOURCE_PATH}/signature_of_eigen3_matrix_library
DESTINATION ${CURRENT_PACKAGES_DIR}/include)
file(COPY ${SOURCE_PATH}/unsupported/Eigen
DESTINATION ${CURRENT_PACKAGES_DIR}/include/unsupported)
# Copy signature file so tools can locate the eigen headers
file(COPY DESTINATION ${CURRENT_PACKAGES_DIR}/include)