[openblas] 02/02: Add support for s390x.
Sébastien Villemot
sebastien at debian.org
Tue Sep 19 10:24:11 UTC 2017
This is an automated email from the git hooks/post-receive script.
sebastien pushed a commit to branch master
in repository openblas.
commit b3b65cf8c7b86a919a49f5a2700d01b66e55e603
Author: Sébastien Villemot <sebastien at debian.org>
Date: Tue Sep 19 12:23:09 2017 +0200
Add support for s390x.
New patch force-zarch.patch introduced to force the generic build.
Gbp-Dch: Full
Closes: #875618
---
debian/control | 4 +--
debian/patches/force-zarch.patch | 55 ++++++++++++++++++++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 11 +++++---
4 files changed, 65 insertions(+), 6 deletions(-)
diff --git a/debian/control b/debian/control
index 2d8076e..5527809 100644
--- a/debian/control
+++ b/debian/control
@@ -13,7 +13,7 @@ Vcs-Git: https://anonscm.debian.org/git/debian-science/packages/openblas.git
Homepage: https://github.com/xianyi/OpenBLAS
Package: libopenblas-base
-Architecture: amd64 arm64 armhf i386 powerpc ppc64el ppc64 kfreebsd-i386 kfreebsd-amd64 mips64el sparc64
+Architecture: amd64 arm64 armhf i386 powerpc ppc64el ppc64 kfreebsd-i386 kfreebsd-amd64 mips64el sparc64 s390x
Multi-Arch: same
Section: libs
Depends: ${shlibs:Depends},
@@ -37,7 +37,7 @@ Description: Optimized BLAS (linear algebra) library (shared library)
"Building Optimized OpenBLAS Packages on your ARCH" in README.Debian
Package: libopenblas-dev
-Architecture: amd64 arm64 armhf i386 powerpc ppc64el ppc64 kfreebsd-i386 kfreebsd-amd64 mips64el sparc64
+Architecture: amd64 arm64 armhf i386 powerpc ppc64el ppc64 kfreebsd-i386 kfreebsd-amd64 mips64el sparc64 s390x
Multi-Arch: same
Section: libdevel
Depends: libopenblas-base (= ${binary:Version}),
diff --git a/debian/patches/force-zarch.patch b/debian/patches/force-zarch.patch
new file mode 100644
index 0000000..4c8266f
--- /dev/null
+++ b/debian/patches/force-zarch.patch
@@ -0,0 +1,55 @@
+Description: Add support for TARGET=ZARCH_GENERIC and TARGET=Z13
+ Needed in order to build a generic enough package (using TARGET=ZARCH_GENERIC).
+Author: Sébastien Villemot <sebastien at debian.org>
+Bug-Debian: https://bugs.debian.org/875618
+Forwarded: https://github.com/xianyi/OpenBLAS/pull/1308
+Last-Update: 2017-09-19
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/getarch.c
++++ b/getarch.c
+@@ -137,6 +137,8 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ /* #define FORCE_ITANIUM2 */
+ /* #define FORCE_SPARC */
+ /* #define FORCE_SPARCV7 */
++/* #define FORCE_ZARCH_GENERIC */
++/* #define FORCE_Z13 */
+ /* #define FORCE_GENERIC */
+
+ #ifdef FORCE_P2
+@@ -964,6 +966,26 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ #else
+ #endif
+
++#ifdef FORCE_ZARCH_GENERIC
++#define FORCE
++#define ARCHITECTURE "ZARCH"
++#define SUBARCHITECTURE "ZARCH_GENERIC"
++#define ARCHCONFIG "-DZARCH_GENERIC " \
++ "-DDTB_DEFAULT_ENTRIES=64"
++#define LIBNAME "zarch_generic"
++#define CORENAME "ZARCH_GENERIC"
++#endif
++
++#ifdef FORCE_Z13
++#define FORCE
++#define ARCHITECTURE "ZARCH"
++#define SUBARCHITECTURE "Z13"
++#define ARCHCONFIG "-DZ13 " \
++ "-DDTB_DEFAULT_ENTRIES=64"
++#define LIBNAME "z13"
++#define CORENAME "Z13"
++#endif
++
+ #ifndef FORCE
+
+ #if defined(__powerpc__) || defined(__powerpc) || defined(powerpc) || \
+--- a/TargetList.txt
++++ b/TargetList.txt
+@@ -85,3 +85,6 @@ VULCAN
+ THUNDERX
+ THUNDERX2T99
+
++9.System Z:
++ZARCH_GENERIC
++Z13
diff --git a/debian/patches/series b/debian/patches/series
index c0b5dd9..ba43956 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,3 +5,4 @@ no-embedded-lapack.patch
shared-blas-lapack.patch
matgen-symbols-not-included.patch
order-files.patch
+force-zarch.patch
diff --git a/debian/rules b/debian/rules
index e9d29f2..a91e3b0 100755
--- a/debian/rules
+++ b/debian/rules
@@ -17,6 +17,9 @@ ifneq (,$(findstring $(DEB_HOST_ARCH),$(ENABLE_DYNAMIC_ARCHS)))
GENERIC_OPTIONS += DYNAMIC_ARCH=1
endif
+# For other archs, there is no dynamic arch selection. To avoid selecting a
+# target based on the buildd hardware, we enforce a generic-enough target.
+
# We cannot use the ARMv7 profile on armhf, because it requires a 32-register FP unit.
# See kernel/arm/KERNEL.ARMv7: it loads some *_vfpv3.S files, which use 32 registers.
# Also, it FTBFS if GCC flag -mvfpv3 is removed (see arm-gcc-flags.patch), because GCC
@@ -31,14 +34,10 @@ ifeq ($(DEB_HOST_ARCH),arm64)
GENERIC_OPTIONS += TARGET=ARMV8
endif
-# There is no dynamic arch selection on PowerPC. To avoid selecting a
-# target based on the buildd hardware, we enforce a generic-enough
-# target.
ifeq ($(DEB_HOST_ARCH),powerpc)
GENERIC_OPTIONS += TARGET=PPCG4
endif
-# Same for mips64el
ifeq ($(DEB_HOST_ARCH),mips64el)
GENERIC_OPTIONS += TARGET=SICORTEX
endif
@@ -51,6 +50,10 @@ ifeq ($(DEB_HOST_ARCH),sparc64)
GENERIC_OPTIONS += TARGET=SPARC
endif
+ifeq ($(DEB_HOST_ARCH),s390x)
+ GENERIC_OPTIONS += TARGET=ZARCH_GENERIC
+endif
+
ifeq (,$(filter custom,$(DEB_BUILD_OPTIONS)))
# Generic package
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/openblas.git
More information about the debian-science-commits
mailing list