public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-libs/wayland/, dev-libs/wayland/files/
@ 2024-08-22 14:50 Sam James
  0 siblings, 0 replies; 3+ messages in thread
From: Sam James @ 2024-08-22 14:50 UTC (permalink / raw
  To: gentoo-commits

commit:     bdd989aff6fbe6b1137aa5a9228009a8aa4154dd
Author:     Alfred Wingate <parona <AT> protonmail <DOT> com>
AuthorDate: Sun Jul 14 20:04:55 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Aug 22 14:48:42 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bdd989af

dev-libs/wayland: fix revdep clang builds with C23

Closes: https://bugs.gentoo.org/936061
Signed-off-by: Alfred Wingate <parona <AT> protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/37554
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/wayland-1.23.0-c23-clang-fix.patch       | 146 +++++++++++++++++++++
 dev-libs/wayland/wayland-1.23.0-r1.ebuild          |  70 ++++++++++
 2 files changed, 216 insertions(+)

diff --git a/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch b/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch
new file mode 100644
index 000000000000..8dc80d3c8fe8
--- /dev/null
+++ b/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch
@@ -0,0 +1,146 @@
+https://bugs.gentoo.org/936061
+https://gitlab.freedesktop.org/wlroots/wlroots/-/issues/3859
+https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/401
+
+From 7be937e795ff88128d64b88f9482f05aa0d91319 Mon Sep 17 00:00:00 2001
+From: Kirill Primak <vyivel@eclair.cafe>
+Date: Sat, 29 Jun 2024 15:05:00 +0300
+Subject: [PATCH] Put WL_DEPRECATED in front of the function declarations
+
+This fixes the following clang error when using C23:
+
+../src/wayland-server-core.h:680:41: error: 'deprecated' attribute cannot be applied to types
+  680 |                      int32_t stride, uint32_t format) WL_DEPRECATED;
+      |                                                       ^
+../src/wayland-util.h:52:25: note: expanded from macro 'WL_DEPRECATED'
+   52 | #define WL_DEPRECATED [[deprecated]]
+      |                         ^
+
+Signed-off-by: Kirill Primak <vyivel@eclair.cafe>
+--- a/src/wayland-server-core.h
++++ b/src/wayland-server-core.h
+@@ -674,10 +674,11 @@ wl_display_init_shm(struct wl_display *display);
+ uint32_t *
+ wl_display_add_shm_format(struct wl_display *display, uint32_t format);
+ 
++WL_DEPRECATED
+ struct wl_shm_buffer *
+ wl_shm_buffer_create(struct wl_client *client,
+ 		     uint32_t id, int32_t width, int32_t height,
+-		     int32_t stride, uint32_t format) WL_DEPRECATED;
++		     int32_t stride, uint32_t format);
+ 
+ void
+ wl_log_set_handler_server(wl_log_func_t handler);
+--- a/src/wayland-server.c
++++ b/src/wayland-server.c
+@@ -2483,9 +2483,10 @@ wl_priv_signal_final_emit(struct wl_priv_signal *signal, void *data)
+ 
+ /** \cond */ /* Deprecated functions below. */
+ 
++WL_DEPRECATED
+ uint32_t
+ wl_client_add_resource(struct wl_client *client,
+-		       struct wl_resource *resource) WL_DEPRECATED;
++		       struct wl_resource *resource);
+ 
+ WL_EXPORT uint32_t
+ wl_client_add_resource(struct wl_client *client,
+@@ -2514,11 +2515,12 @@ wl_client_add_resource(struct wl_client *client,
+ 	return resource->object.id;
+ }
+ 
++WL_DEPRECATED
+ struct wl_resource *
+ wl_client_add_object(struct wl_client *client,
+ 		     const struct wl_interface *interface,
+ 		     const void *implementation,
+-		     uint32_t id, void *data) WL_DEPRECATED;
++		     uint32_t id, void *data);
+ 
+ WL_EXPORT struct wl_resource *
+ wl_client_add_object(struct wl_client *client,
+@@ -2537,10 +2539,11 @@ wl_client_add_object(struct wl_client *client,
+ 	return resource;
+ }
+ 
++WL_DEPRECATED
+ struct wl_resource *
+ wl_client_new_object(struct wl_client *client,
+ 		     const struct wl_interface *interface,
+-		     const void *implementation, void *data) WL_DEPRECATED;
++		     const void *implementation, void *data);
+ 
+ WL_EXPORT struct wl_resource *
+ wl_client_new_object(struct wl_client *client,
+@@ -2599,10 +2602,11 @@ wl_client_get_user_data(struct wl_client *client)
+ 	return client->data;
+ }
+ 
++WL_DEPRECATED
+ struct wl_global *
+ wl_display_add_global(struct wl_display *display,
+ 		      const struct wl_interface *interface,
+-		      void *data, wl_global_bind_func_t bind) WL_DEPRECATED;
++		      void *data, wl_global_bind_func_t bind);
+ 
+ WL_EXPORT struct wl_global *
+ wl_display_add_global(struct wl_display *display,
+@@ -2612,9 +2616,10 @@ wl_display_add_global(struct wl_display *display,
+ 	return wl_global_create(display, interface, interface->version, data, bind);
+ }
+ 
++WL_DEPRECATED
+ void
+ wl_display_remove_global(struct wl_display *display,
+-			 struct wl_global *global) WL_DEPRECATED;
++			 struct wl_global *global);
+ 
+ WL_EXPORT void
+ wl_display_remove_global(struct wl_display *display, struct wl_global *global)
+--- a/src/wayland-server.h
++++ b/src/wayland-server.h
+@@ -70,30 +70,35 @@ struct wl_resource {
+ 	void *data;
+ };
+ 
++WL_DEPRECATED
+ uint32_t
+ wl_client_add_resource(struct wl_client *client,
+-		       struct wl_resource *resource) WL_DEPRECATED;
++		       struct wl_resource *resource);
+ 
++WL_DEPRECATED
+ struct wl_resource *
+ wl_client_add_object(struct wl_client *client,
+ 		     const struct wl_interface *interface,
+ 		     const void *implementation,
+-		     uint32_t id, void *data) WL_DEPRECATED;
++		     uint32_t id, void *data);
+ 
++WL_DEPRECATED
+ struct wl_resource *
+ wl_client_new_object(struct wl_client *client,
+ 		     const struct wl_interface *interface,
+-		     const void *implementation, void *data) WL_DEPRECATED;
++		     const void *implementation, void *data);
+ 
++WL_DEPRECATED
+ struct wl_global *
+ wl_display_add_global(struct wl_display *display,
+ 		      const struct wl_interface *interface,
+ 		      void *data,
+-		      wl_global_bind_func_t bind) WL_DEPRECATED;
++		      wl_global_bind_func_t bind);
+ 
++WL_DEPRECATED
+ void
+ wl_display_remove_global(struct wl_display *display,
+-			 struct wl_global *global) WL_DEPRECATED;
++			 struct wl_global *global);
+ 
+ #endif
+ 
+-- 
+GitLab
+

