From abde393a0cf6c07fd0eaf350438232db8d061fc7 Mon Sep 17 00:00:00 2001 From: CentOS Buildsys Date: May 12 2013 11:00:52 +0000 Subject: import libhugetlbfs-2.16-2.el7.src.rpm --- diff --git a/.libhugetlbfs.metadata b/.libhugetlbfs.metadata new file mode 100644 index 0000000..35c2a4d --- /dev/null +++ b/.libhugetlbfs.metadata @@ -0,0 +1 @@ +4dd1c44990d0d8d480419ba371928ab2e0bede7c SOURCES/libhugetlbfs-2.16.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 0e7897f..0000000 --- a/README.md +++ /dev/null @@ -1,5 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 - -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/libhugetlbfs-2.15-fortify.patch b/SOURCES/libhugetlbfs-2.15-fortify.patch new file mode 100644 index 0000000..0f89a2c --- /dev/null +++ b/SOURCES/libhugetlbfs-2.15-fortify.patch @@ -0,0 +1,12 @@ +diff -up libhugetlbfs-2.15/Makefile.fortify libhugetlbfs-2.15/Makefile +--- libhugetlbfs-2.15/Makefile.fortify 2012-12-12 11:33:54.725402249 +0100 ++++ libhugetlbfs-2.15/Makefile 2012-12-12 11:34:24.130531531 +0100 +@@ -30,7 +30,7 @@ INSTALL = install + LDFLAGS += -Wl,-z,noexecstack -ldl + CFLAGS ?= -O2 -g + CFLAGS += -Wall -fPIC +-CPPFLAGS += -D__LIBHUGETLBFS__ ++CPPFLAGS += -D__LIBHUGETLBFS__ -DFORTIFY_SOURCE + + ARCH = $(shell uname -m | sed -e s/i.86/i386/) + diff --git a/SOURCES/libhugetlbfs-2.16-s390.patch b/SOURCES/libhugetlbfs-2.16-s390.patch new file mode 100644 index 0000000..1523468 --- /dev/null +++ b/SOURCES/libhugetlbfs-2.16-s390.patch @@ -0,0 +1,32 @@ +diff -up libhugetlbfs-2.16/Makefile.s390 libhugetlbfs-2.16/Makefile +--- libhugetlbfs-2.16/Makefile.s390 2013-05-12 08:49:28.160883455 +0200 ++++ libhugetlbfs-2.16/Makefile 2013-05-12 08:49:39.586906994 +0200 +@@ -84,17 +84,26 @@ CFLAGS += -DNO_ELFLINK + else + ifeq ($(ARCH),s390x) + CC64 = gcc -m64 +-CC32 = gcc -m31 +-ELF32 = elf_s390 + ELF64 = elf64_s390 + TMPLIB64 = lib64 + TMPLIB32 = lib + CUSTOM_LDSCRIPTS = no ++ifneq ($(BUILDTYPE),NATIVEONLY) ++CC32 = gcc -m31 ++ELF32 = elf_s390 ++endif ++else ++ifeq ($(ARCH),s390) ++CC32 = gcc -m31 ++ELF32 = elf_s390 ++TMPLIB32 = lib ++CUSTOM_LDSCRIPTS = no + else + $(error "Unrecognized architecture ($(ARCH))") + endif + endif + endif ++endif + endif + endif + endif diff --git a/SPECS/libhugetlbfs.spec b/SPECS/libhugetlbfs.spec new file mode 100644 index 0000000..f22ecf5 --- /dev/null +++ b/SPECS/libhugetlbfs.spec @@ -0,0 +1,215 @@ +Name: libhugetlbfs +Version: 2.16 +Release: 2%{?dist} +Summary: A library which provides easy access to huge pages of memory +Group: System Environment/Libraries +License: LGPLv2+ +URL: http://libhugetlbfs.sourceforge.net/ +Source0: http://downloads.sourceforge.net/libhugetlbfs/%{name}-%{version}.tar.gz +Patch0: libhugetlbfs-2.16-s390.patch +Patch1: libhugetlbfs-2.15-fortify.patch +BuildRequires: glibc-devel +BuildRequires: glibc-static + +%define ldscriptdir %{_datadir}/%{name}/ldscripts + +%description +libhugetlbfs is a library which provides easy access to huge pages of memory. +It is a wrapper for the hugetlbfs file system. Applications can use huge pages +to fulfill malloc() requests without being recompiled by using LD_PRELOAD. +Alternatively, applications can be linked against libhugetlbfs without source +modifications to load BSS or BSS, data, and text segments into large pages. + +%package devel +Summary: Header files for libhugetlbfs +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} +%description devel +Contains header files for building with libhugetlbfs. + +%package utils +Summary: Userspace utilities for configuring the hugepage environment +Group: Applications/System +Requires: %{name} = %{version}-%{release} +%description utils +This packages contains a number of utilities that will help administrate the +use of huge pages on your system. hugeedit modifies binaries to set default +segment remapping behavior. hugectl sets environment variables for using huge +pages and then execs the target program. hugeadm gives easy access to huge page +pool size control. pagesize lists page sizes available on the machine. + +%prep +%setup -q -n %{name}-%{version} +%patch0 -p1 -b .s390 +%patch1 -p1 -b .fortify + +%build +# Parallel builds are not reliable +make BUILDTYPE=NATIVEONLY + +%install +make install PREFIX=%{_prefix} DESTDIR=$RPM_BUILD_ROOT LDSCRIPTDIR=%{ldscriptdir} BUILDTYPE=NATIVEONLY +make install-helper PREFIX=%{_prefix} DESTDIR=$RPM_BUILD_ROOT LDSCRIPTDIR=%{ldscriptdir} BUILDTYPE=NATIVEONLY +mkdir -p -m755 $RPM_BUILD_ROOT%{_sysconfdir}/security/limits.d +touch $RPM_BUILD_ROOT%{_sysconfdir}/security/limits.d/hugepages.conf + +# remove statically built libraries: +rm -f $RPM_BUILD_ROOT/%{_libdir}/*.a +# remove unused sbin directory +rm -fr $RPM_BUILD_ROOT/%{_sbindir}/ + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files +%{_libdir}/libhugetlbfs.so* +%{_datadir}/%{name}/ +%{_mandir}/man7/libhugetlbfs.7.gz +%ghost %config(noreplace) %{_sysconfdir}/security/limits.d/hugepages.conf +%exclude %{_libdir}/libhugetlbfs_privutils.so +%doc README HOWTO LGPL-2.1 NEWS + +%files devel +%{_includedir}/hugetlbfs.h +%{_mandir}/man3/getpagesizes.3.gz +%{_mandir}/man3/free_huge_pages.3.gz +%{_mandir}/man3/get_huge_pages.3.gz +%{_mandir}/man3/gethugepagesize.3.gz +%{_mandir}/man3/gethugepagesizes.3.gz +%{_mandir}/man3/free_hugepage_region.3.gz +%{_mandir}/man3/get_hugepage_region.3.gz +%{_mandir}/man3/hugetlbfs_find_path.3.gz +%{_mandir}/man3/hugetlbfs_find_path_for_size.3.gz +%{_mandir}/man3/hugetlbfs_test_path.3.gz +%{_mandir}/man3/hugetlbfs_unlinked_fd.3.gz +%{_mandir}/man3/hugetlbfs_unlinked_fd_for_size.3.gz + +%files utils +%{_bindir}/hugeedit +%{_bindir}/hugeadm +%{_bindir}/hugectl +%{_bindir}/pagesize +%{_bindir}/huge_page_setup_helper.py +%exclude %{_bindir}/cpupcstat +%exclude %{_bindir}/oprofile_map_events.pl +%exclude %{_bindir}/oprofile_start.sh +%{_mandir}/man8/hugeedit.8.gz +%{_mandir}/man8/hugectl.8.gz +%{_mandir}/man8/hugeadm.8.gz +%{_mandir}/man1/pagesize.1.gz +%{_mandir}/man1/ld.hugetlbfs.1.gz +%exclude %{_mandir}/man8/cpupcstat.8.gz +%exclude /usr/lib/perl5/TLBC + +%changelog +* Sun May 12 2013 Anton Arapov - 2.16-2 +- Fortify code +- Fix s390 build issues (#960107) + +* Mon Apr 29 2013 Peter Robinson - 2.16-1 +- Upstream 2.16 release (adds ARM support) + +* Thu Feb 14 2013 Fedora Release Engineering - 2.15-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Sat Dec 08 2012 Eric B Munson - 2.15 +- Update for upstream 2.15 release + +* Thu Jul 19 2012 Fedora Release Engineering - 2.13-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Sat Mar 24 2012 Eric B Munson +- Update for upstream 2.13 release + +* Wed Jul 20 2011 Eric B Munson +- Update for upstream 2.12 release + +* Tue Feb 08 2011 Fedora Release Engineering - 2.9-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Mon Apr 05 2010 Eric B Munson 2.8-1 +- Update for upstream 2.8 release + +* Wed Feb 10 2010 Eric B Munson 2.7-2 +- Include patch that fixes build on ppc + +* Tue Jan 05 2010 Eric B Munson 2.7-1 +- Update for upstream 2.7 release + +* Fri Oct 02 2009 Jarod Wilson 2.6-3 +- Add hopefully-about-to-be-merged-upstream hugeadm enhancements +- Add huge pages setup helper script, using new hugeadm enhancements + +* Thu Sep 03 2009 Nils Philippsen 2.6-2 +- fix building on s390x + +* Mon Aug 31 2009 Eric Munson 2.6-1 +- Updating for the libhugetlbfs-2.6 release + +* Fri Jul 24 2009 Fedora Release Engineering - 2.5-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Mon Jul 20 2009 Eric Munson 2.5-2 +- Update Group for -utils package to Applications/System + +* Tue Jun 30 2009 Eric Munson 2.5-1 +- Updating for the libhugetlbfs-2.5 release + +* Tue Jun 02 2009 Eric Munson 2.4-2 +- Adding patch to remove S390 32 bit build + +* Fri May 29 2009 Eric Munson 2.4-1 +- Updating for the libhugetlbfs-2.4 release + +* Wed Apr 15 2009 Eric Munson 2.3-1 +- Updating for the libhugetlbfs-2.3 release + +* Wed Feb 11 2009 Eric Munson 2.2-1 +- Updating for the libhugetlbfs-2.2 release + +* Fri Dec 19 2008 Eric Munson 2.1.2-1 +- Updating for libhugetlbfs-2.1.2 release + +* Fri Dec 19 2008 Eric Munson 2.1.1-1 +- Updating for libhugetlbfs-2.1.1 release + +* Thu Dec 18 2008 Josh Boyer 2.1-2 +- Fix broken dependency caused by just dropping -test + subpackage + +* Thu Oct 16 2008 Eric Munson 2.1-1 +- Updating for libhuge-2.1 release +- Adding -devel and -utils subpackages for various utilities + and devel files. + +* Wed May 14 2008 Eric Munson 1.3-1 +- Updating for libhuge-1.3 release + +* Tue Mar 25 2008 Eric Munson 1.2-1 +- Removing test rpm target, and excluding test files + +* Mon Mar 26 2007 Steve Fox - 1.1-1 +- New release (1.1) +- Fix directory ownership + +* Wed Aug 30 2006 Steve Fox - 0.20060825-1 +- New release (1.0-preview4) +- patch0 (Makefile-ldscript.diff) merged upstream + +* Tue Jul 25 2006 Steve Fox - 0.20060706-4 +- Bump for build system + +* Tue Jul 25 2006 Steve Fox - 0.20060706-3 +- Don't use parallel build as it has random failures + +* Thu Jul 20 2006 Steve Fox - 0.20060706-2 +- Fix the Makefile so that the ld.hugetlbfs script doesn't store the + DESTDIR in the path to the ldscripts dir + +* Fri Jul 7 2006 Steve Fox - 0.20060706-1 +- New release which includes a fix for the syscall macro removal in the + Rawhide kernels + +* Thu Jun 29 2006 Steve Fox - 0.20060628-1 +- First Fedora package