pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/math/openblas openblas: update to 0.3.10, fixing build...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7307d7dc4203
branches:  trunk
changeset: 449305:7307d7dc4203
user:      thor <thor%pkgsrc.org@localhost>
date:      Thu Mar 25 23:22:35 2021 +0000

description:
openblas: update to 0.3.10, fixing build with gcc 10

Fix openblas build issues, mainly by updating to 0.3.10.

This pulls in these commits from WIP (newest first):

commit 3c6284cba90280bc367cf4d1d8252ae4d6e92e76
Author: Jason Bacon <bacon%NetBSD.org@localhost>
Date:   Thu Feb 25 11:56:13 2021 -0600

    openblas: Update ONLY_FOR_PLATFORMS documentation

commit 8071bf28f3ffc95af046ff3eaaac6983f4f70035
Author: Jason Bacon <bacon%NetBSD.org@localhost>
Date:   Thu Feb 25 11:51:32 2021 -0600

    openblas*: Successful build on NetBSD

commit 056e3d5c972a4b286e8755dbee323a9951855165
Author: Dr. Thomas Orgis <thomas.orgis%uni-hamburg.de@localhost>
Date:   Wed Feb 24 18:40:17 2021 +0100

    openblas: flags from environment again to un-break PICy build

    The bug that prompted us to force the compiler flags in the
    make arguments is fixed. Now we got a different one: The logic
    that decides to add -fPIC where needed is overridden when doing
    this, resulting in relocation errors (strangely, not with every
    toolchain).

    So let's remove that again and take FFLAGS and friends from the
    environment again.

commit 86af17db8526e629c2c02c6af1f1ce7db6f6ba6d
Author: Dr. Thomas Orgis <thomas.orgis%uni-hamburg.de@localhost>
Date:   Thu Nov 12 12:44:39 2020 +0100

    openblas: version 0.3.10

    This updated fixes the build with gcc 10 (segfault in cblat1 test).

    I did not go all the way to the current 0.3.12, as that would
    need some hacking of chosen compiler flags. 0.3.13 should be
    the next one.

    This commit also fixes the ARCH → ARCH_ sed to change all
    occurences on a line.

This fulfills pkg/55999 and was approved by wiz during freeze.

diffstat:

 math/openblas/Makefile.common                |  19 +++-----------
 math/openblas/distinfo                       |  37 +++++++++++++--------------
 math/openblas/patches/patch-Makefile         |  31 ++++++++---------------
 math/openblas/patches/patch-Makefile.install |  14 +++++-----
 math/openblas/patches/patch-Makefile.system  |  10 +++---
 math/openblas/patches/patch-exports+Makefile |  14 ++--------
 math/openblas/patches/patch-getarch.c        |  10 +++---
 math/openblas/patches/patch-utest_Makefile   |  19 --------------
 math/openblas/version.mk                     |   6 +++-
 9 files changed, 57 insertions(+), 103 deletions(-)

diffs (truncated from 341 to 300 lines):

diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/Makefile.common
--- a/math/openblas/Makefile.common     Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/Makefile.common     Thu Mar 25 23:22:35 2021 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.1 2020/11/05 16:31:45 bacon Exp $
+# $NetBSD: Makefile.common,v 1.2 2021/03/25 23:22:35 thor Exp $
 #
 # used by math/openblas_pthread/Makefile
 # used by math/openblas_openmp/Makefile
@@ -27,10 +27,9 @@
 COMMENT=       Optimized BLAS library based on GotoBLAS2
 LICENSE=       modified-bsd
 
-# Needs source patching and/or GCC_REQD for NetBSD
-# NetBSD gfortran framework needs improvements for this and other packages
+# Darwin has a .so/.dylib PLIST issue
 # Untested on other platforms
-ONLY_FOR_PLATFORM=     Linux-*-*
+ONLY_FOR_PLATFORM=     Linux-*-* NetBSD-*-*
 
 USE_LANGUAGES= c fortran
 USE_TOOLS+=    gmake perl:build
