Accepting request 342709 from Base:System
- Add zero_filesize_segment.patch to fix testcase on s390x - Fixes bnc#919680 - Patches already included mainline and now deleted: D libhugetlbfs-2.18-restrict-is-a-reserved-word.patch D fix_plt_extrasz_always_returning_0_on_ppc64le.patch - Latest version from git next branch OBS-URL: https://build.opensuse.org/request/show/342709 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libhugetlbfs?expand=0&rev=42
This commit is contained in:
commit
d7918c1949
14
_service
Normal file
14
_service
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
<services>
|
||||||
|
<service name="tar_scm" mode="disabled">
|
||||||
|
<param name="url">git://github.com/libhugetlbfs/libhugetlbfs.git</param>
|
||||||
|
<param name="scm">git</param>
|
||||||
|
<param name="filename">libhugetlbfs</param>
|
||||||
|
<param name="version">2.18.99</param>
|
||||||
|
<param name="revision">next</param>
|
||||||
|
</service>
|
||||||
|
<service name="recompress" mode="disabled">
|
||||||
|
<param name="file">*.tar</param>
|
||||||
|
<param name="compression">xz</param>
|
||||||
|
</service>
|
||||||
|
<service name="set_version" mode="disabled" />
|
||||||
|
</services>
|
@ -1,39 +0,0 @@
|
|||||||
Subject: fix plt_extrasz() always returning 0 on ppc64le
|
|
||||||
From: Signed-off-by: Jan Stancek <jstancek@redhat.com>
|
|
||||||
|
|
||||||
libhugetlbfs.so is not linked with elf64lppc.o on ppc64le,
|
|
||||||
which makes plt_extrasz() always return 0.
|
|
||||||
|
|
||||||
This is causing failures (SIGSEGV) in these tests:
|
|
||||||
HUGETLB_ELFMAP=W linkhuge_rw (16M: 64):
|
|
||||||
HUGETLB_ELFMAP=RW linkhuge_rw (16M: 64):
|
|
||||||
HUGETLB_SHARE=0 HUGETLB_ELFMAP=W linkhuge_rw (16M: 64):
|
|
||||||
HUGETLB_SHARE=1 HUGETLB_ELFMAP=W linkhuge_rw (16M: 64):
|
|
||||||
HUGETLB_SHARE=0 HUGETLB_ELFMAP=RW linkhuge_rw (16M: 64):
|
|
||||||
HUGETLB_SHARE=1 HUGETLB_ELFMAP=RW linkhuge_rw (16M: 64):
|
|
||||||
as they miss some already initialized data when performing
|
|
||||||
"minimal copy" in get_extracopy().
|
|
||||||
|
|
||||||
This patch links also elf64lppc.o, which defines powerpc
|
|
||||||
specific version of plt_extrasz().
|
|
||||||
|
|
||||||
Signed-off-by: Jan Stancek <jstancek@redhat.com>
|
|
||||||
---
|
|
||||||
Makefile | 3 +++
|
|
||||||
1 files changed, 3 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/Makefile b/Makefile
|
|
||||||
index b24bd0f..8cf469f 100644
|
|
||||||
--- a/Makefile
|
|
||||||
+++ b/Makefile
|
|
||||||
@@ -142,6 +142,9 @@ endif
|
|
||||||
ifeq ($(ELF64),elf64ppc)
|
|
||||||
LIBOBJS64 += obj64/$(ELF64).o
|
|
||||||
endif
|
|
||||||
+ifeq ($(ELF64),elf64lppc)
|
|
||||||
+LIBOBJS64 += obj64/$(ELF64).o
|
|
||||||
+endif
|
|
||||||
LIBOBJS32 += $(LIBOBJS:%=obj32/%)
|
|
||||||
LIBOBJS64 += $(LIBOBJS:%=obj64/%)
|
|
||||||
|
|
||||||
-- 1.7.1
|
|
@ -1,22 +0,0 @@
|
|||||||
diff -up libhugetlbfs-2.18/hugeutils.c.orig libhugetlbfs-2.18/hugeutils.c
|
|
||||||
--- libhugetlbfs-2.18/hugeutils.c.orig 2015-06-24 00:23:09.374535669 +0200
|
|
||||||
+++ libhugetlbfs-2.18/hugeutils.c 2015-06-24 00:23:45.536534148 +0200
|
|
||||||
@@ -301,14 +301,14 @@ void hugetlbfs_setup_env()
|
|
||||||
|
|
||||||
env = getenv("HUGETLB_RESTRICT_EXE");
|
|
||||||
if (env) {
|
|
||||||
- char *p, *tok, *exe, buf[MAX_EXE+1], restrict[MAX_EXE];
|
|
||||||
+ char *p, *tok, *exe, buf[MAX_EXE+1], restriction[MAX_EXE];
|
|
||||||
int found = 0;
|
|
||||||
|
|
||||||
exe = get_exe_name(buf, sizeof buf);
|
|
||||||
DEBUG("Found HUGETLB_RESTRICT_EXE, this exe is \"%s\"\n", exe);
|
|
||||||
- strncpy(restrict, env, sizeof restrict);
|
|
||||||
- restrict[sizeof(restrict)-1] = 0;
|
|
||||||
- for (p = restrict; (tok = strtok(p, ":")) != NULL; p = NULL) {
|
|
||||||
+ strncpy(restriction, env, sizeof restriction);
|
|
||||||
+ restriction[sizeof(restriction)-1] = 0;
|
|
||||||
+ for (p = restriction; (tok = strtok(p, ":")) != NULL; p = NULL) {
|
|
||||||
DEBUG(" ...check exe match for \"%s\"\n", tok);
|
|
||||||
if (strcmp(tok, exe) == 0) {
|
|
||||||
found = 1;
|
|
3
libhugetlbfs-2.18.99.tar.xz
Normal file
3
libhugetlbfs-2.18.99.tar.xz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:bb9f56779d9af2aade386146b26fc76eede22a58fe6009d9ae936108564e88a6
|
||||||
|
size 143708
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:8c6ed5e884988e0c879a3705455ece153cf805f69cb9c710334e2711acbb6a06
|
|
||||||
size 181275
|
|
@ -1,3 +1,17 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Nov 6 13:10:03 UTC 2015 - fvogt@suse.com
|
||||||
|
|
||||||
|
- Add zero_filesize_segment.patch to fix testcase on s390x
|
||||||
|
- Fixes bnc#919680
|
||||||
|
- Patches already included mainline and now deleted:
|
||||||
|
D libhugetlbfs-2.18-restrict-is-a-reserved-word.patch
|
||||||
|
D fix_plt_extrasz_always_returning_0_on_ppc64le.patch
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Nov 6 12:01:55 UTC 2015 - fvogt@suse.com
|
||||||
|
|
||||||
|
- Latest version from git next branch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Jun 23 22:35:32 UTC 2015 - antoine.belvire@laposte.net
|
Tue Jun 23 22:35:32 UTC 2015 - antoine.belvire@laposte.net
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package libhugetlbfs
|
# spec file for package libhugetlbfs
|
||||||
#
|
#
|
||||||
# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -16,27 +16,15 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%define my_make_flags V=1 CFLAGS="%{optflags} -fPIC" BUILDTYPE=NATIVEONLY PREFIX=%{_prefix} LIBDIR32=%{_libdir} DESTDIR=%{buildroot}
|
||||||
Name: libhugetlbfs
|
Name: libhugetlbfs
|
||||||
|
Version: 2.18.99
|
||||||
%if 0%{?suse_version} > 1140
|
Release: 0
|
||||||
BuildRequires: glibc-devel-static
|
|
||||||
%endif
|
|
||||||
BuildRequires: doxygen
|
|
||||||
|
|
||||||
Summary: Hugetlbfs helper library
|
Summary: Hugetlbfs helper library
|
||||||
License: LGPL-2.1+
|
License: LGPL-2.1+
|
||||||
Group: Development/Libraries/Other
|
Group: Development/Libraries/Other
|
||||||
# bug437293
|
Url: https://github.com/libhugetlbfs/libhugetlbfs
|
||||||
%ifarch ppc64
|
Source0: %{name}-%{version}.tar.xz
|
||||||
Obsoletes: libhugetlbfs-64bit
|
|
||||||
%endif
|
|
||||||
#
|
|
||||||
Version: 2.18
|
|
||||||
Release: 0
|
|
||||||
Url: http://libhugetlbfs.sourceforge.net/
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
||||||
%define my_make_flags V=1 CFLAGS="$RPM_OPT_FLAGS -fPIC" BUILDTYPE=NATIVEONLY PREFIX=/usr LIBDIR32=%{_libdir} DESTDIR=$RPM_BUILD_ROOT
|
|
||||||
Source0: http://downloads.sourceforge.net/project/libhugetlbfs/libhugetlbfs/%{version}/libhugetlbfs-%{version}.tar.gz
|
|
||||||
Source1: baselibs.conf
|
Source1: baselibs.conf
|
||||||
Patch2: libhugetlbfs.s390.patch
|
Patch2: libhugetlbfs.s390.patch
|
||||||
Patch4: libhugetlbfs.tests-malloc.patch
|
Patch4: libhugetlbfs.tests-malloc.patch
|
||||||
@ -44,22 +32,34 @@ Patch7: libhugetlbfs_ia64_fix_missing_test.patch
|
|||||||
Patch8: libhugetlbfs_fix_tests.patch
|
Patch8: libhugetlbfs_fix_tests.patch
|
||||||
Patch13: ignore-perl-modules.diff
|
Patch13: ignore-perl-modules.diff
|
||||||
Patch14: disable-rw-on-non-ldscripts.diff
|
Patch14: disable-rw-on-non-ldscripts.diff
|
||||||
Patch15: fix_plt_extrasz_always_returning_0_on_ppc64le.patch
|
Patch15: zero_filesize_segment.patch
|
||||||
# PATCH-FIX-UPSTREAM libhugetlbfs-2.18-restrict-is-a-reserved-word.patch -- Fix compilation with GCC 5 (and C99/C11 in general)
|
BuildRequires: doxygen
|
||||||
Patch16: libhugetlbfs-2.18-restrict-is-a-reserved-word.patch
|
BuildRequires: glibc-devel-static
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
# bug437293
|
||||||
|
%ifarch ppc64
|
||||||
|
Obsoletes: libhugetlbfs-64bit
|
||||||
|
%endif
|
||||||
|
|
||||||
%description
|
%description
|
||||||
The libhugetlbfs package interacts with the Linux hugetlbfs to
|
The libhugetlbfs package interacts with the Linux hugetlbfs to
|
||||||
make large pages available to applications in a transparent manner.
|
make large pages available to applications in a transparent manner.
|
||||||
|
|
||||||
%package libhugetlb-devel
|
%package devel
|
||||||
Summary: Devel package for libhugetlb
|
Summary: Devel package for libhugetlb
|
||||||
Group: Development/Libraries/Other
|
Group: Development/Libraries/Other
|
||||||
Requires: libhugetlbfs
|
Requires: libhugetlbfs
|
||||||
|
|
||||||
%description libhugetlb-devel
|
%description devel
|
||||||
Devel package, header and static library, of libhugetlb
|
Devel package, header and static library, of libhugetlb
|
||||||
|
|
||||||
|
%package tests
|
||||||
|
Summary: Tests for package libhugetlb
|
||||||
|
Group: Development/Libraries/Other
|
||||||
|
|
||||||
|
%description tests
|
||||||
|
The testsuite for libhugetlb. Binaries can be found in %{_libdir}/libhugetlbfs/tests
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
@ -69,37 +69,36 @@ Devel package, header and static library, of libhugetlb
|
|||||||
%patch13
|
%patch13
|
||||||
%patch14
|
%patch14
|
||||||
%patch15 -p1
|
%patch15 -p1
|
||||||
%patch16 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
echo %{version} > version
|
||||||
make %{my_make_flags}
|
make %{my_make_flags}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
make %{my_make_flags} install
|
make %{my_make_flags} install
|
||||||
make \
|
make %{my_make_flags} install-tests
|
||||||
%ifarch sparc sparcv9
|
mkdir -p %{buildroot}%{_prefix}/include
|
||||||
CC32="gcc" CC64="" NATIVEONLY=1 \
|
cp -avL hugetlbfs.h %{buildroot}%{_prefix}/include
|
||||||
%endif
|
chmod 644 %{buildroot}%{_libdir}/*.a
|
||||||
%{my_make_flags} install
|
[ ! -f %{buildroot}%{_libdir}/libhugetlbfs/tests/obj64/dummy.ldscript ] || chmod -f a-x %{buildroot}%{_libdir}/libhugetlbfs/tests/obj64/dummy.ldscript
|
||||||
mkdir -p $RPM_BUILD_ROOT/usr/include
|
|
||||||
cp -avL hugetlbfs.h $RPM_BUILD_ROOT/usr/include
|
|
||||||
chmod 644 $RPM_BUILD_ROOT%{_libdir}/*.a
|
|
||||||
|
|
||||||
%clean
|
|
||||||
rm -rf $RPM_BUILD_ROOT
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
%doc LGPL-2.1 HOWTO README NEWS
|
%doc LGPL-2.1 HOWTO README NEWS
|
||||||
/usr/share/libhugetlbfs
|
%{_datadir}/libhugetlbfs
|
||||||
/usr/bin/*
|
%{_bindir}/*
|
||||||
%{_mandir}/man*/*.gz
|
%{_mandir}/man*/*.gz
|
||||||
%{_libdir}/libhugetlbfs_privutils.so
|
%{_libdir}/libhugetlbfs_privutils.so
|
||||||
%{_libdir}/libhugetlbfs.so
|
%{_libdir}/libhugetlbfs.so
|
||||||
|
|
||||||
%files libhugetlb-devel
|
%files devel
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
/usr/include/hugetlbfs.h
|
%{_includedir}/hugetlbfs.h
|
||||||
%{_libdir}/libhugetlbfs.a
|
%{_libdir}/libhugetlbfs.a
|
||||||
|
|
||||||
|
%files tests
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%dir %{_libdir}/libhugetlbfs
|
||||||
|
%{_libdir}/libhugetlbfs/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
38
zero_filesize_segment.patch
Normal file
38
zero_filesize_segment.patch
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
diff --git a/tests/Makefile b/tests/Makefile
|
||||||
|
index e2e1156..4daa5d1 100644
|
||||||
|
--- a/tests/Makefile
|
||||||
|
+++ b/tests/Makefile
|
||||||
|
@@ -39,6 +39,11 @@ LDLIBS = $(STATIC_LDLIBS) -ldl -lhugetlbfs_privutils
|
||||||
|
LDFLAGS32 = -L../obj32
|
||||||
|
LDFLAGS64 = -L../obj64
|
||||||
|
INSTALL = install
|
||||||
|
+ifeq ($(ARCH),s390x)
|
||||||
|
+ARCH_SUFFIX = .s390x
|
||||||
|
+else
|
||||||
|
+ARCH_SUFFIX =
|
||||||
|
+endif
|
||||||
|
|
||||||
|
TESTS = $(LIB_TESTS) $(NOLIB_TESTS) $(STRESS_TESTS) dummy.ldscript
|
||||||
|
ifdef ELF32
|
||||||
|
@@ -181,7 +186,7 @@ $(LDSCRIPT_TESTS:%=obj32/%): obj32/%: %.ld obj32/%.o obj32/testutils.o
|
||||||
|
@$(VECHO) LD32 "(preload test)" $@
|
||||||
|
$(CC32) $(LDFLAGS) $(LDFLAGS32) -o $@ -Lobj32 $^ $(LDLIBS) || cp $(BADTOOLCHAIN) $@
|
||||||
|
|
||||||
|
-$(LDSCRIPT_TESTS:%=obj64/%): obj64/%: %.ld obj64/%.o obj64/testutils.o
|
||||||
|
+$(LDSCRIPT_TESTS:%=obj64/%): obj64/%: %$(ARCH_SUFFIX).ld obj64/%.o obj64/testutils.o
|
||||||
|
@$(VECHO) LD64 "(preload test)" $@
|
||||||
|
$(CC64) $(LDFLAGS) $(LDFLAGS64) -o $@ -Lobj64 $^ $(LDLIBS) || cp $(BADTOOLCHAIN) $@
|
||||||
|
|
||||||
|
diff --git a/tests/zero_filesize_segment.s390x.ld b/tests/zero_filesize_segment.s390x.ld
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000..813a92f
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/tests/zero_filesize_segment.s390x.ld
|
||||||
|
@@ -0,0 +1,7 @@
|
||||||
|
+SECTIONS
|
||||||
|
+{
|
||||||
|
+ .empty (0x90000000) : {
|
||||||
|
+ __empty_segment = .;
|
||||||
|
+ . = . + 4;
|
||||||
|
+ }
|
||||||
|
+}
|
Loading…
Reference in New Issue
Block a user