mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-01-19 05:50:58 +08:00
commit
583c79c51f
43
ports/piex/CMakeLists.txt
Normal file
43
ports/piex/CMakeLists.txt
Normal file
@ -0,0 +1,43 @@
|
||||
cmake_minimum_required(VERSION 3.8.0)
|
||||
project(piex)
|
||||
|
||||
if(MSVC)
|
||||
add_compile_options(/W3 /wd4005 /wd4996 /wd4018 -D_CRT_SECURE_NO_WARNINGS)
|
||||
endif()
|
||||
|
||||
include_directories(".")
|
||||
|
||||
add_library(binary_parse
|
||||
src/binary_parse/cached_paged_byte_array.cc
|
||||
src/binary_parse/range_checked_byte_ptr.cc
|
||||
)
|
||||
|
||||
add_library(image_type_recognition
|
||||
src/image_type_recognition/image_type_recognition_lite.cc
|
||||
)
|
||||
|
||||
target_link_libraries(image_type_recognition binary_parse)
|
||||
|
||||
add_library(tiff_directory
|
||||
src/tiff_directory/tiff_directory.cc
|
||||
)
|
||||
|
||||
target_link_libraries(tiff_directory binary_parse)
|
||||
|
||||
add_library(piex
|
||||
src/piex.cc
|
||||
src/tiff_parser.cc
|
||||
)
|
||||
|
||||
target_link_libraries(piex tiff_directory image_type_recognition binary_parse)
|
||||
|
||||
install(
|
||||
TARGETS piex
|
||||
RUNTIME DESTINATION bin
|
||||
LIBRARY DESTINATION lib
|
||||
ARCHIVE DESTINATION lib
|
||||
)
|
||||
|
||||
if(NOT DISABLE_INSTALL_HEADERS)
|
||||
install(FILES src/piex.h src/piex_types.h DESTINATION include/src)
|
||||
endif()
|
3
ports/piex/CONTROL
Normal file
3
ports/piex/CONTROL
Normal file
@ -0,0 +1,3 @@
|
||||
Source: piex
|
||||
Version: 2017-09-01-473434f2dd974978b
|
||||
Description: The Preview Image Extractor (PIEX) is designed to find and extract the largest
|
28
ports/piex/portfile.cmake
Normal file
28
ports/piex/portfile.cmake
Normal file
@ -0,0 +1,28 @@
|
||||
include(vcpkg_common_functions)
|
||||
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
||||
message(WARNING "Dynamic not supported building static")
|
||||
set(VCPKG_LIBRARY_LINKAGE static)
|
||||
endif()
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO google/piex
|
||||
REF 473434f2dd974978b329faf5c87ae8aa09a2714d
|
||||
SHA512 cb4a4107eb5e880673accac0f19965f3318e5e4c2fc24724afef5d15eab40d5866e17eb1a23af3b06b729d0e898ed99a6407d1f3000e94e3bbd71e1952d19627
|
||||
HEAD_REF master
|
||||
)
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS_DEBUG
|
||||
-DDISABLE_INSTALL_HEADERS=ON
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/piex RENAME copyright)
|
Loading…
Reference in New Issue
Block a user