Compare commits
9 Commits
Author | SHA256 | Date | |
---|---|---|---|
4f8fab8d8b | |||
aeba815071 | |||
7381c1d02a | |||
54496bc767 | |||
76a7fb791b | |||
9d34012fd0 | |||
c52efca805 | |||
87d26be6c9 | |||
656e64931f |
@@ -1,102 +0,0 @@
|
||||
From 105d6c1fede00c3a9055e5a531ebf3d99bac406e Mon Sep 17 00:00:00 2001
|
||||
From: Charles Giessen <charles@lunarg.com>
|
||||
Date: Thu, 17 Jul 2025 09:56:40 -0500
|
||||
Subject: [PATCH] build: Remove pkg-config provided library names
|
||||
|
||||
The library names of Xcb, Xlib, and Wayland do not need to be queried from pkg-config,
|
||||
instead they can be hardcoded to use the fallback names.
|
||||
|
||||
The intent of querying the library names was to prevent issues where the hardcoded name
|
||||
was not the platform-appropriate name. But because <library>_LINK_LIBRARIES can have
|
||||
more than one library name, the logic to assign <library>_LINK_LIBRARIES into a compile
|
||||
definition breaks horribly. While it is possible to handle this in CMake, the dlopen code would
|
||||
also have to handle it which is much more error prone.
|
||||
---
|
||||
cube/CMakeLists.txt | 20 --------------------
|
||||
cube/wayland_loader.h | 3 ---
|
||||
cube/xcb_loader.h | 3 ---
|
||||
cube/xlib_loader.h | 3 ---
|
||||
4 files changed, 29 deletions(-)
|
||||
|
||||
diff --git a/cube/CMakeLists.txt b/cube/CMakeLists.txt
|
||||
index 7e135e79b..dac6bfed9 100644
|
||||
--- a/cube/CMakeLists.txt
|
||||
+++ b/cube/CMakeLists.txt
|
||||
@@ -307,16 +307,6 @@ if (ANDROID)
|
||||
return()
|
||||
endif()
|
||||
|
||||
-if (XCB_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "XCB_LIBRARY=\"${XCB_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-if (X11_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "XLIB_LIBRARY=\"${X11_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-if (WAYLAND_CLIENT_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "WAYLAND_LIBRARY=\"${WAYLAND_CLIENT_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-
|
||||
# ----------------------------------------------------------------------------
|
||||
# vkcubepp
|
||||
|
||||
@@ -360,16 +350,6 @@ target_include_directories(vkcubepp PRIVATE .)
|
||||
# target_compile_definitions(vkcubepp PRIVATE ${ENABLED_CUBE_PLATFORMS})
|
||||
# target_link_libraries(vkcubepp ${CMAKE_DL_LIBS} Vulkan::Headers)
|
||||
target_compile_definitions(vkcubepp PRIVATE ${ENABLED_CUBE_PLATFORMS})
|
||||
target_link_libraries(vkcubepp Vulkan::Headers volk::volk_headers)
|
||||
|
||||
-if (XCB_LINK_LIBRARIES )
|
||||
- target_compile_definitions(vkcubepp PUBLIC "XCB_LIBRARY=\"${XCB_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-if (X11_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcubepp PUBLIC "XLIB_LIBRARY=\"${X11_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-if (WAYLAND_CLIENT_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcubepp PUBLIC "WAYLAND_LIBRARY=\"${WAYLAND_CLIENT_LINK_LIBRARIES}\"")
|
||||
-endif()
|
||||
-
|
||||
if(APPLE)
|
||||
install(
|
||||
TARGETS vkcubepp
|
||||
diff --git a/cube/wayland_loader.h b/cube/wayland_loader.h
|
||||
index 2afab6e97..7d7d91412 100644
|
||||
--- a/cube/wayland_loader.h
|
||||
+++ b/cube/wayland_loader.h
|
||||
@@ -80,9 +80,6 @@ static PFN_wl_display_disconnect cube_wl_display_disconnect = NULL;
|
||||
|
||||
static inline void *initialize_wayland() {
|
||||
void *wayland_library = NULL;
|
||||
-#if defined(WAYLAND_LIBRARY)
|
||||
- wayland_library = dlopen(WAYLAND_LIBRARY, RTLD_NOW | RTLD_LOCAL);
|
||||
-#endif
|
||||
if (NULL == wayland_library) {
|
||||
wayland_library = dlopen("libwayland-client.so.0", RTLD_NOW | RTLD_LOCAL);
|
||||
}
|
||||
diff --git a/cube/xcb_loader.h b/cube/xcb_loader.h
|
||||
index a94d5ab56..cecd25402 100644
|
||||
--- a/cube/xcb_loader.h
|
||||
+++ b/cube/xcb_loader.h
|
||||
@@ -88,9 +88,6 @@ static PFN_xcb_screen_next cube_xcb_screen_next = NULL;
|
||||
|
||||
void *initialize_xcb() {
|
||||
void *xcb_library = NULL;
|
||||
-#if defined(XCB_LIBRARY)
|
||||
- xcb_library = dlopen(XCB_LIBRARY, RTLD_NOW | RTLD_LOCAL);
|
||||
-#endif
|
||||
if (NULL == xcb_library) {
|
||||
xcb_library = dlopen("libxcb.so.1", RTLD_NOW | RTLD_LOCAL);
|
||||
}
|
||||
diff --git a/cube/xlib_loader.h b/cube/xlib_loader.h
|
||||
index c7874d0e7..881789f18 100644
|
||||
--- a/cube/xlib_loader.h
|
||||
+++ b/cube/xlib_loader.h
|
||||
@@ -72,9 +72,6 @@ static PFN_XFlush cube_XFlush = NULL;
|
||||
|
||||
void* initialize_xlib() {
|
||||
void* xlib_library = NULL;
|
||||
-#if defined(XLIB_LIBRARY)
|
||||
- xlib_library = dlopen(XLIB_LIBRARY, RTLD_NOW | RTLD_LOCAL);
|
||||
-#endif
|
||||
if (NULL == xlib_library) {
|
||||
xlib_library = dlopen("libX11.so.6", RTLD_NOW | RTLD_LOCAL);
|
||||
}
|
50
cmake.patch
Normal file
50
cmake.patch
Normal file
@@ -0,0 +1,50 @@
|
||||
From 2cb1cd9899748daa5c30f822aaafdc4d2fcca464 Mon Sep 17 00:00:00 2001
|
||||
From: Jan Engelhardt <jengelh@inai.de>
|
||||
Date: Sun, 6 Jul 2025 17:27:55 +0200
|
||||
Subject: [PATCH] build: workaround FTBFS due to cmake
|
||||
References: https://github.com/KhronosGroup/Vulkan-Tools/issues/1130
|
||||
|
||||
[6/19] Building C object cube/CMakeFiles/vkcube.dir/cube.c.o
|
||||
FAILED: [code=2] cube/CMakeFiles/vkcube.dir/cube.c.o
|
||||
/usr/bin/cc -D/usr/lib64/libm.so" -DVK_USE_PLATFORM_DISPLAY_KHR -DVK_USE_PLATFORM_WAYLAND_KHR -DVK_USE_PLATFORM_XCB_KHR -DVK_USE_PLATFORM_XLIB_KHR -DWAYLAND_LIBRARY=\"/usr/lib64/libwayland-client.so -DXCB_LIBRARY=\"/usr/lib64/libxcb.so\" -DXLIB_LIBRARY=\"/usr/lib64/libX11.so\" -I/usr/include/wayland -I/home/ej/obs_nosave/zu/X11/Wayland/vulkan-tools/Vulkan-Tools/cube -I/home/ej/obs_nosave/zu/X11/Wayland/vulkan-tools/Vulkan-Tools/cube/. -O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -O2 -g -DNDEBUG -std=c99 -fPIE -fvisibility=hidden -Wall -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wno-stringop-truncation -MD -MT cube/CMakeFiles/vkcube.dir/cube.c.o -MF cube/CMakeFiles/vkcube.dir/cube.c.o.d -o cube/CMakeFiles/vkcube.dir/cube.c.o -c /home/ej/obs_nosave/zu/X11/Wayland/vulkan-tools/Vulkan-Tools/cube/cube.c
|
||||
/bin/sh: -c: line 1: unexpected EOF while looking for matching `"'
|
||||
ninja: build stopped: subcommand failed.
|
||||
|
||||
Effectively switch from cc -DXLIB_LIBRARY=... to -UXLIB_LIBRARY.
|
||||
I found the C code already handles this approach appropriately.
|
||||
---
|
||||
cube/CMakeLists.txt | 6 ------
|
||||
1 file changed, 6 deletions(-)
|
||||
|
||||
Index: Vulkan-Tools-vulkan-sdk-1.4.321.0/cube/CMakeLists.txt
|
||||
===================================================================
|
||||
--- Vulkan-Tools-vulkan-sdk-1.4.321.0.orig/cube/CMakeLists.txt
|
||||
+++ Vulkan-Tools-vulkan-sdk-1.4.321.0/cube/CMakeLists.txt
|
||||
@@ -308,13 +308,10 @@ if (ANDROID)
|
||||
endif()
|
||||
|
||||
if (XCB_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "XCB_LIBRARY=\"${XCB_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
if (X11_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "XLIB_LIBRARY=\"${X11_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
if (WAYLAND_CLIENT_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcube PRIVATE "WAYLAND_LIBRARY=\"${WAYLAND_CLIENT_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
@@ -361,13 +358,10 @@ target_compile_definitions(vkcubepp PRIV
|
||||
target_link_libraries(vkcubepp ${CMAKE_DL_LIBS} Vulkan::Headers)
|
||||
|
||||
if (XCB_LINK_LIBRARIES )
|
||||
- target_compile_definitions(vkcubepp PUBLIC "XCB_LIBRARY=\"${XCB_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
if (X11_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcubepp PUBLIC "XLIB_LIBRARY=\"${X11_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
if (WAYLAND_CLIENT_LINK_LIBRARIES)
|
||||
- target_compile_definitions(vkcubepp PUBLIC "WAYLAND_LIBRARY=\"${WAYLAND_CLIENT_LINK_LIBRARIES}\"")
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
BIN
v1.4.304.tar.gz
(Stored with Git LFS)
BIN
v1.4.304.tar.gz
(Stored with Git LFS)
Binary file not shown.
BIN
vulkan-sdk-1.4.321.0.tar.gz
(Stored with Git LFS)
Normal file
BIN
vulkan-sdk-1.4.321.0.tar.gz
(Stored with Git LFS)
Normal file
Binary file not shown.
@@ -1,9 +1,33 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 7 09:03:56 UTC 2025 - Antonio Larrosa <alarrosa@suse.com>
|
||||
Thu Jul 17 06:13:32 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Add rebased patch from upstream to fix building with
|
||||
wayland 1.24:
|
||||
* 0001-build-Remove-pkg-config-provided-library-names.patch
|
||||
- Update to tag SDK-1.4.321.0
|
||||
* cube: prefer Wayland over X11 when available
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Jul 6 15:30:16 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Add cmake.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 5 19:09:31 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Remove unused dependency on vulkan-volk
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun May 18 04:29:18 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Update to tag SDK-1.4.313.0
|
||||
* vkcubepp: Support protected output
|
||||
* cube: Only count non-minimized frames
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Mar 13 16:41:22 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Update to tag SDK-1.4.309.0
|
||||
* vulkaninfo: Add video profiles support
|
||||
* cube: Correctly apply sRGB OETF/EOTF
|
||||
* icd: Add VkPhysicalDeviceMaintenance3Properties
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Dec 24 01:33:04 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package vulkan-tools
|
||||
#
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
# Copyright (c) 2025 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -17,22 +17,20 @@
|
||||
|
||||
|
||||
Name: vulkan-tools
|
||||
Version: 1.4.304
|
||||
Version: 1.4.321
|
||||
Release: 0
|
||||
Summary: Diagnostic utilities for Vulkan
|
||||
License: Apache-2.0
|
||||
Group: Development/Tools/Other
|
||||
URL: https://github.com/KhronosGroup/Vulkan-Tools
|
||||
Source: https://github.com/KhronosGroup/Vulkan-Tools/archive/refs/tags/v%version.tar.gz
|
||||
Source: https://github.com/KhronosGroup/Vulkan-Tools/archive/refs/tags/vulkan-sdk-%version.0.tar.gz
|
||||
Source9: baselibs.conf
|
||||
# PATCH-FIX-UPSTREAM
|
||||
Patch0: 0001-build-Remove-pkg-config-provided-library-names.patch
|
||||
Patch1: cmake.patch
|
||||
BuildRequires: cmake >= 3.17
|
||||
BuildRequires: gcc-c++ >= 4.8
|
||||
BuildRequires: glslang-devel
|
||||
BuildRequires: pkg-config
|
||||
BuildRequires: python3-base
|
||||
BuildRequires: vulkan-volk-devel >= %version
|
||||
BuildRequires: pkgconfig(vulkan) >= %version
|
||||
BuildRequires: pkgconfig(wayland-protocols)
|
||||
BuildRequires: pkgconfig(x11)
|
||||
@@ -48,7 +46,7 @@ graphics applications such as games and interactive media.
|
||||
This package contains the Khronos official Vulkan tools and utilities.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n Vulkan-Tools-%version
|
||||
%autosetup -n Vulkan-Tools-vulkan-sdk-%version.0 -p1
|
||||
|
||||
%build
|
||||
mkdir -p glslang/bin
|
||||
|
Reference in New Issue
Block a user