@@ -39,11 +38,6 @@
 
 TEST_TARGET=   tests
 
-# Work around CFLAGS breakage:
-# https://github.com/xianyi/OpenBLAS/issues/818
-MAKE_FLAGS+=   CFLAGS=${CFLAGS:Q}
-MAKE_FLAGS+=   CXXFLAGS=${CXXFLAGS:Q}
-MAKE_FLAGS+=   FFLAGS=${FFLAGS:Q}
 # Also set compilers explicitly, overriding Makefile.rule
 MAKE_FLAGS+=   CC=${CC:Q}
 MAKE_FLAGS+=   CXX=${CXX:Q}
@@ -92,7 +86,7 @@
 
 SUBST_CLASSES+=                arch
 SUBST_STAGE.arch=      pre-build
-SUBST_SED.arch+=       -e "s+(ARCH)+(ARCH_)+"
+SUBST_SED.arch+=       -e "s+(ARCH)+(ARCH_)+g"
 SUBST_FILES.arch+=     Makefile.tail
 SUBST_FILES.arch+=     driver/level3/Makefile
 SUBST_FILES.arch+=     driver/others/Makefile
@@ -101,11 +95,6 @@
 SUBST_FILES.arch+=     kernel/Makefile
 SUBST_FILES.arch+=     kernel/Makefile.L3
 SUBST_FILES.arch+=     lapack/laswp/Makefile
-SUBST_FILES.arch+=     lapack-netlib/SRC/Makefile
-SUBST_FILES.arch+=     lapack-netlib/SRC/VARIANTS/Makefile
-SUBST_FILES.arch+=     lapack-netlib/TESTING/MATGEN/Makefile
-SUBST_FILES.arch+=     lapack-netlib/LAPACKE/src/Makefile
-SUBST_FILES.arch+=     lapack-netlib/LAPACKE/utils/Makefile
 SUBST_FILES.arch+=     reference/Makefile
 SUBST_FILES.arch+=     Makefile.system
 
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/distinfo
--- a/math/openblas/distinfo    Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/distinfo    Thu Mar 25 23:22:35 2021 +0000
@@ -1,27 +1,26 @@
-$NetBSD: distinfo,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: distinfo,v 1.2 2021/03/25 23:22:35 thor Exp $
 
