mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-30 01:58:59 +08:00
33 lines
1.4 KiB
CMake
33 lines
1.4 KiB
CMake
include(vcpkg_common_functions)
|
|
|
|
set(SQLITE_VERSION 3180000)
|
|
set(SQLITE_HASH d390c1d83afc27ec184ea6ab392477647cc80eb97ca177797cd494409c5646435c7a84502cc74ded1b654af13e65d2eef444bb0255a127e59d2cf40d5d0c1192)
|
|
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/sqlite-amalgamation-${SQLITE_VERSION})
|
|
|
|
vcpkg_download_distfile(ARCHIVE
|
|
URLS "https://sqlite.org/2017/sqlite-amalgamation-${SQLITE_VERSION}.zip"
|
|
FILENAME "sqlite-amalgamation-${SQLITE_VERSION}.zip"
|
|
SHA512 ${SQLITE_HASH})
|
|
vcpkg_extract_source_archive(${ARCHIVE})
|
|
|
|
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
|
|
|
vcpkg_configure_cmake(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PREFER_NINJA
|
|
OPTIONS
|
|
-DSOURCE=${SOURCE_PATH}
|
|
-DVCPKG_CMAKE_SYSTEM_NAME=${VCPKG_CMAKE_SYSTEM_NAME}
|
|
)
|
|
vcpkg_build_cmake()
|
|
vcpkg_install_cmake()
|
|
|
|
file(READ ${CURRENT_PACKAGES_DIR}/debug/share/sqlite3/sqlite3Config-debug.cmake SQLITE3_DEBUG_CONFIG)
|
|
string(REPLACE "\${_IMPORT_PREFIX}" "\${_IMPORT_PREFIX}/debug" SQLITE3_DEBUG_CONFIG "${SQLITE3_DEBUG_CONFIG}")
|
|
file(WRITE ${CURRENT_PACKAGES_DIR}/share/sqlite3/sqlite3Config-debug.cmake "${SQLITE3_DEBUG_CONFIG}")
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
|
|
file(WRITE ${CURRENT_PACKAGES_DIR}/share/sqlite3/copyright "SQLite is in the Public Domain.\nhttp://www.sqlite.org/copyright.html\n")
|
|
vcpkg_copy_pdbs()
|