2020-06-02 07:00:57 +08:00
|
|
|
set(SQLITE_VERSION 3320000)
|
|
|
|
set(SQLITE_HASH cf176859dfe5b6b92f02c8408faf3389fba0bd441308dea058085e031c45ab28377ce5ae519c48efe0ae51a16d4242e8d00461229ed099ee5cc2741a0f32ecd4 )
|
2017-04-02 04:35:22 +08:00
|
|
|
|
2017-02-15 20:14:37 +08:00
|
|
|
vcpkg_download_distfile(ARCHIVE
|
2020-02-29 13:27:31 +08:00
|
|
|
URLS "https://sqlite.org/2020/sqlite-amalgamation-${SQLITE_VERSION}.zip"
|
2017-04-02 04:35:22 +08:00
|
|
|
FILENAME "sqlite-amalgamation-${SQLITE_VERSION}.zip"
|
2018-11-07 09:29:12 +08:00
|
|
|
SHA512 ${SQLITE_HASH}
|
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_extract_source_archive_ex(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
ARCHIVE ${ARCHIVE}
|
|
|
|
REF ${SQLITE_VERSION}
|
2019-07-16 01:41:11 +08:00
|
|
|
PATCHES fix-arm-uwp.patch
|
2018-11-07 09:29:12 +08:00
|
|
|
)
|
2017-02-15 20:14:37 +08:00
|
|
|
|
|
|
|
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
|
|
|
|
2020-01-10 06:36:56 +08:00
|
|
|
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
|
|
|
INVERTED_FEATURES
|
|
|
|
tool SQLITE3_SKIP_TOOLS
|
|
|
|
)
|
2018-02-28 04:24:41 +08:00
|
|
|
|
2017-02-15 20:14:37 +08:00
|
|
|
vcpkg_configure_cmake(
|
|
|
|
SOURCE_PATH ${SOURCE_PATH}
|
2017-04-02 04:35:22 +08:00
|
|
|
PREFER_NINJA
|
2020-01-10 06:36:56 +08:00
|
|
|
OPTIONS ${FEATURE_OPTIONS}
|
2018-02-28 04:24:41 +08:00
|
|
|
OPTIONS_DEBUG
|
|
|
|
-DSQLITE3_SKIP_TOOLS=ON
|
2017-02-15 20:14:37 +08:00
|
|
|
)
|
2018-02-28 04:24:41 +08:00
|
|
|
|
2017-02-15 20:14:37 +08:00
|
|
|
vcpkg_install_cmake()
|
2018-06-16 11:07:21 +08:00
|
|
|
vcpkg_fixup_cmake_targets()
|
2017-02-15 20:14:37 +08:00
|
|
|
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
|
|
|
2020-01-10 06:36:56 +08:00
|
|
|
if(NOT SQLITE3_SKIP_TOOLS AND EXISTS ${CURRENT_PACKAGES_DIR}/tools/sqlite3-bin${VCPKG_HOST_EXECUTABLE_SUFFIX})
|
|
|
|
file(RENAME ${CURRENT_PACKAGES_DIR}/tools/sqlite3-bin${VCPKG_HOST_EXECUTABLE_SUFFIX} ${CURRENT_PACKAGES_DIR}/tools/sqlite3${VCPKG_HOST_EXECUTABLE_SUFFIX})
|
|
|
|
endif()
|
|
|
|
|
2018-06-16 11:07:21 +08:00
|
|
|
configure_file(
|
|
|
|
${CMAKE_CURRENT_LIST_DIR}/sqlite3-config.in.cmake
|
|
|
|
${CURRENT_PACKAGES_DIR}/share/sqlite3/sqlite3-config.cmake
|
|
|
|
@ONLY
|
|
|
|
)
|
|
|
|
|
2020-01-10 06:36:56 +08:00
|
|
|
file(WRITE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright "SQLite is in the Public Domain.\nhttp://www.sqlite.org/copyright.html\n")
|
2020-06-02 07:00:57 +08:00
|
|
|
vcpkg_copy_pdbs()
|