-SHA1 (openblas-0.3.7/OpenBLAS-0.3.7.tar.gz) = 6a79b36d1bf73584a513139806d226f9189d621e
-RMD160 (openblas-0.3.7/OpenBLAS-0.3.7.tar.gz) = 72103fa62efaa9ab77f80f9ae70b1417fa6f2122
-SHA512 (openblas-0.3.7/OpenBLAS-0.3.7.tar.gz) = 9c4898301c675471bbce2bb99b6bbe7c90724784fac06504416d4bd5da3cd4488f727b0a118c9a38ea342daac2af9e32597a847004241cc57de693b58b856262
-Size (openblas-0.3.7/OpenBLAS-0.3.7.tar.gz) = 11986592 bytes
-SHA1 (openblas-0.3.7/large.tgz) = a689e5b180595b40c5719b0f358b31b15b57a2db
-RMD160 (openblas-0.3.7/large.tgz) = 8010ff4002ef42cf22a9ee9345011d68fc27d855
-SHA512 (openblas-0.3.7/large.tgz) = e24db2b8a4253ccff9ca196815901c1fefd55e882f4fe1085715ac84b8f318e1842a91072130c17fdd144344ffc80233a77500da9349acb54e504b3935825965
-Size (openblas-0.3.7/large.tgz) = 2595 bytes
-SHA1 (openblas-0.3.7/timing.tgz) = fd47fc3f26d142a791df51e4a422a49662507252
-RMD160 (openblas-0.3.7/timing.tgz) = f0fe220e7ab611d4db8d8cab960361955e2ab093
-SHA512 (openblas-0.3.7/timing.tgz) = be0abfcfffdf0e118ed7e25a8451639833cf0ad6bb04d101bbe194c16f656b6ce509b2f76acf4ad626d1fb5b126bd5498cfea262f2946c2d077751112a2906af
-Size (openblas-0.3.7/timing.tgz) = 1059485 bytes
-SHA1 (patch-Makefile) = 6029076c34765e53a26617fb4bd36b56ba413f1b
-SHA1 (patch-Makefile.install) = 08c80677f8040623eaf5277cf92b5f5969fb4a07
-SHA1 (patch-Makefile.system) = d9dec776fb0d2919850506f682f3623b68751c90
+SHA1 (openblas-0.3.10/OpenBLAS-0.3.10.tar.gz) = cbe3fdd0e6ee235debc611d76976dac62f3ddc1c
+RMD160 (openblas-0.3.10/OpenBLAS-0.3.10.tar.gz) = 031ed30a7934655dcbeb26d9d71f8e9ec3094a55
+SHA512 (openblas-0.3.10/OpenBLAS-0.3.10.tar.gz) = 64a5f983b2f6e02cdb6e0f14433498cc5daa1ccfb49246f7a2dcd38f9982fa608f2abea069fe0e35012af8c1441c43d1f6418eaccd40795f5002fed1c36ce05d
+Size (openblas-0.3.10/OpenBLAS-0.3.10.tar.gz) = 12246979 bytes
+SHA1 (openblas-0.3.10/large.tgz) = a689e5b180595b40c5719b0f358b31b15b57a2db
+RMD160 (openblas-0.3.10/large.tgz) = 8010ff4002ef42cf22a9ee9345011d68fc27d855
+SHA512 (openblas-0.3.10/large.tgz) = e24db2b8a4253ccff9ca196815901c1fefd55e882f4fe1085715ac84b8f318e1842a91072130c17fdd144344ffc80233a77500da9349acb54e504b3935825965
+Size (openblas-0.3.10/large.tgz) = 2595 bytes
+SHA1 (openblas-0.3.10/timing.tgz) = fd47fc3f26d142a791df51e4a422a49662507252
+RMD160 (openblas-0.3.10/timing.tgz) = f0fe220e7ab611d4db8d8cab960361955e2ab093
+SHA512 (openblas-0.3.10/timing.tgz) = be0abfcfffdf0e118ed7e25a8451639833cf0ad6bb04d101bbe194c16f656b6ce509b2f76acf4ad626d1fb5b126bd5498cfea262f2946c2d077751112a2906af
+Size (openblas-0.3.10/timing.tgz) = 1059485 bytes
+SHA1 (patch-Makefile) = 91690ebbbe3acc0c4339120c752dfa22952db9eb
+SHA1 (patch-Makefile.install) = 8d4320114f66dd6fabaec94c9710ebc5b7b49d39
+SHA1 (patch-Makefile.system) = 4a0267b3181230cae4575041070fc30186355e0a
 SHA1 (patch-c_check) = c5990809434a259399c75e660aad5abe83899548
 SHA1 (patch-common__arm.h) = f08ec61bee8317daac267e90a79f46097b3431c9
 SHA1 (patch-cpuid__arm.c) = 20f95cede90cbe548c0cd09ed2e3d37d1d4aeabd
 SHA1 (patch-cpuid__arm64.c) = bbeb7222b32ec821511a6798fc27ff7269700662
 SHA1 (patch-cpuid_ia64.c) = 39649319b8c0a37b8d494e3c03b1ddb6fb616603
-SHA1 (patch-exports+Makefile) = 973016eae339d014d9f6f146e1e934793eb76145
+SHA1 (patch-exports+Makefile) = 03f5b3cc41d215a961bb4d1dd197d72f8ddaadbc
 SHA1 (patch-f_check) = 9162d6a31f96c6af5aada82f6e78cf0385384215
