From 13c2f3ddffd8458be6076df804958b509b6b4fdf Mon Sep 17 00:00:00 2001 From: Adrian Schollmeyer Date: Sun, 19 May 2024 16:10:34 +0200 Subject: [PATCH 1/2] gui-libs/pugl: new package, add 0.20231112, 9999 --- gui-libs/pugl/Manifest | 1 + gui-libs/pugl/metadata.xml | 8 +++ gui-libs/pugl/pugl-0.20231112.ebuild | 78 ++++++++++++++++++++++++++++ gui-libs/pugl/pugl-9999.ebuild | 78 ++++++++++++++++++++++++++++ 4 files changed, 165 insertions(+) create mode 100644 gui-libs/pugl/Manifest create mode 100644 gui-libs/pugl/metadata.xml create mode 100644 gui-libs/pugl/pugl-0.20231112.ebuild create mode 100644 gui-libs/pugl/pugl-9999.ebuild diff --git a/gui-libs/pugl/Manifest b/gui-libs/pugl/Manifest new file mode 100644 index 00000000..fa6bd80b --- /dev/null +++ b/gui-libs/pugl/Manifest @@ -0,0 +1 @@ +DIST pugl-0.20231112.gh.tar.gz 227776 BLAKE2B 69a651dd8f4300d7e3a249e4cee64642dee909ee9a06ce41355cb57279239f62e6d491ffb072fd515adab003b432b66c494fe842b41179a4e5fc330f36181774 SHA512 5565cd06c67483ff5b2120ace400e0c2ba7fab5b246b8e1d7a22fa3269d1aa6086fa210d92ca8efa5d70b6b18a314db5d47669126e2f4d8e6db690a04b0a2fe6 diff --git a/gui-libs/pugl/metadata.xml b/gui-libs/pugl/metadata.xml new file mode 100644 index 00000000..65be7f9a --- /dev/null +++ b/gui-libs/pugl/metadata.xml @@ -0,0 +1,8 @@ + + + + + nex+b-g-o@nexadn.de + Adrian Schollmeyer + + diff --git a/gui-libs/pugl/pugl-0.20231112.ebuild b/gui-libs/pugl/pugl-0.20231112.ebuild new file mode 100644 index 00000000..47c1b460 --- /dev/null +++ b/gui-libs/pugl/pugl-0.20231112.ebuild @@ -0,0 +1,78 @@ +# Copyright 2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit meson python-any-r1 + +DESCRIPTION="Minimal portable API for embeddable GUIs" +HOMEPAGE="https://github.com/lv2/pugl" + +if [[ "${PV}" == "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/lv2/pugl.git" +else + PUGL_COMMIT=e33b2f6b0cea6d6263990aa9abe6a69fdfba5973 + SRC_URI="https://github.com/lv2/pugl/archive/${PUGL_COMMIT}.tar.gz -> ${P}.gh.tar.gz" + KEYWORDS="~amd64" + S="${WORKDIR}/${PN}-${PUGL_COMMIT}" +fi + +LICENSE="ISC" +# subslot is SONAME version +SLOT="0/0.5.3" +IUSE="cairo doc opengl vulkan" + +RDEPEND=" + x11-libs/libX11 + x11-libs/libXcursor + x11-libs/libXext + x11-libs/libXrandr + + cairo? ( x11-libs/cairo ) + opengl? ( virtual/opengl ) + vulkan? ( media-libs/vulkan-loader ) +" +DEPEND="${RDEPEND}" +# shellcheck disable=SC2016 +BDEPEND=" + doc? ( + app-text/doxygen + + $(python_gen_any_dep ' + dev-python/sphinx-lv2-theme[${PYTHON_USEDEP}] + dev-python/sphinx[${PYTHON_USEDEP}] + dev-python/sphinxygen[${PYTHON_USEDEP}] + ') + ) +" + +# Tests don't work in the sandbox +RESTRICT="test" + +python_check_deps() { + ! use doc || \ + python_has_version "dev-python/sphinx-lv2-theme[${PYTHON_USEDEP}]" \ + && python_has_version "dev-python/sphinx[${PYTHON_USEDEP}]" \ + && python_has_version "dev-python/sphinxygen[${PYTHON_USEDEP}]" +} + +src_configure() { + local emesonargs=( + "$(meson_feature cairo)" + "$(meson_feature doc docs)" + "$(meson_use doc docs_cpp)" + "$(meson_feature opengl)" + "$(meson_feature vulkan)" + + -Dxcursor=enabled + -Dxsync=enabled + -Dxrandr=enabled + + -Dexamples=disabled + -Dlint=false + -Dtests=disabled + ) + meson_src_configure +} diff --git a/gui-libs/pugl/pugl-9999.ebuild b/gui-libs/pugl/pugl-9999.ebuild new file mode 100644 index 00000000..1084a1f6 --- /dev/null +++ b/gui-libs/pugl/pugl-9999.ebuild @@ -0,0 +1,78 @@ +# Copyright 2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit meson python-any-r1 + +DESCRIPTION="Minimal portable API for embeddable GUIs" +HOMEPAGE="https://github.com/lv2/pugl" + +if [[ "${PV}" == "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/lv2/pugl.git" +else + PUGL_COMMIT= + SRC_URI="https://github.com/lv2/pugl/archive/${PUGL_COMMIT}.tar.gz -> ${P}.gh.tar.gz" + KEYWORDS="~amd64" + S="${WORKDIR}/${PN}-${PUGL_COMMIT}" +fi + +LICENSE="ISC" +# subslot is SONAME version +SLOT="0/0.5.3" +IUSE="cairo doc opengl vulkan" + +RDEPEND=" + x11-libs/libX11 + x11-libs/libXcursor + x11-libs/libXext + x11-libs/libXrandr + + cairo? ( x11-libs/cairo ) + opengl? ( virtual/opengl ) + vulkan? ( media-libs/vulkan-loader ) +" +DEPEND="${RDEPEND}" +# shellcheck disable=SC2016 +BDEPEND=" + doc? ( + app-text/doxygen + + $(python_gen_any_dep ' + dev-python/sphinx-lv2-theme[${PYTHON_USEDEP}] + dev-python/sphinx[${PYTHON_USEDEP}] + dev-python/sphinxygen[${PYTHON_USEDEP}] + ') + ) +" + +# Tests don't work in the sandbox +RESTRICT="test" + +python_check_deps() { + ! use doc || \ + python_has_version "dev-python/sphinx-lv2-theme[${PYTHON_USEDEP}]" \ + && python_has_version "dev-python/sphinx[${PYTHON_USEDEP}]" \ + && python_has_version "dev-python/sphinxygen[${PYTHON_USEDEP}]" +} + +src_configure() { + local emesonargs=( + "$(meson_feature cairo)" + "$(meson_feature doc docs)" + "$(meson_use doc docs_cpp)" + "$(meson_feature opengl)" + "$(meson_feature vulkan)" + + -Dxcursor=enabled + -Dxsync=enabled + -Dxrandr=enabled + + -Dexamples=disabled + -Dlint=false + -Dtests=disabled + ) + meson_src_configure +} From e9fcabe0707256d8dd7cc85edbd81563eefa00f0 Mon Sep 17 00:00:00 2001 From: Adrian Schollmeyer Date: Sun, 19 May 2024 17:31:04 +0200 Subject: [PATCH 2/2] media-sound/carla: add pugl support, fix X11 dep This finally fixes the build errors when USE="-X" is used to build carla, as this requires gui-libs/pugl instead of libX11. Also, X support doesn't need a full X server, but only libX11, which finally allows installing and running media-sound/carla[X] on Wayland. Closes: https://github.com/gentoo-audio/audio-overlay/issues/528 --- .../carla/{carla-2.5.2.ebuild => carla-2.5.2-r1.ebuild} | 0 .../carla/{carla-2.5.4.ebuild => carla-2.5.4-r1.ebuild} | 0 .../carla/{carla-2.5.5.ebuild => carla-2.5.5-r1.ebuild} | 0 media-sound/carla/carla-9999-r1.ebuild | 4 +++- 4 files changed, 3 insertions(+), 1 deletion(-) rename media-sound/carla/{carla-2.5.2.ebuild => carla-2.5.2-r1.ebuild} (100%) rename media-sound/carla/{carla-2.5.4.ebuild => carla-2.5.4-r1.ebuild} (100%) rename media-sound/carla/{carla-2.5.5.ebuild => carla-2.5.5-r1.ebuild} (100%) diff --git a/media-sound/carla/carla-2.5.2.ebuild b/media-sound/carla/carla-2.5.2-r1.ebuild similarity index 100% rename from media-sound/carla/carla-2.5.2.ebuild rename to media-sound/carla/carla-2.5.2-r1.ebuild diff --git a/media-sound/carla/carla-2.5.4.ebuild b/media-sound/carla/carla-2.5.4-r1.ebuild similarity index 100% rename from media-sound/carla/carla-2.5.4.ebuild rename to media-sound/carla/carla-2.5.4-r1.ebuild diff --git a/media-sound/carla/carla-2.5.5.ebuild b/media-sound/carla/carla-2.5.5-r1.ebuild similarity index 100% rename from media-sound/carla/carla-2.5.5.ebuild rename to media-sound/carla/carla-2.5.5-r1.ebuild diff --git a/media-sound/carla/carla-9999-r1.ebuild b/media-sound/carla/carla-9999-r1.ebuild index e40e46ca..65ad4249 100644 --- a/media-sound/carla/carla-9999-r1.ebuild +++ b/media-sound/carla/carla-9999-r1.ebuild @@ -39,7 +39,9 @@ RDEPEND="${PYTHON_DEPS} rdf? ( dev-python/rdflib ) sf2? ( media-sound/fluidsynth ) sndfile? ( media-libs/libsndfile ) - X? ( x11-base/xorg-server )" + X? ( x11-libs/libX11 ) + !X? ( gui-libs/pugl:= ) +" DEPEND=${RDEPEND} src_prepare() {