diff --git a/build/pkgs/giac/checksums.ini b/build/pkgs/giac/checksums.ini index b313d50549c..71293fdadc7 100644 --- a/build/pkgs/giac/checksums.ini +++ b/build/pkgs/giac/checksums.ini @@ -1,5 +1,5 @@ tarball=giac-VERSION.tar.bz2 -sha1=c8b4b40dae98a83adda0142332a482c4fec2d4eb -md5=504151eb5f483a24c941822d792f0bb3 -cksum=3611162964 +sha1=873f44e8b6a8f43121c30587d99016763c9e047c +md5=52eda3193e16ab05b4fb2a727c8f3308 +cksum=2879733923 upstream_url=https://trac.sagemath.org/raw-attachment/ticket/29552/giac-VERSION.tar.bz2 diff --git a/build/pkgs/giac/dependencies b/build/pkgs/giac/dependencies index 72a653466b0..c36972a1011 100644 --- a/build/pkgs/giac/dependencies +++ b/build/pkgs/giac/dependencies @@ -1,4 +1,4 @@ -readline libpng $(MP_LIBRARY) mpfr mpfi ntl gsl pari +readline libpng $(MP_LIBRARY) mpfr mpfi ntl gsl pari glpk curl ---------- All lines of this file are ignored except the first. diff --git a/build/pkgs/giac/package-version.txt b/build/pkgs/giac/package-version.txt index 913adb80abb..d24489e06fe 100644 --- a/build/pkgs/giac/package-version.txt +++ b/build/pkgs/giac/package-version.txt @@ -1 +1 @@ -1.5.0.87 +1.5.0.87p0 diff --git a/build/pkgs/giac/patches/autotools/configure-libpng.patch b/build/pkgs/giac/patches/autotools/configure-libpng.patch deleted file mode 100644 index deabc0eb8ab..00000000000 --- a/build/pkgs/giac/patches/autotools/configure-libpng.patch +++ /dev/null @@ -1,12 +0,0 @@ -patch configure.in to correctly check multiple libpng soname versions -the resulting patch to configure is in ../configure-libpng.patch -see https://trac.sagemath.org/ticket/25818 ---- a/configure.in 2018-07-10 18:26:56.330278000 +0000 -+++ b/configure.in 2018-07-10 19:06:58.602278000 +0000 -@@ -100,7 +100,7 @@ - [ if test "x$enableval" = "xno"; then CONFIG_PNG="no"; fi], []) - - if test "x$CONFIG_PNG" = "xyes"; then -- AC_CHECK_HEADERS(png.h, AC_CHECK_LIB(png,main)) dnl AC_CHECK_LIBS(main,[png16,png14,png12,png])) -+ AC_CHECK_HEADERS(png.h, AC_SEARCH_LIBS(png_sig_cmp,[png16 png14 png12 png])) - fi diff --git a/build/pkgs/giac/patches/autotools/giac-1.5.0.87-gsl_lapack.patch b/build/pkgs/giac/patches/autotools/giac-1.5.0.87-gsl_lapack.patch new file mode 100644 index 00000000000..1ecb49fa081 --- /dev/null +++ b/build/pkgs/giac/patches/autotools/giac-1.5.0.87-gsl_lapack.patch @@ -0,0 +1,83 @@ +diff --git a/configure.in b/configure.in +index 204d17a..434e4c9 100644 +--- a/configure.in ++++ b/configure.in +@@ -38,6 +38,7 @@ AC_LANG([C++]) + AC_PROG_LIBTOOL + AC_PROG_YACC + AM_PROG_LEX ++PKG_PROG_PKG_CONFIG + AC_C_BIGENDIAN + + dnl Check for standard C+headers +@@ -139,47 +140,17 @@ AC_CHECK_SIZEOF(long) + AC_CHECK_SIZEOF(long long) + + dnl Checking for Gnu Sci Lib +-CONFIG_GSL="yes" +-AC_ARG_ENABLE([gsl],[ +- AS_HELP_STRING([--enable-gsl], [Use GNU scientific library [[default=yes]]])], +- [ if test "x$enableval" = "xno"; then CONFIG_GSL="no"; fi], []) +- +-if test "$CONFIG_GSL" = "yes"; then +- AC_CHECK_HEADERS(gsl/gsl_blas.h) +- AC_CHECK_HEADERS(gsl/gsl_eigen.h) +- if test "$ac_cv_header_gsl_gsl_blas_h" != "yes" -o "$ac_cv_header_gsl_gsl_eigen_h" != "yes"; then +- CONFIG_GSL="no" +- fi +-fi +-if test "$CONFIG_GSL" = "yes"; then +- save_LIBS="$LIBS" +- AC_CHECK_LIB(gslcblas, main, [], [CONFIG_GSL="no"]) +- AC_CHECK_LIB(gsl, gsl_sf_gamma, [], [CONFIG_GSL="no"]) +- LIBS="$save_LIBS" +- fi +-GSL_LIBS="" +-if test "$CONFIG_GSL" = "yes"; then +- GSL_LIBS="-lgsl -lgslcblas" +- fi +-AC_SUBST(CONFIG_GSL) +-AC_SUBST(GSL_LIBS) +-AM_CONDITIONAL(CONFIG_GSL, [test "$CONFIG_GSL" = "yes"]) +- +-CONFIG_LAPACK="yes" +-AC_ARG_ENABLE([lapack], +- [AS_HELP_STRING([--enable-lapack], [Use LAPACK [[default=yes]]])], +- [ if test "$enableval" = "no"; then CONFIG_LAPACK="no"; fi], []) ++PKG_CHECK_MODULES([GSL], [gsl],[ ++ AC_DEFINE(HAVE_LIBGSL,1, [Define if gsl is installed]) ++ AC_SUBST(GSL_LIBS)]) + +-if test "$CONFIG_LAPACK" = "yes"; then +-# AC_CHECK_LIB(f2c, main, [], [CONFIG_LAPACK="no"]) +-# AC_CHECK_LIB(blas, main, [], [CONFIG_LAPACK="no"]) +-# AC_CHECK_LIB(tmglib, main, [], [CONFIG_LAPACK="no"]) +- AC_CHECK_LIB(gfortran, main) +- AC_CHECK_LIB(blas, main) +- AC_CHECK_LIB(lapack, main, [], [CONFIG_LAPACK="no"]) +-# AX_BLAS([have_blas=yes],[have_blas=no]) +-# AX_LAPACK([have_lapack=yes],[have_lapack=no]) +-fi ++PKG_CHECK_MODULES([LAPACK], [lapack],[ ++ AC_DEFINE(HAVE_LIBLAPACK,1,[Define if LAPACK is installed]) ++ AC_SUBST(LAPACK_LIBS)]) ++ ++PKG_CHECK_MODULES([BLAS], [blas],[ ++ AC_DEFINE(HAVE_BLAS,1,[Define if BLAS is installed]) ++ AC_SUBST(BLAS_LIBS)]) + + CONFIG_PARI="yes" + AC_ARG_ENABLE([pari], +diff --git a/src/Makefile.am b/src/Makefile.am +index b5dd325..d45b553 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -14,7 +14,7 @@ libgiac_la_SOURCES = input_lexer.ll sym2poly.cc gausspol.cc threaded.cc \ + help.cc lpsolve.cc optimization.cc signalprocessing.cc \ + graphe.cc graphtheory.cc nautywrapper.c markup.cc kdisplay.cc kadd.cc # Ugh.. + +-libgiac_la_LIBADD = $(NTL_LIBS) $(COCOA_LIBS) $(PARI_LIBS) $(GSL_LIBS) ++libgiac_la_LIBADD = $(NTL_LIBS) $(COCOA_LIBS) $(PARI_LIBS) $(GSL_LIBS) $(LAPACK_LIBS) $(BLAS_LIBS) + + giacincludedir = $(includedir)/giac + giacinclude_HEADERS = dispatch.h fraction.h gen.h desolve.h misc.h ti89.h \ diff --git a/build/pkgs/giac/patches/autotools/ticket-22315-autotools.patch b/build/pkgs/giac/patches/autotools/ticket-22315-autotools.patch deleted file mode 100644 index b660982360b..00000000000 --- a/build/pkgs/giac/patches/autotools/ticket-22315-autotools.patch +++ /dev/null @@ -1,48 +0,0 @@ -diff -ruN a/Makefile.am b/Makefile.am ---- a/Makefile.am 2017-02-06 16:01:16.484367300 +0100 -+++ b/Makefile.am 2017-02-06 16:06:28.013569300 +0100 -@@ -8,18 +8,18 @@ - ## FIXME: installing autoconf-generated config.h is just PLAIN WRONG. - - install-exec-hook: -- cp config.h $(DESTDIR)/$(includedir)/giac -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/ -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/pixmaps -- cp xcas.xpm $(DESTDIR)/$(prefix)/share/pixmaps/xcas.xpm -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/applications -- cp xcas.desktop $(DESTDIR)/$(prefix)/share/applications/xcas.desktop -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/application-registry -- cp xcas.applications $(DESTDIR)/$(prefix)/share/application-registry/xcas.applications -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/icons/ -- ./mkinstalldirs $(DESTDIR)/$(prefix)/share/icons/hicolor -- for SIZE in 256 128 64 32 16; do ./mkinstalldirs $(DESTDIR)/$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE} && ./mkinstalldirs $(DESTDIR)/$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/apps && cp icons/xcas_$${SIZE}.png $(DESTDIR)/$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/apps/xcas.png; done -- for SIZE in 256 128 64 32 16; do ./mkinstalldirs $(DESTDIR)/$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/mimetypes && cp icons/x-xcas_$${SIZE}.png $(DESTDIR)/$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/mimetypes/application-x-xcas.png; done -+ cp config.h $(DESTDIR)$(includedir)/giac -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/ -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/pixmaps -+ cp xcas.xpm $(DESTDIR)$(prefix)/share/pixmaps/xcas.xpm -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/applications -+ cp xcas.desktop $(DESTDIR)$(prefix)/share/applications/xcas.desktop -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/application-registry -+ cp xcas.applications $(DESTDIR)$(prefix)/share/application-registry/xcas.applications -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/icons/ -+ ./mkinstalldirs $(DESTDIR)$(prefix)/share/icons/hicolor -+ for SIZE in 256 128 64 32 16; do ./mkinstalldirs $(DESTDIR)$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE} && ./mkinstalldirs $(DESTDIR)$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/apps && cp icons/xcas_$${SIZE}.png $(DESTDIR)$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/apps/xcas.png; done -+ for SIZE in 256 128 64 32 16; do ./mkinstalldirs $(DESTDIR)$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/mimetypes && cp icons/x-xcas_$${SIZE}.png $(DESTDIR)$(prefix)/share/icons/hicolor/$${SIZE}x$${SIZE}/mimetypes/application-x-xcas.png; done - - ACLOCAL_AMFLAGS = -I m4 - -diff -ruN a/src/Makefile.am b/src/Makefile.am ---- a/src/Makefile.am 2017-02-06 16:01:51.663379800 +0100 -+++ b/src/Makefile.am 2017-02-06 16:01:25.730657700 +0100 -@@ -85,8 +85,8 @@ - bin_SCRIPTS = pgiac - - install-exec-hook: -- rm -f $(DESTDIR)$(bindir)/cas_help -- mv $(DESTDIR)/$(bindir)/aide$(EXEEXT) $(DESTDIR)$(bindir)/cas_help -+ rm -f $(DESTDIR)$(bindir)/cas_help$(EXEEXT) -+ mv $(DESTDIR)$(bindir)/aide$(EXEEXT) $(DESTDIR)$(bindir)/cas_help - ln -sf cas_help $(DESTDIR)$(bindir)/en_cas_help - ln -sf cas_help $(DESTDIR)$(bindir)/es_cas_help - ln -sf cas_help $(DESTDIR)$(bindir)/fr_cas_help diff --git a/build/pkgs/giac/spkg-install.in b/build/pkgs/giac/spkg-install.in index d6a931b3b10..b4b2c4905cb 100644 --- a/build/pkgs/giac/spkg-install.in +++ b/build/pkgs/giac/spkg-install.in @@ -40,7 +40,6 @@ echo "Configuring giac..." # --disable-ao (avoid libao deps) -# --disable-lapack (avoid lapack and blas deps because they could be from the base system) # On OS X (10.12) the built in intl is broken DISABLENLS="" if [ "$UNAME" = "Darwin" ]; then @@ -48,7 +47,7 @@ if [ "$UNAME" = "Darwin" ]; then DISABLENLS="--disable-nls" fi -sdh_configure --disable-gui --disable-ao --disable-lapack "$DISABLENLS" --enable-png=no --disable-samplerate +sdh_configure --disable-gui --disable-ao "$DISABLENLS" --enable-png=no --disable-samplerate ############################################################# # Build diff --git a/build/pkgs/giac/spkg-src b/build/pkgs/giac/spkg-src index 910da816bc4..ce9ebcb7d91 100755 --- a/build/pkgs/giac/spkg-src +++ b/build/pkgs/giac/spkg-src @@ -15,7 +15,7 @@ set -e VERSION="1.5.0" VERSIONREV="87" -PATCHSUFFIX="" +PATCHSUFFIX="p0" # The upstream tarball name is: giac"$SOURCEORIG".tar.gz SOURCEORIG=_"$VERSION"-"$VERSIONREV" @@ -67,9 +67,15 @@ touch html_mtt touch html_vall # - # building giac source tarball for the spkg -cd ../../../ +cd ../../ + +for a in "$SAGE_ROOT"/build/pkgs/giac/patches/autotools/*.patch; do + patch -p1 < $a +done +autoreconf -fi + +cd .. tar -cjf "$OUTPUTFILEBASENAME".tar.bz2 src # cleaning extracted dir. @@ -78,3 +84,6 @@ rm -rf "$TARGET" # going back to starting dir cd "$ORIGDIR" +#$SAGE_ROOT/sage -package update giac "$VERSION"."$VERSIONREV""$PATCHSUFFIX" +echo "$VERSION"."$VERSIONREV""$PATCHSUFFIX" > build/pkgs/giac/package-version.txt +$SAGE_ROOT/sage -package fix-checksum giac