mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-25 10:09:06 +08:00
98ae960b4b
* [qt5-macextras] Add qt5-macextras port * [cutelyst2] Fix install on mac * [qt5-purchasing] Add missing dependency on qt5-declarative * [qt5] Ensure we link to required libraries for qt5 static build * [qscintilla] Fix install on mac * [libqglviewer] Fix install paths on mac * [libqglviewer] Fix regressions * [qscintilla] Fix regressions * Bump version numbers * [qt5] restore harfbuzz on osx
61 lines
2.3 KiB
CMake
61 lines
2.3 KiB
CMake
include(vcpkg_common_functions)
|
|
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/QScintilla_gpl-2.10)
|
|
vcpkg_download_distfile(ARCHIVE
|
|
URLS "https://sourceforge.net/projects/pyqt/files/QScintilla2/QScintilla-2.10/QScintilla_gpl-2.10.zip"
|
|
FILENAME "QScintilla_gpl-2.10.zip"
|
|
SHA512 7c580cfee03af1056f530af756a0ff9cc2396a5419fa23aecc66a6bc8809a4fb154788956220bb0b068a5c214d571c053271c3906d6d541196fbbf7c6dbec917
|
|
)
|
|
vcpkg_extract_source_archive(${ARCHIVE})
|
|
|
|
vcpkg_find_acquire_program(PYTHON3)
|
|
|
|
# Add python3 to path
|
|
get_filename_component(PYTHON_PATH ${PYTHON3} DIRECTORY)
|
|
vcpkg_add_to_path(PREPEND ${PYTHON_PATH})
|
|
vcpkg_add_to_path(${CURRENT_INSTALLED_DIR}/bin)
|
|
vcpkg_add_to_path(${CURRENT_INSTALLED_DIR}/debug/bin)
|
|
|
|
#Store build paths
|
|
set(DEBUG_DIR "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg")
|
|
set(RELEASE_DIR "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel")
|
|
|
|
vcpkg_configure_qmake(
|
|
SOURCE_PATH ${SOURCE_PATH}/Qt4Qt5
|
|
OPTIONS
|
|
CONFIG+=build_all
|
|
CONFIG-=hide_symbols
|
|
DEFINES+=SCI_NAMESPACE
|
|
)
|
|
|
|
if(CMAKE_HOST_WIN32)
|
|
vcpkg_build_qmake(
|
|
RELEASE_TARGETS release
|
|
DEBUG_TARGETS debug
|
|
)
|
|
else()
|
|
vcpkg_build_qmake()
|
|
endif()
|
|
|
|
file(GLOB HEADER_FILES ${SOURCE_PATH}/Qt4Qt5/Qsci/*)
|
|
file(COPY ${HEADER_FILES} DESTINATION ${CURRENT_PACKAGES_DIR}/include/Qsci)
|
|
|
|
if(CMAKE_HOST_WIN32)
|
|
configure_file(${RELEASE_DIR}/release/qscintilla2_qt5.lib ${CURRENT_PACKAGES_DIR}/lib/qscintilla2.lib COPYONLY)
|
|
configure_file(${DEBUG_DIR}/debug/qscintilla2_qt5.lib ${CURRENT_PACKAGES_DIR}/debug/lib/qscintilla2.lib COPYONLY)
|
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
|
file(COPY ${RELEASE_DIR}/release/qscintilla2_qt5.dll DESTINATION ${CURRENT_PACKAGES_DIR}/bin)
|
|
file(COPY ${DEBUG_DIR}/debug/qscintilla2_qt5.dll DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin)
|
|
endif()
|
|
elseif(CMAKE_HOST_APPLE)
|
|
configure_file(${RELEASE_DIR}/libqscintilla2_qt5.a ${CURRENT_PACKAGES_DIR}/lib/libqscintilla2.a COPYONLY)
|
|
configure_file(${DEBUG_DIR}/libqscintilla2_qt5.a ${CURRENT_PACKAGES_DIR}/debug/lib/libqscintilla2.a COPYONLY)
|
|
endif()
|
|
|
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
# Handle copyright
|
|
file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/qscintilla)
|
|
file(RENAME ${CURRENT_PACKAGES_DIR}/share/qscintilla/LICENSE ${CURRENT_PACKAGES_DIR}/share/qscintilla/copyright)
|