-SHA1 (patch-getarch.c) = 3d0ea5b989c6402d9e2f03a6cc2de848f06ca16d
+SHA1 (patch-getarch.c) = 0cf098b7203586206df95b24d1e95b0b5b9fd500
 SHA1 (patch-interface__ztrmv.c) = 6038946f8fb9542e680178ece2bd0d0d5853baad
-SHA1 (patch-utest_Makefile) = e6f816dfd5b905db93a1a963d86ae3afbeed81d3
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/patches/patch-Makefile
--- a/math/openblas/patches/patch-Makefile      Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/patches/patch-Makefile      Thu Mar 25 23:22:35 2021 +0000
@@ -1,18 +1,18 @@
-$NetBSD: patch-Makefile,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: patch-Makefile,v 1.2 2021/03/25 23:22:35 thor Exp $
 
 Remove special library names.
 
---- Makefile.orig      2019-08-11 21:23:27.000000000 +0000
+--- Makefile.orig      2020-06-14 20:03:04.000000000 +0000
 +++ Makefile
-@@ -100,7 +100,6 @@ ifneq ($(NO_SHARED), 1)
- ifeq ($(OSNAME), $(filter $(OSNAME),Linux SunOS Android Haiku))
+@@ -115,7 +115,6 @@ ifneq ($(NO_SHARED), 1)
+ ifeq ($(OSNAME), $(filter $(OSNAME),Linux SunOS Android Haiku FreeBSD DragonFly))
        @$(MAKE) -C exports so
        @ln -fs $(LIBSONAME) $(LIBPREFIX).so
 -      @ln -fs $(LIBSONAME) $(LIBPREFIX).so.$(MAJOR_VERSION)
  endif
- ifeq ($(OSNAME), $(filter $(OSNAME),FreeBSD OpenBSD NetBSD DragonFly))
+ ifeq ($(OSNAME), $(filter $(OSNAME),OpenBSD NetBSD))
        @$(MAKE) -C exports so