diff --git a/dev-libs/wayland/wayland-1.23.0-r1.ebuild b/dev-libs/wayland/wayland-1.23.0-r1.ebuild
new file mode 100644
index 000000000000..ec497be319af
--- /dev/null
+++ b/dev-libs/wayland/wayland-1.23.0-r1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+if [[ ${PV} = *9999* ]]; then
+	EGIT_REPO_URI="https://gitlab.freedesktop.org/wayland/wayland.git"
+	inherit git-r3
+else
+	SRC_URI="https://gitlab.freedesktop.org/wayland/${PN}/-/releases/${PV}/downloads/${P}.tar.xz"
+	KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+fi
+inherit meson-multilib
+
+DESCRIPTION="Wayland protocol libraries"
+HOMEPAGE="https://wayland.freedesktop.org/ https://gitlab.freedesktop.org/wayland/wayland"
+
+LICENSE="MIT"
+SLOT="0"
+IUSE="doc test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="
+	~dev-util/wayland-scanner-${PV}
+	virtual/pkgconfig
+	doc? (
+		>=app-text/doxygen-1.6[dot]
+		app-text/xmlto
+		>=media-gfx/graphviz-2.26.0
+	)
+"
+DEPEND="
+	>=dev-libs/libffi-3.0.13-r1:=[${MULTILIB_USEDEP}]
+"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+	"${FILESDIR}"/wayland-1.23.0-c23-clang-fix.patch
+)
+
+multilib_src_configure() {
+	local emesonargs=(
+		$(meson_native_use_bool doc documentation)
+		$(meson_native_true dtd_validation)
+		-Dlibraries=true
+		-Dscanner=false
+		$(meson_use test tests)
+	)
+	meson_src_configure
+}
+
+src_test() {
+	# We set it on purpose to only a short subdir name, as socket paths are
+	# created in there, which are 108 byte limited. With this it hopefully
+	# barely fits to the limit with /var/tmp/portage/${CATEGORY}/${PF}/temp/x
+	export XDG_RUNTIME_DIR="${T}"/x
+	mkdir "${XDG_RUNTIME_DIR}" || die
+	chmod 0700 "${XDG_RUNTIME_DIR}" || die
+
+	multilib-minimal_src_test
+}
+
+src_install() {
+	meson-multilib_src_install
+
+	if use doc; then
+		mv "${ED}"/usr/share/doc/"${PN}"/* "${ED}"/usr/share/doc/"${PF}"/ || die
+		rmdir "${ED}"/usr/share/doc/"${PN}" || die
+	fi
+}


^ permalink raw reply related	[flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-libs/wayland/, dev-libs/wayland/files/
@ 2025-01-10  4:58 Matt Turner
  0 siblings, 0 replies; 3+ messages in thread
From: Matt Turner @ 2025-01-10  4:58 UTC (permalink / raw
  To: gentoo-commits

commit:     824ec41b7b4212df225f1d16cb420414c4e72052
Author:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 10 04:56:45 2025 +0000
Commit:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Fri Jan 10 04:58:05 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=824ec41b

dev-libs/wayland: Drop old versions

Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>

 dev-libs/wayland/Manifest                          |   1 -
 .../files/wayland-1.23.0-c23-clang-fix.patch       | 146 ---------------------
 dev-libs/wayland/wayland-1.23.0-r1.ebuild          |  70 ----------
 3 files changed, 217 deletions(-)

diff --git a/dev-libs/wayland/Manifest b/dev-libs/wayland/Manifest
index f60d83496dc1..5013c30fd704 100644
--- a/dev-libs/wayland/Manifest
+++ b/dev-libs/wayland/Manifest
@@ -1,2 +1 @@
-DIST wayland-1.23.0.tar.xz 237900 BLAKE2B efb80e3c67db7a707a6d2ea66e7a5132173550bc13fdff447925ec3d33bfba8131532f819d5ab0dd80924cb4339b58b7ca83d9e70a436cea8268167476355bd8 SHA512 9c525231a7ea3e68d3178230d476285a960d23e38571ac96d885f86c0588c52ef01460bff6833db5adb9456ce8db7b996613611187aac972736748ba91b8fd81
 DIST wayland-1.23.1.tar.xz 238212 BLAKE2B 74784b537a6e28610466ff1549286cea9ff8b9ca914afa26a07f177bbe0be56b80de037d5eb5d07a38bf02a9041c32e62c896facd5417c1435571640ad8f87b2 SHA512 818eda003e3f7aa15690eedb1ff227a6056b2ce54bf23d45ffe573dc40a914623c5a1358218b59444dcdc483db0503324f0d27091d0ea954412a8b290de5f50a

diff --git a/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch b/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch
deleted file mode 100644
index 8dc80d3c8fe8..000000000000
--- a/dev-libs/wayland/files/wayland-1.23.0-c23-clang-fix.patch
+++ /dev/null
@@ -1,146 +0,0 @@
-https://bugs.gentoo.org/936061
-https://gitlab.freedesktop.org/wlroots/wlroots/-/issues/3859
-https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/401
-
-From 7be937e795ff88128d64b88f9482f05aa0d91319 Mon Sep 17 00:00:00 2001
-From: Kirill Primak <vyivel@eclair.cafe>
-Date: Sat, 29 Jun 2024 15:05:00 +0300
-Subject: [PATCH] Put WL_DEPRECATED in front of the function declarations
-
-This fixes the following clang error when using C23:
-
-../src/wayland-server-core.h:680:41: error: 'deprecated' attribute cannot be applied to types
-  680 |                      int32_t stride, uint32_t format) WL_DEPRECATED;
-      |                                                       ^
-../src/wayland-util.h:52:25: note: expanded from macro 'WL_DEPRECATED'
-   52 | #define WL_DEPRECATED [[deprecated]]
-      |                         ^
-
-Signed-off-by: Kirill Primak <vyivel@eclair.cafe>
---- a/src/wayland-server-core.h
-+++ b/src/wayland-server-core.h
-@@ -674,10 +674,11 @@ wl_display_init_shm(struct wl_display *display);
- uint32_t *
- wl_display_add_shm_format(struct wl_display *display, uint32_t format);
- 
-+WL_DEPRECATED
- struct wl_shm_buffer *
- wl_shm_buffer_create(struct wl_client *client,
- 		     uint32_t id, int32_t width, int32_t height,
--		     int32_t stride, uint32_t format) WL_DEPRECATED;
-+		     int32_t stride, uint32_t format);
- 
- void
- wl_log_set_handler_server(wl_log_func_t handler);
---- a/src/wayland-server.c
-+++ b/src/wayland-server.c
-@@ -2483,9 +2483,10 @@ wl_priv_signal_final_emit(struct wl_priv_signal *signal, void *data)
- 
- /** \cond */ /* Deprecated functions below. */
- 
-+WL_DEPRECATED
- uint32_t
- wl_client_add_resource(struct wl_client *client,
--		       struct wl_resource *resource) WL_DEPRECATED;
-+		       struct wl_resource *resource);
- 
- WL_EXPORT uint32_t
- wl_client_add_resource(struct wl_client *client,
-@@ -2514,11 +2515,12 @@ wl_client_add_resource(struct wl_client *client,
- 	return resource->object.id;
- }
- 
-+WL_DEPRECATED
- struct wl_resource *
- wl_client_add_object(struct wl_client *client,
- 		     const struct wl_interface *interface,
- 		     const void *implementation,
--		     uint32_t id, void *data) WL_DEPRECATED;
-+		     uint32_t id, void *data);
- 
- WL_EXPORT struct wl_resource *
- wl_client_add_object(struct wl_client *client,
-@@ -2537,10 +2539,11 @@ wl_client_add_object(struct wl_client *client,
- 	return resource;
- }
- 
-+WL_DEPRECATED
- struct wl_resource *
- wl_client_new_object(struct wl_client *client,
- 		     const struct wl_interface *interface,
--		     const void *implementation, void *data) WL_DEPRECATED;
-+		     const void *implementation, void *data);
- 
- WL_EXPORT struct wl_resource *
- wl_client_new_object(struct wl_client *client,
-@@ -2599,10 +2602,11 @@ wl_client_get_user_data(struct wl_client *client)
- 	return client->data;
- }
- 
-+WL_DEPRECATED
- struct wl_global *
- wl_display_add_global(struct wl_display *display,
- 		      const struct wl_interface *interface,
--		      void *data, wl_global_bind_func_t bind) WL_DEPRECATED;
-+		      void *data, wl_global_bind_func_t bind);
- 
- WL_EXPORT struct wl_global *
- wl_display_add_global(struct wl_display *display,
-@@ -2612,9 +2616,10 @@ wl_display_add_global(struct wl_display *display,
- 	return wl_global_create(display, interface, interface->version, data, bind);
- }
- 
-+WL_DEPRECATED
- void
- wl_display_remove_global(struct wl_display *display,
--			 struct wl_global *global) WL_DEPRECATED;
-+			 struct wl_global *global);
- 
- WL_EXPORT void
- wl_display_remove_global(struct wl_display *display, struct wl_global *global)
---- a/src/wayland-server.h
-+++ b/src/wayland-server.h
-@@ -70,30 +70,35 @@ struct wl_resource {
- 	void *data;
- };
- 
-+WL_DEPRECATED
- uint32_t
- wl_client_add_resource(struct wl_client *client,
--		       struct wl_resource *resource) WL_DEPRECATED;
-+		       struct wl_resource *resource);
- 
-+WL_DEPRECATED
- struct wl_resource *
- wl_client_add_object(struct wl_client *client,
- 		     const struct wl_interface *interface,
- 		     const void *implementation,
--		     uint32_t id, void *data) WL_DEPRECATED;
-+		     uint32_t id, void *data);
- 
-+WL_DEPRECATED
- struct wl_resource *
- wl_client_new_object(struct wl_client *client,
- 		     const struct wl_interface *interface,
--		     const void *implementation, void *data) WL_DEPRECATED;
-+		     const void *implementation, void *data);
- 
-+WL_DEPRECATED
- struct wl_global *
- wl_display_add_global(struct wl_display *display,
- 		      const struct wl_interface *interface,
- 		      void *data,
--		      wl_global_bind_func_t bind) WL_DEPRECATED;
-+		      wl_global_bind_func_t bind);
- 
-+WL_DEPRECATED
- void
- wl_display_remove_global(struct wl_display *display,
--			 struct wl_global *global) WL_DEPRECATED;
-+			 struct wl_global *global);
- 
- #endif
- 
--- 
-GitLab
-

