2020-05-08 02:56:16 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO osmocom/rtl-sdr
|
|
|
|
REF d794155ba65796a76cd0a436f9709f4601509320
|
|
|
|
SHA512 21fe10f1dbecca651650f03d1008560930fac439d220c33b4a23acce98d78d8476ff200765eed8cfa6cddde761d45f7ba36c8b5bc3662aa85819172830ea4938
|
|
|
|
HEAD_REF master
|
2020-05-30 07:51:12 +08:00
|
|
|
PATCHES
|
|
|
|
Compile-with-msvc.patch
|
|
|
|
fix-version.patch
|
2020-05-08 02:56:16 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
file(
|
2023-03-02 02:39:14 +08:00
|
|
|
COPY "${CMAKE_CURRENT_LIST_DIR}/Findlibusb.cmake"
|
|
|
|
DESTINATION "${SOURCE_PATH}/cmake/Modules"
|
2020-05-08 02:56:16 +08:00
|
|
|
)
|
|
|
|
|
2023-03-02 02:39:14 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2020-05-08 02:56:16 +08:00
|
|
|
)
|
|
|
|
|
2023-03-02 02:39:14 +08:00
|
|
|
vcpkg_cmake_install()
|
|
|
|
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/rtlsdr)
|
2020-05-08 02:56:16 +08:00
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
|
|
|
file(
|
2023-03-02 02:39:14 +08:00
|
|
|
INSTALL "${SOURCE_PATH}/COPYING"
|
|
|
|
DESTINATION "${CURRENT_PACKAGES_DIR}/share/rtlsdr"
|
2020-05-08 02:56:16 +08:00
|
|
|
RENAME copyright
|
|
|
|
)
|
|
|
|
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
|
|
|
|
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
2023-03-02 02:39:14 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
|
2020-05-08 02:56:16 +08:00
|
|
|
else()
|
|
|
|
file(GLOB DEBUG_TOOLS "${CURRENT_PACKAGES_DIR}/debug/bin/*.exe")
|
|
|
|
file(GLOB RELEASE_TOOLS "${CURRENT_PACKAGES_DIR}/bin/*.exe")
|
|
|
|
file(
|
|
|
|
INSTALL ${RELEASE_TOOLS}
|
2023-03-02 02:39:14 +08:00
|
|
|
DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}"
|
2020-05-08 02:56:16 +08:00
|
|
|
)
|
2023-03-02 02:39:14 +08:00
|
|
|
vcpkg_copy_tool_dependencies("${CURRENT_PACKAGES_DIR}/tools/${PORT}")
|
2020-05-08 02:56:16 +08:00
|
|
|
file(REMOVE ${DEBUG_TOOLS} ${RELEASE_TOOLS})
|
|
|
|
endif()
|