-@@ -108,8 +107,6 @@ ifeq ($(OSNAME), $(filter $(OSNAME),Free
+@@ -123,8 +122,6 @@ ifeq ($(OSNAME), $(filter $(OSNAME),Open
  endif
  ifeq ($(OSNAME), Darwin)
        @$(MAKE) -C exports dyn
@@ -21,7 +21,7 @@
  endif
  ifeq ($(OSNAME), WINNT)
        @$(MAKE) -C exports dll
-@@ -146,7 +143,6 @@ ifeq ($(NO_SHARED), 1)
+@@ -161,7 +158,6 @@ ifeq ($(NO_SHARED), 1)
        $(error OpenBLAS: neither static nor shared are enabled.)
  endif
  endif
@@ -29,7 +29,7 @@
        @for d in $(SUBDIRS) ; \
        do if test -d $$d; then \
          $(MAKE) -C $$d $(@F) || exit 1 ; \
-@@ -180,7 +176,6 @@ endif
+@@ -195,7 +191,6 @@ endif
  prof : prof_blas prof_lapack
  
  prof_blas :
@@ -37,7 +37,7 @@
        for d in $(SUBDIRS) ; \
        do if test -d $$d; then \
          $(MAKE) -C $$d prof || exit 1 ; \
-@@ -191,7 +186,6 @@ ifeq ($(DYNAMIC_ARCH), 1)
+@@ -206,7 +201,6 @@ ifeq ($(DYNAMIC_ARCH), 1)
  endif
  
  blas :
@@ -45,7 +45,7 @@
        for d in $(BLASDIRS) ; \
        do if test -d $$d; then \
          $(MAKE) -C $$d libs || exit 1 ; \
-@@ -199,7 +193,6 @@ blas :
+@@ -214,7 +208,6 @@ blas :
        done
  
  hpl :
@@ -53,7 +53,7 @@
        for d in $(BLASDIRS) ../laswp exports ; \
        do if test -d $$d; then \
          $(MAKE) -C $$d $(@F) || exit 1 ; \
-@@ -213,7 +206,6 @@ ifeq ($(DYNAMIC_ARCH), 1)
+@@ -228,7 +221,6 @@ ifeq ($(DYNAMIC_ARCH), 1)
  endif
  
  hpl_p :
@@ -61,12 +61,3 @@
        for d in $(SUBDIRS) ../laswp exports ; \
        do if test -d $$d; then \
          $(MAKE) -C $$d $(@F) || exit 1 ; \
-@@ -255,7 +247,7 @@ ifeq ($(NOFORTRAN), $(filter 0,$(NOFORTR
-       -@echo "LOADOPTS    = $(FFLAGS) $(EXTRALIB)" >> $(NETLIB_LAPACK_DIR)/make.inc
-       -@echo "CC          = $(CC)" >> $(NETLIB_LAPACK_DIR)/make.inc
-       -@echo "override CFLAGS      = $(LAPACK_CFLAGS)" >> $(NETLIB_LAPACK_DIR)/make.inc
--      -@echo "override ARCH        = $(AR)" >> $(NETLIB_LAPACK_DIR)/make.inc
-+      -@echo "override ARCH_        = $(AR)" >> $(NETLIB_LAPACK_DIR)/make.inc
-       -@echo "ARCHFLAGS   = $(ARFLAGS) -ru" >> $(NETLIB_LAPACK_DIR)/make.inc
-       -@echo "RANLIB      = $(RANLIB)" >> $(NETLIB_LAPACK_DIR)/make.inc
-       -@echo "LAPACKLIB   = ../$(LIBNAME)" >> $(NETLIB_LAPACK_DIR)/make.inc
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/patches/patch-Makefile.install
--- a/math/openblas/patches/patch-Makefile.install      Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/patches/patch-Makefile.install      Thu Mar 25 23:22:35 2021 +0000
@@ -1,10 +1,10 @@
-$NetBSD: patch-Makefile.install,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: patch-Makefile.install,v 1.2 2021/03/25 23:22:35 thor Exp $
 
 Second part of removing the special library names.
 
---- Makefile.install.orig      2019-08-11 21:23:27.000000000 +0000
+--- Makefile.install.orig      2020-06-14 20:03:04.000000000 +0000
 +++ Makefile.install
-@@ -61,8 +61,6 @@ endif
+@@ -62,8 +62,6 @@ endif
  ifneq ($(NO_STATIC),1)
        @echo Copying the static library to $(DESTDIR)$(OPENBLAS_LIBRARY_DIR)
        @install -pm644 $(LIBNAME) "$(DESTDIR)$(OPENBLAS_LIBRARY_DIR)"
@@ -13,8 +13,8 @@
  endif
  #for install shared library
  ifneq ($(NO_SHARED),1)
-@@ -70,8 +68,7 @@ ifneq ($(NO_SHARED),1)
- ifeq ($(OSNAME), $(filter $(OSNAME),Linux SunOS Android Haiku))
+@@ -71,8 +69,7 @@ ifneq ($(NO_SHARED),1)
+ ifeq ($(OSNAME), $(filter $(OSNAME),Linux SunOS Android Haiku FreeBSD DragonFly))
        @install -pm755 $(LIBSONAME) "$(DESTDIR)$(OPENBLAS_LIBRARY_DIR)"
        @cd "$(DESTDIR)$(OPENBLAS_LIBRARY_DIR)" ; \
 -      ln -fs $(LIBSONAME) $(LIBPREFIX).so ; \
@@ -22,8 +22,8 @@
 +      ln -fs $(LIBSONAME) $(LIBPREFIX).so
  endif
  
- ifeq ($(OSNAME), $(filter $(OSNAME),FreeBSD OpenBSD NetBSD DragonFly))
-@@ -110,16 +107,13 @@ endif
+ ifeq ($(OSNAME), $(filter $(OSNAME),OpenBSD NetBSD))
+@@ -112,16 +109,13 @@ endif
  ifneq ($(NO_STATIC),1)
        @echo Copying the static library to $(DESTDIR)$(OPENBLAS_LIBRARY_DIR)
        @installbsd -c -m 644 $(LIBNAME) "$(DESTDIR)$(OPENBLAS_LIBRARY_DIR)"
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/patches/patch-Makefile.system
--- a/math/openblas/patches/patch-Makefile.system       Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/patches/patch-Makefile.system       Thu Mar 25 23:22:35 2021 +0000
@@ -1,11 +1,11 @@
-$NetBSD: patch-Makefile.system,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: patch-Makefile.system,v 1.2 2021/03/25 23:22:35 thor Exp $
 
 Fully control the library name via LIBNAMESUFFIX
 And a bit of ARCH_
 
---- Makefile.system.orig       2019-08-11 21:23:27.000000000 +0000
+--- Makefile.system.orig       2020-06-14 20:03:04.000000000 +0000
 +++ Makefile.system
-@@ -1242,31 +1242,15 @@ ifndef LIBSUFFIX
+@@ -1326,31 +1326,15 @@ ifndef LIBSUFFIX
  LIBSUFFIX = a
  endif
  
@@ -41,7 +41,7 @@
  endif
  LIBDYNNAME   = $(LIBNAME:.$(LIBSUFFIX)=.dylib)
  LIBDEFNAME   = $(LIBNAME:.$(LIBSUFFIX)=.def)
-@@ -1297,7 +1281,7 @@ LIB_COMPONENTS = CBLAS
+@@ -1381,7 +1365,7 @@ LIB_COMPONENTS = CBLAS
  endif
  
  export OSNAME
@@ -49,4 +49,4 @@
 +export ARCH_
  export CORE
  export LIBCORE
- export PGCPATH
+ export __BYTE_ORDER__
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/patches/patch-exports+Makefile
--- a/math/openblas/patches/patch-exports+Makefile      Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/patches/patch-exports+Makefile      Thu Mar 25 23:22:35 2021 +0000
@@ -1,18 +1,10 @@
-$NetBSD: patch-exports+Makefile,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: patch-exports+Makefile,v 1.2 2021/03/25 23:22:35 thor Exp $
 
 Improve dynamic lib naming
 
---- exports/Makefile.orig      2019-08-11 21:23:27.000000000 +0000
+--- exports/Makefile.orig      2020-06-14 20:03:04.000000000 +0000
 +++ exports/Makefile
-@@ -173,6 +173,7 @@ endif
- #http://stackoverflow.com/questions/7656425/makefile-ifeq-logical-or
- ifeq ($(OSNAME), $(filter $(OSNAME),FreeBSD OpenBSD NetBSD DragonFly))
- 
-+EXTRALIB += -lgfortran
- so : ../$(LIBSONAME)
- 
- ifeq (, $(SYMBOLPREFIX)$(SYMBOLSUFFIX))
-@@ -184,6 +185,7 @@ else
+@@ -192,6 +192,7 @@ else
  endif
        $(CC) $(CFLAGS) $(LDFLAGS)  -shared -o ../$(LIBSONAME) \
        -Wl,--whole-archive $< -Wl,--no-whole-archive \
diff -r a38f0d0fda5d -r 7307d7dc4203 math/openblas/patches/patch-getarch.c
--- a/math/openblas/patches/patch-getarch.c     Thu Mar 25 22:09:24 2021 +0000
+++ b/math/openblas/patches/patch-getarch.c     Thu Mar 25 23:22:35 2021 +0000
@@ -1,11 +1,11 @@
-$NetBSD: patch-getarch.c,v 1.1 2020/11/05 16:31:45 bacon Exp $
+$NetBSD: patch-getarch.c,v 1.2 2021/03/25 23:22:35 thor Exp $
 
 Do not override our parallel make choice.
 
---- getarch.c.orig     2018-12-31 23:09:59.000000000 +0100
-+++ getarch.c  2019-03-22 17:24:40.477260427 +0100
-@@ -1236,19 +1236,6 @@
- #endif


Home | Main Index | Thread Index | Old Index