diff --git a/dev-libs/wayland/wayland-1.23.0-r1.ebuild b/dev-libs/wayland/wayland-1.23.0-r1.ebuild
deleted file mode 100644
index d3a90d11bb3b..000000000000
--- a/dev-libs/wayland/wayland-1.23.0-r1.ebuild
+++ /dev/null
@@ -1,70 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-if [[ ${PV} = *9999* ]]; then
-	EGIT_REPO_URI="https://gitlab.freedesktop.org/wayland/wayland.git"
-	inherit git-r3
-else
-	SRC_URI="https://gitlab.freedesktop.org/wayland/${PN}/-/releases/${PV}/downloads/${P}.tar.xz"
-	KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
-fi
-inherit meson-multilib
-
-DESCRIPTION="Wayland protocol libraries"
-HOMEPAGE="https://wayland.freedesktop.org/ https://gitlab.freedesktop.org/wayland/wayland"
-
-LICENSE="MIT"
-SLOT="0"
-IUSE="doc test"
-RESTRICT="!test? ( test )"
-
-BDEPEND="
-	~dev-util/wayland-scanner-${PV}
-	virtual/pkgconfig
-	doc? (
-		>=app-text/doxygen-1.6[dot]
-		app-text/xmlto
-		>=media-gfx/graphviz-2.26.0
-	)
-"
-DEPEND="
-	>=dev-libs/libffi-3.0.13-r1:=[${MULTILIB_USEDEP}]
-"
-RDEPEND="${DEPEND}"
-
-PATCHES=(
-	"${FILESDIR}"/wayland-1.23.0-c23-clang-fix.patch
-)
-
-multilib_src_configure() {
-	local emesonargs=(
-		$(meson_native_use_bool doc documentation)
-		$(meson_native_true dtd_validation)
-		-Dlibraries=true
-		-Dscanner=false
-		$(meson_use test tests)
-	)
-	meson_src_configure
-}
-
-src_test() {
-	# We set it on purpose to only a short subdir name, as socket paths are
-	# created in there, which are 108 byte limited. With this it hopefully
-	# barely fits to the limit with /var/tmp/portage/${CATEGORY}/${PF}/temp/x
-	export XDG_RUNTIME_DIR="${T}"/x
-	mkdir "${XDG_RUNTIME_DIR}" || die
-	chmod 0700 "${XDG_RUNTIME_DIR}" || die
-
-	multilib-minimal_src_test
-}
-
-src_install() {
-	meson-multilib_src_install
-
-	if use doc; then
-		mv "${ED}"/usr/share/doc/"${PN}"/* "${ED}"/usr/share/doc/"${PF}"/ || die
-		rmdir "${ED}"/usr/share/doc/"${PN}" || die
-	fi
-}


^ permalink raw reply related	[flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-libs/wayland/, dev-libs/wayland/files/
@ 2016-03-01 17:39 Mart Raudsepp
  0 siblings, 0 replies; 3+ messages in thread
From: Mart Raudsepp @ 2016-03-01 17:39 UTC (permalink / raw
  To: gentoo-commits

commit:     bd0be58e1d9fd7f19ccf9a24bb963b5fdb742c3d
Author:     Mart Raudsepp <leio <AT> gentoo <DOT> org>
AuthorDate: Tue Mar  1 10:51:20 2016 +0000
Commit:     Mart Raudsepp <leio <AT> gentoo <DOT> org>
CommitDate: Tue Mar  1 17:39:04 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bd0be58e

dev-libs/wayland: Fix multilib and add missing libxml2 dependency

Multilib support was broken in previous versions, as the configure
options were in src_configure, not multilib_src_configure, and so
it always built with configuration for "native" ABI, meaning that
USE=doc with multilib was probably broken. Now with 1.10 this
becomes more apparent with a new libxml2 dependency in wayland-scanner
for DTD validation.
As we do not currently install /usr/bin/wayland-scanner for other ABIs,
just disable the dtd validation support there. Ideally we wouldn't
build it at all then, but not a clean way to do so upstream right now.
For --{dis,en}able-dtd-validation to work, we need to patch the
build system to fix the support for the configure flag.
Thanks to this we are able to add the missing libxml2 dependency
without requiring multilib libxml2 for that (and commonly then also
multilib icu), which is nice, as many users haven't had a need for
a 32bit version of those as of yet and icu is a bit bigger compile.

Remove USE=static-libs handling, as autotools-utils takes care
of it for us when it's in IUSE. Also make use of the
multilib_native_use_enable helper to simplify the ebuild.

Gentoo-bug: 575212

 ...uild-fix-configure-disable-dtd-validation.patch | 223 +++++++++++++++++++++
 dev-libs/wayland/wayland-1.10.0.ebuild             |  17 +-
 2 files changed, 232 insertions(+), 8 deletions(-)

diff --git a/dev-libs/wayland/files/1.10.0-build-fix-configure-disable-dtd-validation.patch b/dev-libs/wayland/files/1.10.0-build-fix-configure-disable-dtd-validation.patch
new file mode 100644
index 0000000..4d9795b
--- /dev/null
+++ b/dev-libs/wayland/files/1.10.0-build-fix-configure-disable-dtd-validation.patch
@@ -0,0 +1,223 @@
+From: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
+Date: Mon, 29 Feb 2016 14:59:51 +0200
+Subject: [PATCH] build: fix ./configure --disable-dtd-validation
+
+When configured with --disable-dtd-validation:
+
+  CPPAS    src/dtddata.o
+src/dtddata.S: Assembler messages:
+src/dtddata.S:39: Error: file not found: src/wayland.dtd.embed
+Makefile:1520: recipe for target 'src/dtddata.o' failed
+
+This is because the variable name used does not match the implicit
+variable name in autoconf.
+
+Fix the variable name, making both --disable-dtd-validation and
+--enable-dtd-validation to what they should.
+
+Do not try to build dtddata.S if dtd-validation is disabled. It depends
+on wayland.dtd.embed which is created by configure only if
+dtd-validation is enabled.
+
+If not building dtddata.S, also make sure the extern definitions in
+scanner.c are compiled out.
+
+Bugzilla: https://bugs.gentoo.org/show_bug.cgi?id=575212
+Reported-by: leio@gentoo.org
+Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
+Reviewed-by: Quentin Glidic <sardemff7+git@sardemff7.net>
+Tested-by: Bryce Harrington <bryce@osg.samsung.com>
+[Mart: Added Makefile.in and configure changes to patch file to avoid autoreconf]
+Signed-off-by: Mart Raudsepp <leio@gentoo.org>
+---
+ Makefile.am   |  5 ++++-
+ Makefile.in   | 20 ++++++++++++--------
+ configure     | 18 ++++++++++++++++--
+ configure.ac  |  5 +++--
+ src/scanner.c |  6 +++---
+ 5 files changed, 38 insertions(+), 16 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index e850abc..49e25a6 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -23,11 +23,14 @@ pkgconfigdir = $(libdir)/pkgconfig
+ pkgconfig_DATA =
+ 
+ bin_PROGRAMS = wayland-scanner
+-wayland_scanner_SOURCES = src/scanner.c src/dtddata.S
++wayland_scanner_SOURCES = src/scanner.c
+ wayland_scanner_CFLAGS = $(EXPAT_CFLAGS) $(LIBXML_CFLAGS) $(AM_CFLAGS)
+ wayland_scanner_LDADD = $(EXPAT_LIBS) $(LIBXML_LIBS) libwayland-util.la
+ pkgconfig_DATA += src/wayland-scanner.pc
+ 
++if DTD_VALIDATION
++wayland_scanner_SOURCES += src/dtddata.S
++endif
+ src/dtddata.o: protocol/wayland.dtd
+ 
+ if USE_HOST_SCANNER
+diff --git a/Makefile.in b/Makefile.in
+index 6d9ffb2..32e6d51 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -82,8 +82,9 @@ POST_UNINSTALL = :
+ build_triplet = @build@
+ host_triplet = @host@
+ bin_PROGRAMS = wayland-scanner$(EXEEXT)
+-@ENABLE_LIBRARIES_TRUE@am__append_1 = libwayland-private.la
+-@ENABLE_LIBRARIES_TRUE@am__append_2 = src/wayland-client.pc \
++@DTD_VALIDATION_TRUE@am__append_1 = src/dtddata.S
++@ENABLE_LIBRARIES_TRUE@am__append_2 = libwayland-private.la
++@ENABLE_LIBRARIES_TRUE@am__append_3 = src/wayland-client.pc \
+ @ENABLE_LIBRARIES_TRUE@	src/wayland-server.pc \
+ @ENABLE_LIBRARIES_TRUE@	cursor/wayland-cursor.pc
+ @ENABLE_LIBRARIES_TRUE@TESTS = array-test$(EXEEXT) \
+@@ -101,7 +102,7 @@ bin_PROGRAMS = wayland-scanner$(EXEEXT)
+ @ENABLE_LIBRARIES_TRUE@	resources-test$(EXEEXT) \
+ @ENABLE_LIBRARIES_TRUE@	message-test$(EXEEXT) \
+ @ENABLE_LIBRARIES_TRUE@	headers-test$(EXEEXT) $(am__EXEEXT_1)
+-@ENABLE_CPP_TEST_TRUE@@ENABLE_LIBRARIES_TRUE@am__append_3 = cpp-compile-test
++@ENABLE_CPP_TEST_TRUE@@ENABLE_LIBRARIES_TRUE@am__append_4 = cpp-compile-test
+ @ENABLE_LIBRARIES_TRUE@check_PROGRAMS = $(am__EXEEXT_2) \
+ @ENABLE_LIBRARIES_TRUE@	exec-fd-leak-checker$(EXEEXT)
+ @ENABLE_LIBRARIES_TRUE@noinst_PROGRAMS = fixed-benchmark$(EXEEXT)
+@@ -382,8 +383,10 @@ am__socket_test_SOURCES_DIST = tests/socket-test.c
+ @ENABLE_LIBRARIES_TRUE@	tests/socket-test.$(OBJEXT)
+ socket_test_OBJECTS = $(am_socket_test_OBJECTS)
+ @ENABLE_LIBRARIES_TRUE@socket_test_DEPENDENCIES = libtest-runner.la
++am__wayland_scanner_SOURCES_DIST = src/scanner.c src/dtddata.S
++@DTD_VALIDATION_TRUE@am__objects_1 = src/dtddata.$(OBJEXT)
+ am_wayland_scanner_OBJECTS = src/wayland_scanner-scanner.$(OBJEXT) \
+-	src/dtddata.$(OBJEXT)
++	$(am__objects_1)
+ wayland_scanner_OBJECTS = $(am_wayland_scanner_OBJECTS)
+ wayland_scanner_DEPENDENCIES = $(am__DEPENDENCIES_1) \
+ 	$(am__DEPENDENCIES_1) libwayland-util.la
+@@ -491,7 +494,8 @@ DIST_SOURCES = $(am__libtest_runner_la_SOURCES_DIST) \
+ 	$(am__resources_test_SOURCES_DIST) \
+ 	$(am__sanity_test_SOURCES_DIST) \
+ 	$(am__signal_test_SOURCES_DIST) \
+-	$(am__socket_test_SOURCES_DIST) $(wayland_scanner_SOURCES)
++	$(am__socket_test_SOURCES_DIST) \
++	$(am__wayland_scanner_SOURCES_DIST)
+ RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+ 	ctags-recursive dvi-recursive html-recursive info-recursive \
+ 	install-data-recursive install-dvi-recursive \
+@@ -918,8 +922,8 @@ dist_pkgdata_DATA = \
+ 	protocol/wayland.dtd
+ 
+ pkgconfigdir = $(libdir)/pkgconfig
+-pkgconfig_DATA = src/wayland-scanner.pc $(am__append_2)
+-wayland_scanner_SOURCES = src/scanner.c src/dtddata.S
++pkgconfig_DATA = src/wayland-scanner.pc $(am__append_3)
++wayland_scanner_SOURCES = src/scanner.c $(am__append_1)
+ wayland_scanner_CFLAGS = $(EXPAT_CFLAGS) $(LIBXML_CFLAGS) $(AM_CFLAGS)
+ wayland_scanner_LDADD = $(EXPAT_LIBS) $(LIBXML_LIBS) libwayland-util.la
+ @USE_HOST_SCANNER_FALSE@wayland_scanner = $(top_builddir)/wayland-scanner
+@@ -929,7 +933,7 @@ libwayland_util_la_SOURCES = \
+ 	src/wayland-util.c			\
+ 	src/wayland-util.h
+ 
+-noinst_LTLIBRARIES = libwayland-util.la $(am__append_1)
++noinst_LTLIBRARIES = libwayland-util.la $(am__append_2)
+ @ENABLE_LIBRARIES_TRUE@lib_LTLIBRARIES = libwayland-server.la \
+ @ENABLE_LIBRARIES_TRUE@	libwayland-client.la \
+ @ENABLE_LIBRARIES_TRUE@	libwayland-cursor.la
+diff --git a/configure.ac b/configure.ac
+index f54a8b9..b27f34b 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -76,7 +76,7 @@ AC_ARG_ENABLE([dtd-validation],
+ 	      [AC_HELP_STRING([--disable-dtd-validation],
+ 			      [Disable DTD validation of the protocol])],
+ 	      [],
+-	      [enable_dtdvalidation=yes])
++	      [enable_dtd_validation=yes])
+ 
+ AM_CONDITIONAL(USE_HOST_SCANNER, test "x$with_host_scanner" = xyes)
+ 
+@@ -112,7 +112,8 @@ PKG_CHECK_MODULES(EXPAT, [expat], [],
+ 	 AC_SUBST(EXPAT_LIBS)
+ 	])
+ 
+-if test "x$enable_dtdvalidation" = "xyes"; then
++AM_CONDITIONAL([DTD_VALIDATION], [test "x$enable_dtd_validation" = "xyes"])
++if test "x$enable_dtd_validation" = "xyes"; then
+ 	PKG_CHECK_MODULES(LIBXML, [libxml-2.0])
+ 	AC_DEFINE(HAVE_LIBXML, 1, [libxml-2.0 is available])
+ 	AC_CONFIG_LINKS([src/wayland.dtd.embed:protocol/wayland.dtd])
+diff --git a/configure b/configure
+index 83e4971..6340d4f 100755
+--- a/configure
++++ b/configure
+@@ -711,6 +711,8 @@ HAVE_XSLTPROC_TRUE
+ XSLTPROC
+ LIBXML_LIBS
+ LIBXML_CFLAGS
++DTD_VALIDATION_FALSE
++DTD_VALIDATION_TRUE
+ EXPAT_LIBS
+ EXPAT_CFLAGS
+ FFI_LIBS
+@@ -15728,7 +15730,7 @@ fi
+ if test "${enable_dtd_validation+set}" = set; then :
+   enableval=$enable_dtd_validation;
+ else
+-  enable_dtdvalidation=yes
++  enable_dtd_validation=yes
+ fi
+ 
+ 
+@@ -16114,7 +16116,15 @@ $as_echo "yes" >&6; }
+ 
+ fi
+ 
+-if test "x$enable_dtdvalidation" = "xyes"; then
++ if test "x$enable_dtd_validation" = "xyes"; then
++  DTD_VALIDATION_TRUE=
++  DTD_VALIDATION_FALSE='#'
++else
++  DTD_VALIDATION_TRUE='#'
++  DTD_VALIDATION_FALSE=
++fi
++
++if test "x$enable_dtd_validation" = "xyes"; then
+ 
+ pkg_failed=no
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBXML" >&5
+@@ -16669,6 +16679,10 @@ if test -z "${ENABLE_LIBRARIES_TRUE}" && test -z "${ENABLE_LIBRARIES_FALSE}"; th
+   as_fn_error $? "conditional \"ENABLE_LIBRARIES\" was never defined.
+ Usually this means the macro was only invoked conditionally." "$LINENO" 5
+ fi
++if test -z "${DTD_VALIDATION_TRUE}" && test -z "${DTD_VALIDATION_FALSE}"; then
++  as_fn_error $? "conditional \"DTD_VALIDATION\" was never defined.
++Usually this means the macro was only invoked conditionally." "$LINENO" 5
++fi
+ if test -z "${HAVE_XSLTPROC_TRUE}" && test -z "${HAVE_XSLTPROC_FALSE}"; then
+   as_fn_error $? "conditional \"HAVE_XSLTPROC\" was never defined.
+ Usually this means the macro was only invoked conditionally." "$LINENO" 5
+diff --git a/src/scanner.c b/src/scanner.c
+index d3e2328..04747e3 100644
+--- a/src/scanner.c
++++ b/src/scanner.c
+@@ -40,13 +40,13 @@
+ 
+ #if HAVE_LIBXML
+ #include <libxml/parser.h>
+-#endif
+-
+-#include "wayland-util.h"
+ 
+ /* Embedded wayland.dtd file, see dtddata.S */
+ extern char DTD_DATA_begin;
+ extern int DTD_DATA_len;
++#endif
++
++#include "wayland-util.h"
+ 
+ enum side {
+ 	CLIENT,
+-- 
+2.6.4
+

diff --git a/dev-libs/wayland/wayland-1.10.0.ebuild b/dev-libs/wayland/wayland-1.10.0.ebuild
index bf4b8cc..b3d1bfc 100644
--- a/dev-libs/wayland/wayland-1.10.0.ebuild
+++ b/dev-libs/wayland/wayland-1.10.0.ebuild
@@ -29,7 +29,8 @@ SLOT="0"
 IUSE="doc static-libs"
 
 RDEPEND=">=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
-	>=virtual/libffi-3.0.13-r1:=[${MULTILIB_USEDEP}]"
+	>=virtual/libffi-3.0.13-r1:=[${MULTILIB_USEDEP}]
+	dev-libs/libxml2:="
 DEPEND="${RDEPEND}
 	doc? (
 		>=app-doc/doxygen-1.6[dot]
@@ -39,19 +40,19 @@ DEPEND="${RDEPEND}
 	)
 	virtual/pkgconfig"
 
-src_configure() {
+# dtd validation configure patch is upstream and will be part of 1.11
+PATCHES=( "${FILESDIR}/${PV}-build-fix-configure-disable-dtd-validation.patch" )
+
+multilib_src_configure() {
 	local myeconfargs=(
-		$(use_enable static-libs static)
-		$(use_enable doc documentation)
+		$(multilib_native_use_enable doc documentation)
+		$(multilib_native_enable dtd-validation)
 	)
 	if tc-is-cross-compiler ; then
 		myeconfargs+=( --with-host-scanner )
 	fi
-	if ! multilib_is_native_abi; then
-		myeconfargs+=( --disable-documentation )
-	fi
 
-	autotools-multilib_src_configure
+	autotools-utils_src_configure
 }
 
 src_test() {


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-01-10  4:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-22 14:50 [gentoo-commits] repo/gentoo:master commit in: dev-libs/wayland/, dev-libs/wayland/files/ Sam James
  -- strict thread matches above, loose matches on Subject: below --
2025-01-10  4:58 Matt Turner
2016-03-01 17:39 Mart Raudsepp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox