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/singular/, sci-mathematics/singular/files/
Date: Sun, 30 May 2021 14:25:25 +0000 (UTC)	[thread overview]
Message-ID: <1622384643.5399f4f40e04ef04fef15df3039b60b749158f5e.mjo@gentoo> (raw)

commit:     5399f4f40e04ef04fef15df3039b60b749158f5e
Author:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
AuthorDate: Sun May 30 14:10:26 2021 +0000
Commit:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
CommitDate: Sun May 30 14:24:03 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5399f4f4

sci-mathematics/singular: new upstream version 4.2.0_p3.

Nothing exciting here except rebased patches.

Package-Manager: Portage-3.0.18, Repoman-3.0.2
Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>

 sci-mathematics/singular/Manifest                  |   1 +
 .../files/singular-4.2.0-doc_install.patch         |  79 ++++++++++++++++
 .../files/singular-4.2.0-gfan_linking.patch        |  38 ++++++++
 sci-mathematics/singular/singular-4.2.0_p3.ebuild  | 104 +++++++++++++++++++++
 4 files changed, 222 insertions(+)

diff --git a/sci-mathematics/singular/Manifest b/sci-mathematics/singular/Manifest
index 6b537a9d225..13b96e74c09 100644
--- a/sci-mathematics/singular/Manifest
+++ b/sci-mathematics/singular/Manifest
@@ -1 +1,2 @@
 DIST singular-4.2.0p1.tar.gz 14155171 BLAKE2B 444553f87d7ca8d6a62e4519c9857a6892757e92285df7c3b686913a9b51c9ae8d802c41382b0b2b6e37dc2dc496d4a10f262c98407470219cdce131e8baf127 SHA512 2ecd8940c9e8d70a93dbdb4df6da313c00151e5cb959f8eed5856e8df99089b5a03e514fbcdc70903c77df8b59fa7ef9f3b134f1de510b795fa6ea0341089bd8
+DIST singular-4.2.0p3.tar.gz 16641923 BLAKE2B 4dd7e1a42c71bbba625e171aee656580b443656f50458909ffae1af81b1413d5330aa032656032ea365225eb088491fe2a48997895e37bc89eea5f17b8fbebb8 SHA512 b9833389b648ec4ba2bd09253f00254b9ae3dc61313fc81c9003b283fc413caab4274e55750de1c342ef24a8fc0ce817643cd31eabbb2999de7f5017dfa1411f

diff --git a/sci-mathematics/singular/files/singular-4.2.0-doc_install.patch b/sci-mathematics/singular/files/singular-4.2.0-doc_install.patch
new file mode 100644
index 00000000000..b0656d9fb67
--- /dev/null
+++ b/sci-mathematics/singular/files/singular-4.2.0-doc_install.patch
@@ -0,0 +1,79 @@
+From 74ec250d3d89d0125c409b3340aca50a00b067ad Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky <michael@orlitzky.com>
+Date: Sun, 30 May 2021 08:28:41 -0400
+Subject: [PATCH 3/3] autotools: support docdir and htmldir.
+
+Instead of hard-coding the "doc" and "html" subdirectories,
+allow them to be ./configured.
+---
+ Makefile.am             | 8 ++++----
+ configure.ac            | 5 +++++
+ resources/configure.ac  | 4 ++++
+ resources/feResource.cc | 2 +-
+ 4 files changed, 14 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index fbea51d..c5d78a7 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -16,10 +16,10 @@ bin_SCRIPTS = libsingular-config
+ 
+ install-data-local:
+ 	if test -e $(srcdir)/doc/doc.tbz2; then\
+-	  (cat ${top_srcdir}/doc/doc.tbz2| (cd $(DESTDIR)$(datadir)/singular; tar -jx --no-same-owner -f -));\
+-	   mkdir $(DESTDIR)$(datadir)/info;\
+-	   mkdir $(DESTDIR)$(datadir)/doc;\
+-	   mv  $(DESTDIR)$(datadir)/singular/singular.hlp  $(DESTDIR)$(datadir)/info/.;\
++	   mkdir -p $(DESTDIR)$(docdir);\
++	   (cat ${top_srcdir}/doc/doc.tbz2| (cd $(DESTDIR)$(docdir); tar -jx --no-same-owner -f -));\
++	   mv  $(DESTDIR)$(docdir)/singular.hlp  $(DESTDIR)$(datadir)/info/.;\
++	   @INSTALL_DATA@ doc/singular.idx  $(DESTDIR)$(datadir)/singular/.;\
+ 	fi
+ 
+ uninstall-local:
+diff --git a/configure.ac b/configure.ac
+index 490a45f..997db6c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -228,6 +228,11 @@ AX_NORMALIZE_PATH([config_datadir],['/'])
+ AC_DEFINE_UNQUOTED([DATA_DIR],"$config_datadir",[datadir])
+ AC_SUBST(DATA_DIR, "$config_datadir")
+ 
++AX_RECURSIVE_EVAL([[$]docdir], [config_docdir])
++AX_NORMALIZE_PATH([config_docdir],['/'])
++AC_DEFINE_UNQUOTED([DOC_DIR],"$config_docdir",[docdir])
++AC_SUBST(DOC_DIR, "$config_docdir")
++
+ SING_SHOW_FLAGS([Compiler/linker flags: ])
+ 
+ 
+diff --git a/resources/configure.ac b/resources/configure.ac
+index 0dc468f..da68144 100644
+--- a/resources/configure.ac
++++ b/resources/configure.ac
+@@ -72,5 +72,9 @@ AX_RECURSIVE_EVAL([[$]datadir], [config_datadir])
+ AX_NORMALIZE_PATH([config_datadir],['/'])
+ AC_DEFINE_UNQUOTED([DATA_DIR],"$config_datadir",[datadir])
+ 
++AX_RECURSIVE_EVAL([[$]htmldir], [config_htmldir])
++AX_NORMALIZE_PATH([config_htmldir],['/'])
++AC_DEFINE_UNQUOTED([HTML_DIR],"$config_datadir",[htmldir])
++
+ AC_CONFIG_FILES([singular_resources.pc Makefile])
+ AC_OUTPUT
+diff --git a/resources/feResource.cc b/resources/feResource.cc
+index 3d75bc9..7e4fc8c 100644
+--- a/resources/feResource.cc
++++ b/resources/feResource.cc
+@@ -85,7 +85,7 @@ VAR feResourceConfig_s feResourceConfigs[] =
+   {"DefaultDir",'d',    feResDir,   "SINGULAR_DEFAULT_DIR",  SINGULAR_DEFAULT_DIR,  (char *)""},
+   {"InfoFile",  'i',    feResFile,  "SINGULAR_INFO_FILE",   "%D/info/singular.hlp", (char *)""},
+   {"IdxFile",   'x',    feResFile,  "SINGULAR_IDX_FILE",    "%D/singular/singular.idx",  (char *)""},
+-  {"HtmlDir",   'h',    feResDir,   "SINGULAR_HTML_DIR",    "%D/singular/html",              (char *)""},
++  {"HtmlDir",   'h',    feResDir,   "SINGULAR_HTML_DIR",    HTML_DIR,              (char *)""},
+   {"ManualUrl", 'u',    feResUrl,   "SINGULAR_URL",         "https://www.singular.uni-kl.de/Manual/",    (char *)""},
+   {"ExDir",     'm',    feResDir,   "SINGULAR_EXAMPLES_DIR","%r/examples",          (char *)""},
+   {"Path",      'p',    feResPath,  NULL,                   "%b;%P;$PATH",             (char *)""},
+-- 
+2.31.1
+

diff --git a/sci-mathematics/singular/files/singular-4.2.0-gfan_linking.patch b/sci-mathematics/singular/files/singular-4.2.0-gfan_linking.patch
new file mode 100644
index 00000000000..267bf19361a
--- /dev/null
+++ b/sci-mathematics/singular/files/singular-4.2.0-gfan_linking.patch
@@ -0,0 +1,38 @@
+From 705149b86a80dd8b53fa8c1717872e9b2e9dbbcb Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky <michael@orlitzky.com>
+Date: Sun, 30 May 2021 08:10:10 -0400
+Subject: [PATCH 1/3] gfanlib/Makefile.am: use LIBADD for additional libraries.
+
+The $GMP_LIBS and $CDDGMPLDFLAGS variables were being added to
+libgfan_la_LDFLAGS, which isn't quite correct. Since both contain
+library (-l) flags, they belong in _LIBADD rather than _LDFLAGS:
+
+  https://www.gnu.org/software/automake/manual/html_node/Libtool-Flags.html
+
+This commit moves them to a new libgfan_la_LIBADD variable.
+---
+ gfanlib/Makefile.am | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/gfanlib/Makefile.am b/gfanlib/Makefile.am
+index cec8d8f..96e1893 100644
+--- a/gfanlib/Makefile.am
++++ b/gfanlib/Makefile.am
+@@ -18,9 +18,13 @@ AM_CXXFLAGS = @CXX11_FLAG@
+ 
+ SOURCES = gfanlib_circuittableint.cpp gfanlib_mixedvolume.cpp gfanlib_paralleltraverser.cpp gfanlib_polyhedralfan.cpp gfanlib_polymakefile.cpp gfanlib_symmetriccomplex.cpp gfanlib_symmetry.cpp gfanlib_traversal.cpp gfanlib_zcone.cpp gfanlib_zfan.cpp
+ libgfan_la_SOURCES = $(SOURCES)
+-libgfan_la_LDFLAGS = $(SINGULAR_LDFLAGS) $(CDDGMPLDFLAGS) $(GMP_LIBS)
++libgfan_la_LDFLAGS = $(SINGULAR_LDFLAGS)
+ libgfan_la_CPPFLAGS= $(GMP_CPPFLAGS) $(CDDGMPCPPFLAGS)
+ 
++# Despite the naming convention, $CDDGMPLDFLAGS contains "-lcddgmp"
++# and the rest of the $GMP_LIBS flags.
++libgfan_la_LIBADD = $(CDDGMPLDFLAGS) $(GMP_LIBS)
++
+ noinst_HEADERS = config.h gfanlib_mixedvolume.h gfanlib_polymakefile.h gfanlib_symmetry.h gfanlib_vector.h gfanlib_z.h _config.h  gfanlib.h gfanlib_paralleltraverser.h gfanlib_q.h  gfanlib_traversal.h gfanlib_zcone.h gfanlib_circuittableint.h gfanlib_matrix.h gfanlib_polyhedralfan.h gfanlib_symmetriccomplex.h gfanlib_tropicalhomotopy.h gfanlib_zfan.h
+ 
+ DISTCLEANFILES =  config.h
+-- 
+2.31.1
+

diff --git a/sci-mathematics/singular/singular-4.2.0_p3.ebuild b/sci-mathematics/singular/singular-4.2.0_p3.ebuild
new file mode 100644
index 00000000000..df77bad38d5
--- /dev/null
+++ b/sci-mathematics/singular/singular-4.2.0_p3.ebuild
@@ -0,0 +1,104 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools elisp-common
+
+MY_PN=Singular
+MY_PV=$(ver_rs 3 '')
+# Consistency is different...
+MY_DIR2=$(ver_cut 1-3 ${PV})
+MY_DIR=$(ver_rs 1- '-' ${MY_DIR2})
+
+DESCRIPTION="Computer algebra system for polynomial computations"
+HOMEPAGE="https://www.singular.uni-kl.de/ https://github.com/Singular/Sources"
+SRC_URI="ftp://jim.mathematik.uni-kl.de/pub/Math/${MY_PN}/SOURCES/${MY_DIR}/${PN}-${MY_PV}.tar.gz"
+
+LICENSE="BSD GPL-2 GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~x86-linux"
+IUSE="emacs examples +readline static-libs"
+
+RDEPEND="dev-libs/gmp:0
+	dev-libs/ntl:=
+	emacs? ( >=app-editors/emacs-23.1:* )
+	sci-mathematics/flint
+	sci-libs/cddlib
+	dev-lang/perl
+	readline? ( sys-libs/readline )"
+
+DEPEND="${RDEPEND}"
+
+SITEFILE=60${PN}-gentoo.el
+
+S="${WORKDIR}/${PN}-${MY_DIR2}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-4.2.0-gfan_linking.patch"
+	"${FILESDIR}/${PN}-4.2.0-doc_install.patch"
+	"${FILESDIR}/${PN}-4.2.0-no-static.patch"
+)
+
+src_prepare() {
+	default
+
+	eautoreconf
+}
+
+src_configure() {
+	econf --with-gmp \
+		--with-ntl="${EPREFIX}"/usr \
+		--with-flint \
+		--enable-gfanlib \
+		--disable-debug \
+		--disable-doc \
+		--enable-factory \
+		--enable-libfac \
+		--enable-IntegerProgramming \
+		--disable-polymake \
+		$(use_enable static-libs static) \
+		$(use_enable emacs) \
+		$(use_with readline)
+}
+
+src_compile() {
+	default
+
+	if use emacs; then
+		pushd "${S}"/emacs
+		elisp-compile *.el || die "elisp-compile failed"
+		popd
+	fi
+}
+
+src_install() {
+	# Do not compress singular's info file (singular.hlp)
+	# some consumer of that file do not know how to deal with compression
+	docompress -x /usr/share/info
+
+	default
+
+	dosym Singular /usr/bin/"${PN}"
+
+	# purge .la file
+	find "${ED}" -name '*.la' -delete || die
+}
+
+src_test() {
+	# SINGULAR_PROCS_DIR need to be set to "" otherwise plugins from
+	# an already installed version of singular may be used and cause segfault
+	# See https://github.com/Singular/Sources/issues/980
+	SINGULAR_PROCS_DIR="" emake check
+}
+
+pkg_postinst() {
+	einfo "Additional functionality can be enabled by installing"
+	einfo "sci-mathematics/4ti2"
+
+	use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+	use emacs && elisp-site-regen
+}


             reply	other threads:[~2021-05-30 14:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-30 14:25 Michael Orlitzky [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-03-09 19:45 [gentoo-commits] repo/gentoo:master commit in: sci-mathematics/singular/, sci-mathematics/singular/files/ Michael Orlitzky
2022-05-27 12:23 Michael Orlitzky
2022-04-22  0:50 Sam James
2021-07-02  1:03 Michael Orlitzky
2021-05-30 11:51 Michael Orlitzky
2019-12-07 23:50 David Seifert

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=1622384643.5399f4f40e04ef04fef15df3039b60b749158f5e.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