source: spec/trunk/SPECS/gmp.spec@ 1010

Last change on this file since 1010 was 264, checked in by Yuri Dario, 14 years ago

spec: gmp, A GNU arbitrary precision library, initial build.

File size: 2.7 KB
Line 
1#
2# Important for %{ix86}:
3# This rpm has to be build on a CPU with sse2 support like Pentium 4 !
4#
5
6Summary: A GNU arbitrary precision library
7Name: gmp
8Version: 5.0.2
9Release: 2%{?dist}
10URL: http://gmplib.org/
11
12Source0: ftp://ftp.gnu.org/pub/gnu/gmp/gmp-%{version}.tar.bz2
13Patch0: gmp.diff
14
15License: LGPLv3+
16Group: System Environment/Libraries
17BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
18#BuildRequires: autoconf automake libtool
19
20%description
21The gmp package contains GNU MP, a library for arbitrary precision
22arithmetic, signed integers operations, rational numbers and floating
23point numbers. GNU MP is designed for speed, for both small and very
24large operands. GNU MP is fast because it uses fullwords as the basic
25arithmetic type, it uses fast algorithms, it carefully optimizes
26assembly code for many CPUs' most common inner loops, and it generally
27emphasizes speed over simplicity/elegance in its operations.
28
29Install the gmp package if you need a fast arbitrary precision
30library.
31
32%package devel
33Summary: Development tools for the GNU MP arbitrary precision library
34Group: Development/Libraries
35Requires: %{name} = %{version}-%{release}
36#Requires(post): /sbin/install-info
37#Requires(preun): /sbin/install-info
38
39%description devel
40The libraries, header files and documentation for using the GNU MP
41arbitrary precision library in applications.
42
43If you want to develop applications which will use the GNU MP library,
44you'll need to install the gmp-devel package. You'll also need to
45install the gmp package.
46
47%package static
48Summary: Development tools for the GNU MP arbitrary precision library
49Group: Development/Libraries
50Requires: %{name}-devel = %{version}-%{release}
51
52%description static
53The static libraries for using the GNU MP arbitrary precision library
54in applications.
55
56%prep
57%setup -q
58%patch0 -p1 -b .os2~
59
60%build
61export CONFIG_SHELL="/@unixroot/usr/bin/sh.exe"
62%configure \
63 --host=none-pc-os2-emx --build=none-pc-os2-emx \
64 --disable-shared --enable-static \
65 "--cache-file=%{_topdir}/cache/%{name}-%{_target_cpu}.cache"
66make %{?_smp_mflags}
67
68%install
69rm -rf $RPM_BUILD_ROOT
70make install DESTDIR=$RPM_BUILD_ROOT
71
72cp -p gmp.dll $RPM_BUILD_ROOT%{_libdir}
73cp -p .libs/gmp_s.a $RPM_BUILD_ROOT%{_libdir}
74
75install -m 644 gmp-mparam.h ${RPM_BUILD_ROOT}%{_includedir}
76rm -f $RPM_BUILD_ROOT%{_libdir}/lib*.la
77rm -f $RPM_BUILD_ROOT%{_infodir}/dir
78
79%clean
80rm -rf $RPM_BUILD_ROOT
81
82%files
83%defattr(-,root,root,-)
84%doc COPYING COPYING.LIB NEWS README
85%{_libdir}/*.dll
86
87%files devel
88%defattr(-,root,root,-)
89%{_libdir}/gmp.a
90%{_includedir}/*.h
91%{_infodir}/gmp.info*
92
93%files static
94%defattr(-,root,root,-)
95%{_libdir}/gmp_s.a
96
97%changelog
98* Fri Dec 02 2011 yd
99- build as dll
100
101* Thu Dec 01 2011 yd
102- build as static lib
Note: See TracBrowser for help on using the repository browser.