commit: 5b06cf931df7aa97fa04ceef87a4108237485024 Author: François Bissey <frp.bissey <AT> gmail <DOT> com> AuthorDate: Wed Aug 23 05:04:25 2017 +0000 Commit: Benda XU <heroxbd <AT> gentoo <DOT> org> CommitDate: Fri Aug 25 06:08:24 2017 +0000 URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=5b06cf93
sci-libs/openblas: Bump to 0.2.20. Clean up after fixing multilib wrapper issue. Use https to make repoman happy. Closes: https://github.com/gentoo/sci/pull/800 Bug: 617312 Package-Manager: Portage-2.3.6, Repoman-2.3.3 ...-openblas_config_header_same_between_ABIs.patch | 21 --- .../openblas/files/openblas-0.2.20-non-glibc.patch | 144 +++++++++++++++++++++ ...las-0.2.14.ebuild => openblas-0.2.14-r1.ebuild} | 18 +-- ...las-0.2.15.ebuild => openblas-0.2.15-r1.ebuild} | 18 +-- ...las-0.2.19.ebuild => openblas-0.2.19-r1.ebuild} | 10 +- ...enblas-0.2.19.ebuild => openblas-0.2.20.ebuild} | 13 +- sci-libs/openblas/openblas-9999.ebuild | 16 +-- 7 files changed, 156 insertions(+), 84 deletions(-) diff --git a/sci-libs/openblas/files/openblas-0.2.11-openblas_config_header_same_between_ABIs.patch b/sci-libs/openblas/files/openblas-0.2.11-openblas_config_header_same_between_ABIs.patch deleted file mode 100644 index 7a851116c..000000000 --- a/sci-libs/openblas/files/openblas-0.2.11-openblas_config_header_same_between_ABIs.patch +++ /dev/null @@ -1,21 +0,0 @@ ---- openblas-0.2.11-orig/getarch_2nd.c 2014-08-18 13:16:14.000000000 +1000 -+++ openblas-0.2.11/getarch_2nd.c 2014-09-01 23:44:07.070560148 +1000 -@@ -64,13 +64,13 @@ - - - if ((argc >= 2) && (*argv[1] == '1')) { -- printf("#define SLOCAL_BUFFER_SIZE\t%ld\n", (SGEMM_DEFAULT_Q * SGEMM_DEFAULT_UNROLL_N * 4 * 1 * sizeof(float))); -- printf("#define DLOCAL_BUFFER_SIZE\t%ld\n", (DGEMM_DEFAULT_Q * DGEMM_DEFAULT_UNROLL_N * 2 * 1 * sizeof(double))); -- printf("#define CLOCAL_BUFFER_SIZE\t%ld\n", (CGEMM_DEFAULT_Q * CGEMM_DEFAULT_UNROLL_N * 4 * 2 * sizeof(float))); -- printf("#define ZLOCAL_BUFFER_SIZE\t%ld\n", (ZGEMM_DEFAULT_Q * ZGEMM_DEFAULT_UNROLL_N * 2 * 2 * sizeof(double))); -+ printf("#define SLOCAL_BUFFER_SIZE\t(SGEMM_DEFAULT_Q*SGEMM_DEFAULT_UNROLL_N*4*1*sizeof(float))\n"); -+ printf("#define DLOCAL_BUFFER_SIZE\t(DGEMM_DEFAULT_Q*DGEMM_DEFAULT_UNROLL_N*2*1*sizeof(double))\n"); -+ printf("#define CLOCAL_BUFFER_SIZE\t(CGEMM_DEFAULT_Q*CGEMM_DEFAULT_UNROLL_N*4*2*sizeof(float))\n"); -+ printf("#define ZLOCAL_BUFFER_SIZE\t(ZGEMM_DEFAULT_Q*ZGEMM_DEFAULT_UNROLL_N*2*2*sizeof(double))\n"); - - #ifdef USE64BITINT -- printf("#define USE64BITINT\n"); -+/* printf("#define USE64BITINT\n"); */ - #endif - printf("#define GEMM_MULTITHREAD_THRESHOLD\t%ld\n", (long int)GEMM_MULTITHREAD_THRESHOLD); - } diff --git a/sci-libs/openblas/files/openblas-0.2.20-non-glibc.patch b/sci-libs/openblas/files/openblas-0.2.20-non-glibc.patch new file mode 100644 index 000000000..afde85585 --- /dev/null +++ b/sci-libs/openblas/files/openblas-0.2.20-non-glibc.patch @@ -0,0 +1,144 @@ +From 480e697681763cf31f015eb1ebad49a495f562c5 Mon Sep 17 00:00:00 2001 +From: Martin Kroeker <[email protected]> +Date: Mon, 24 Jul 2017 16:17:50 +0200 +Subject: [PATCH] Revert "Honor cgroup/cpuset limits when enumerating cpus" + (#1246) + +--- + driver/others/init.c | 49 +++++-------------------------------------------- + driver/others/memory.c | 37 ------------------------------------- + 2 files changed, 5 insertions(+), 81 deletions(-) + +diff --git a/driver/others/init.c b/driver/others/init.c +index 4c75d72e4..3e6176967 100644 +--- a/driver/others/init.c ++++ b/driver/others/init.c +@@ -778,11 +778,11 @@ static int initialized = 0; + void gotoblas_affinity_init(void) { + + int cpu, num_avail; +-#ifndef USE_OPENMP ++#ifndef USE_OPENMP + cpu_set_t cpu_mask; + #endif + int i; +- ++ + if (initialized) return; + + initialized = 1; +@@ -826,54 +826,15 @@ void gotoblas_affinity_init(void) { + common -> shmid = pshmid; + + if (common -> magic != SH_MAGIC) { +- cpu_set_t *cpusetp; +- int nums; +- int ret; +- + #ifdef DEBUG + fprintf(stderr, "Shared Memory Initialization.\n"); + #endif + + //returns the number of processors which are currently online +- +- nums = sysconf(_SC_NPROCESSORS_CONF); +- +-#if !defined(__GLIBC_PREREQ) || !__GLIBC_PREREQ(2, 3) +- common->num_procs = nums; +-#elif __GLIBC_PREREQ(2, 7) +- cpusetp = CPU_ALLOC(nums); +- if (cpusetp == NULL) { +- common->num_procs = nums; +- } else { +- size_t size; +- size = CPU_ALLOC_SIZE(nums); +- ret = sched_getaffinity(0,size,cpusetp); +- if (ret!=0) +- common->num_procs = nums; +- else +- common->num_procs = CPU_COUNT_S(size,cpusetp); +- } +- CPU_FREE(cpusetp); +-#else +- ret = sched_getaffinity(0,sizeof(cpu_set_t), cpusetp); +- if (ret!=0) { +- common->num_procs = nums; +- } else { +-#if !__GLIBC_PREREQ(2, 6) +- int i; +- int n = 0; +- for (i=0;i<nums;i++) +- if (CPU_ISSET(i,cpusetp)) n++; +- common->num_procs = n; +- } +-#else +- common->num_procs = CPU_COUNT(sizeof(cpu_set_t),cpusetp); +-#endif +- +-#endif ++ common -> num_procs = sysconf(_SC_NPROCESSORS_CONF);; + + if(common -> num_procs > MAX_CPUS) { +- fprintf(stderr, "\nOpenBLAS Warning : The number of CPU/Cores(%d) is beyond the limit(%d). Terminated.\n", common->num_procs, MAX_CPUS); ++ fprintf(stderr, "\nOpenBLAS Warining : The number of CPU/Cores(%d) is beyond the limit(%d). Terminated.\n", common->num_procs, MAX_CPUS); + exit(1); + } + +@@ -886,7 +847,7 @@ void gotoblas_affinity_init(void) { + if (common -> num_nodes > 1) numa_mapping(); + + common -> final_num_procs = 0; +- for(i = 0; i < common -> avail_count; i++) common -> final_num_procs += rcount(common -> avail[i]) + 1; //Make the max cpu number. ++ for(i = 0; i < common -> avail_count; i++) common -> final_num_procs += rcount(common -> avail[i]) + 1; //Make the max cpu number. + + for (cpu = 0; cpu < common -> final_num_procs; cpu ++) common -> cpu_use[cpu] = 0; + +diff --git a/driver/others/memory.c b/driver/others/memory.c +index 38d063715..916950315 100644 +--- a/driver/others/memory.c ++++ b/driver/others/memory.c +@@ -175,44 +175,7 @@ int get_num_procs(void); + #else + int get_num_procs(void) { + static int nums = 0; +-cpu_set_t *cpusetp; +-size_t size; +-int ret; +-int i,n; +- + if (!nums) nums = sysconf(_SC_NPROCESSORS_CONF); +-#if !defined(OS_LINUX) +- return nums; +-#endif +- +-#if !defined(__GLIBC_PREREQ) +- return nums; +-#endif +-#if !__GLIBC_PREREQ(2, 3) +- return nums; +-#endif +- +-#if !__GLIBC_PREREQ(2, 7) +- ret = sched_getaffinity(0,sizeof(cpu_set_t), cpusetp); +- if (ret!=0) return nums; +- n=0; +-#if !__GLIBC_PREREQ(2, 6) +- for (i=0;i<nums;i++) +- if (CPU_ISSET(i,cpusetp)) n++; +- nums=n; +-#else +- nums = CPU_COUNT(sizeof(cpu_set_t),cpusetp); +-#endif +- return nums; +-#endif +- +- cpusetp = CPU_ALLOC(nums); +- if (cpusetp == NULL) return nums; +- size = CPU_ALLOC_SIZE(nums); +- ret = sched_getaffinity(0,size,cpusetp); +- if (ret!=0) return nums; +- nums = CPU_COUNT_S(size,cpusetp); +- CPU_FREE(cpusetp); + return nums; + } + #endif diff --git a/sci-libs/openblas/openblas-0.2.14.ebuild b/sci-libs/openblas/openblas-0.2.14-r1.ebuild similarity index 86% rename from sci-libs/openblas/openblas-0.2.14.ebuild rename to sci-libs/openblas/openblas-0.2.14-r1.ebuild index 6dc5fd3c2..453be881f 100644 --- a/sci-libs/openblas/openblas-0.2.14.ebuild +++ b/sci-libs/openblas/openblas-0.2.14-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2016 Gentoo Foundation +# Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -10,8 +10,8 @@ inherit alternatives-2 eutils multilib numeric numeric-int64-multibuild DESCRIPTION="Optimized BLAS library based on GotoBLAS2" HOMEPAGE="http://xianyi.github.com/OpenBLAS/" SRC_URI=" - http://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz - http://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" + https://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz + https://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" LICENSE="BSD" SLOT="0" @@ -23,8 +23,6 @@ DEPEND="${RDEPEND} virtual/pkgconfig" MULTILIB_WRAPPED_HEADERS=( - /usr/include/openblas/cblas.h - /usr/include/openblas/f77blas.h /usr/include/openblas/openblas_config.h ) @@ -115,16 +113,6 @@ src_compile() { emake libs ${openblas_flags} NO_SHARED=1 NEED_PIC= mv libopenblas* libs/ || die fi - # Fix Bug 524612 - [science overlay] sci-libs/openblas-0.2.11 - Assembler messages: - # ../kernel/x86_64/gemm_kernel_8x4_barcelona.S:451: Error: missing ')' - # The problem is applying this patch in src_prepare() causes build failures on - # assembler code as the assembler does not understand sizeof(float). So - # delay applying the patch until after building the libraries. - epatch "${FILESDIR}/${PN}-0.2.11-openblas_config_header_same_between_ABIs.patch" - rm -f config.h config_last.h || die - # Note: prints this spurious warning: make: Nothing to be done for 'config.h'. - emake config.h - cp config.h config_last.h || die mv libs/libopenblas* . || die } diff --git a/sci-libs/openblas/openblas-0.2.15.ebuild b/sci-libs/openblas/openblas-0.2.15-r1.ebuild similarity index 86% rename from sci-libs/openblas/openblas-0.2.15.ebuild rename to sci-libs/openblas/openblas-0.2.15-r1.ebuild index c419d8974..64e2fb9c1 100644 --- a/sci-libs/openblas/openblas-0.2.15.ebuild +++ b/sci-libs/openblas/openblas-0.2.15-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2016 Gentoo Foundation +# Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -10,8 +10,8 @@ inherit alternatives-2 eutils multilib numeric numeric-int64-multibuild DESCRIPTION="Optimized BLAS library based on GotoBLAS2" HOMEPAGE="http://xianyi.github.com/OpenBLAS/" SRC_URI=" - http://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz - http://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" + https://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz + https://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" LICENSE="BSD" SLOT="0" @@ -23,8 +23,6 @@ DEPEND="${RDEPEND} virtual/pkgconfig" MULTILIB_WRAPPED_HEADERS=( - /usr/include/openblas/cblas.h - /usr/include/openblas/f77blas.h /usr/include/openblas/openblas_config.h ) @@ -116,16 +114,6 @@ src_compile() { emake libs ${openblas_flags} NO_SHARED=1 NEED_PIC= mv libopenblas* libs/ || die fi - # Fix Bug 524612 - [science overlay] sci-libs/openblas-0.2.11 - Assembler messages: - # ../kernel/x86_64/gemm_kernel_8x4_barcelona.S:451: Error: missing ')' - # The problem is applying this patch in src_prepare() causes build failures on - # assembler code as the assembler does not understand sizeof(float). So - # delay applying the patch until after building the libraries. - epatch "${FILESDIR}/${PN}-0.2.11-openblas_config_header_same_between_ABIs.patch" - rm -f config.h config_last.h || die - # Note: prints this spurious warning: make: Nothing to be done for 'config.h'. - emake config.h - cp config.h config_last.h || die mv libs/libopenblas* . || die } diff --git a/sci-libs/openblas/openblas-0.2.19.ebuild b/sci-libs/openblas/openblas-0.2.19-r1.ebuild similarity index 94% copy from sci-libs/openblas/openblas-0.2.19.ebuild copy to sci-libs/openblas/openblas-0.2.19-r1.ebuild index c44cd74c9..81ed705fb 100644 --- a/sci-libs/openblas/openblas-0.2.19.ebuild +++ b/sci-libs/openblas/openblas-0.2.19-r1.ebuild @@ -9,8 +9,8 @@ inherit alternatives-2 eutils multilib numeric numeric-int64-multibuild DESCRIPTION="Optimized BLAS library based on GotoBLAS2" HOMEPAGE="http://xianyi.github.com/OpenBLAS/" -SRC_URI="http://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz - http://sagetrac.lipn.univ-paris13.fr/sage/${PN}-0.2.19-clang-3.9.patch" +SRC_URI="https://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz + https://sagetrac.lipn.univ-paris13.fr/sage/${PN}-0.2.19-clang-3.9.patch" LICENSE="BSD" SLOT="0" @@ -22,8 +22,6 @@ DEPEND="${RDEPEND} virtual/pkgconfig" MULTILIB_WRAPPED_HEADERS=( - /usr/include/openblas/cblas.h - /usr/include/openblas/f77blas.h /usr/include/openblas/openblas_config.h ) @@ -121,10 +119,6 @@ src_compile() { emake libs ${openblas_flags} NO_SHARED=1 NEED_PIC= mv libopenblas* libs/ || die fi - rm -f config.h config_last.h || die - # Note: prints this spurious warning: make: Nothing to be done for 'config.h'. - emake config.h - cp config.h config_last.h || die mv libs/libopenblas* . || die } diff --git a/sci-libs/openblas/openblas-0.2.19.ebuild b/sci-libs/openblas/openblas-0.2.20.ebuild similarity index 91% rename from sci-libs/openblas/openblas-0.2.19.ebuild rename to sci-libs/openblas/openblas-0.2.20.ebuild index c44cd74c9..4686f4890 100644 --- a/sci-libs/openblas/openblas-0.2.19.ebuild +++ b/sci-libs/openblas/openblas-0.2.20.ebuild @@ -9,8 +9,7 @@ inherit alternatives-2 eutils multilib numeric numeric-int64-multibuild DESCRIPTION="Optimized BLAS library based on GotoBLAS2" HOMEPAGE="http://xianyi.github.com/OpenBLAS/" -SRC_URI="http://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz - http://sagetrac.lipn.univ-paris13.fr/sage/${PN}-0.2.19-clang-3.9.patch" +SRC_URI="https://github.com/xianyi/OpenBLAS/tarball/v${PV} -> ${P}.tar.gz" LICENSE="BSD" SLOT="0" @@ -22,15 +21,11 @@ DEPEND="${RDEPEND} virtual/pkgconfig" MULTILIB_WRAPPED_HEADERS=( - /usr/include/openblas/cblas.h - /usr/include/openblas/f77blas.h /usr/include/openblas/openblas_config.h ) PATCHES=( - "${DISTDIR}"/${PN}-0.2.19-clang-3.9.patch - "${FILESDIR}"/${PN}-0.2.19-MAKE.patch - "${FILESDIR}"/${PN}-0.2.19-utest_ldflags.patch + "${FILESDIR}"/${PN}-0.2.20-non-glibc.patch ) get_openblas_flags() { @@ -121,10 +116,6 @@ src_compile() { emake libs ${openblas_flags} NO_SHARED=1 NEED_PIC= mv libopenblas* libs/ || die fi - rm -f config.h config_last.h || die - # Note: prints this spurious warning: make: Nothing to be done for 'config.h'. - emake config.h - cp config.h config_last.h || die mv libs/libopenblas* . || die } diff --git a/sci-libs/openblas/openblas-9999.ebuild b/sci-libs/openblas/openblas-9999.ebuild index 5e6becd38..e4ed2800f 100644 --- a/sci-libs/openblas/openblas-9999.ebuild +++ b/sci-libs/openblas/openblas-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2016 Gentoo Foundation +# Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -9,7 +9,7 @@ inherit alternatives-2 eutils git-r3 multilib numeric numeric-int64-multibuild DESCRIPTION="Optimized BLAS library based on GotoBLAS2" HOMEPAGE="http://xianyi.github.com/OpenBLAS/" -SRC_URI="http://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" +SRC_URI="https://dev.gentoo.org/~gienah/distfiles/${PN}-0.2.11-gentoo.patch" EGIT_REPO_URI="https://github.com/xianyi/OpenBLAS.git" EGIT_BRANCH="develop" @@ -23,8 +23,6 @@ DEPEND="${RDEPEND} virtual/pkgconfig" MULTILIB_WRAPPED_HEADERS=( - /usr/include/openblas/cblas.h - /usr/include/openblas/f77blas.h /usr/include/openblas/openblas_config.h ) @@ -109,16 +107,6 @@ src_compile() { emake libs ${openblas_flags} NO_SHARED=1 NEED_PIC= mv libopenblas* libs/ || die fi - # Fix Bug 524612 - [science overlay] sci-libs/openblas-0.2.11 - Assembler messages: - # ../kernel/x86_64/gemm_kernel_8x4_barcelona.S:451: Error: missing ')' - # The problem is applying this patch in src_prepare() causes build failures on - # assembler code as the assembler does not understand sizeof(float). So - # delay applying the patch until after building the libraries. - epatch "${FILESDIR}/${PN}-0.2.11-openblas_config_header_same_between_ABIs.patch" - rm -f config.h config_last.h || die - # Note: prints this spurious warning: make: Nothing to be done for 'config.h'. - emake config.h - cp config.h config_last.h || die mv libs/libopenblas* . || die }
