Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion ports/unicorn-lib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ option(UNICORN_LIB_SKIP_HEADERS "If the headers installation is skipped or not."

find_path(RS_CORE_LIB_INCLUDE_DIR rs-core/common.hpp)
#find_library(RW_UTILITIES_LIBRARY NAMES rw_utilities)
find_library(ZLIB_LIBRARY NAMES zlib HINTS ${INSTALLED_LIB_PATH})
Comment thread
JackBoosY marked this conversation as resolved.
Outdated
find_library(PCRE2_LIBRARY NAMES pcre2-8 HINTS ${INSTALLED_LIB_PATH})
Comment thread
JackBoosY marked this conversation as resolved.
Outdated

file(GLOB_RECURSE UNICORN_LIB_SOURCES ${PROJECT_SOURCE_DIR}/unicorn/*.cpp)
foreach(ITR ${UNICORN_LIB_SOURCES})
Expand All @@ -24,7 +26,14 @@ target_compile_definitions(
PRIVATE -DUNICODE -D_UNICODE _CRT_SECURE_NO_WARNINGS
)

target_link_libraries(unicorn-lib ${PCRE2_LIBRARY})
Comment thread
JackBoosY marked this conversation as resolved.
Outdated
target_link_libraries(unicorn-lib ${ZLIB_LIBRARY})
Comment thread
JackBoosY marked this conversation as resolved.
Outdated

if(NOT UNICORN_LIB_SKIP_HEADERS)
install(DIRECTORY ${PROJECT_SOURCE_DIR}/unicorn DESTINATION include FILES_MATCHING PATTERN "*.hpp")
endif()
install(TARGETS unicorn-lib DESTINATION lib)
install(TARGETS unicorn-lib
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
)
2 changes: 1 addition & 1 deletion ports/unicorn-lib/CONTROL
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Source: unicorn-lib
Version: 2019-05-07
Version: 2019-05-07-1
Description: Unicode library for C++ by Ross Smith
Build-Depends: rs-core-lib, pcre2, zlib, libiconv
3 changes: 3 additions & 0 deletions ports/unicorn-lib/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,13 @@ vcpkg_configure_cmake(
PREFER_NINJA
OPTIONS_DEBUG
-DUNICORN_LIB_SKIP_HEADERS=ON
-DINSTALLED_LIB_PATH=${CURRENT_INSTALLED_DIR}/lib
Comment thread
JackBoosY marked this conversation as resolved.
Outdated
)

vcpkg_install_cmake()
vcpkg_copy_pdbs()

file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)

# Handle copyright
file(INSTALL ${SOURCE_PATH}/LICENSE.TXT DESTINATION ${CURRENT_PACKAGES_DIR}/share/unicorn-lib RENAME copyright)