diff options
| author | Nagy-Egri Máté Ferenc <csiga.biga@aol.com> | 2018-10-13 00:07:30 +0200 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2018-10-12 15:07:30 -0700 |
| commit | 7a3cc8db7f63236104e9742fc2c27ee1d882b0c6 (patch) | |
| tree | 93c6439210c559dbaa4d800ff4296d16464eef5f | |
| parent | 064fe93191dc4bdc856ae3a2e2a36cac523249ce (diff) | |
| download | vcpkg-7a3cc8db7f63236104e9742fc2c27ee1d882b0c6.tar.gz vcpkg-7a3cc8db7f63236104e9742fc2c27ee1d882b0c6.zip | |
[hwloc] Added utility hwloc-info (#4279)
* Added version number to project() invocation
* Added URL to project() invocation
* added hwloc-info target and install()
* Removed URL (oops), fixed hwloc-info when using shared libs
* [hwloc] Bump control version. Don't package debug version of hwloc-info.
| -rw-r--r-- | ports/hwloc/CMakeLists.txt | 24 | ||||
| -rw-r--r-- | ports/hwloc/CONTROL | 2 | ||||
| -rw-r--r-- | ports/hwloc/portfile.cmake | 2 |
3 files changed, 24 insertions, 4 deletions
diff --git a/ports/hwloc/CMakeLists.txt b/ports/hwloc/CMakeLists.txt index 7f75c558c..1b2e1c802 100644 --- a/ports/hwloc/CMakeLists.txt +++ b/ports/hwloc/CMakeLists.txt @@ -1,5 +1,7 @@ cmake_minimum_required(VERSION 3.0) -project(hwloc C) +project(hwloc + LANGUAGES C + VERSION 1.11.7) configure_file(contrib/windows/hwloc_config.h include/hwloc/autogen/config.h COPYONLY) configure_file(contrib/windows/static-components.h include/static-components.h COPYONLY) @@ -36,14 +38,30 @@ add_library(libhwloc src/dolib.c) set_target_properties(libhwloc PROPERTIES DEFINE_SYMBOL _USRDLL) -target_include_directories(libhwloc PRIVATE ./include ./src ${CMAKE_CURRENT_BINARY_DIR}/include) -target_compile_definitions(libhwloc PRIVATE _CRT_SECURE_NO_WARNINGS) + +add_executable(hwloc-info + utils/hwloc/hwloc-info.c) + +target_link_libraries(hwloc-info PRIVATE libhwloc) + +foreach(Target IN ITEMS libhwloc hwloc-info) + target_include_directories(${Target} PRIVATE ./include ./src ${CMAKE_CURRENT_BINARY_DIR}/include) + target_compile_definitions(${Target} PRIVATE _CRT_SECURE_NO_WARNINGS) +endforeach(Target) install(TARGETS libhwloc RUNTIME DESTINATION bin ARCHIVE DESTINATION lib LIBRARY DESTINATION lib) +install(TARGETS hwloc-info + RUNTIME DESTINATION tools/hwloc) +if(BUILD_SHARED_LIBS) + install(TARGETS libhwloc + RUNTIME DESTINATION tools/hwloc) +endif(BUILD_SHARED_LIBS) + + if(NOT HWLOC_SKIP_INCLUDES) install(FILES include/hwloc.h DESTINATION include) install(DIRECTORY include/hwloc DESTINATION include FILES_MATCHING PATTERN "*.h") diff --git a/ports/hwloc/CONTROL b/ports/hwloc/CONTROL index ef2564050..e2c820060 100644 --- a/ports/hwloc/CONTROL +++ b/ports/hwloc/CONTROL @@ -1,4 +1,4 @@ Source: hwloc -Version: 1.11.7-2 +Version: 1.11.7-3 Description: Portable Hardware Locality (hwloc) The Portable Hardware Locality (hwloc) software package provides a portable abstraction (across OS, versions, architectures, ...) of the hierarchical topology of modern architectures, including NUMA memory nodes, sockets, shared caches, cores and simultaneous multithreading. It also gathers various system attributes such as cache and memory information as well as the locality of I/O devices such as network interfaces, InfiniBand HCAs or GPUs. diff --git a/ports/hwloc/portfile.cmake b/ports/hwloc/portfile.cmake index a2031bdcb..64a18ddc7 100644 --- a/ports/hwloc/portfile.cmake +++ b/ports/hwloc/portfile.cmake @@ -28,6 +28,8 @@ else() endif() file(WRITE ${CURRENT_PACKAGES_DIR}/include/hwloc/autogen/config.h "${PUBLIC_CONFIG_H}") +file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/tools) + # Handle copyright file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/hwloc) file(RENAME ${CURRENT_PACKAGES_DIR}/share/hwloc/COPYING ${CURRENT_PACKAGES_DIR}/share/hwloc/copyright) |
