From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 17174138351 for ; Wed, 8 Apr 2020 18:16:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 230BCE0ACB; Wed, 8 Apr 2020 18:16:13 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id EC19DE0ACB for ; Wed, 8 Apr 2020 18:16:12 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 7B38034EF99 for ; Wed, 8 Apr 2020 18:16:11 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id E8A2F1C3 for ; Wed, 8 Apr 2020 18:16:08 +0000 (UTC) From: "Anthony G. Basile" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anthony G. Basile" Message-ID: <1586369758.ce15ee2538d76f6c59be35bfd4e8f2db7ef3c3bc.blueness@gentoo> Subject: [gentoo-commits] proj/musl:master commit in: x11-apps/igt-gpu-tools/, x11-apps/igt-gpu-tools/files/ X-VCS-Repository: proj/musl X-VCS-Files: x11-apps/igt-gpu-tools/Manifest x11-apps/igt-gpu-tools/files/0001-igt-gpu-tools-1.24-musl.patch x11-apps/igt-gpu-tools/igt-gpu-tools-1.24.ebuild x11-apps/igt-gpu-tools/metadata.xml X-VCS-Directories: x11-apps/igt-gpu-tools/files/ x11-apps/igt-gpu-tools/ X-VCS-Committer: blueness X-VCS-Committer-Name: Anthony G. Basile X-VCS-Revision: ce15ee2538d76f6c59be35bfd4e8f2db7ef3c3bc X-VCS-Branch: master Date: Wed, 8 Apr 2020 18:16:08 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: faff1679-b86b-46b5-90f1-22e4bf08f104 X-Archives-Hash: 69dd1ff3ec92a29ac546bb678f541900 commit: ce15ee2538d76f6c59be35bfd4e8f2db7ef3c3bc Author: g3ngr33n tutanota com> AuthorDate: Wed Apr 8 16:52:01 2020 +0000 Commit: Anthony G. Basile gentoo org> CommitDate: Wed Apr 8 18:15:58 2020 +0000 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=ce15ee25 x11-apps/igt-gpu-tools: Musl patch - Patch to allow build on musl for igt-gpu-tools-1.24 - Build log : https://pastebin.com/21UzLgvL Package-Manager: Portage-2.3.89, Repoman-2.3.20 Signed-off-by: Anthony G. Basile gentoo.org> x11-apps/igt-gpu-tools/Manifest | 1 + .../files/0001-igt-gpu-tools-1.24-musl.patch | 169 +++++++++++++++++++++ x11-apps/igt-gpu-tools/igt-gpu-tools-1.24.ebuild | 106 +++++++++++++ x11-apps/igt-gpu-tools/metadata.xml | 17 +++ 4 files changed, 293 insertions(+) diff --git a/x11-apps/igt-gpu-tools/Manifest b/x11-apps/igt-gpu-tools/Manifest new file mode 100644 index 0000000..da385bc --- /dev/null +++ b/x11-apps/igt-gpu-tools/Manifest @@ -0,0 +1 @@ +DIST igt-gpu-tools-1.24.tar.xz 1207436 BLAKE2B 0b04033be0195a4fee5611aeae2f47334ce1de5df65c652ebc0b36d1185286268bb426f472e3c1311ff576e8184e7a4efb95ef3181006ed8c448ea76452940d7 SHA512 22c25e27ead64f561fe8f46b132d6c7562a90d7bff09dc2618a532b16d7b8fdf54ed94d986a45655657b54219d350ce1b1e6c89da2b6073024e9bbe0973fa190 diff --git a/x11-apps/igt-gpu-tools/files/0001-igt-gpu-tools-1.24-musl.patch b/x11-apps/igt-gpu-tools/files/0001-igt-gpu-tools-1.24-musl.patch new file mode 100644 index 0000000..2122725 --- /dev/null +++ b/x11-apps/igt-gpu-tools/files/0001-igt-gpu-tools-1.24-musl.patch @@ -0,0 +1,169 @@ +--- a/benchmarks/gem_syslatency.c ++++ b/benchmarks/gem_syslatency.c +@@ -41,10 +41,10 @@ + #include + #include + #include "drm.h" +- ++#include "signal_compat.h" + #include + +-#define sigev_notify_thread_id _sigev_un._tid ++#define sigev_notify_thread_id sigev_notify_function + + static volatile int done; + +--- a/lib/igt_aux.c ++++ b/lib/igt_aux.c +@@ -31,6 +31,7 @@ + #endif + #include + #include ++#include + #include + #include + #include +@@ -73,6 +74,8 @@ + #include /* for dirname() */ + #endif + ++#include "signal_compat.h" ++ + /** + * SECTION:igt_aux + * @short_description: Auxiliary libraries and support functions + +--- a/lib/igt_aux.h ++++ b/lib/igt_aux.h +@@ -46,7 +46,7 @@ + # define gettid() (pid_t)(syscall(__NR_gettid)) + # endif + #endif +-#define sigev_notify_thread_id _sigev_un._tid ++#define sigev_notify_thread_id sigev_notify_function + + /* auxialiary igt helpers from igt_aux.c */ + /* generally useful helpers */ + +--- a/lib/igt_halffloat.c ++++ b/lib/igt_halffloat.c +@@ -162,7 +162,7 @@ + return fi.f; + } + +-#if defined(__x86_64__) && !defined(__clang__) ++#if defined(__x86_64__) && !defined(__clang__) && defined(__GLIBC__) + #pragma GCC push_options + #pragma GCC target("f16c") + +--- a/lib/igt_x86.c ++++ b/lib/igt_x86.c +@@ -190,7 +190,7 @@ + } + #endif + +-#if defined(__x86_64__) && !defined(__clang__) ++#if defined(__x86_64__) && !defined(__clang__) && defined(__GLIBC__) + #pragma GCC push_options + #pragma GCC target("sse4.1") + #pragma GCC diagnostic ignored "-Wpointer-arith" + +--- /dev/null ++++ b/lib/signal_compat.h +@@ -0,0 +1,8 @@ ++#define SIGEV_SIGNAL 0 ++#define SIGEV_NONE 1 ++#define SIGEV_THREAD 2 ++ ++#define SIGEV_SIGNAL 0 /* notify via signal */ ++#define SIGEV_NONE 1 /* other notification: meaningless */ ++#define SIGEV_THREAD 2 /* deliver via thread creation */ ++#define SIGEV_THREAD_ID 4 /* deliver to thread */ + +--- a/tests/drm_read.c ++++ b/tests/drm_read.c +@@ -220,7 +220,7 @@ + pthread_mutex_unlock(&w.mutex); + + /* Give each thread a chance to sleep in drm_read() */ +- pthread_yield(); ++ sched_yield(); + + /* One event should wake all threads as none consume */ + generate_event(w.fd, pipe); + +--- a/tests/kms_hdmi_inject.c ++++ b/tests/kms_hdmi_inject.c +@@ -26,6 +26,7 @@ + + #include + ++#include + #include "igt.h" + #include "igt_edid.h" + #include "igt_eld.h" + +--- a/tests/kms_sysfs_edid_timing.c ++++ b/tests/kms_sysfs_edid_timing.c +@@ -24,6 +24,7 @@ + + #include + #include ++#include + #include + + #define THRESHOLD_PER_CONNECTOR 10 + +--- a/tools/aubdump.c ++++ b/tools/aubdump.c +@@ -226,10 +226,10 @@ + }; + + static int close_init_helper(int fd); +-static int ioctl_init_helper(int fd, unsigned long request, ...); ++static int ioctl_init_helper(int fd, int request, ...); + + static int (*libc_close)(int fd) = close_init_helper; +-static int (*libc_ioctl)(int fd, unsigned long request, ...) = ioctl_init_helper; ++static int (*libc_ioctl)(int fd, int request, ...) = ioctl_init_helper; + + static int drm_fd = -1; + static char *filename = NULL; +@@ -856,7 +856,7 @@ + } + + static int +-gem_ioctl(int fd, unsigned long request, void *argp) ++gem_ioctl(int fd, int request, void *argp) + { + int ret; + +@@ -1150,7 +1150,7 @@ + DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_EXECBUFFER2, struct drm_i915_gem_execbuffer2) + + int +-ioctl(int fd, unsigned long request, ...) ++ioctl(int fd, int request, ...) + { + va_list args; + void *argp; +@@ -1290,7 +1290,7 @@ + } + + static int +-ioctl_init_helper(int fd, unsigned long request, ...) ++ioctl_init_helper(int fd, int request, ...) + { + va_list args; + void *argp; + +--- a/lib/igt_eld.c ++++ b/lib/igt_eld.c +@@ -29,6 +29,7 @@ + #include + #include + #include ++#include + + #include "igt_core.h" + #include "igt_eld.h" \ No newline at end of file diff --git a/x11-apps/igt-gpu-tools/igt-gpu-tools-1.24.ebuild b/x11-apps/igt-gpu-tools/igt-gpu-tools-1.24.ebuild new file mode 100644 index 0000000..414e99f --- /dev/null +++ b/x11-apps/igt-gpu-tools/igt-gpu-tools-1.24.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +EGIT_REPO_URI="https://gitlab.freedesktop.org/drm/${PN}.git" +if [[ ${PV} = *9999* ]]; then + GIT_ECLASS="git-r3" +fi + +inherit ${GIT_ECLASS} meson + +DESCRIPTION="Intel GPU userland tools" + +HOMEPAGE="https://01.org/linuxgraphics https://gitlab.freedesktop.org/drm/igt-gpu-tools" +if [[ ${PV} = *9999* ]]; then + SRC_URI="" +else + KEYWORDS="~amd64 ~x86" + SRC_URI="https://www.x.org/releases/individual/app/${P}.tar.xz" +fi +LICENSE="MIT" +SLOT="0" +IUSE="chamelium doc man overlay runner unwind valgrind video_cards_amdgpu video_cards_intel video_cards_nouveau X xv" +REQUIRED_USE=" + || ( video_cards_amdgpu video_cards_intel video_cards_nouveau ) + overlay? ( + video_cards_intel + || ( X xv ) + ) +" +RESTRICT="test" + +RDEPEND=" + dev-libs/elfutils + dev-libs/glib:2 + sys-apps/kmod:= + sys-libs/libunwind:= + sys-libs/zlib:= + sys-process/procps:= + virtual/libudev:= + >=x11-libs/cairo-1.12.0[X?] + >=x11-libs/libdrm-2.4.82[video_cards_amdgpu?,video_cards_intel?,video_cards_nouveau?] + >=x11-libs/libpciaccess-0.10 + x11-libs/pixman + chamelium? ( + dev-libs/xmlrpc-c[curl] + sci-libs/gsl + media-libs/alsa-lib:= + ) + overlay? ( + >=x11-libs/libXrandr-1.3 + xv? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXv + ) + ) + runner? ( dev-libs/json-c:= ) + unwind? ( sys-libs/libunwind ) + valgrind? ( dev-util/valgrind ) + " +DEPEND="${RDEPEND} + doc? ( >=dev-util/gtk-doc-1.25-r1 ) + man? ( dev-python/docutils ) + overlay? ( + >=dev-util/peg-0.1.18 + x11-base/xorg-proto + ) + video_cards_intel? ( + sys-devel/bison + sys-devel/flex + ) +" +PATCHES=( + "${FILESDIR}"/0001-${PN}-1.24-musl.patch +) + +src_prepare() { + sed -e "s/find_program('rst2man-3'/find_program('rst2man.py', 'rst2man-3'/" -i man/meson.build + default_src_prepare +} + +src_configure() { + local gpus="" + use video_cards_amdgpu && gpus+="amdgpu," + use video_cards_intel && gpus+="intel," + use video_cards_nouveau && gpus+="nouveau," + + local overlay_backends="" + use overlay && use xv && overlay_backends+="xv," + use overlay && use X && overlay_backends+="x," + + local emesonargs=( + $(meson_feature chamelium build_chamelium) + $(meson_feature doc build_docs) + $(meson_feature man build_man) + $(meson_feature overlay build_overlay) + $(meson_feature runner build_runner) + $(meson_feature doc build_tests) # Test build is required for docs + $(meson_feature valgrind with_valgrind) + $(meson_feature unwind with_libunwind) + -Doverlay_backends=${overlay_backends%?} + -Dwith_libdrm=${gpus%?} + ) + meson_src_configure +} diff --git a/x11-apps/igt-gpu-tools/metadata.xml b/x11-apps/igt-gpu-tools/metadata.xml new file mode 100644 index 0000000..887359b --- /dev/null +++ b/x11-apps/igt-gpu-tools/metadata.xml @@ -0,0 +1,17 @@ + + + + + x11@gentoo.org + X11 + + + Enables support for building Chamelium tests + Build and install man pages + Build the intel-gpu-overlay utility + Build the test runner + Support valgrind annotations + Enable intel-gpu-overlay xv backend + Enable intel-gpu-overlay xlib/cairo backend + +