123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450 |
- #
- # Important for %{ix86}:
- # This rpm has to be build on a CPU with sse2 support like Pentium 4 !
- #
- %ifarch %{ix86}
- %define SSE2 1
- %else
- %define SSE2 0
- %endif
- # Don't you want to build a libraries using SSE2?
- %{?_without_sse2%define SSE2 0}
- %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
- Summary: A GNU arbitrary precision library.
- Summary(ja): GNU 多倍長演算ライブラリ
- Name: gmp
- Version: 5.1.3
- Release: 2%{?_dist_release}
- URL: http://gmplib.org/
- Source: ftp://ftp.gnu.org/pub/gnu/gmp/gmp-%{version}.tar.xz
- Source2: gmp.h
- Source3: gmp-mparam.h
- Patch0: gmp-4.0.1-s390.patch
- License: LGPLv3+
- Group: System Environment/Libraries
- BuildRoot: %{_tmppath}/%{name}-%{version}-root
- BuildRequires: autoconf libtool
- Obsoletes: gmp4
- Vendor: Project Vine
- Distribution: Vine Linux
- Packager: inagaki, kenta
- %description
- The gmp package contains GNU MP, a library for arbitrary precision
- arithmetic, signed integers operations, rational numbers and floating
- point numbers. GNU MP is designed for speed, for both small and very
- large operands. GNU MP is fast because it uses fullwords as the basic
- arithmetic type, it uses fast algorithms, it carefully optimizes
- assembly code for many CPUs' most common inner loops, and it generally
- emphasizes speed over simplicity/elegance in its operations.
- Install the gmp package if you need a fast arbitrary precision
- library.
- %package devel
- Summary: Development tools for the GNU MP arbitrary precision library.
- Group: Development/Libraries
- Requires: %{name} = %{version}-%{release}
- Requires(post): /sbin/install-info
- Requires(preun): /sbin/install-info
- #Obsoletes: gmp4-devel
- %description devel
- The libraries, header files and documentation for using the GNU MP
- arbitrary precision library in applications.
- If you want to develop applications which will use the GNU MP library,
- you'll need to install the gmp-devel package. You'll also need to
- install the gmp package.
- %package static
- Summary: Development tools for the GNU MP arbitrary precision library
- Group: Development/Libraries
- Requires: %{name}-devel = %{version}-%{release}
- %description static
- The static libraries for using the GNU MP arbitrary precision library
- in applications.
- %package -n compat32-%{name}
- Summary: A GNU arbitrary precision library.
- Group: System Environment/Libraries
- Requires: %{name} = %{version}-%{release}
- %description -n compat32-%{name}
- The gmp package contains GNU MP, a library for arbitrary precision
- arithmetic, signed integers operations, rational numbers and floating
- point numbers. GNU MP is designed for speed, for both small and very
- large operands. GNU MP is fast because it uses fullwords as the basic
- arithmetic type, it uses fast algorithms, it carefully optimizes
- assembly code for many CPUs' most common inner loops, and it generally
- emphasizes speed over simplicity/elegance in its operations.
- Install the gmp package if you need a fast arbitrary precision
- library.
- %package -n compat32-%{name}-devel
- Summary: Development tools for the GNU MP arbitrary precision library.
- Group: Development/Libraries
- Requires: compat32-%{name} = %{version}-%{release}
- Requires: %{name}-devel = %{version}-%{release}
- %description -n compat32-%{name}-devel
- The libraries, header files and documentation for using the GNU MP
- arbitrary precision library in applications.
- If you want to develop applications which will use the GNU MP library,
- you'll need to install the gmp-devel package. You'll also need to
- install the gmp package.
- %package -n compat32-%{name}-static
- Summary: Development tools for the GNU MP arbitrary precision library
- Group: Development/Libraries
- Requires: compat32-%{name}-devel = %{version}-%{release}
- %description -n compat32-%{name}-static
- The static libraries for using the GNU MP arbitrary precision library
- in applications.
- %prep
- %setup -q
- %patch0 -p1
- %build
- autoreconf -if
- if as --help | grep -q execstack; then
- # the object files do not require an executable stack
- export CCAS="gcc -c -Wa,--noexecstack"
- fi
- mkdir base
- cd base
- ln -s ../configure .
- #%configure --enable-mpbsd --enable-cxx
- %configure --enable-cxx
- perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool
- export LD_LIBRARY_PATH=`pwd`/.libs
- make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}
- cd ..
- %if %{SSE2}
- %define _host pentium4-vine-linux
- mkdir build-sse2
- cd build-sse2
- ln -s ../configure .
- CFLAGS="%{optflags} -march=pentium4"
- #%configure --enable-mpbsd --enable-cxx
- %configure --enable-cxx
- perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool
- export LD_LIBRARY_PATH=`pwd`/.libs
- make %{?_smp_mflags}
- unset CFLAGS
- cd ..
- %endif
- %install
- [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
- cd base
- export LD_LIBRARY_PATH=`pwd`/.libs
- make install DESTDIR=$RPM_BUILD_ROOT
- install -m 644 gmp-mparam.h ${RPM_BUILD_ROOT}%{_includedir}
- rm -f $RPM_BUILD_ROOT%{_libdir}/lib{gmp,mp,gmpxx}.la
- rm -f $RPM_BUILD_ROOT%{_infodir}/dir
- /sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}
- ln -sf libgmpxx.so.4 $RPM_BUILD_ROOT%{_libdir}/libgmpxx.so
- cd ..
- %if %{SSE2}
- cd build-sse2
- export LD_LIBRARY_PATH=`pwd`/.libs
- mkdir $RPM_BUILD_ROOT%{_libdir}/sse2
- install -m 755 .libs/libgmp.so.*.* $RPM_BUILD_ROOT%{_libdir}/sse2
- cp -a .libs/libgmp.so.[^.]* $RPM_BUILD_ROOT%{_libdir}/sse2
- chmod 755 $RPM_BUILD_ROOT%{_libdir}/sse2/libgmp.so.[^.]*
- install -m 755 .libs/libgmpxx.so.*.* $RPM_BUILD_ROOT%{_libdir}/sse2
- cp -a .libs/libgmpxx.so.? $RPM_BUILD_ROOT%{_libdir}/sse2
- chmod 755 $RPM_BUILD_ROOT%{_libdir}/sse2/libgmpxx.so.?
- cd ..
- %endif
- # Rename gmp.h to gmp-<arch>.h and gmp-mparam.h to gmp-mparam-<arch>.h to
- # avoid file conflicts on multilib systems and install wrapper include files
- # gmp.h and gmp-mparam-<arch>.h
- basearch=%{_arch}
- # always use i386 for iX86
- %ifarch %{ix86}
- basearch=i386
- %endif
- # always use arm for arm*
- %ifarch %{arm}
- basearch=arm
- %endif
- # Rename files and install wrappers
- mv %{buildroot}/%{_includedir}/gmp.h %{buildroot}/%{_includedir}/gmp-${basearch}.h
- install -m644 %{SOURCE2} %{buildroot}/%{_includedir}/gmp.h
- mv %{buildroot}/%{_includedir}/gmp-mparam.h %{buildroot}/%{_includedir}/gmp-mparam-${basearch}.h
- install -m644 %{SOURCE3} %{buildroot}/%{_includedir}/gmp-mparam.h
- %check
- %ifnarch ppc
- cd base
- export LD_LIBRARY_PATH=`pwd`/.libs
- make %{?_smp_mflags} check
- cd ..
- %endif
- %if %{SSE2}
- cd build-sse2
- export LD_LIBRARY_PATH=`pwd`/.libs
- make %{?_smp_mflags} check
- cd ..
- %endif
- %post -p /sbin/ldconfig
- %postun -p /sbin/ldconfig
- %post devel
- /sbin/install-info %{_infodir}/gmp.info.gz %{_infodir}/dir
- %preun devel
- if [ "$1" = 0 ]; then
- /sbin/install-info --delete %{_infodir}/gmp.info.gz %{_infodir}/dir
- fi
- %post -n compat32-%{name} -p /sbin/ldconfig
- %postun -n compat32-%{name} -p /sbin/ldconfig
- %clean
- [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
- %files
- %defattr(-,root,root,-)
- %doc COPYING COPYING.LIB NEWS README
- %{_libdir}/libgmp.so.*
- %{_libdir}/libgmpxx.so.*
- %if %{SSE2}
- %{_libdir}/sse2/*
- %endif
- %files devel
- %defattr(-,root,root,-)
- %{_libdir}/libgmp.so
- %{_libdir}/libgmpxx.so
- #{_libdir}/libmpfr.a
- %{_includedir}/*.h
- %{_infodir}/gmp.info*
- #{_infodir}/mpfr.info*
- %files static
- %defattr(-,root,root,-)
- %doc README
- %{_libdir}/libgmp.a
- %{_libdir}/libgmpxx.a
- # compat32
- %if %{build_compat32}
- %files -n compat32-%{name}
- %defattr(-,root,root,-)
- %{_libdir}/libgmp.so.*
- %{_libdir}/libgmpxx.so.*
- %if %{SSE2}
- %{_libdir}/sse2/*
- %endif
- %files -n compat32-%{name}-devel
- %defattr(-,root,root,-)
- %{_libdir}/libgmp.so
- %{_libdir}/libgmpxx.so
- #{_libdir}/libmpfr.a
- %files -n compat32-%{name}-static
- %defattr(-,root,root,-)
- %doc README
- %{_libdir}/libgmp.a
- %{_libdir}/libgmpxx.a
- %endif
- %changelog
- * Tue Jan 14 2014 NAKAMURA Kenta <kenta@vinelinux.org> 5.1.3-2
- - rebuilt with the current environment
- * Sun Nov 03 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> 5.1.3-1
- - new upstream release
- - changed file archive type to xz
- - replaced Patch0 to Fedora rawhide's Patch
- - deleted unrecognized option: --enable-mpbsd
- * Tue Apr 19 2011 NAKAMURA Kenta <kenta@vinelinux.org> 4.3.2-1
- - new upstream release
- * Sun Apr 17 2011 Shu KONNO <owa@bg.wakwak.com> 4.3.1-2
- - rebuilt with rpm-4.8.1-3
- * Sat Nov 28 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.1-1
- - new upstream release
- - split static libraries to subpackage
- * Sun Jun 28 2009 NAKAMURA Kenta <kenta@vinelinux.org> 4.2.2-5
- - added compat32 package for x86_64 arch support
- - run autoreconf to get autotools right
- * Mon May 19 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-4
- - applied new versioning policy
- - added Patch3 from upstream
- * Wed Oct 24 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-3vl2
- - remove --enable-mpfr
- (mpfr has been splitted since gmp 4.2)
- * Wed Oct 24 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-3vl1
- - new upstream release
- * Mon Sep 24 2007 Ivana Varekova <varekova@redhat.com> 4.2.2-3
- - fix libgmpxx.so link
- * Thu Sep 20 2007 Ivana Varekova <varekova@redhat.com> 4.2.2-2
- - fix check tag
- * Thu Nov 2 2006 Thomas Woerner <twoerner@redhat.com> 4.1.4-10
- - fixed arch order in gmp.h and gmp-mparam.h wrapper for all architectures
- - re-include libraries using SSE2 on x86 arch
- - updated URL
- * Wed May 09 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1.4-6vl2
- - rebuilt with new toolchain
- * Sat Feb 11 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.1.4-6vl1
- - new upstream release
- * Mon Apr 18 2005 Thomas Woerner <twoerner@redhat.com> 4.1.4-6
- - fixed __setfpucw call in mpfr-test.h
- * Sun Sep 26 2004 Florian La Roche <Florian.LaRoche@redhat.de>
- - disable ppc64 patch, now fixed upstream
- * Wed Mar 31 2004 Thomas Woerner <twoerner@redhat.com> 4.1.2-14
- - dropped RPATH (#118506)
- - exclude libraries using SSE2 in default settings.
- * Fri Mar 12 2004 KOBAYASHI R. Taizo <tkoba@vinelinux.org> 4.1.2-13vl1
- - modified for Vine
- * Mon Jan 20 2003 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1-1vl3
- - added Obsoletes: gmp4(-devel)
- * Wed Jan 15 2003 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1-1vl2
- - rebuilt against new toolchain
- * Fri May 31 2002 KOBAYASHI R. Taizo <tkoba@vinelinux.org>
- - modified for Vine
- * Sat May 25 2002 Florian La Roche <Florian.LaRoche@redhat.de>
- - update to version 4.1
- - patch s390 gmp-mparam.h to match other archs.
- * Thu May 23 2002 Tim Powers <timp@redhat.com>
- - automated rebuild
- * Mon Mar 11 2002 Trond Eivind Glomsrød <teg@redhat.com> 4.0.1-3
- - Use standard %%configure macro and edit %%{_tmppath}
- * Tue Feb 26 2002 Trond Eivind Glomsrød <teg@redhat.com> 4.0.1-2
- - Rebuild
- * Tue Jan 22 2002 Florian La Roche <Florian.LaRoche@redhat.de>
- - update to 4.0.1
- - bzip2 src
- * Wed Jan 09 2002 Tim Powers <timp@redhat.com>
- - automated rebuild
- * Sun Jun 24 2001 Elliot Lee <sopwith@redhat.com>
- - Bump release + rebuild.
- * Mon Feb 05 2001 Philipp Knirsch <pknirsch@redhat.de>
- - Fixed bugzilla bug #25515 where GMP wouldn't work on IA64 as IA64 is not
- correctly identified as a 64 bit platform.
- * Mon Dec 18 2000 Preston Brown <pbrown@redhat.com>
- - include bsd mp library
- * Tue Oct 17 2000 Florian La Roche <Florian.LaRoche@redhat.de>
- - update to 3.1.1
- * Sun Sep 3 2000 Florian La Roche <Florian.LaRoche@redhat.com>
- - update to 3.1
- * Sat Aug 19 2000 Preston Brown <pbrown@redhat.com>
- - devel subpackage depends on main package so that .so symlink is OK.
- * Thu Jul 13 2000 Prospector <bugzilla@redhat.com>
- - automatic rebuild
- * Sat Jun 3 2000 Nalin Dahyabhai <nalin@redhat.com>
- - switch to the configure and makeinstall macros
- - FHS-compliance fixing
- - move docs to non-devel package
- * Fri Apr 28 2000 Bill Nottingham <notting@redhat.com>
- - libtoolize for ia64
- * Fri Apr 28 2000 Florian La Roche <Florian.LaRoche@redhat.com>
- - update to 3.0.1
- * Thu Apr 27 2000 Jakub Jelinek <jakub@redhat.com>
- - sparc64 fixes for 3.0
- * Wed Apr 26 2000 Florian La Roche <Florian.LaRoche@redhat.com>
- - update to 3.0
- * Mon Feb 14 2000 Matt Wilson <msw@redhat.com>
- - #include <string.h> in files that use string functions
- * Wed Feb 02 2000 Cristian Gafton <gafton@redhat.com>
- - fix description and summary
- * Mon Dec 06 1999 Michael K. Johnson <johnsonm@redhat.com>
- - s/GPL/LGPL/
- - build as non-root (#7604)
- * Mon Sep 06 1999 Jakub Jelinek <jj@ultra.linux.cz>
- - merge in some debian gmp fixes
- - Ulrich Drepper's __gmp_scale2 fix
- - my mpf_set_q fix
- - sparc64 fixes
- * Wed Apr 28 1999 Cristian Gafton <gafton@redhat.com>
- - add sparc patch for PIC handling
- * Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com>
- - auto rebuild in the new build environment (release 8)
- * Thu Feb 11 1999 Michael Johnson <johnsonm@redhat.com>
- - include the private header file gmp-mparam.h because several
- apps seem to assume that they are building against the gmp
- source tree and require it. Sigh.
- * Tue Jan 12 1999 Michael K. Johnson <johnsonm@redhat.com>
- - libtoolize to work on arm
- * Thu Sep 10 1998 Cristian Gafton <gafton@redhat.com>
- - yet another touch of the spec file
- * Wed Sep 2 1998 Michael Fulbright <msf@redhat.com>
- - looked over before inclusion in RH 5.2
- * Sun May 24 1998 Dick Porter <dick@cymru.net>
- - Patch Makefile.in, not Makefile
- - Don't specify i586, let configure decide the arch
- * Sat Jan 24 1998 Marc Ewing <marc@redhat.com>
- - started with package from Toshio Kuratomi <toshiok@cats.ucsc.edu>
- - cleaned up file list
- - fixed up install-info support
|