public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michael Orlitzky" <mjo@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-mathematics/pari/
Date: Wed,  2 Aug 2023 10:46:14 +0000 (UTC)	[thread overview]
Message-ID: <1690972711.ff400d7539fc97a478f50776d449e922ec1e3ea7.mjo@gentoo> (raw)

commit:     ff400d7539fc97a478f50776d449e922ec1e3ea7
Author:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
AuthorDate: Wed Aug  2 02:21:46 2023 +0000
Commit:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
CommitDate: Wed Aug  2 10:38:31 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ff400d75

sci-mathematics/pari: new revision to fix USE=X handling

Pari's build system is interesting, and choosing a graphics library (for
use in plotting) is... not straightforward. We have two patches that
affect it, and still nobody has noticed in all this time that USE=X does
precisely nothing at all.

I've just sent one of those patches, for building against fltk,
upstream. To avoid having to reroll the other patch and add an X11 case
to it, this revision switches from using e.g. the "--with-fltk" flag to
using "--graphic=fltk" instead. This turns out to be a stronger hint to
the build system, and more imporantly supports both none/X11 as options,
unlike --with-foo. Hopefully it allows us to go patch-free with the next
release of pari.

Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>

 .../pari/{pari-2.15.4.ebuild => pari-2.15.4-r1.ebuild}   | 16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/sci-mathematics/pari/pari-2.15.4.ebuild b/sci-mathematics/pari/pari-2.15.4-r1.ebuild
similarity index 84%
rename from sci-mathematics/pari/pari-2.15.4.ebuild
rename to sci-mathematics/pari/pari-2.15.4-r1.ebuild
index 4869bbe3d995..f7363f67f698 100644
--- a/sci-mathematics/pari/pari-2.15.4.ebuild
+++ b/sci-mathematics/pari/pari-2.15.4-r1.ebuild
@@ -16,6 +16,7 @@ LICENSE="GPL-2"
 SLOT="0/8"
 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
 IUSE="data doc examples fltk gmp test threads X"
+REQUIRED_USE="fltk? ( !X )" # mutually exclusive plot implementations
 RESTRICT="!test? ( test )"
 
 BDEPEND="
@@ -31,6 +32,9 @@ DEPEND="
 	X? ( x11-libs/libX11:0= )"
 RDEPEND="${DEPEND}"
 
