Add vkmark graphics benchmarking tool
v4 cover Add vkmark graphics benchmarking tool
Hi,
This is a new version after applying the review comments from v3. As it needs a newer Mesa it needs to be based on Bernd's series:
Subject: [Buildroot] [PATCH v2 1/5] package/libdrm: add host variant
Message-Id: <[email protected]>
Date: Fri, 21 Feb 2025 17:44:18 +0100
From: Bernd Kuhls <[email protected]>
For convenience you can find my current working branch at:
https://gitlab.com/stsquad/buildroot/-/tree/add-virtio-vulkan-vkmark?ref_type=heads
which includes Bernd's series and is based on master:
a031b51637 * origin/master 2025.02-rc1 Update for 2025.02-rc1
For v4
- new patch to vkmark to run under VirtIO
- see individual patches for other updates
For v3
- re-based on current master
- new vulkan-sdk package (for volk loader)
- bump vulkan support to 1.4.307
- include isystem patch (maybe squash with ^?)
- vkmark now has a tagged release (2025.01)
- addressed review comments (see individual patches)
For v2
- added SOFTPIPE fixes (these need merging into Bernd's series)
- addressed remaining comments for dependencies
- tweaked a few more dependancies
- added a vkmark test
The test won't currently work if the system QEMU doesn't support Venus which requires QEMU 9.2.0 (released 11/12/2024) built with an upto date virglrenderer (available in Debian Trixie/Testing). It doesn't have to be merged now and can wait until the rest of the world catches up.
I plan to use buildroot generated images for QEMU's own functional tests for Venus.
I've run through:
utils/docker-run make check-package
and everything looks clean. Full details about the changes are bellow the ---'s in the individual commits.
Alex Bennée (6):
testing: drop unneeded vga/vnc stanzas from QEMU invocation package/vulkan-sdk: new package package/vulkan-[headers|loader|tools]: bump to 1.4.307 release package/vulkan-tools: suppress isystem being passed package/vkmark: add vkmark benchmarking tool support/testing: add test for vkmark package
DEVELOPERS | 3 + package/Config.in | 2 + ...-handle-Vulkan-errors-during-probing.patch | 77 +++++++++++++++++++ package/vkmark/Config.in | 48 ++++++++++++ package/vkmark/vkmark.hash | 3 + package/vkmark/vkmark.mk | 34 ++++++++ package/vulkan-headers/vulkan-headers.hash | 2 +- package/vulkan-headers/vulkan-headers.mk | 2 +- package/vulkan-loader/vulkan-loader.hash | 2 +- package/vulkan-sdk/Config.in | 8 ++ package/vulkan-sdk/vulkan-sdk.hash | 3 + package/vulkan-sdk/vulkan-sdk.mk | 18 +++++ ...aninfo-suppress-isystem-being-passed.patch | 57 ++++++++++++++ package/vulkan-tools/Config.in | 3 +- package/vulkan-tools/vulkan-tools.hash | 2 +- package/vulkan-tools/vulkan-tools.mk | 3 +- support/testing/infra/emulator.py | 4 +- support/testing/tests/package/test_flutter.py | 2 - support/testing/tests/package/test_vkmark.py | 74 ++++++++++++++++++ .../etc/profile.d/10-xdg-runtime.sh | 1 + 20 files changed, 339 insertions(+), 9 deletions(-) create mode 100644 package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch create mode 100644 package/vkmark/Config.in create mode 100644 package/vkmark/vkmark.hash create mode 100644 package/vkmark/vkmark.mk create mode 100644 package/vulkan-sdk/Config.in create mode 100644 package/vulkan-sdk/vulkan-sdk.hash create mode 100644 package/vulkan-sdk/vulkan-sdk.mk create mode 100644 package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch create mode 100644 support/testing/tests/package/test_vkmark.py create mode 100644 support/testing/tests/package/test_vkmark/rootfs-overlay/etc/profile.d/10-xdg-runtime.sh
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 1/6 testing: drop unneeded vga/vnc stanzas from QEMU invocation
The aarch64 virt platform doesn't have any default VGA devices so we don't need to configure them here.
--- support/testing/tests/package/test_flutter.py | 2 -- 1 file changed, 2 deletions(-)
support/testing/tests/package/test_flutter.py +0 -2
@@ -48,8 +48,6 @@ class TestFlutter(infra.basetest.BRTest, GraphicsBase): "-cpu", "cortex-a57", "-m", "512M", "-smp", "4", - "-vga", "std", - "-vnc", "none", "-drive", f"file={img},if=virtio,format=raw"]) self.emulator.login()
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 1/6] testing: drop unneeded vga/vnc stanzas from QEMU invocation
Quoted 4 lines · Alex Bennée
The aarch64 virt platform doesn't have any default VGA devices so we don't need to configure them here.
Signed-off-by Alex Bennée <[email protected]>
Applied to master, thanks.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 1/6] testing: drop unneeded vga/vnc stanzas from QEMU invocation
In reply to Alex BennéeQuoted 4 lines · Alex Bennée
The aarch64 virt platform doesn't have any default VGA devices so we don't need to configure them here.
Signed-off-by Alex Bennée <[email protected]>
Applied to 2025.02.x, thanks.
Regards,
Arnout
Quoted 9 lines
--- support/testing/tests/package/test_flutter.py | 2 -- 1 file changed, 2 deletions(-)support/testing/tests/package/test_flutter.py +0
-0
support/testing/tests/package/test_flutter.py class TestFlutter(infra.basetest.BRTest, GraphicsBase): · line 53
Quoted 8 lines
support/testing/tests/package/test_flutter.py +0
-2@@ -48,8 +48,6 @@ class TestFlutter(infra.basetest.BRTest, GraphicsBase): "-cpu", "cortex-a57", "-m", "512M", "-smp", "4", - "-vga", "std", - "-vnc", "none", "-drive", f"file={img},if=virtio,format=raw"]) self.emulator.login()
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 2/6 package/vulkan-sdk: new package
In reply to Alex BennéeThe principle component of this is the new volk meta-loader which is required for more recent versions of vulkan-tools.
--- package/Config.in | 1 + package/vulkan-sdk/Config.in | 8 ++++++++ package/vulkan-sdk/vulkan-sdk.hash | 3 +++ package/vulkan-sdk/vulkan-sdk.mk | 18 ++++++++++++++++++ 4 files changed, 30 insertions(+) create mode 100644 package/vulkan-sdk/Config.in create mode 100644 package/vulkan-sdk/vulkan-sdk.hash create mode 100644 package/vulkan-sdk/vulkan-sdk.mk
package/Config.in +1 -0
@@ -374,6 +374,7 @@ comment "Graphic libraries" source "package/tk/Config.in" source "package/vulkan-headers/Config.in" source "package/vulkan-loader/Config.in" + source "package/vulkan-sdk/Config.in" source "package/vulkan-tools/Config.in" comment "Other GUIs"
package/vulkan-sdk/Config.in new file +8 -0
@@ -0,0 +1,8 @@ +config BR2_PACKAGE_VULKAN_SDK + bool "vulkan-sdk" + select BR2_PACKAGE_VULKAN_HEADERS + + help + The Vulkan meta-loader + + https://github.com/zeux/volk
package/vulkan-sdk/vulkan-sdk.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally calculated +sha256 ab3d4a8ccaeb32652259cdd008399504a41792675b0421d90b67729ee274746f 1.4.304.tar.gz +sha256 33c831f76b79501665e66c23ac8f876020457c216d44526a8f747da897999b35 LICENSE.md
package/vulkan-sdk/vulkan-sdk.mk new file +18 -0
@@ -0,0 +1,18 @@ +################################################################################ +# +# vulkan-sdk +# +################################################################################ + +VULKAN_SDK_VERSION = 1.4.304 +VULKAN_SDK_SITE = https://github.com/zeux/volk/archive +VULKAN_SDK_SOURCE= $(VULKAN_SDK_VERSION).tar.gz +VULKAN_SDK_LICENSE = MIT +VULKAN_SDK_LICENSE_FILES = LICENSE.md +VULKAN_SDK_INSTALL_STAGING = YES + +VULKAN_SDK_DEPENDENCIES = vulkan-headers + +VULKAN_SDK_CONF_OPTS += -DVOLK_INSTALL=ON + +$(eval $(cmake-package))
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 3/6 package/vulkan-[headers|loader|tools]: bump to 1.4.307 release
In reply to Alex BennéeUpdate to the current release. We now need the recently added vulkan-sdk to have access to the volk loader.
---
v3
- fix up comment, properly select the SDK package
--- package/vulkan-headers/vulkan-headers.hash | 2 +- package/vulkan-headers/vulkan-headers.mk | 2 +- package/vulkan-loader/vulkan-loader.hash | 2 +- package/vulkan-tools/Config.in | 3 ++- package/vulkan-tools/vulkan-tools.hash | 2 +- package/vulkan-tools/vulkan-tools.mk | 3 ++- 6 files changed, 8 insertions(+), 6 deletions(-)
package/vulkan-headers/vulkan-headers.hash +1 -1
@@ -1,3 +1,3 @@ # Locally calculated -sha256 317e467a5fb2eaa6a18b984ec70fdbfaccd93595a3e6f4bcceca7d3fab280505 vulkan-headers-1.3.262.tar.gz +sha256 6e8445bc12c1e2702c27f4f02d1a057fb83f40cc56c6a8e4583141d4eaad90d4 vulkan-headers-1.4.307.tar.gz sha256 ac24e5ea920e4318e4d02c4086ae51f53cfb03feed06c18df1019e7ada1ec7bc LICENSE.md
package/vulkan-headers/vulkan-headers.mk +1 -1
@@ -6,7 +6,7 @@ # Note: changing this version will also affect vulkan-loader and # vulkan-tools, so please update those packages as well. -VULKAN_HEADERS_VERSION = 1.3.262 +VULKAN_HEADERS_VERSION = 1.4.307 VULKAN_HEADERS_SITE = $(call github,KhronosGroup,Vulkan-Headers,v$(VULKAN_HEADERS_VERSION)) VULKAN_HEADERS_LICENSE = Apache-2.0, MIT VULKAN_HEADERS_LICENSE_FILES = LICENSE.md
package/vulkan-loader/vulkan-loader.hash +1 -1
@@ -1,3 +1,3 @@ # Locally calculated -sha256 3bbaa5ee64058a89949eb777de66ce94bfe3141892514172cfc9451c756802d5 vulkan-loader-1.3.262.tar.gz +sha256 661f7b7d1536538420771372dd8050f2d224fcf3a023f31d66ea76d8af7b911e vulkan-loader-1.4.307.tar.gz sha256 43c0a37e6a0fa7ff3c843b3ec5a4fac84b712558ddac103fbd4c1649662a9ece LICENSE.txt
package/vulkan-tools/Config.in +2 -1
@@ -6,12 +6,13 @@ config BR2_PACKAGE_VULKAN_TOOLS depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader select BR2_PACKAGE_VULKAN_HEADERS select BR2_PACKAGE_VULKAN_LOADER + select BR2_PACKAGE_VULKAN_SDK help The Khronos official Vulkan Tools and Utilities. https://github.com/KhronosGroup/Vulkan-Tools -comment "vulkan-tools needs a toolchain w/ C++, dynamic library, threads, gcc >= 4.9" +comment "vulkan-tools needs a toolchain w/ C++, dynamic library, threads, gcc >= 4.9, vulkan-sdk" depends on !BR2_INSTALL_LIBSTDCPP || BR2_STATIC_LIBS || \ !BR2_TOOLCHAIN_HAS_THREADS || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
package/vulkan-tools/vulkan-tools.hash +1 -1
@@ -1,3 +1,3 @@ # Locally calculated -sha256 8c77d02694d0516ae2ba3f3718745647e87e788ef93faabb2e3674ff32608010 vulkan-tools-1.3.262.tar.gz +sha256 4f0baeaf078c2a9d298b87d6d6ef85c3faf08f0f95b8a7d7d7ff243c6de2707c vulkan-tools-1.4.307.tar.gz sha256 cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30 LICENSE.txt
package/vulkan-tools/vulkan-tools.mk +2 -1
@@ -11,7 +11,8 @@ VULKAN_TOOLS_LICENSE_FILES = LICENSE.txt VULKAN_TOOLS_DEPENDENCIES = \ vulkan-headers \ - vulkan-loader + vulkan-loader \ + vulkan-sdk VULKAN_TOOLS_CONF_OPTS += \ -DBUILD_CUBE=OFF \
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 4/6 package/vulkan-tools: suppress isystem being passed
In reply to Alex BennéeThis applies NO_SYSTEM_FROM_IMPORTED 1 to the vulkaninfo build to prevent -isystem being passed, breaking the build with:
... aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15: fatal error: stdlib.h: No such file or directory
79 | #include_next <stdlib.h>
| ^~~~~~~~~~compilation terminated.
--- ...aninfo-suppress-isystem-being-passed.patch | 57 +++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch
package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +57 -0
@@ -0,0 +1,57 @@ +From 932a9902f923aa0b6423ceee8fb0289665a1d157 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Alex=20Benn=C3=A9e?= <[email protected]> +Date: Fri, 14 Feb 2025 10:44:58 +0000 +Subject: [PATCH] vulkaninfo: suppress -isystem being passed +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +During the process of updating vulkan-tools in buildroot I ran into +the following build failure: + + [ 50%] Building CXX object vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o + In file included from /home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/bits/stl_algo.h:71, + from /home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/algorithm:61, + from /home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/./vulkaninfo.h:31, + from /home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/generated/vulkaninfo.hpp:28, + from /home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/vulkaninfo.cpp:34: + /home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15: fatal error: stdlib.h: No such file or directory + 79 | #include_next <stdlib.h> + | ^~~~~~~~~~ + compilation terminated. + make[2]: *** [vulkaninfo/CMakeFiles/vulkaninfo.dir/build.make:76: vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o] Error 1 + make[1]: *** [CMakeFiles/Makefile2:116: vulkaninfo/CMakeFiles/vulkaninfo.dir/all] Error 2 + make: *** [Makefile:136: all] Error 2 + +The underlying reason was -isystem being passed to the build which I +think resets the include path for system includes. This might be a bug +in cmake but from looking at the CMake source I found some examples +that set: NO_SYSTEM_FROM_IMPORTED 1 as a target property which seems +to do the job. + +This doesn't seem to affect the normal non-cross build although I +wouldn't expect you need to pass -isystem anyway. + +Upstream: https://github.com/KhronosGroup/Vulkan-Tools/pull/1077 +Signed-off-by: Alex Bennée <[email protected]> +--- + vulkaninfo/CMakeLists.txt | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/vulkaninfo/CMakeLists.txt b/vulkaninfo/CMakeLists.txt +index 7e51bb2d..d4f7e1fa 100644 +--- a/vulkaninfo/CMakeLists.txt ++++ b/vulkaninfo/CMakeLists.txt +@@ -22,7 +22,8 @@ set(VULKANINFO_NAME vulkaninfo) + set(GENERATED generated) + + add_executable(vulkaninfo) +-set_target_properties(vulkaninfo PROPERTIES OUTPUT_NAME ${VULKANINFO_NAME}) ++set_target_properties(vulkaninfo PROPERTIES OUTPUT_NAME ${VULKANINFO_NAME} ++ NO_SYSTEM_FROM_IMPORTED 1) + + target_sources(vulkaninfo PRIVATE vulkaninfo.cpp) + +-- +2.39.5 +
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 4/6] package/vulkan-tools: suppress isystem being passed
Hi Alex,
Thanks for the patch!
If the vulkan-tools package is known to be broken from its bump to 1.4.307 from the previous patch, this patch should preferably be squashed with the bump. We are trying to keep each commit functional to make git bisect easier.
Could you squash this patch with the previous one, please?
Quoted 95 lines · Alex Bennée
This applies
NO_SYSTEM_FROM_IMPORTED1 to the vulkaninfo build to prevent -isystem being passed, breaking the build with:... aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15:
fatal error:stdlib.h: No such file or directory79 | #include_next <stdlib.h> | ^~~~~~~~~~compilation terminated.
Signed-off-by Alex Bennée <[email protected]>--- ...aninfo-suppress-isystem-being-passed.patch | 57 +++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644
package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch(quoted diff) +0
-0
b/package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patchpackage/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +12
-0@@ -0,0 +1,57 @@ +From 932a9902f923aa0b6423ceee8fb0289665a1d157 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Alex=20Benn=C3=A9e?= <[email protected]> +Date: Fri, 14 Feb 2025 10:44:58 +0000 +Subject: [PATCH] vulkaninfo: suppress -isystem being passed +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +During the process of updating vulkan-tools in buildroot I ran into +the following build failure: + + [ 50%] Building CXX object
vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o
+ In file included from/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/bits/stl_algo.h:71,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/algorithm:61,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/./vulkaninfo.h:31,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/generated/vulkaninfo.hpp:28,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/vulkaninfo.cpp:34:
+/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15: fatal error:stdlib.h: No such file or directorypackage/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +4
-0+ 79 | #include_next <stdlib.h> + | ^~~~~~~~~~ + compilation terminated. + make[2]: *** [vulkaninfo/CMakeFiles/vulkaninfo.dir/build.make:76:
vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o] Error 1
+ make[1]: *** [CMakeFiles/Makefile2:116:
vulkaninfo/CMakeFiles/vulkaninfo.dir/all] Error 2package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +26
-0+ make: *** [Makefile:136: all] Error 2 + +The underlying reason was -isystem being passed to the build which I +think resets the include path for system includes. This might be a bug +in cmake but from looking at the CMake source I found some examples +that set: NO_SYSTEM_FROM_IMPORTED 1 as a target property which seems +to do the job. + +This doesn't seem to affect the normal non-cross build although I +wouldn't expect you need to pass -isystem anyway. + +Upstream: https://github.com/KhronosGroup/Vulkan-Tools/pull/1077 +Signed-off-by: Alex Bennée <[email protected]> +--- + vulkaninfo/CMakeLists.txt | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/vulkaninfo/CMakeLists.txt b/vulkaninfo/CMakeLists.txt +index 7e51bb2d..d4f7e1fa 100644 +--- a/vulkaninfo/CMakeLists.txt ++++ b/vulkaninfo/CMakeLists.txt +@@ -22,7 +22,8 @@ set(VULKANINFO_NAME vulkaninfo) + set(GENERATED generated) + + add_executable(vulkaninfo) +-set_target_properties(vulkaninfo PROPERTIES OUTPUT_NAME${VULKANINFO_NAME}) ++set_target_properties(vulkaninfo PROPERTIES
OUTPUT_NAME${VULKANINFO_NAME}
++NO_SYSTEM_FROM_IMPORTED
1)package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +6
-1+ + target_sources(vulkaninfo PRIVATE vulkaninfo.cpp) + +-- +2.39.5 + --2.39.5
Quoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Best regards,
Julien.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 4/6] package/vulkan-tools: suppress isystem being passed
Quoted 10 lines · Julien Olivain
Hi Alex,
Thanks for the patch!
If the vulkan-tools package is known to be broken from its bump to 1.4.307 from the previous patch, this patch should preferably be squashed with the bump. We are trying to keep each commit functional to make git bisect easier.
Could you squash this patch with the previous one, please?
After bumping the versions the build seems to work without the patch so I can drop it now.
Quoted 104 lines · Alex Bennée
Quoted 93 lines
This applies
NO_SYSTEM_FROM_IMPORTED1 to the vulkaninfo build to prevent -isystem being passed, breaking the build with:
... aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15:
fatal error:stdlib.h: No such file or directory79 | #include_next <stdlib.h> | ^~~~~~~~~~compilation terminated.
Signed-off-by Alex Bennée <[email protected]>--- ...aninfo-suppress-isystem-being-passed.patch | 57 +++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644
package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patchdiff --gita/package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patchb/package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patchnew file mode 100644
index 0000000000..26f8c4a55f
---/dev/null
+++b/package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patchpackage/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +12
-0@@ -0,0 +1,57 @@ +From 932a9902f923aa0b6423ceee8fb0289665a1d157 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Alex=20Benn=C3=A9e?= <[email protected]> +Date: Fri, 14 Feb 2025 10:44:58 +0000 +Subject: [PATCH] vulkaninfo: suppress -isystem being passed +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +During the process of updating vulkan-tools in buildroot I ran into +the following build failure: + + [ 50%] Building CXX object
vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o
+ In file included from/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/bits/stl_algo.h:71,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/algorithm:61,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/./vulkaninfo.h:31,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/generated/vulkaninfo.hpp:28,
+ from/home/alex/lsrc/tests/buildroot.git/builds/arm64/build/vulkan-tools-1.4.307/vulkaninfo/vulkaninfo.cpp:34:
+/home/alex/lsrc/tests/buildroot.git/builds/arm64/host/aarch64-buildroot-linux-gnu/include/c++/14.2.0/cstdlib:79:15:
fatal error:stdlib.h: No such file or directorypackage/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +4
-0+ 79 | #include_next <stdlib.h> + | ^~~~~~~~~~ + compilation terminated. + make[2]: *** [vulkaninfo/CMakeFiles/vulkaninfo.dir/build.make:76:
vulkaninfo/CMakeFiles/vulkaninfo.dir/vulkaninfo.cpp.o] Error 1
+ make[1]: *** [CMakeFiles/Makefile2:116:
vulkaninfo/CMakeFiles/vulkaninfo.dir/all] Error 2package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +26
-0+ make: *** [Makefile:136: all] Error 2 + +The underlying reason was -isystem being passed to the build which I +think resets the include path for system includes. This might be a bug +in cmake but from looking at the CMake source I found some examples +that set: NO_SYSTEM_FROM_IMPORTED 1 as a target property which seems +to do the job. + +This doesn't seem to affect the normal non-cross build although I +wouldn't expect you need to pass -isystem anyway. + +Upstream: https://github.com/KhronosGroup/Vulkan-Tools/pull/1077 +Signed-off-by: Alex Bennée <[email protected]> +--- + vulkaninfo/CMakeLists.txt | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/vulkaninfo/CMakeLists.txt b/vulkaninfo/CMakeLists.txt +index 7e51bb2d..d4f7e1fa 100644 +--- a/vulkaninfo/CMakeLists.txt ++++ b/vulkaninfo/CMakeLists.txt +@@ -22,7 +22,8 @@ set(VULKANINFO_NAME vulkaninfo) + set(GENERATED generated) + + add_executable(vulkaninfo) +-set_target_properties(vulkaninfo PROPERTIES OUTPUT_NAME${VULKANINFO_NAME}) ++set_target_properties(vulkaninfo PROPERTIES
OUTPUT_NAME${VULKANINFO_NAME}
++NO_SYSTEM_FROM_IMPORTED1)package/vulkan-tools/0001-vulkaninfo-suppress-isystem-being-passed.patch new file +6
-1+ + target_sources(vulkaninfo PRIVATE vulkaninfo.cpp) + +-- +2.39.5 + --Quoted 5 lines
2.39.5
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildrootBest regards,
Julien.
Signature · 6 lines
Alex Bennée Virtualisation Tech Lead @ Linaro _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 5/6 package/vkmark: add vkmark benchmarking tool
In reply to Alex BennéeWe build from the recent 2025.1 release although we need one commit from master to better handle the missing KHR_display extension.
---
v4
- fix tab vs space damage
- don't if BR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initial VKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly to VKMARK_DEPENDENCIES
- drop duplicate BR2_INSTALL_LIBSTDCPP
- drop BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends
--- DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77 +++++++++++++++++++ package/vkmark/Config.in | 48 ++++++++++++ package/vkmark/vkmark.hash | 3 + package/vkmark/vkmark.mk | 34 ++++++++ 6 files changed, 166 insertions(+) create mode 100644 package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch create mode 100644 package/vkmark/Config.in create mode 100644 package/vkmark/vkmark.hash create mode 100644 package/vkmark/vkmark.mk
DEVELOPERS +3 -0
@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/ N: Alexandre Belloni <[email protected]> F: package/tz/ +N: Alex Bennée <[email protected]> +F: package/vkmark/ + N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/
package/Config.in +1 -0
@@ -338,6 +338,7 @@ comment "Graphic applications" source "package/swaybg/Config.in" source "package/tesseract-ocr/Config.in" source "package/tinifier/Config.in" + source "package/vkmark/Config.in" comment "Graphic libraries" source "package/cegui/Config.in"
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +77 -0
77 lines not on this page · raw message
package/vkmark/Config.in new file +48 -0
48 lines not on this page · raw message
package/vkmark/vkmark.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally computed +sha256 1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edc vkmark-2025.01.tar.gz +sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING-LGPL2.1
package/vkmark/vkmark.mk new file +34 -0
@@ -0,0 +1,34 @@ +################################################################################ +# +# vkmark +# +################################################################################ + +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headers vulkan-loader + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package))
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
Hi Alex,
thank you for these series.
Am Mo., 3. März 2025 um 17:16 Uhr schrieb Alex Bennée < [email protected]>:
Quoted 272 lines
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly toVKMARK_DEPENDENCIES
- drop duplicateBR2_INSTALL_LIBSTDCPP
- dropBR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends--- DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77 +++++++++++++++++++ package/vkmark/Config.in | 48 ++++++++++++ package/vkmark/vkmark.hash | 3 + package/vkmark/vkmark.mk | 34 ++++++++ 6 files changed, 166 insertions(+) create mode 100644 package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch create mode 100644 package/vkmark/Config.in create mode 100644 package/vkmark/vkmark.hash create mode 100644 package/vkmark/vkmark.mkDEVELOPERS +3
-0@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/ N: Alexandre Belloni <[email protected]> F: package/tz/ +N: Alex Bennée <[email protected]> +F: package/vkmark/ + N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/package/Config.in +1
-0@@ -338,6 +338,7 @@ comment "Graphic applications" source "package/swaybg/Config.in" source "package/tesseract-ocr/Config.in" source "package/tinifier/Config.in" + source "package/vkmark/Config.in" comment "Graphic libraries" source "package/cegui/Config.in"diff --git
a/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchb/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchnew file mode 100644
index 0000000000..7e2e43a946
---/dev/null
+++b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchpackage/Config.in +10
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:00 2001 +From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors during probing + +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]> +Upstream:https://github.com/vkmark/vkmark/commit/37d0a0d7fa6dcde6f62718d2115e8b76646bff23
package/Config.in +6
-0+ +--- + src/ws/display_window_system_plugin.cpp | 39 ++++++++++++------------- + 1 file changed, 19 insertions(+), 20 deletions(-) + +diff --git a/src/ws/display_window_system_plugin.cppb/src/ws/display_window_system_plugin.cpp
package/Config.in +19
-0+index 523092b..fcbd949 100644 +--- a/src/ws/display_window_system_plugin.cpp ++++ b/src/ws/display_window_system_plugin.cpp +@@ -72,24 +72,22 @@ int vkmark_window_system_probe(Options const& options) + .setPApplicationInfo(&app_info) + .setEnabledExtensionCount(exts.size()) + .setPpEnabledExtensionNames(exts.data()); +- auto vk_instance = ManagedResource<vk::Instance>{ +- vk::createInstance(create_info), +- [] (auto& i) { i.destroy(); }}; +- if (!vk_instance.raw) +- return VKMARK_WINDOW_SYSTEM_PROBE_BAD; +- +- auto physical_devices = vk_instance.raw.enumeratePhysicalDevices(); +- auto physical_device = options.use_device_with_uuid ? +- std::find_if( +- physical_devices.begin(), physical_devices.end(), +- [&options] (auto pd) { +- returnstatic_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
+- options.use_device_with_uuid; }) : +- physical_devices.begin(); +- +- if (physical_device != physical_devices.end()) ++ ++ try + { +- try ++ auto vk_instance = ManagedResource<vk::Instance>{ ++ vk::createInstance(create_info), ++ [] (auto& i) { i.destroy(); }}; ++ auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();
++ autophysical_device= options.use_device_with_uuid ?
++ std::find_if(
++physical_devices.begin(),physical_devices.end(),
++ [&options] (auto pd) {
++ return
static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
++ options.use_device_with_uuid; }) :
++physical_devices.begin();
++
++ if (physical_device!=physical_devices.end())package/Config.in +2
-0+ { + auto display_index =std::stoi(get_display_index_option(options));
package/Config.in +3
-0+ if (display_index < 0) +@@ -97,10 +95,11 @@ int vkmark_window_system_probe(Options const& options) + DisplayNativeSystem::get_display_surface_create_info(*physical_device,
display_index);
+ returnVKMARK_WINDOW_SYSTEM_PROBE_OK+VKMARK_DISPLAY_WINDOW_SYSTEM_PRIORITY;package/Config.in +15
-0+ } +- catch (...) +- { +- } + } ++ catch (...) ++ { ++ } ++ + + return VKMARK_WINDOW_SYSTEM_PROBE_BAD; + } +-- +2.39.5 +package/vkmark/Config.in new file +29
-0@@ -0,0 +1,48 @@ +config BR2_PACKAGE_VKMARK_FLAVOR_ANY + bool + +config BR2_PACKAGE_VKMARK_FLAVOR_KMS + bool + default y if BR2_PACKAGE_HAS_LIBGBM + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND + bool + default y if BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_X11 + bool + default y if BR2_PACKAGE_XORG7 + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK + bool "vkmark" + depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + depends on !BR2_STATIC_LIBS # vulkan-loader + depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader + select BR2_PACKAGE_GLM + depends on BR2_USE_WCHAR # assimp + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp + depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm, assimp,vkmark
package/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_ASSIMP + select BR2_PACKAGE_WAYLAND_PROTOCOLS if
BR2_PACKAGE_VKMARK_FLAVOR_WAYLANDpackage/vkmark/Config.in new file +9
-0+ select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_XCB_UTIL_WM if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_VKMARK_FLAVOR_KMS + help + vmmark is an Vulkan GPU benchmark. + + https://github.com/vkmark/vkmark + +comment "vkmark needs a toolchain w/ dynamic library, threads, wchar, gccQuoted 1 line
= 7, C++"
package/vkmark/Config.in new file +8
-0+ depends on BR2_STATIC_LIBS || \ + !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR || \ + !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \ + !BR2_INSTALL_LIBSTDCPP + +comment "vkmark needs a backend: gbm, wayland or xcb" + depends on !BR2_PACKAGE_VKMARK_FLAVOR_ANYpackage/vkmark/vkmark.hash new file +2
-0@@ -0,0 +1,3 @@ +# Locally computed +sha256 1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edcvkmark-2025.01.tar.gz
+sha256dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551COPYING-LGPL2.1package/vkmark/vkmark.mk new file +34
-1@@ -0,0 +1,34 @@ +################################################################################ +# +# vkmark +# +################################################################################ + +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headers vulkan-loader + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package)) --
Quoted 3 lines
2.39.5
I tried to build vkmark but get this error:
Quoted 1 line
Quoted 1 line
Quoted 1 line
vkmark custom Configuring
rm -rf/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build
mkdir -p/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build
sed -e "/^\[binaries\]$/s:$::" -e "/^\[properties\]$/s:$::" -e
"s%@TARGET_CC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc%g"
-e "s%@TARGET_CXX@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++%g"
-e "s%@TARGET_AR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc-ar%g"
-e "s%@TARGET_FC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gfortran%g"
-e "s%@TARGET_STRIP@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-strip%g"
-e "s%@TARGET_ARCH@%aarch64%g" -e "s%@TARGET_CPU@%cortex-a53%g" -e
"s%@TARGET_ENDIAN@%little%g" -e "s%@TARGET_FCFLAGS@%%g" -e
"s%@TARGET_CFLAGS@%'-D_LARGEFILE_SOURCE',
'-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0',
'-D_FORTIFY_SOURCE=1'%g" -e "s%@TARGET_LDFLAGS@%%g" -e
"s%@TARGET_CXXFLAGS@%'-D_LARGEFILE_SOURCE',
'-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0',
'-D_FORTIFY_SOURCE=1'%g" -e
"s%@BR2_CMAKE@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake%g"
-e "s%@PKGCONF_HOST_BINARY@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf%g"
-e "s%@HOST_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host%g" -e
"s%@STAGING_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/aarch64-buildroot-linux-gnu/sysroot%g"
-e "s%@STATIC@%false%g"/srv/storage/hthiery/sources/sa67/buildroot/support/misc/
cross-compilation.conf.in >/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.conf PATH="/srv/storage/hthiery/sources/sa67/out-graphic/host/bin:/srv/storage/hthiery/sources/sa67/out-graphic/host/sbin:/home/hthiery/.local/bin:/home/hthiery/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" CC_FOR_BUILD="/usr/bin/gcc" CXX_FOR_BUILD="/usr/bin/g++"
PYTHONNOUSERSITE=y/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/meson setup
--prefix=/usr --libdir=lib --default-library=shared --buildtype=release --cross-file=/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.conf
-Db_pie=false -Db_staticpic=true -Dstrip=false
-Dbuild.pkg_config_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/pkgconfig
-Dbuild.cmake_prefix_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/cmake
-Dkms=true -Dwayland=false -Dxcb=false/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build
The Meson build system
Version: 1.7.0
Source dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom
Build dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom/buildroot-build
Build type: cross build
Project name: vkmark
Project version: 2025.01
C compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc
(gcc 14.2.0 "aarch64-linux-gcc.br_real (Buildroot
2021.11-12449-g1bef613319) 14.2.0")
C linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc
ld.bfd 2.42
C++ compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++
(gcc 14.2.0 "aarch64-linux-g++.br_real (Buildroot
2021.11-12449-g1bef613319) 14.2.0")
C++ linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++
ld.bfd 2.42
C compiler for the build machine: /usr/bin/gcc (gcc 8.3.0 "gcc (Debian
8.3.0-6) 8.3.0")
C linker for the build machine: /usr/bin/gcc ld.bfd 2.31.1
C++ compiler for the build machine: /usr/bin/g++ (gcc 8.3.0 "g++ (Debian
8.3.0-6) 8.3.0")
C++ linker for the build machine: /usr/bin/g++ ld.bfd 2.31.1
Build machine cpu family: x86_64
Build machine cpu: x86_64
Host machine cpu family: aarch64
Host machine cpu: cortex-a53
Target machine cpu family: aarch64
Target machine cpu: cortex-a53
Found pkg-config: YES
(/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkg-config) 2.3.0
Build-time dependency vulkan found: YES 1.4.307
Library dl found: YES
Found pkg-config: YES
(/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf) 2.3.0
Found CMake: /srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake
(3.31.5)
Run-time dependency glm found: YES 1.0.0
Run-time dependency assimp found: YES 5.4.3
Run-time dependency xcb found: NO (tried pkgconfig and cmake)
Run-time dependency xcb-icccm found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-client found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-protocols found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-scanner found: NO (tried pkgconfig and cmake)
Run-time dependency libdrm found: YES 2.4.124
Run-time dependency gbm found: YES 25.0.6
Program python3 found: YES
(/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/python3)
../out-graphic/build/vkmark-custom/src/meson.build:9:19: ERROR: File /usr/share/vulkan/registry/vk.xml does not exist
Is the vk.xml file installed on your system in /usr/share/vulkan/registry/vk.xml? I think the problem is related to the vulkan.pc file that has a wrong prefix value set.
Can you confirm that?
---
Heiko
Quoted 5 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
Hi Alex,
Am Mi., 28. Mai 2025 um 16:00 Uhr schrieb Heiko Thiery < [email protected]>:
Quoted 382 lines
Hi Alex,
thank you for these series.
Am Mo., 3. März 2025 um 17:16 Uhr schrieb Alex Bennée < [email protected]>:
Quoted 277 lines
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly toVKMARK_DEPENDENCIES
- drop duplicateBR2_INSTALL_LIBSTDCPP
- dropBR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends--- DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77 +++++++++++++++++++ package/vkmark/Config.in | 48 ++++++++++++ package/vkmark/vkmark.hash | 3 + package/vkmark/vkmark.mk | 34 ++++++++ 6 files changed, 166 insertions(+) create mode 100644 package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch create mode 100644 package/vkmark/Config.in create mode 100644 package/vkmark/vkmark.hash create mode 100644 package/vkmark/vkmark.mkDEVELOPERS +3
-0@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/ N: Alexandre Belloni <[email protected]> F: package/tz/ +N: Alex Bennée <[email protected]> +F: package/vkmark/ + N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/package/Config.in +1
-0@@ -338,6 +338,7 @@ comment "Graphic applications" source "package/swaybg/Config.in" source "package/tesseract-ocr/Config.in" source "package/tinifier/Config.in" + source "package/vkmark/Config.in" comment "Graphic libraries" source "package/cegui/Config.in"diff --git
a/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchb/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchnew file mode 100644
index 0000000000..7e2e43a946
---/dev/null
+++b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchpackage/Config.in +10
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:00 2001 +From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors during probing + +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]> +Upstream:https://github.com/vkmark/vkmark/commit/37d0a0d7fa6dcde6f62718d2115e8b76646bff23
package/Config.in +6
-0+ +--- + src/ws/display_window_system_plugin.cpp | 39 ++++++++++++------------- + 1 file changed, 19 insertions(+), 20 deletions(-) + +diff --git a/src/ws/display_window_system_plugin.cppb/src/ws/display_window_system_plugin.cpp
+index 523092b..fcbd949 100644
+--- a/src/ws/display_window_system_plugin.cpp
++++ b/src/ws/display_window_system_plugin.cpp
+@@ -72,24 +72,22 @@ intvkmark_window_system_probe(Options const& options)package/Config.in +15
-0+ .setPApplicationInfo(&app_info) + .setEnabledExtensionCount(exts.size()) + .setPpEnabledExtensionNames(exts.data()); +- auto vk_instance = ManagedResource<vk::Instance>{ +- vk::createInstance(create_info), +- [] (auto& i) { i.destroy(); }}; +- if (!vk_instance.raw) +- return VKMARK_WINDOW_SYSTEM_PROBE_BAD; +- +- auto physical_devices = vk_instance.raw.enumeratePhysicalDevices(); +- auto physical_device = options.use_device_with_uuid ? +- std::find_if( +- physical_devices.begin(), physical_devices.end(), +- [&options] (auto pd) { +- returnstatic_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
+- options.use_device_with_uuid; }) : +- physical_devices.begin(); +- +- if (physical_device != physical_devices.end()) ++ ++ try + { +- try ++ auto vk_instance = ManagedResource<vk::Instance>{ ++ vk::createInstance(create_info), ++ [] (auto& i) { i.destroy(); }}; ++ auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();
++ autophysical_device= options.use_device_with_uuid ?
++ std::find_if(
++physical_devices.begin(),physical_devices.end(),
++ [&options] (auto pd) {
++ return
static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
++ options.use_device_with_uuid; }) :
++physical_devices.begin();
++
++ if (physical_device!=physical_devices.end())package/Config.in +2
-0+ { + auto display_index =std::stoi(get_display_index_option(options));
+ if (display_index< 0)
+@@ -97,10 +95,11 @@ intvkmark_window_system_probe(Options const& options)
+
DisplayNativeSystem::get_display_surface_create_info(*physical_device,display_index);
+ returnVKMARK_WINDOW_SYSTEM_PROBE_OK+VKMARK_DISPLAY_WINDOW_SYSTEM_PRIORITY;package/Config.in +15
-0+ } +- catch (...) +- { +- } + } ++ catch (...) ++ { ++ } ++ + + return VKMARK_WINDOW_SYSTEM_PROBE_BAD; + } +-- +2.39.5 +package/vkmark/Config.in new file +29
-0@@ -0,0 +1,48 @@ +config BR2_PACKAGE_VKMARK_FLAVOR_ANY + bool + +config BR2_PACKAGE_VKMARK_FLAVOR_KMS + bool + default y if BR2_PACKAGE_HAS_LIBGBM + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND + bool + default y if BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_X11 + bool + default y if BR2_PACKAGE_XORG7 + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK + bool "vkmark" + depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + depends on !BR2_STATIC_LIBS # vulkan-loader + depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader + select BR2_PACKAGE_GLM + depends on BR2_USE_WCHAR # assimp + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp + depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm, assimp,vkmark
package/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_ASSIMP + select BR2_PACKAGE_WAYLAND_PROTOCOLS if
BR2_PACKAGE_VKMARK_FLAVOR_WAYLANDpackage/vkmark/Config.in new file +9
-0+ select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_XCB_UTIL_WM if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_VKMARK_FLAVOR_KMS + help + vmmark is an Vulkan GPU benchmark. + + https://github.com/vkmark/vkmark + +comment "vkmark needs a toolchain w/ dynamic library, threads, wchar,gcc >= 7, C++"
package/vkmark/Config.in new file +8
-0+ depends on BR2_STATIC_LIBS || \ + !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR || \ + !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \ + !BR2_INSTALL_LIBSTDCPP + +comment "vkmark needs a backend: gbm, wayland or xcb" + depends on !BR2_PACKAGE_VKMARK_FLAVOR_ANYpackage/vkmark/vkmark.hash new file +2
-0@@ -0,0 +1,3 @@ +# Locally computed +sha256
1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edcvkmark-2025.01.tar.gz
+sha256dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551COPYING-LGPL2.1package/vkmark/vkmark.mk new file +11
-0@@ -0,0 +1,34 @@ +################################################################################ +# +# vkmark +# +################################################################################ + +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headersvulkan-loader
package/vkmark/vkmark.mk new file +23
-1+ +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package)) --Quoted 3 lines
2.39.5
I tried to build vkmark but get this error:
Quoted 1 line
Quoted 1 line
Quoted 1 line
vkmark custom Configuring
rm -rf
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildmkdir -p/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build
sed -e "/^\[binaries\]$/s:$::" -e "/^\[properties\]$/s:$::" -e
"s%@TARGET_CC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc%g"(quoted diff) +0
-5-e "s%@TARGET_CXX@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++%g" -e "s%@TARGET_AR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc-ar%g" -e "s%@TARGET_FC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gfortran%g" -e "s%@TARGET_STRIP@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-strip%g" -e "s%@TARGET_ARCH@%aarch64%g" -e "s%@TARGET_CPU@%cortex-a53%g" -e"s%@TARGET_ENDIAN@%little%g" -e "s%@TARGET_FCFLAGS@%%g" -e "s%@TARGET_CFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0', '-D_FORTIFY_SOURCE=1'%g" -e "s%@TARGET_LDFLAGS@%%g" -e "s%@TARGET_CXXFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0',
'-D_FORTIFY_SOURCE=1'%g" -e "s%@BR2_CMAKE@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake%g"(quoted diff) +0
-2-e "s%@PKGCONF_HOST_BINARY@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf%g" -e "s%@HOST_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host%g" -e"s%@STAGING_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/aarch64-buildroot-linux-gnu/sysroot%g"
-e "s%@STATIC@%false%g"/srv/storage/hthiery/sources/sa67/buildroot/support/misc/
cross-compilation.conf.in >/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.confPATH="/srv/storage/hthiery/sources/sa67/out-graphic/host/bin:/srv/storage/hthiery/sources/sa67/out-graphic/host/sbin:/home/hthiery/.local/bin:/home/hthiery/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" CC_FOR_BUILD="/usr/bin/gcc" CXX_FOR_BUILD="/usr/bin/g++"
PYTHONNOUSERSITE=y/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/mesonsetup
--prefix=/usr --libdir=lib --default-library=shared --buildtype=release --cross-file=/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.conf(quoted diff) +0
-4-Db_pie=false -Db_staticpic=true -Dstrip=false -Dbuild.pkg_config_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/pkgconfig -Dbuild.cmake_prefix_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/cmake -Dkms=true -Dwayland=false -Dxcb=false
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildThe Meson build system
Version: 1.7.0
Source dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-customBuild dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom/buildroot-buildBuild type: cross build
Project name: vkmark
Project version: 2025.01
C compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc(gcc 14.2.0 "aarch64-linux-gcc.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gccld.bfd 2.42
C++ compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++(gcc 14.2.0 "aarch64-linux-g++.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C++ linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++ld.bfd 2.42
C compiler for the build machine:/usr/bin/gcc(gcc 8.3.0 "gcc (Debian 8.3.0-6) 8.3.0")
C linker for the build machine:/usr/bin/gccld.bfd 2.31.1
C++ compiler for the build machine:/usr/bin/g++(gcc 8.3.0 "g++ (Debian 8.3.0-6) 8.3.0")
C++ linker for the build machine:/usr/bin/g++ld.bfd 2.31.1
Build machine cpu family:x86_64
Build machine cpu:x86_64
Host machine cpu family: aarch64
Host machine cpu: cortex-a53
Target machine cpu family: aarch64
Target machine cpu: cortex-a53
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkg-config) 2.3.0 Build-time dependency vulkan found: YES 1.4.307
Library dl found: YES
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf) 2.3.0 Found CMake:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake(3.31.5)
Run-time dependency glm found: YES 1.0.0
Run-time dependency assimp found: YES 5.4.3
Run-time dependency xcb found: NO (tried pkgconfig and cmake) Run-time dependency xcb-icccm found: NO (tried pkgconfig and cmake) Run-time dependency wayland-client found: NO (tried pkgconfig and cmake) Run-time dependency wayland-protocols found: NO (tried pkgconfig and cmake) Run-time dependency wayland-scanner found: NO (tried pkgconfig and cmake) Run-time dependency libdrm found: YES 2.4.124
Run-time dependency gbm found: YES 25.0.6
Program python3 found: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/python3)
Quoted 9 lines
../out-graphic/build/vkmark-custom/src/meson.build:9:19: ERROR: File
/usr/share/vulkan/registry/vk.xmldoes not existIs the vk.xml file installed on your system in
/usr/share/vulkan/registry/vk.xml? I think the problem is related to the vulkan.pc file that has a wrong prefix value set.
I did some more debugging on that failure and see that on another host it builds just fine. It is not related to the vulkan.pc file, because on the machine where the build successfully builds the content is the same. There seems to be another problem. I did some more tests but cannot find the root cause of the failure at the moment.
--
Heiko
Quoted 13 lines
Can you confirm that?
---
HeikoQuoted 5 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
In reply to Heiko ThieryHi Heiko, Alex,
Quoted 405 lines · Heiko Thiery
Hi Alex,
thank you for these series.
Am Mo., 3. März 2025 um 17:16 Uhr schrieb Alex Bennée <[email protected]>:
Quoted 30 lines
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly toVKMARK_DEPENDENCIES
- drop duplicateBR2_INSTALL_LIBSTDCPP
- dropBR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends
---DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77Quoted 7 lines
+++++++++++++++++++
package/vkmark/Config.in | 48 ++++++++++++
package/vkmark/vkmark.hash | 3 +package/vkmark/vkmark.mk[1] | 34 ++++++++6 files changed, 166 insertions(+)create mode 100644
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 28 lines
create mode 100644 package/vkmark/Config.in
create mode 100644 package/vkmark/vkmark.hash
create mode 100644package/vkmark/vkmark.mk[1]DEVELOPERS +0
-0@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/N: Alexandre Belloni <[email protected]> F: package/tz/DEVELOPERS +3
-0+N: Alex Bennée <[email protected]> +F: package/vkmark/ +N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/package/Config.in +0
-0@@ -338,6 +338,7 @@ comment "Graphic applications"source "package/swaybg/Config.in"
source "package/tesseract-ocr/Config.in"
source "package/tinifier/Config.in"
+ source "package/vkmark/Config.in"Quoted 4 lines
comment "Graphic libraries"
source "package/cegui/Config.in"
diff --git
a/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 1 line
b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 5 lines
new file mode 100644
index 0000000000..7e2e43a946
---/dev/null
+++
b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 8 lines
package/Config.in +1
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:002001
package/Config.in +3
-0+From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors duringprobing
package/Config.in
Quoted 6 lines
package/Config.in +6
-0+ +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]> +Upstream:https://github.com/vkmark/vkmark/commit/37d0a0d7fa6dcde6f62718d2115e8b76646bff23
Quoted 55 lines
package/Config.in +7
-0+ +--- + src/ws/display_window_system_plugin.cpp | 39 ++++++++++++------------- + 1 file changed, 19 insertions(+), 20 deletions(-) + +diff --git a/src/ws/display_window_system_plugin.cppb/src/ws/display_window_system_plugin.cpp
+index 523092b..fcbd949 100644
+--- a/src/ws/display_window_system_plugin.cpp
++++ b/src/ws/display_window_system_plugin.cpp
+@@ -72,24 +72,22 @@ intvkmark_window_system_probe(Options const& options)package/Config.in +10
-0+ .setPApplicationInfo(&app_info) + .setEnabledExtensionCount(exts.size()) + .setPpEnabledExtensionNames(exts.data()); +- auto vk_instance = ManagedResource<vk::Instance>{ +- vk::createInstance(create_info), +- [] (auto& i) { i.destroy(); }}; +- if (!vk_instance.raw) +- return VKMARK_WINDOW_SYSTEM_PROBE_BAD; +- +- auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();+- auto physical_device = options.use_device_with_uuid ? +- std::find_if( +- physical_devices.begin(), physical_devices.end(), +- [&options] (auto pd) { +- return static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) == +- options.use_device_with_uuid; }) : +- physical_devices.begin(); +- +- if (physical_device != physical_devices.end()) ++ ++ try + { +- try ++ auto vk_instance = ManagedResource<vk::Instance>{ ++ vk::createInstance(create_info), ++ [] (auto& i) { i.destroy(); }}; ++ auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();
++ autophysical_device= options.use_device_with_uuid ?
++ std::find_if(
++physical_devices.begin(),physical_devices.end(),
++ [&options] (auto pd) {
++ return
static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
++ options.use_device_with_uuid; }) :
++physical_devices.begin();
++
++ if (physical_device!=physical_devices.end())package/Config.in +2
-0+ { + auto display_index =Quoted 6 lines
std::stoi(get_display_index_option(options));
+ if (display_index< 0)
+@@ -97,10 +95,11 @@ intvkmark_window_system_probe(Options const& options)
+DisplayNativeSystem::get_display_surface_create_info(*physical_device,
package/vkmark/vkmark.mk [1]
Quoted 97 lines
display_index);
+ returnVKMARK_WINDOW_SYSTEM_PROBE_OK+VKMARK_DISPLAY_WINDOW_SYSTEM_PRIORITY;package/Config.in +15
-0+ } +- catch (...) +- { +- } + } ++ catch (...) ++ { ++ } ++ + + return VKMARK_WINDOW_SYSTEM_PROBE_BAD; + } +-- +2.39.5 +package/vkmark/Config.in new file +29
-0@@ -0,0 +1,48 @@ +config BR2_PACKAGE_VKMARK_FLAVOR_ANY + bool + +config BR2_PACKAGE_VKMARK_FLAVOR_KMS + bool + default y if BR2_PACKAGE_HAS_LIBGBM + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND + bool + default y if BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_X11 + bool + default y if BR2_PACKAGE_XORG7 + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK + bool "vkmark" + depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + depends on !BR2_STATIC_LIBS # vulkan-loader + depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader + select BR2_PACKAGE_GLM + depends on BR2_USE_WCHAR # assimp + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp + depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm,assimp, vkmark
package/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_ASSIMP + select BR2_PACKAGE_WAYLAND_PROTOCOLS if
BR2_PACKAGE_VKMARK_FLAVOR_WAYLANDpackage/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_XCB_UTIL_WM if
BR2_PACKAGE_VKMARK_FLAVOR_X11package/vkmark/Config.in new file +7
-0+ select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_VKMARK_FLAVOR_KMS + help + vmmark is an Vulkan GPU benchmark. + + https://github.com/vkmark/vkmark + +comment "vkmark needs a toolchain w/ dynamic library, threads,wchar, gcc >= 7, C++"
package/vkmark/Config.in new file +8
-0+ depends on BR2_STATIC_LIBS || \ + !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR || \ + !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \ + !BR2_INSTALL_LIBSTDCPP + +comment "vkmark needs a backend: gbm, wayland or xcb" + depends on !BR2_PACKAGE_VKMARK_FLAVOR_ANYpackage/vkmark/vkmark.hash new file +2
-0@@ -0,0 +1,3 @@ +# Locally computed +sha256
1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edcvkmark-2025.01.tar.gz
+sha256dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551COPYING-LGPL2.1package/vkmark/vkmark.mk renamed from package/vkmark/vkmark.mk [1] +0
-0[1]
new file mode 100644
index 0000000000..7b721c6c99package/vkmark/vkmark.mk [1] new file +0
-0@@ -0,0 +1,34 @@+################################################################################
package/vkmark/vkmark.mk [1] line 3
Quoted 4 lines
package/vkmark/vkmark.mk [1] new file +3
-0+# +# vkmark +#+################################################################################
Quoted 31 lines
package/vkmark/vkmark.mk [1] new file +6
-0+ +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headersvulkan-loader
package/vkmark/vkmark.mk [1] new file +23
-1+ +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package)) --Quoted 1 line
2.39.5
I tried to build vkmark but get this error:
Quoted 1 line
Quoted 1 line
Quoted 1 line
vkmark custom Configuring
rm -rf
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildmkdir -p/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build
sed -e "/^\[binaries\]$/s:$::" -e "/^\[properties\]$/s:$::" -e
"s%@TARGET_CC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc%g" -e "s%@TARGET_CXX@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++%g" -e "s%@TARGET_AR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc-ar%g" -e "s%@TARGET_FC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gfortran%g" -e "s%@TARGET_STRIP@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-strip%g" -e "s%@TARGET_ARCH@%aarch64%g" -e "s%@TARGET_CPU@%cortex-a53%g" -e "s%@TARGET_ENDIAN@%little%g" -e "s%@TARGET_FCFLAGS@%%g" -e "s%@TARGET_CFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0', '-D_FORTIFY_SOURCE=1'%g" -e "s%@TARGET_LDFLAGS@%%g" -e "s%@TARGET_CXXFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0', '-D_FORTIFY_SOURCE=1'%g" -e "s%@BR2_CMAKE@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake%g" -e "s%@PKGCONF_HOST_BINARY@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf%g"(quoted diff) +0
-2-e "s%@HOST_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host%g" -e"s%@STAGING_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/aarch64-buildroot-linux-gnu/sysroot%g"
-e "s%@STATIC@%false%g"/srv/storage/hthiery/sources/sa67/buildroot/support/misc/cross-compilation.conf.in
[2] >/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.confPATH="/srv/storage/hthiery/sources/sa67/out-graphic/host/bin:/srv/storage/hthiery/sources/sa67/out-graphic/host/sbin:/home/hthiery/.local/bin:/home/hthiery/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" CC_FOR_BUILD="/usr/bin/gcc" CXX_FOR_BUILD="/usr/bin/g++"
PYTHONNOUSERSITE=y/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/mesonsetup
--prefix=/usr --libdir=lib --default-library=shared
--buildtype=release
--cross-file=/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.conf(quoted diff) +0
-4-Db_pie=false -Db_staticpic=true -Dstrip=false -Dbuild.pkg_config_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/pkgconfig -Dbuild.cmake_prefix_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/cmake -Dkms=true -Dwayland=false -Dxcb=false
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildThe Meson build system
Version: 1.7.0
Source dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-customBuild dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom/buildroot-buildBuild type: cross build
Project name: vkmark
Project version: 2025.01
C compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc(gcc 14.2.0 "aarch64-linux-gcc.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gccld.bfd 2.42
C++ compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++(gcc 14.2.0 "aarch64-linux-g++.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C++ linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++ld.bfd 2.42
C compiler for the build machine:/usr/bin/gcc(gcc 8.3.0 "gcc (Debian 8.3.0-6) 8.3.0")
C linker for the build machine:/usr/bin/gccld.bfd 2.31.1
C++ compiler for the build machine:/usr/bin/g++(gcc 8.3.0 "g++ (Debian 8.3.0-6) 8.3.0")
C++ linker for the build machine:/usr/bin/g++ld.bfd 2.31.1
Build machine cpu family:x86_64
Build machine cpu:x86_64
Host machine cpu family: aarch64
Host machine cpu: cortex-a53
Target machine cpu family: aarch64
Target machine cpu: cortex-a53
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkg-config) 2.3.0
Build-time dependency vulkan found: YES 1.4.307
Library dl found: YES
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf) 2.3.0 Found CMake:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake(3.31.5) Run-time dependency glm found: YES 1.0.0
Run-time dependency assimp found: YES 5.4.3
Run-time dependency xcb found: NO (tried pkgconfig and cmake) Run-time dependency xcb-icccm found: NO (tried pkgconfig and cmake) Run-time dependency wayland-client found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-protocols found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-scanner found: NO (tried pkgconfig and cmake)
Run-time dependency libdrm found: YES 2.4.124
Run-time dependency gbm found: YES 25.0.6
Program python3 found: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/python3)
Quoted 8 lines
../out-graphic/build/vkmark-custom/src/meson.build:9:19: ERROR: File
/usr/share/vulkan/registry/vk.xmldoes not existIs the vk.xml file installed on your system in
/usr/share/vulkan/registry/vk.xml? I think the problem is related to the vulkan.pc file that has a wrong prefix value set.Can you confirm that?
I can reproduce the issue. When using the Buildroot docker reference image, with the commands:
utils/docker-run
cat >.config <<EOF
BR2_aarch64=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0"
BR2_SYSTEM_DHCP="eth0"
BR2_ROOTFS_POST_IMAGE_SCRIPT="board/qemu/post-image.sh"
BR2_ROOTFS_POST_SCRIPT_ARGS="qemu_aarch64_virt_defconfig"
BR2_LINUX_KERNEL=y
BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=yBR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/qemu/aarch64-virt/linux.config"
BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y
BR2_PACKAGE_VKMARK=y
BR2_PACKAGE_MESA3D=y
BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_VIRGL=y
BR2_PACKAGE_MESA3D_VULKAN_DRIVER_VIRTIO=y
BR2_PACKAGE_MESA3D_OPENGL_ES=y
BR2_TARGET_ROOTFS_EXT2=y
BR2_TARGET_ROOTFS_EXT2_4=y
BR2_TARGET_ROOTFS_EXT2_SIZE="600M"
# BR2_TARGET_ROOTFS_TAR is not set
EOF
make olddefconfig
makeIt fails with:
output/build/vkmark-2025.01/src/meson.build:9:19: ERROR: File
/usr/share/vulkan/registry/vk.xml does not exist.
If I build directly on my host system, which has the vulkan headers available at /usr/share/vulkan/registry/vk.xml, it works.
vkmark meson should take the file from:
$(STAGING_DIR)/usr/share/vulkan/registry/vk.xml
Quoted 9 lines
---
HeikoQuoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 4 lines
Links:
------
[1] http://vkmark.mk
[2] http://cross-compilation.conf.in
Best regards,
Julien.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
Hi,
Am Sa., 31. Mai 2025 um 23:14 Uhr schrieb Julien Olivain <[email protected]>:
Quoted 474 lines
Hi Heiko, Alex,
Quoted 45 lines · Heiko Thiery
Hi Alex,
thank you for these series.
Am Mo., 3. März 2025 um 17:16 Uhr schrieb Alex Bennée <[email protected]>:
Quoted 37 lines
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly toVKMARK_DEPENDENCIES
- drop duplicateBR2_INSTALL_LIBSTDCPP
- dropBR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends
---DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77+++++++++++++++++++
package/vkmark/Config.in | 48 ++++++++++++
package/vkmark/vkmark.hash | 3 +package/vkmark/vkmark.mk[1] | 34 ++++++++6 files changed, 166 insertions(+)create mode 100644
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 28 lines
Quoted 28 lines
create mode 100644 package/vkmark/Config.in
create mode 100644 package/vkmark/vkmark.hash
create mode 100644package/vkmark/vkmark.mk[1]DEVELOPERS +0
-0@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/N: Alexandre Belloni <[email protected]> F: package/tz/DEVELOPERS +3
-0+N: Alex Bennée <[email protected]> +F: package/vkmark/ +N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/package/Config.in +0
-0@@ -338,6 +338,7 @@ comment "Graphic applications"source "package/swaybg/Config.in"
source "package/tesseract-ocr/Config.in"
source "package/tinifier/Config.in"
+ source "package/vkmark/Config.in"Quoted 5 lines
Quoted 4 lines
comment "Graphic libraries"
source "package/cegui/Config.in"
diff --git
a/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 2 lines
Quoted 1 line
b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 6 lines
Quoted 5 lines
new file mode 100644
index 0000000000..7e2e43a946
---/dev/null
+++
b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchQuoted 6 lines
Quoted 6 lines
package/Config.in +1
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:002001
package/Config.in +3
-0+From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors duringQuoted 9 lines
package/Config.in
Quoted 8 lines
probing
package/Config.in +6
-0+ +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]> +Upstream:https://github.com/vkmark/vkmark/commit/37d0a0d7fa6dcde6f62718d2115e8b76646bff23
Quoted 151 lines
Quoted 55 lines
package/Config.in +7
-0+ +--- + src/ws/display_window_system_plugin.cpp | 39 ++++++++++++------------- + 1 file changed, 19 insertions(+), 20 deletions(-) + +diff --git a/src/ws/display_window_system_plugin.cppb/src/ws/display_window_system_plugin.cpp
+index 523092b..fcbd949 100644
+--- a/src/ws/display_window_system_plugin.cpp
++++ b/src/ws/display_window_system_plugin.cpp
+@@ -72,24 +72,22 @@ intvkmark_window_system_probe(Options const& options)package/Config.in +10
-0+ .setPApplicationInfo(&app_info) + .setEnabledExtensionCount(exts.size()) + .setPpEnabledExtensionNames(exts.data()); +- auto vk_instance = ManagedResource<vk::Instance>{ +- vk::createInstance(create_info), +- [] (auto& i) { i.destroy(); }}; +- if (!vk_instance.raw) +- return VKMARK_WINDOW_SYSTEM_PROBE_BAD; +- +- auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();+- auto physical_device = options.use_device_with_uuid ? +- std::find_if( +- physical_devices.begin(), physical_devices.end(), +- [&options] (auto pd) { +- return static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) == +- options.use_device_with_uuid; }) : +- physical_devices.begin(); +- +- if (physical_device != physical_devices.end()) ++ ++ try + { +- try ++ auto vk_instance = ManagedResource<vk::Instance>{ ++ vk::createInstance(create_info), ++ [] (auto& i) { i.destroy(); }}; ++ auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();
++ autophysical_device= options.use_device_with_uuid ?
++ std::find_if(
++physical_devices.begin(),physical_devices.end(),
++ [&options] (auto pd) {
++ return
static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
++ options.use_device_with_uuid; }) :
++physical_devices.begin();
++
++ if (physical_device!=physical_devices.end())package/Config.in +2
-0+ { + auto display_index =Quoted 6 lines
std::stoi(get_display_index_option(options));
+ if (display_index< 0)
+@@ -97,10 +95,11 @@ intvkmark_window_system_probe(Options const& options)
+DisplayNativeSystem::get_display_surface_create_info(*physical_device,
Quoted 89 lines
display_index);
+ returnVKMARK_WINDOW_SYSTEM_PROBE_OK+VKMARK_DISPLAY_WINDOW_SYSTEM_PRIORITY;package/Config.in +15
-0+ } +- catch (...) +- { +- } + } ++ catch (...) ++ { ++ } ++ + + return VKMARK_WINDOW_SYSTEM_PROBE_BAD; + } +-- +2.39.5 +package/vkmark/Config.in new file +29
-0@@ -0,0 +1,48 @@ +config BR2_PACKAGE_VKMARK_FLAVOR_ANY + bool + +config BR2_PACKAGE_VKMARK_FLAVOR_KMS + bool + default y if BR2_PACKAGE_HAS_LIBGBM + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND + bool + default y if BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_X11 + bool + default y if BR2_PACKAGE_XORG7 + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK + bool "vkmark" + depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + depends on !BR2_STATIC_LIBS # vulkan-loader + depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader + select BR2_PACKAGE_GLM + depends on BR2_USE_WCHAR # assimp + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp + depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm,assimp, vkmark
package/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_ASSIMP + select BR2_PACKAGE_WAYLAND_PROTOCOLS if
BR2_PACKAGE_VKMARK_FLAVOR_WAYLANDpackage/vkmark/Config.in new file +2
-0+ select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_XCB_UTIL_WM if
BR2_PACKAGE_VKMARK_FLAVOR_X11package/vkmark/Config.in new file +7
-0+ select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_VKMARK_FLAVOR_KMS + help + vmmark is an Vulkan GPU benchmark. + + https://github.com/vkmark/vkmark + +comment "vkmark needs a toolchain w/ dynamic library, threads,wchar, gcc >= 7, C++"
package/vkmark/Config.in new file +8
-0+ depends on BR2_STATIC_LIBS || \ + !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR || \ + !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \ + !BR2_INSTALL_LIBSTDCPP + +comment "vkmark needs a backend: gbm, wayland or xcb" + depends on !BR2_PACKAGE_VKMARK_FLAVOR_ANYpackage/vkmark/vkmark.hash new file +2
-0@@ -0,0 +1,3 @@ +# Locally computed +sha256
1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edcvkmark-2025.01.tar.gz
+sha256dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551COPYING-LGPL2.1Quoted 9 lines
package/vkmark/vkmark.mk [1]
Quoted 8 lines
package/vkmark/vkmark.mk renamed from package/vkmark/vkmark.mk [1] +0
-0[1]
new file mode 100644
index 0000000000..7b721c6c99package/vkmark/vkmark.mk [1] new file +0
-0@@ -0,0 +1,34 @@+################################################################################
Quoted 5 lines
package/vkmark/vkmark.mk [1] line 3
Quoted 4 lines
package/vkmark/vkmark.mk [1] new file +3
-0+# +# vkmark +#+################################################################################
Quoted 35 lines
Quoted 31 lines
package/vkmark/vkmark.mk [1] new file +6
-0+ +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headersvulkan-loader
package/vkmark/vkmark.mk [1] new file +23
-1+ +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package)) --Quoted 1 line
2.39.5
I tried to build vkmark but get this error:
Quoted 3 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
vkmark custom Configuring
rm -rf
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildQuoted 2 lines
mkdir -p
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildQuoted 2 lines
sed -e "/^\[binaries\]$/s:$::" -e "/^\[properties\]$/s:$::" -e
"s%@TARGET_CC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc%g"
Quoted 2 lines
-e
"s%@TARGET_CXX@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++%g"
Quoted 2 lines
-e
"s%@TARGET_AR@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc-ar%g"
Quoted 2 lines
-e
"s%@TARGET_FC@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gfortran%g"
Quoted 2 lines
-e
"s%@TARGET_STRIP@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-strip%g"
Quoted 8 lines
-e "s%@TARGET_ARCH@%aarch64%g" -e "s%@TARGET_CPU@%cortex-a53%g" -e "s%@TARGET_ENDIAN@%little%g" -e "s%@TARGET_FCFLAGS@%%g" -e "s%@TARGET_CFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0', '-D_FORTIFY_SOURCE=1'%g" -e "s%@TARGET_LDFLAGS@%%g" -e "s%@TARGET_CXXFLAGS@%'-D_LARGEFILE_SOURCE', '-D_LARGEFILE64_SOURCE', '-D_FILE_OFFSET_BITS=64', '-O2', '-g0', '-D_FORTIFY_SOURCE=1'%g" -e
"s%@BR2_CMAKE@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake%g"
Quoted 2 lines
-e
"s%@PKGCONF_HOST_BINARY@%/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf%g"
Quoted 3 lines
(quoted diff) +0
-2-e "s%@HOST_DIR@%/srv/storage/hthiery/sources/sa67/out-graphic/host%g" -e"s%@STAGING_DIR
@%/srv/storage/hthiery/sources/sa67/out-graphic/host/aarch64-buildroot-linux-gnu/sysroot%g"
Quoted 2 lines
-e "s%@STATIC@%false%g"
/srv/storage/hthiery/sources/sa67/buildroot/support/misc/cross-compilation.conf.in
Quoted 2 lines
[2] >
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.confQuoted 1 line
PATH="/srv/storage/hthiery/sources/sa67/out-graphic/host/bin:/srv/storage/hthiery/sources/sa67/out-graphic/host/sbin:/home/hthiery/.local/bin:/home/hthiery/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"
Quoted 6 lines
CC_FOR_BUILD="/usr/bin/gcc" CXX_FOR_BUILD="/usr/bin/g++" PYTHONNOUSERSITE=y
/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/mesonsetup --prefix=/usr --libdir=lib --default-library=shared --buildtype=release--cross-file=/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-build/cross-compilation.conf
Quoted 2 lines
-Db_pie=false -Db_staticpic=true -Dstrip=false
-Dbuild.pkg_config_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/pkgconfig
Quoted 1 line
-Dbuild.cmake_prefix_path=/srv/storage/hthiery/sources/sa67/out-graphic/host/lib/cmake
Quoted 3 lines
-Dkms=true -Dwayland=false -Dxcb=false
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom/
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom//buildroot-buildQuoted 6 lines
The Meson build system
Version: 1.7.0
Source dir:/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-customBuild dir:
/srv/storage/hthiery/sources/sa67/out-graphic/build/vkmark-custom/buildroot-buildQuoted 53 lines
Build type: cross build
Project name: vkmark
Project version: 2025.01
C compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gcc(gcc 14.2.0 "aarch64-linux-gcc.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-gccld.bfd 2.42
C++ compiler for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++(gcc 14.2.0 "aarch64-linux-g++.br_real (Buildroot 2021.11-12449-g1bef613319) 14.2.0")
C++ linker for the host machine:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/aarch64-linux-g++ld.bfd 2.42
C compiler for the build machine:/usr/bin/gcc(gcc 8.3.0 "gcc (Debian 8.3.0-6) 8.3.0")
C linker for the build machine:/usr/bin/gccld.bfd 2.31.1 C++ compiler for the build machine:/usr/bin/g++(gcc 8.3.0 "g++ (Debian 8.3.0-6) 8.3.0")
C++ linker for the build machine:/usr/bin/g++ld.bfd 2.31.1 Build machine cpu family:x86_64
Build machine cpu:x86_64
Host machine cpu family: aarch64
Host machine cpu: cortex-a53
Target machine cpu family: aarch64
Target machine cpu: cortex-a53
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkg-config) 2.3.0
Build-time dependency vulkan found: YES 1.4.307
Library dl found: YES
Found pkg-config: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/pkgconf) 2.3.0 Found CMake:/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/cmake(3.31.5) Run-time dependency glm found: YES 1.0.0
Run-time dependency assimp found: YES 5.4.3
Run-time dependency xcb found: NO (tried pkgconfig and cmake) Run-time dependency xcb-icccm found: NO (tried pkgconfig and cmake) Run-time dependency wayland-client found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-protocols found: NO (tried pkgconfig and cmake)
Run-time dependency wayland-scanner found: NO (tried pkgconfig and cmake)
Run-time dependency libdrm found: YES 2.4.124
Run-time dependency gbm found: YES 25.0.6
Program python3 found: YES (/srv/storage/hthiery/sources/sa67/out-graphic/host/bin/python3)Quoted 8 lines
../out-graphic/build/vkmark-custom/src/meson.build:9:19: ERROR: File
/usr/share/vulkan/registry/vk.xmldoes not existIs the vk.xml file installed on your system in
/usr/share/vulkan/registry/vk.xml? I think the problem is related to the vulkan.pc file that has a wrong prefix value set.Can you confirm that?
I can reproduce the issue. When using the Buildroot docker reference image, with the commands:
utils/docker-run cat >.config <<EOF BR2_aarch64=y BR2_TOOLCHAIN_EXTERNAL=y BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0" BR2_SYSTEM_DHCP="eth0" BR2_ROOTFS_POST_IMAGE_SCRIPT="board/qemu/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="qemu_aarch64_virt_defconfig" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=yBR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/qemu/aarch64-virt/linux.config"
BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y BR2_PACKAGE_VKMARK=y BR2_PACKAGE_MESA3D=y BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_VIRGL=y BR2_PACKAGE_MESA3D_VULKAN_DRIVER_VIRTIO=y BR2_PACKAGE_MESA3D_OPENGL_ES=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="600M" # BR2_TARGET_ROOTFS_TAR is not set EOF make olddefconfig makeIt fails with:
Quoted 9 lines
output/build/vkmark-2025.01/src/meson.build:9:19: ERROR: File
/usr/share/vulkan/registry/vk.xmldoes not exist.If I build directly on my host system, which has the vulkan headers available at
/usr/share/vulkan/registry/vk.xml, it works.vkmark meson should take the file from:
$(STAGING_DIR)/usr/share/vulkan/registry/vk.xml
You are right. It is related to the location of the vk.xml file. I opened an issue on the vkmark github page:
https://github.com/vkmark/vkmark/issues/75.
I have a workaround for that but it does not seem like a valid final solution. See my comment in the github issue.
Quoted 10 lines
Quoted 10 lines
---
HeikoQuoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 9 lines
Quoted 4 lines
Links:
------
[1] http://vkmark.mk
[2] http://cross-compilation.conf.inBest regards,
Julien.
BR
--
Heiko
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
In reply to Alex BennéeHi Alex,
Thanks for the patch.
Quoted 73 lines · Alex Bennée
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
v3
- add xcb-util-wm deps under X11
- add assimp directly toVKMARK_DEPENDENCIES
- drop duplicateBR2_INSTALL_LIBSTDCPP
- dropBR2_TOOLCHAIN_GCC_AT_LEAST_4_9
v2
- fix whitespace errors in Config.in
- fix sorting of sources
- add DEVELOPERS entry
- rework KConfig based on review
- drop unused sha256sum
- explicitly enable/disable the backends--- DEVELOPERS | 3 + package/Config.in | 1 + ...-handle-Vulkan-errors-during-probing.patch | 77 +++++++++++++++++++ package/vkmark/Config.in | 48 ++++++++++++ package/vkmark/vkmark.hash | 3 + package/vkmark/vkmark.mk | 34 ++++++++ 6 files changed, 166 insertions(+) create mode 100644 package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch create mode 100644 package/vkmark/Config.in create mode 100644 package/vkmark/vkmark.hash create mode 100644 package/vkmark/vkmark.mkDEVELOPERS +3
-0@@ -144,6 +144,9 @@ F: package/liblog4c-localtime/ N: Alexandre Belloni <[email protected]> F: package/tz/ +N: Alex Bennée <[email protected]> +F: package/vkmark/ + N: Alexandre Esse <[email protected]> F: package/kvazaar/ F: package/v4l2loopback/package/Config.in +1
-0@@ -338,6 +338,7 @@ comment "Graphic applications" source "package/swaybg/Config.in" source "package/tesseract-ocr/Config.in" source "package/tinifier/Config.in" + source "package/vkmark/Config.in" comment "Graphic libraries" source "package/cegui/Config.in"(quoted diff) +0
-0
b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch line 9
Quoted 9 lines
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +9
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:00 2001 +From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors during probing + +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]>
There is a small typo here. It should be:
This is reported by "utils/docker-run make check-package".
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch:0: missing Signed-off-by in the header (https://nightly.buildroot.org/#_format_and_licensing_of_the_package_patches)
Could you send an updated version of this patch, please?
Quoted 191 lines
(quoted diff) +1
-0+Upstream:https://github.com/vkmark/vkmark/commit/37d0a0d7fa6dcde6f62718d2115e8b76646bff23
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +7
-0+ +--- + src/ws/display_window_system_plugin.cpp | 39 ++++++++++++------------- + 1 file changed, 19 insertions(+), 20 deletions(-) + +diff --git a/src/ws/display_window_system_plugin.cppb/src/ws/display_window_system_plugin.cpp
+index 523092b..fcbd949 100644
+--- a/src/ws/display_window_system_plugin.cpp
++++ b/src/ws/display_window_system_plugin.cpp
+@@ -72,24 +72,22 @@ intvkmark_window_system_probe(Options const& options)package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +10
-0+ .setPApplicationInfo(&app_info) + .setEnabledExtensionCount(exts.size()) + .setPpEnabledExtensionNames(exts.data()); +- auto vk_instance = ManagedResource<vk::Instance>{ +- vk::createInstance(create_info), +- [] (auto& i) { i.destroy(); }}; +- if (!vk_instance.raw) +- return VKMARK_WINDOW_SYSTEM_PROBE_BAD; +- +- auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();+- auto physical_device = options.use_device_with_uuid ? +- std::find_if( +- physical_devices.begin(), physical_devices.end(), +- [&options] (auto pd) { +- return static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) == +- options.use_device_with_uuid; }) : +- physical_devices.begin(); +- +- if (physical_device != physical_devices.end()) ++ ++ try + { +- try ++ auto vk_instance = ManagedResource<vk::Instance>{ ++ vk::createInstance(create_info), ++ [] (auto& i) { i.destroy(); }}; ++ auto physical_devices =
vk_instance.raw.enumeratePhysicalDevices();
++ autophysical_device= options.use_device_with_uuid ?
++ std::find_if(
++physical_devices.begin(),physical_devices.end(),
++ [&options] (auto pd) {
++ return
static_cast<DeviceUUID>(pd.getProperties().pipelineCacheUUID) ==
++ options.use_device_with_uuid; }) :
++physical_devices.begin();
++
++ if (physical_device!=physical_devices.end())(quoted diff) +2
-0+ { + auto display_index =std::stoi(get_display_index_option(options));
+ if (display_index< 0)
+@@ -97,10 +95,11 @@ intvkmark_window_system_probe(Options const& options)
+DisplayNativeSystem::get_display_surface_create_info(*physical_device, display_index);
+ returnVKMARK_WINDOW_SYSTEM_PROBE_OK+VKMARK_DISPLAY_WINDOW_SYSTEM_PRIORITY;package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +15
-0+ } +- catch (...) +- { +- } + } ++ catch (...) ++ { ++ } ++ + + return VKMARK_WINDOW_SYSTEM_PROBE_BAD; + } +-- +2.39.5 +package/vkmark/Config.in new file +31
-0@@ -0,0 +1,48 @@ +config BR2_PACKAGE_VKMARK_FLAVOR_ANY + bool + +config BR2_PACKAGE_VKMARK_FLAVOR_KMS + bool + default y if BR2_PACKAGE_HAS_LIBGBM + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND + bool + default y if BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK_FLAVOR_X11 + bool + default y if BR2_PACKAGE_XORG7 + select BR2_PACKAGE_VKMARK_FLAVOR_ANY + +config BR2_PACKAGE_VKMARK + bool "vkmark" + depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + depends on !BR2_STATIC_LIBS # vulkan-loader + depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader + select BR2_PACKAGE_GLM + depends on BR2_USE_WCHAR # assimp + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp + depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm, assimp, vkmark + select BR2_PACKAGE_ASSIMP + select BR2_PACKAGE_WAYLAND_PROTOCOLS if
BR2_PACKAGE_VKMARK_FLAVOR_WAYLANDpackage/vkmark/Config.in new file +9
-0+ select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_XCB_UTIL_WM if BR2_PACKAGE_VKMARK_FLAVOR_X11 + select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_VKMARK_FLAVOR_KMS + help + vmmark is an Vulkan GPU benchmark. + + https://github.com/vkmark/vkmark + +comment "vkmark needs a toolchain w/ dynamic library, threads, wchar,gcc >= 7, C++"
package/vkmark/Config.in new file +8
-0+ depends on BR2_STATIC_LIBS || \ + !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR || \ + !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \ + !BR2_INSTALL_LIBSTDCPP + +comment "vkmark needs a backend: gbm, wayland or xcb" + depends on !BR2_PACKAGE_VKMARK_FLAVOR_ANYpackage/vkmark/vkmark.hash new file +2
-0@@ -0,0 +1,3 @@ +# Locally computed +sha256
1ae362844344d0f9878b7a3f13005f77eae705108892a4e8abf237d452d37edcvkmark-2025.01.tar.gz +sha256dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551COPYING-LGPL2.1package/vkmark/vkmark.mk new file +11
-0@@ -0,0 +1,34 @@ +################################################################################ +# +# vkmark +# +################################################################################ + +VKMARK_VERSION = 2025.01 +VKMARK_SITE = $(call github,vkmark,vkmark,$(VKMARK_VERSION)) +VKMARK_LICENSE = LGPL-2.1 +VKMARK_LICENSE_FILES = COPYING-LGPL2.1 +VKMARK_DEPENDENCIES = assimp glm host-pkgconf vulkan-headersvulkan-loader
package/vkmark/vkmark.mk new file +23
-1+ +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_KMS),y) +VKMARK_DEPENDENCIES += libdrm libgbm +VKMARK_CONF_OPTS += -Dkms=true +else +VKMARK_CONF_OPTS += -Dkms=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND),y) +VKMARK_DEPENDENCIES += wayland wayland-protocols +VKMARK_CONF_OPTS += -Dwayland=true +else +VKMARK_CONF_OPTS += -Dwayland=false +endif + +ifeq ($(BR2_PACKAGE_VKMARK_FLAVOR_X11),y) +VKMARK_DEPENDENCIES += libxcb xcb-util-wm +VKMARK_CONF_OPTS += -Dxcb=true +else +VKMARK_CONF_OPTS += -Dxcb=false +endif + +$(eval $(meson-package)) --2.39.5
Quoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Best regards,
Julien.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 5/6] package/vkmark: add vkmark benchmarking tool
Quoted 17 lines · Julien Olivain
Hi Alex,
Thanks for the patch.
Quoted 12 lines · Alex Bennée
We build from the recent 2025.1 release although we need one commit from master to better handle the missing
KHR_displayextension.Signed-off-by Alex Bennée <[email protected]>---
v4
- fix tab vs space damage
- don't ifBR2_PACKAGE_VKMARK_FLAVOR_ANY
- make comments properly depend
- use the new 2025.01 release
- add sha256sum of COPYING-LGPL2.1
- alphabetic sort of initialVKMARK_DEPENDENCIES
- add vulkan error probing patch
<snip>
Quoted 22 lines
Quoted 9 lines
diff --git
a/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchb/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchnew file mode 100644
index 0000000000..7e2e43a946
---/dev/null
+++b/package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patchpackage/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch line 9
Quoted 9 lines
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch new file +9
-0@@ -0,0 +1,77 @@ +From adf1aa346d99d29ad2c5c945c3e4de5e0e3e12cb Mon Sep 17 00:00:00 2001 +From: Alexandros Frantzis <[email protected]> +Date: Thu, 27 Feb 2025 14:33:49 +0200 +Subject: [PATCH] display: Properly handle Vulkan errors during probing + +The vk::createInstance() function throws an exception on error, +so handle it instead of checking for a null return value. + +Signed-of-by: Alex Bennée <[email protected]>There is a small typo here. It should be:
Signed-off-by Alex Bennée <[email protected]>
Quoted 7 lines
This is reported by "utils/docker-run make check-package".
package/vkmark/0001-display-Properly-handle-Vulkan-errors-during-probing.patch:0:
missing Signed-off-by in the header
(https://nightly.buildroot.org/#_format_and_licensing_of_the_package_patches)Could you send an updated version of this patch, please?
I think this is now handled upstream by:
https://github.com/vkmark/vkmark/pull/72
So I can switch to building from current HEAD or ask the vkmark people to cut a new release.
Signature · 6 lines
Alex Bennée Virtualisation Tech Lead @ Linaro _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v4 6/6 support/testing: add test for vkmark package
In reply to Alex BennéeTo test vkmark we need a headless Weston compositor so we can run the test without messing around with actual displays.
---
Currently this won't work with the host QEMU. You will need QEMU 9.2.0 with a modern virglrenderer (as in Trixie) to expose the Vulkan GPU to the guest.
v2
- add overlay image
- ensure we expose DISPLAY/DBUS env vars
- shorten runtime of vkmark
v3
- fix ordering of select/depend as suggested by check-package
- fix some flake8 complaints
--- package/vkmark/Config.in | 6 +- support/testing/infra/emulator.py | 4 +- support/testing/tests/package/test_vkmark.py | 74 +++++++++++++++++++ .../etc/profile.d/10-xdg-runtime.sh | 1 + 4 files changed, 81 insertions(+), 4 deletions(-) create mode 100644 support/testing/tests/package/test_vkmark.py create mode 100644 support/testing/tests/package/test_vkmark/rootfs-overlay/etc/profile.d/10-xdg-runtime.sh
package/vkmark/Config.in +3 -3
@@ -19,14 +19,14 @@ config BR2_PACKAGE_VKMARK_FLAVOR_X11 config BR2_PACKAGE_VKMARK bool "vkmark" depends on BR2_PACKAGE_VKMARK_FLAVOR_ANY - select BR2_PACKAGE_VULKAN_HEADERS - select BR2_PACKAGE_VULKAN_LOADER depends on !BR2_STATIC_LIBS # vulkan-loader depends on BR2_TOOLCHAIN_HAS_THREADS # vulkan-loader - select BR2_PACKAGE_GLM depends on BR2_USE_WCHAR # assimp depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # assimp depends on BR2_INSTALL_LIBSTDCPP # vulkan-loader, glm, assimp, vkmark + select BR2_PACKAGE_VULKAN_HEADERS + select BR2_PACKAGE_VULKAN_LOADER + select BR2_PACKAGE_GLM select BR2_PACKAGE_ASSIMP select BR2_PACKAGE_WAYLAND_PROTOCOLS if BR2_PACKAGE_VKMARK_FLAVOR_WAYLAND select BR2_PACKAGE_LIBXCB if BR2_PACKAGE_VKMARK_FLAVOR_X11
support/testing/infra/emulator.py +3 -1
@@ -120,7 +120,9 @@ class Emulator(object): host_bin = os.path.join(self.builddir, "host", "bin") br_path = host_bin + os.pathsep + os.environ["PATH"] qemu_env = {"QEMU_AUDIO_DRV": "none", - "PATH": br_path} + "PATH": br_path, + "DBUS_SESSION_BUS_ADDRESS": os.environ["DBUS_SESSION_BUS_ADDRESS"], + "DISPLAY": os.environ["DISPLAY"]} pexpect.run(f"{qemu_cmd[0]} --version", encoding='utf-8', logfile=self.logfile,
support/testing/tests/package/test_vkmark.py new file +74 -0
74 lines not on this page · raw message
support/testing/tests/package/test_vkmark/rootfs-overlay/etc/profile.d/10-xdg-runtime.sh new file +1 -0
@@ -0,0 +1 @@ +export XDG_RUNTIME_DIR=/tmp
Signature · 6 lines
2.39.5 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 6/6] support/testing: add test for vkmark package
Hi Alex,
Quoted 2 lines · Alex Bennée
To test vkmark we need a headless Weston compositor so we can run the test without messing around with actual displays.
This test covers a bit more than the vkmark package. It also test Mesa3D Vulkan Virtio, which brings new requirements on the host-qemu (to have the sufficient version and build options) and also on the host itself (to have a valid vulkan implementation).
The Buildroot test suite currently runs in the Docker reference image, which include an "old" qemu 7.2.15. Specific runtime tests can request a build of host-qemu, which is currently version 10.0 but will lack the virglrenderer support. See:
https://gitlab.com/buildroot.org/buildroot/-/blob/2025.05-rc2/package/qemu/qemu.mk#L465
Finally, if there is no actual Vulkan-capable GPU hardware on the host, it should then use a host-mesa3d vulkan llvmpipe. This would probably be a considerable rework (of host-qemu recipe, or reference docker image).
If merged as is, this test will always fail in the Buildroot Gitlab CI:
https://gitlab.com/buildroot.org/buildroot/-/jobs
Could this test be simplified to run vkmark with Mesa3D Vulkan llvmpipe?
It will no longer test the Vulkan Virtio GPU path, but at least the vkmark recipe will be tested.
What do you think?
Best regards,
Julien.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v4 6/6] support/testing: add test for vkmark package
Quoted 22 lines · Julien Olivain
Hi Alex,
Quoted 2 lines · Alex Bennée
To test vkmark we need a headless Weston compositor so we can run the test without messing around with actual displays.
This test covers a bit more than the vkmark package. It also test Mesa3D Vulkan Virtio, which brings new requirements on the host-qemu (to have the sufficient version and build options) and also on the host itself (to have a valid vulkan implementation).
The Buildroot test suite currently runs in the Docker reference image, which include an "old" qemu 7.2.15. Specific runtime tests can request a build of host-qemu, which is currently version 10.0 but will lack the virglrenderer support. See:
https://gitlab.com/buildroot.org/buildroot/-/blob/2025.05-rc2/package/qemu/qemu.mk#L465Finally, if there is no actual Vulkan-capable GPU hardware on the host, it should then use a host-mesa3d vulkan llvmpipe. This would probably be a considerable rework (of host-qemu recipe, or reference docker image).
Quoted 7 lines
If merged as is, this test will always fail in the Buildroot Gitlab CI:
https://gitlab.com/buildroot.org/buildroot/-/jobsCould this test be simplified to run vkmark with Mesa3D Vulkan llvmpipe?
It will no longer test the Vulkan Virtio GPU path, but at least the vkmark recipe will be tested.
I've simplified the test for CI and added the SWRAST driver so vkmark can run even with an un-accelerated display device. Manually testing with the latest QEMU works with full acceleration.
Quoted 6 lines
What do you think?
Best regards,
Julien.
Signature · 6 lines
Alex Bennée Virtualisation Tech Lead @ Linaro _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot