Accepting request 476773 from home:jmoellers:branches:science:HPC

OBS-URL: https://build.opensuse.org/request/show/476773
OBS-URL: https://build.opensuse.org/package/show/science:HPC/libpsm2?expand=0&rev=3
This commit is contained in:
Philipp Thomas 2017-03-06 08:35:11 +00:00 committed by Git OBS Bridge
parent 5479e0229f
commit db5c71f4d5
6 changed files with 62 additions and 21 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:9ccaee3b735be70cfa33414f5f6d24fd79169d114171ef84f95dc38c7350aee4
size 389465

3
libpsm2-10.3.1.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:06c44796ce820f07e4bc2600b27f150d7f66ca576381b8ff98b2022b701c4b0f
size 374718

View File

@ -0,0 +1,34 @@
Index: libpsm2-10.3.1/psm_context.c
===================================================================
--- libpsm2-10.3.1.orig/psm_context.c
+++ libpsm2-10.3.1/psm_context.c
@@ -146,6 +146,19 @@ static int psmi_get_envvar(const char *e
return 0;
}
+static inline
+uint8_t
+calc_hash(void *ptr, size_t nbytes)
+{
+ uint8_t *ucp = (uint8_t *) ptr;
+ uint8_t hash = 0;
+
+ while (nbytes--)
+ hash ^= *ucp++;
+
+ return hash;
+}
+
static
psm2_error_t
psmi_compute_start_and_end_unit(psmi_context_t *context,long unit_param,
@@ -180,8 +193,7 @@ psmi_compute_start_and_end_unit(psmi_con
/* else, we are going to being looking at:
(a hash of the job key plus the local rank id ) mod nunits. */
- for (i=0;i < sizeof(job_key);i++)
- hashedjk ^= job_key[i];
+ hashedjk = calc_hash(job_key, sizeof(psm2_uuid_t));
*unit_start = (psmi_get_envvar("MPI_LOCALRANKID") + hashedjk) % nunits;
if (*unit_start > 0)
*unit_end = *unit_start - 1;

View File

@ -1,31 +1,26 @@
From b231e55f53c1257c76ecb0805f5fb380de230b2d Mon Sep 17 00:00:00 2001
From: Nirmoy Das <ndas@suse.de>
Date: Thu, 9 Jun 2016 14:15:39 +0200
Subject: [PATCH] use exported variable for version and release
---
Makefile | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
Index: Makefile
Index: libpsm2-10.3.1/Makefile
===================================================================
--- Makefile.orig 2016-12-06 16:12:45.891907761 +0100
+++ Makefile 2016-12-06 16:15:03.063168224 +0100
@@ -135,15 +135,11 @@ endif
--- libpsm2-10.3.1.orig/Makefile
+++ libpsm2-10.3.1/Makefile
@@ -138,7 +138,7 @@ endif
export LIBPSM2_COMPAT_CONF_DIR
# The desired version number comes from the most recent tag starting with "v"
-VERSION := $(shell if [ -e .git ] ; then git describe --tags --abbrev=0 --match='v*' | sed -e 's/^v//' -e 's/-/_/'; else echo "version" ; fi)
+VERSION ?= $(shell if [ -e .git ] ; then git describe --tags --abbrev=0 --match='v*' | sed -e 's/^v//' -e 's/-/_/'; else echo "version" ; fi)
#
# If we have a file called 'rpm_release_extension' (as on github),
# we take the release extension number from this file
@@ -162,11 +162,7 @@ endif
# The desired release number comes the git describe following the version which
# is the number of commits since the version tag was planted suffixed by the g<commitid>
-RELEASE := $(shell if [ -f RELEASE ]; then cat RELEASE;\
ifndef RELEASE
-RELEASE := $(shell if [ -f rpm_release_extension ]; then cat rpm_release_extension;\
- elif [ -e .git ] ; then git describe --tags --long --match='v*' | \
- sed -e 's/v[0-9.]*-\(.*\)/\1/' -e 's/-/_/' | \
- sed -e 's/_g.*$$//'; \
- else echo "release" ; fi)
+RELEASE ?= $(shell if [ -e .git ] ; then git describe --tags --long --match='v*' | sed -e 's/v[0-9.]*-\(.*\)/\1/' -e 's/-/_/' | sed -e 's/_g.*$$//'; else echo "release" ; fi)
endif
DIST_SHA := ${shell if [ -e .git ] ; then git log -n1 --pretty=format:%H ; \
else echo DIST_SHA ; fi}

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Fri Mar 3 13:45:39 UTC 2017 - josef.moellers@suse.com
- Update to new version 10.3.1, mainly bug fixes
Intel has not made available any changelog.
As Intel's source did not compile, replaced calculation of a hash
value by an inline function.
(bnc#1024057, libpsm2-calc-checksum.patch, FATE#321472)
-------------------------------------------------------------------
Tue Dec 6 16:01:36 CET 2016 - pth@suse.de

View File

@ -22,7 +22,7 @@
%define psm_so 2
Name: libpsm2
Version: 10.2.2
Version: 10.3.1
Release: 0
Summary: Intel PSM Libraries
License: BSD-2-Clause or GPL-2.0
@ -32,6 +32,7 @@ Source: %{name}-%{version}.tar.gz
Source1: libpsm2.changelog
Patch2: libpsm2-use_RPM_OPT_FLAGS.patch
Patch3: libpsm2-use-exported-variable-for-version-and-release.patch
Patch4: libpsm2-calc-checksum.patch
BuildRequires: libuuid-devel
BuildRequires: pkg-config
BuildRequires: udev
@ -81,7 +82,9 @@ Support for MPIs linked with PSM versions < 2
%prep
%setup -q -n %{name}-%{version}
%patch2
%patch3
%patch3 -p1
%patch4 -p1
cp %{S:1} ChangeLog
%build