+# Both of these should be obsolete in the next version. I've sent the
+# fltk CXXFLAGS bit upstream, and using --graphic=<foo> hopefully works
+# around the automagic parts.
 PATCHES=(
 	"${FILESDIR}/${PN}"-2.9.4-fltk-detection.patch
 	"${FILESDIR}/${PN}"-2.11.2-no-automagic.patch
@@ -71,6 +75,13 @@ src_configure() {
 	# expecting a compiler driver. See bugs 722090 and 871117.
 	# DLLDFLAGS, on the other hand, is used exactly like LDFLAGS would
 	# be in a less-weird build system.
+	#
+	# There's a lot of automagic involved in the graphics detection.  We
+	# first pass --graphic=none, which disables some of it. We then pass
+	# --graphic=fltk (or --graphic=X11) only if USE=fltk (or USE=X) is
+	# set. This is a stronger hint to the build system than --with-fltk
+	# would be, and importantly does not rely on the corresponding but
+	# nonexistent(!) option option for X11.
 	LD="" DLLD="$(tc-getCC)" DLLDFLAGS="${LDFLAGS}" ./Configure \
 		--prefix="${EPREFIX}"/usr \
 		--datadir="${EPREFIX}/usr/share/${PN}" \
@@ -80,9 +91,10 @@ src_configure() {
 		--with-readline="${EPREFIX}"/usr \
 		--with-readline-lib="${EPREFIX}/usr/$(get_libdir)" \
 		--with-ncurses-lib="${EPREFIX}/usr/$(get_libdir)" \
-		$(use_with fltk) \
+		--graphic=none \
+		$(usex X --graphic=X11 "" "" "") \
+		$(usex fltk --graphic=fltk "" "" "") \
 		$(use_with gmp) \
-		--without-qt \
 		$(usex threads "--mt=pthread" "" "" "") \
 		|| die "./Configure failed"
 }


             reply	other threads:[~2023-08-02 10:46 UTC|newest]

Thread overview: 70+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-02 10:46 Michael Orlitzky [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-02-01 11:35 [gentoo-commits] repo/gentoo:master commit in: sci-mathematics/pari/ Arthur Zamarin
2025-02-01 11:35 Arthur Zamarin
2025-01-12  1:47 Michael Orlitzky
2024-08-19 12:47 Michael Orlitzky
2024-07-14 20:17 Jakov Smolić
2024-07-14 18:57 Arthur Zamarin
2024-03-12 18:40 Michael Orlitzky
2023-11-22 22:06 Michael Orlitzky
2023-10-31  6:05 Sam James
2023-10-31  2:35 Sam James
2023-07-27  3:37 Michael Orlitzky
2023-06-05  5:15 Sam James
2023-06-05  5:02 Sam James
2023-06-05  3:51 Sam James
2023-06-03 11:15 Arthur Zamarin
2023-01-22  1:17 Michael Orlitzky
2023-01-22  1:17 Michael Orlitzky
2022-11-24  1:04 Michael Orlitzky
2022-09-21  1:00 Michael Orlitzky
2022-09-20 22:55 Michael Orlitzky
2022-09-20 22:55 Michael Orlitzky
2022-08-10  8:04 Arthur Zamarin
2022-08-10  8:04 Arthur Zamarin
2022-08-09  6:19 Joonas Niilola
2022-08-08 13:11 Michael Orlitzky
2022-08-08 12:34 Agostino Sarubbo
2022-06-07 14:43 Michael Orlitzky
2022-06-03 10:59 Michael Orlitzky
2022-06-02  0:36 Sam James
2022-06-02  0:36 Sam James
2022-06-02  0:36 Sam James
2022-06-02  0:36 Sam James
2022-04-07  2:27 Michael Orlitzky
2022-01-20 14:19 Michael Orlitzky
2022-01-19 22:43 Sam James
2022-01-19 22:43 Sam James
2022-01-18 21:50 Jakov Smolić
2022-01-18 21:50 Jakov Smolić
2021-11-11  0:46 Michael Orlitzky
2021-11-10 23:53 Michael Orlitzky
2021-11-10  4:15 Sam James
2021-11-05 17:38 Sam James
2021-11-03 20:28 Sam James
2021-11-03 20:28 Sam James
2021-09-22 15:02 Michael Orlitzky
2021-09-22 15:02 Michael Orlitzky
2021-04-29 14:45 Andrey Grozin
2020-10-20 20:48 Michael Orlitzky
2020-07-23  7:03 Kent Fredric
2020-06-29  1:26 Michael Orlitzky
2020-06-28 20:44 Agostino Sarubbo
2020-06-28 20:37 Agostino Sarubbo
2020-06-28 20:33 Agostino Sarubbo
2020-06-28 20:27 Agostino Sarubbo
2020-06-28 11:46 Michael Orlitzky
2020-06-26 20:21 Thomas Deutschmann
2020-04-28 12:44 Michael Orlitzky
2020-04-26 10:38 Joonas Niilola
2020-04-26  8:40 Joonas Niilola
2020-04-26  8:40 Joonas Niilola
2020-02-24 12:50 Agostino Sarubbo
2020-02-24 11:43 Agostino Sarubbo
2020-02-21 15:57 Agostino Sarubbo
2018-04-20  8:02 David Seifert
2018-01-14 13:49 Andreas Sturmlechner
2018-01-14  9:43 Andreas Sturmlechner
2018-01-14  9:43 Andreas Sturmlechner
2016-05-14 23:32 David Seifert
2016-03-10 17:53 Markus Meier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1690972711.ff400d7539fc97a478f50776d449e922ec1e3ea7.mjo@gentoo \
    --to=mjo@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox