Skip to content

Commit

Permalink
[vcpkg baseline][kf5globalaccel] Fix baseline (#26658)
Browse files Browse the repository at this point in the history
* Make x11extras a feature

* versions

* Remove the feature but keep explicit only-on-linux platform selection.

* Fix spelling.

Co-authored-by: Billy O'Neal <bion@microsoft.com>
  • Loading branch information
JavierMatosD and BillyONeal authored Sep 7, 2022
1 parent cbd6d4a commit a291bca
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 7 deletions.
28 changes: 28 additions & 0 deletions ports/kf5globalaccel/make_x11_required.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f78b454..4858674 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -48,19 +48,19 @@ find_package(KF5DBusAddons ${KF_DEP_VERSION} REQUIRED)
find_package(KF5WindowSystem ${KF_DEP_VERSION} REQUIRED)

# no X11 stuff on mac
-if (NOT APPLE)
- find_package(XCB MODULE COMPONENTS XCB KEYSYMS XKB OPTIONAL_COMPONENTS XTEST)
+if (NOT APPLE AND ENABLE_X11EXTRAS)
+ find_package(XCB MODULE REQUIRED COMPONENTS XCB KEYSYMS XKB OPTIONAL_COMPONENTS XTEST)
set_package_properties(XCB PROPERTIES DESCRIPTION "X protocol C-language Binding"
URL "http://xcb.freedesktop.org"
TYPE OPTIONAL
)

- find_package(X11)
+ find_package(X11 REQUIRED)
endif()

set(HAVE_X11 0)

-if(X11_FOUND AND XCB_XCB_FOUND)
+if(X11_FOUND AND XCB_XCB_FOUND AND ENABLE_X11EXTRAS)
set(HAVE_X11 1)
find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED X11Extras)
endif()
7 changes: 2 additions & 5 deletions ports/kf5globalaccel/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,17 @@ vcpkg_from_github(
REF v5.89.0
SHA512 824e4d6204189290dcc542ef3004ad2e2e2f83620dbf381ab78edbef996f412996709b9b49b72aad7c23deeeb6be274906b4cbbbd49498be081330e89c5674de
HEAD_REF master
PATCHES "make_x11_required.patch"
)

# Prevent KDEClangFormat from writing to source effectively blocking parallel configure
file(WRITE "${SOURCE_PATH}/.clang-format" "DisableFormat: true\nSortIncludes: false\n")

if(NOT VCPKG_TARGET_IS_LINUX)
list(APPEND KGLOBALACCEL_OPTIONS -DCMAKE_DISABLE_FIND_PACKAGE_X11=ON)
endif()

vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DBUILD_TESTING=OFF
${KGLOBALACCEL_OPTIONS}
-DENABLE_X11EXTRAS=${VCPKG_TARGET_IS_LINUX}
)

vcpkg_cmake_install()
Expand Down
2 changes: 1 addition & 1 deletion ports/kf5globalaccel/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "kf5globalaccel",
"version": "5.89.0",
"port-version": 2,
"port-version": 3,
"description": "lobal desktop keyboard shortcuts",
"homepage": "https://api.kde.org/frameworks/kglobalaccel/html/index.html",
"dependencies": [
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -3270,7 +3270,7 @@
},
"kf5globalaccel": {
"baseline": "5.89.0",
"port-version": 2
"port-version": 3
},
"kf5guiaddons": {
"baseline": "5.89.0",
Expand Down
5 changes: 5 additions & 0 deletions versions/k-/kf5globalaccel.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "12a2d7458be3768c8fefca6986a678aad429b66e",
"version": "5.89.0",
"port-version": 3
},
{
"git-tree": "610034ef9764b5d45569588235e9a5838ae05757",
"version": "5.89.0",
Expand Down

0 comments on commit a291bca

Please sign in to comment.