summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2023-07-06 23:18:13 -0400
committerMichael Orlitzky <mjo@gentoo.org>2023-07-07 09:17:30 -0400
commitadc3f1cb14828b2d90925192705e63f0c548993c (patch)
treebff35d420d38bb550c34211aa433d4e8ab4936f7 /sci-mathematics/giac
parentsys-kernel/gentoo-sources: stabilize 6.1.38 for amd64 (diff)
downloadgentoo-adc3f1cb14828b2d90925192705e63f0c548993c.tar.gz
gentoo-adc3f1cb14828b2d90925192705e63f0c548993c.tar.bz2
gentoo-adc3f1cb14828b2d90925192705e63f0c548993c.zip
sci-mathematics/giac: unbundle x11-libs/gl2ps.
Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
Diffstat (limited to 'sci-mathematics/giac')
-rw-r--r--sci-mathematics/giac/files/giac-1.9.0.55-system-gl2ps.patch69
-rw-r--r--sci-mathematics/giac/giac-1.9.0.55-r1.ebuild (renamed from sci-mathematics/giac/giac-1.9.0.55.ebuild)26
2 files changed, 86 insertions, 9 deletions
diff --git a/sci-mathematics/giac/files/giac-1.9.0.55-system-gl2ps.patch b/sci-mathematics/giac/files/giac-1.9.0.55-system-gl2ps.patch
new file mode 100644
index 000000000000..e82d892560da
--- /dev/null
+++ b/sci-mathematics/giac/files/giac-1.9.0.55-system-gl2ps.patch
@@ -0,0 +1,69 @@
+From ca8eda770e36d2649bfc808464415308a5e9fc47 Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky <michael@orlitzky.com>
+Date: Thu, 6 Jul 2023 21:27:09 -0400
+Subject: [PATCH 1/1] src: unbundle gl2ps.
+
+Updated patch based on the one by infinity0@debian.org. Ours links
+only libxcas (and not libgiac) to gl2ps.
+---
+ configure.ac | 4 ++++
+ src/Graph3d.cc | 2 +-
+ src/Makefile.am | 6 +++---
+ 3 files changed, 8 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 8e1813e..2f7f644 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -465,6 +465,10 @@ dnl AC_CHECK_LIB(GLU, main)
+ AC_CHECK_LIB(fltk_images, main)
+ FLTK_LIBS="$LIBS $X_LIBS"
+ AC_SUBST(FLTK_LIBS)
++
++ # GL2PS is only used by xcas (the GUI)
++ GL2PS_LIBS="-lgl2ps"
++ AC_SUBST(GL2PS_LIBS)
+ cd src && ln -sf ../fltk-1.3.8 && cd ..
+ fi
+ fi
+diff --git a/src/Graph3d.cc b/src/Graph3d.cc
+index 7f54327..12d4723 100644
+--- a/src/Graph3d.cc
++++ b/src/Graph3d.cc
+@@ -45,7 +45,7 @@
+ #include "Xcas1.h"
+ #include "Cfg.h"
+ #include "Print.h"
+-#include "gl2ps.h"
++#include <gl2ps.h>
+
+ #ifdef __APPLE__
+ //#include <OpenGL/gl.h>
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 3fdd209..120ccb6 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -35,17 +35,17 @@ libbf.h list.h cutils.h qjsgiac.h \
+ quickjs.h js.h quickjs-atom.h quickjs-libc.h quickjs-opcode.h bf2gmp.h
+
+ noinst_LTLIBRARIES = libxcas.la
+-libxcas_la_LIBADD = libgiac.la $(FLTK_LIBS)
++libxcas_la_LIBADD = libgiac.la $(FLTK_LIBS) $(GL2PS_LIBS)
+
+ libxcas_la_SOURCES = History.cc Input.cc Xcas1.cc Equation.cc Print.cc \
+ Tableur.cc Editeur.cc Graph.cc Graph3d.cc Help1.cc Cfg.cc \
+ Flv_CStyle.cc \
+ Flve_Check_Button.cc Flve_Input.cc Flv_Style.cc Flv_Data_Source.cc \
+- Flve_Combo.cc Flv_List.cc Flv_Table.cc gl2ps.c \
++ Flve_Combo.cc Flv_List.cc Flv_Table.cc \
+ History.h Input.h Xcas1.h Equation.h Print.h Tableur.h \
+ Editeur.h Graph.h Graph3d.h Help1.h Cfg.h Python.cc Python.h \
+ Flv_CStyle.H Flve_Check_Button.H Flve_Input.H Flv_Style.H \
+- Flv_Data_Source.H Flve_Combo.H Flv_List.H Flv_Table.H gl2ps.h
++ Flv_Data_Source.H Flve_Combo.H Flv_List.H Flv_Table.H
+
+ ##libjavagiac_la_LIBADD = libgiac.la
+
+--
+2.39.3
+
diff --git a/sci-mathematics/giac/giac-1.9.0.55.ebuild b/sci-mathematics/giac/giac-1.9.0.55-r1.ebuild
index 287394488a2d..ecc901270b63 100644
--- a/sci-mathematics/giac/giac-1.9.0.55.ebuild
+++ b/sci-mathematics/giac/giac-1.9.0.55-r1.ebuild
@@ -22,23 +22,26 @@ done
# nauty and cliquer are automagical dependencies
RDEPEND="dev-libs/gmp:=[cxx(+)]
- sys-libs/readline:=
- gui? ( x11-libs/fltk[opengl]
- media-libs/libpng:= )
- ao? ( media-libs/libao )
dev-libs/mpfr:=
+ dev-libs/ntl:=
+ net-misc/curl
sci-libs/mpfi
sci-libs/gsl:=
+ sci-mathematics/cliquer
+ sci-mathematics/nauty
sci-mathematics/pari:=[threads]
- dev-libs/ntl:=
+ sys-libs/readline:=
virtual/lapack
virtual/blas
- net-misc/curl
- sci-mathematics/cliquer
- sci-mathematics/nauty
+ ao? ( media-libs/libao )
ecm? ( sci-mathematics/gmp-ecm )
+ gc? ( dev-libs/boehm-gc )
glpk? ( sci-mathematics/glpk )
- gc? ( dev-libs/boehm-gc )"
+ gui? (
+ media-libs/libpng:=
+ x11-libs/fltk[opengl]
+ x11-libs/gl2ps
+ )"
DEPEND="${RDEPEND}"
@@ -52,6 +55,7 @@ PATCHES=(
"${FILESDIR}/${PN}-1.9.0.21-pari-2.15.patch"
"${FILESDIR}/${PN}-1.9.0.55-pari-2.15-test.patch"
"${FILESDIR}/${PN}-1.9.0.55-undefined-behavior.patch"
+ "${FILESDIR}/${PN}-1.9.0.55-system-gl2ps.patch"
)
REQUIRED_USE="test? ( gui )"
@@ -68,6 +72,10 @@ src_prepare() {
# if you pass --enable-fltk but the system version isn't detected.
# We make sure that cannot happen under any circumstances.
rm fltk-1.3.8-source.tar.bz2 || die
+
+ # similar deal with gl2ps
+ rm src/gl2ps.[ch] || die
+
default
eautoreconf
}