mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-01-19 03:03:05 +08:00
[date] Update to 2.4 cont. (removed DATE_BUILD_LIB usages)
This commit is contained in:
parent
bfc50d8ee2
commit
60fb59ce4d
@ -14,8 +14,6 @@ add_library(tz src/tz.cpp)
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
target_compile_definitions(tz PRIVATE -DDATE_BUILD_DLL)
|
||||
else()
|
||||
target_compile_definitions(tz PRIVATE -DDATE_BUILD_LIB)
|
||||
endif()
|
||||
|
||||
install(
|
||||
|
@ -25,4 +25,11 @@ vcpkg_install_cmake()
|
||||
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
set(HEADER "${CURRENT_PACKAGES_DIR}/include/date/tz.h")
|
||||
file(READ "${HEADER}" _contents)
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
||||
string(REPLACE "ifdef DATE_BUILD_DLL" "if 1" _contents "${_contents}")
|
||||
endif()
|
||||
file(WRITE "${HEADER}" "${_contents}")
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/date RENAME copyright)
|
||||
|
Loading…
Reference in New Issue
Block a user