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.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 885431581C1 for ; Wed, 17 Jul 2024 05:39:53 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C08CE2BC0AF; Wed, 17 Jul 2024 05:39:52 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 9A91E2BC0AF for ; Wed, 17 Jul 2024 05:39:52 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id AD40133D9AD for ; Wed, 17 Jul 2024 05:39:51 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 26E381E31 for ; Wed, 17 Jul 2024 05:39:50 +0000 (UTC) From: "Ulrich Müller" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Ulrich Müller" Message-ID: <1721194701.fa118a9c6e00e026170807f7b67415e6ba68967f.ulm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: x11-libs/motif/ X-VCS-Repository: repo/gentoo X-VCS-Files: x11-libs/motif/motif-2.3.8-r6.ebuild X-VCS-Directories: x11-libs/motif/ X-VCS-Committer: ulm X-VCS-Committer-Name: Ulrich Müller X-VCS-Revision: fa118a9c6e00e026170807f7b67415e6ba68967f X-VCS-Branch: master Date: Wed, 17 Jul 2024 05:39:50 +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: d5befad7-835f-453c-ab09-df40cfddf4ab X-Archives-Hash: 835d6d40a48c8d941f3bc78e6184082b commit: fa118a9c6e00e026170807f7b67415e6ba68967f Author: Ulrich Müller gentoo org> AuthorDate: Wed Jul 17 05:36:54 2024 +0000 Commit: Ulrich Müller gentoo org> CommitDate: Wed Jul 17 05:38:21 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fa118a9c x11-libs/motif: Try to make linking with libfl.a less brittle Bug: https://bugs.gentoo.org/936172 Signed-off-by: Ulrich Müller gentoo.org> x11-libs/motif/motif-2.3.8-r6.ebuild | 124 +++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) diff --git a/x11-libs/motif/motif-2.3.8-r6.ebuild b/x11-libs/motif/motif-2.3.8-r6.ebuild new file mode 100644 index 000000000000..c4fb0c84c9af --- /dev/null +++ b/x11-libs/motif/motif-2.3.8-r6.ebuild @@ -0,0 +1,124 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools flag-o-matic toolchain-funcs multilib-minimal + +DESCRIPTION="The Motif user interface component toolkit" +HOMEPAGE="https://sourceforge.net/projects/motif/ + https://motif.ics.com/" +SRC_URI="https://downloads.sourceforge.net/project/motif/Motif%20${PV}%20Source%20Code/${P}.tar.gz + https://dev.gentoo.org/~ulm/distfiles/${P}-patches-5.tar.xz" + +LICENSE="LGPL-2.1+ MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +IUSE="examples jpeg +motif22-compatibility png static-libs unicode xft" + +RDEPEND=">=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] + >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}] + >=x11-libs/libXmu-1.1.1-r1[${MULTILIB_USEDEP}] + >=x11-libs/libXt-1.1.4[${MULTILIB_USEDEP}] + jpeg? ( >=media-libs/libjpeg-turbo-1.5.3-r2:0=[${MULTILIB_USEDEP}] ) + png? ( >=media-libs/libpng-1.6.10:0=[${MULTILIB_USEDEP}] ) + unicode? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] ) + xft? ( + >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] + >=x11-libs/libXft-2.3.1-r1[${MULTILIB_USEDEP}] + )" + +DEPEND="${RDEPEND} + x11-base/xorg-proto + x11-misc/xbitmaps" + +BDEPEND="sys-devel/flex + dev-util/byacc" + +src_prepare() { + eapply ../patch + eapply_user + + # remove files generated by flex #864533 + rm tools/wml/{wmllex,wmluiltok}.c || die + + AT_M4DIR=. eautoreconf + + # get around some LANG problems in make (#15119) + LANG=C + + # bug #80421 + filter-flags -ftracer + + # feel free to fix properly if you care + append-flags -fno-strict-aliasing + + # for Solaris Xos_r.h :( + [[ ${CHOST} == *-solaris2.11 ]] \ + && append-cppflags -DNEED_XOS_R_H -DHAVE_READDIR_R_3 + + if use !elibc_glibc && use !elibc_musl && use unicode; then + # libiconv detection in configure script doesn't always work + # http://bugs.motifzone.net/show_bug.cgi?id=1423 + export LIBS="${LIBS} -liconv" + fi + + # avoid mismatch of lex variants #936172 + export LEX=flex + # "bison -y" causes runtime crashes #355795 + export YACC=byacc + + # remember the name of the C compiler for the native ABI + MY_NATIVE_CC=$(tc-getCC) + + # -Werror=lto-type-mismatch + # + # Helpfully, the motif bugtracker is entirely down. They are also + # on sourceforge but only for merge requests? The project is a + # fascinating kind of ghostly haunting. Punting on reporting... for now. + filter-lto +} + +multilib_src_configure() { + ECONF_SOURCE="${S}" econf \ + --with-x \ + --disable-printing \ + $(use_enable static-libs static) \ + $(use_enable motif22-compatibility) \ + $(use_enable unicode utf8) \ + $(use_enable xft) \ + $(use_enable jpeg) \ + $(use_enable png) +} + +multilib_src_compile() { + if ! multilib_is_native_abi; then + # The wmluiltok build tool is linked with libfl.a, so always + # compile it for the native ABI + emake -C tools/wml CC="${MY_NATIVE_CC}" \ + wmluiltok_LDADD="-lfl" wmluiltok + fi + emake +} + +multilib_src_install() { + emake DESTDIR="${D}" install + + if multilib_is_native_abi && use examples; then + emake -C demos DESTDIR="${D}" install-data + dodir /usr/share/doc/${PF}/demos + mv "${ED}"/usr/share/Xm/* "${ED}"/usr/share/doc/${PF}/demos || die + fi +} + +multilib_src_install_all() { + # mwm default configs + insinto /usr/share/X11/app-defaults + newins "${FILESDIR}"/Mwm.defaults Mwm + + # cleanup + rm -rf "${ED}"/usr/share/Xm || die + find "${D}" -type f -name "*.la" -delete || die + + dodoc BUGREPORT ChangeLog README RELEASE RELNOTES TODO +}