aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/kf5syntaxhighlighting
diff options
context:
space:
mode:
Diffstat (limited to 'vcpkg/ports/kf5syntaxhighlighting')
-rw-r--r--vcpkg/ports/kf5syntaxhighlighting/portfile.cmake41
-rw-r--r--vcpkg/ports/kf5syntaxhighlighting/vcpkg.json20
2 files changed, 61 insertions, 0 deletions
diff --git a/vcpkg/ports/kf5syntaxhighlighting/portfile.cmake b/vcpkg/ports/kf5syntaxhighlighting/portfile.cmake
new file mode 100644
index 0000000..0f852c8
--- /dev/null
+++ b/vcpkg/ports/kf5syntaxhighlighting/portfile.cmake
@@ -0,0 +1,41 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO KDE/syntax-highlighting
+ REF v5.98.0
+ SHA512 05dd4d33c54b092629669a24d378002b24b140b767ed52e7f6d90aea5f5b6a30ce04ea1c87d534bd9ed239ae7bb334b65ce13a2b9af5ebef5272467fd44828bd
+ HEAD_REF master
+)
+
+vcpkg_find_acquire_program(PERL)
+get_filename_component(PERL_EXE_PATH ${PERL} DIRECTORY)
+vcpkg_add_to_path("${PERL_EXE_PATH}")
+
+# Prevent KDEClangFormat from writing to source effectively blocking parallel configure
+file(WRITE "${SOURCE_PATH}/.clang-format" "DisableFormat: true\nSortIncludes: false\n")
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DBUILD_TESTING=OFF
+ -DKDE_INSTALL_QMLDIR=qml
+)
+
+vcpkg_cmake_install(ADD_BIN_TO_PATH)
+vcpkg_cmake_config_fixup(PACKAGE_NAME KF5SyntaxHighlighting CONFIG_PATH lib/cmake/KF5SyntaxHighlighting)
+vcpkg_copy_pdbs()
+
+vcpkg_copy_tools(
+ TOOL_NAMES kate-syntax-highlighter
+ AUTO_CLEAN
+)
+
+if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
+ file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
+endif()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+
+file(GLOB LICENSE_FILES "${SOURCE_PATH}/LICENSES/*")
+vcpkg_install_copyright(FILE_LIST ${LICENSE_FILES})
+
diff --git a/vcpkg/ports/kf5syntaxhighlighting/vcpkg.json b/vcpkg/ports/kf5syntaxhighlighting/vcpkg.json
new file mode 100644
index 0000000..3c7deeb
--- /dev/null
+++ b/vcpkg/ports/kf5syntaxhighlighting/vcpkg.json
@@ -0,0 +1,20 @@
+{
+ "name": "kf5syntaxhighlighting",
+ "version": "5.98.0",
+ "description": "Syntax highlighting engine for Kate syntax definitions",
+ "homepage": "https://github.com/KDE/syntax-highlighting",
+ "dependencies": [
+ "ecm",
+ "qt5-base",
+ "qt5-tools",
+ "qt5-xmlpatterns",
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}