source: projects/specs/trunk/g/gmp/gmp-vl.spec @ 3526

Revision 3526, 13.1 KB checked in by owa, 13 years ago (diff)

rebuilt

Line 
1%define configure  CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; FFLAGS="${FFLAGS:-%optflags}" ; export FFLAGS ; ./configure %{_target_platform}  --prefix=%{_prefix} --exec-prefix=%{_exec_prefix} --bindir=%{_bindir} --datadir=%{_datadir}  --libdir=%{_libdir} --mandir=%{_mandir}  --infodir=%{_infodir}
2%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
3
4# This rpm has to be build on a CPU with sse2 support like Pentium 4 !
5%ifarch %{ix86}
6%define              SSE2       1
7%else
8%define              SSE2       0
9%endif
10
11# Don't you want to build a libraries using SSE2?
12%{?_without_sse2%define SSE2    0}
13
14Summary: A GNU arbitrary precision library.
15Summary(ja): GNU 多倍長演算ライブラリ
16Name: gmp
17Version: 4.3.1
18Release: 2%{?_dist_release}
19URL: http://gmplib.org/
20Source: ftp://ftp.gnu.org/pub/gnu/gmp/gmp-%{version}.tar.bz2
21Source2: gmp.h
22Source3: gmp-mparam.h
23Patch0: gmp-4.0.1-s390.patch
24License: LGPLv3+
25Group: System Environment/Libraries
26BuildRoot: %{_tmppath}/%{name}-%{version}-root
27BuildRequires: autoconf libtool
28Obsoletes: gmp4
29
30Vendor: Project Vine
31Distribution: Vine Linux
32
33
34%description
35The gmp package contains GNU MP, a library for arbitrary precision
36arithmetic, signed integers operations, rational numbers and floating
37point numbers. GNU MP is designed for speed, for both small and very
38large operands. GNU MP is fast because it uses fullwords as the basic
39arithmetic type, it uses fast algorithms, it carefully optimizes
40assembly code for many CPUs' most common inner loops, and it generally
41emphasizes speed over simplicity/elegance in its operations.
42
43Install the gmp package if you need a fast arbitrary precision
44library.
45
46%package devel
47Summary: Development tools for the GNU MP arbitrary precision library.
48Group: Development/Libraries
49Requires: %{name} = %{version}-%{release}
50Requires(post): /sbin/install-info
51Requires(preun): /sbin/install-info
52Obsoletes: gmp4-devel
53
54%description devel
55The libraries, header files and documentation for using the GNU MP
56arbitrary precision library in applications.
57
58If you want to develop applications which will use the GNU MP library,
59you'll need to install the gmp-devel package.  You'll also need to
60install the gmp package.
61
62%package static
63Summary: Development tools for the GNU MP arbitrary precision library
64Group: Development/Libraries
65Requires: %{name}-devel = %{version}-%{release}
66
67%description static
68The static libraries for using the GNU MP arbitrary precision library
69in applications.
70
71%package -n compat32-%{name}
72Summary: A GNU arbitrary precision library.
73Group: System Environment/Libraries
74Requires: %{name} = %{version}-%{release}
75
76%description -n compat32-%{name}
77The gmp package contains GNU MP, a library for arbitrary precision
78arithmetic, signed integers operations, rational numbers and floating
79point numbers. GNU MP is designed for speed, for both small and very
80large operands. GNU MP is fast because it uses fullwords as the basic
81arithmetic type, it uses fast algorithms, it carefully optimizes
82assembly code for many CPUs' most common inner loops, and it generally
83emphasizes speed over simplicity/elegance in its operations.
84
85Install the gmp package if you need a fast arbitrary precision
86library.
87
88%package -n compat32-%{name}-devel
89Summary: Development tools for the GNU MP arbitrary precision library.
90Group: Development/Libraries
91Requires: compat32-%{name} = %{version}-%{release}
92Requires: %{name}-devel = %{version}-%{release}
93
94%description -n compat32-%{name}-devel
95The libraries, header files and documentation for using the GNU MP
96arbitrary precision library in applications.
97
98If you want to develop applications which will use the GNU MP library,
99you'll need to install the gmp-devel package.  You'll also need to
100install the gmp package.
101
102%package -n compat32-%{name}-static
103Summary: Development tools for the GNU MP arbitrary precision library
104Group: Development/Libraries
105Requires: compat32-%{name}-devel = %{version}-%{release}
106
107%description -n compat32-%{name}-static
108The static libraries for using the GNU MP arbitrary precision library
109in applications.
110
111
112%prep
113%setup -q
114%patch0 -p1
115
116%build
117autoreconf -if
118if as --help | grep -q execstack; then
119  # the object files do not require an executable stack
120  export CCAS="gcc -c -Wa,--noexecstack"
121fi
122mkdir base
123cd base
124ln -s ../configure .
125%configure --enable-mpbsd --enable-cxx
126perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool
127export LD_LIBRARY_PATH=`pwd`/.libs
128make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}
129cd ..
130
131%if %{SSE2}
132mkdir build-sse2
133cd build-sse2
134ln -s ../configure .
135CFLAGS="%{optflags} -march=pentium4"
136%configure --enable-mpbsd --enable-cxx pentium4-vine-linux
137perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool
138export LD_LIBRARY_PATH=`pwd`/.libs
139make %{?_smp_mflags}
140unset CFLAGS
141cd ..
142%endif
143
144%install
145[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
146cd base
147export LD_LIBRARY_PATH=`pwd`/.libs
148make install DESTDIR=$RPM_BUILD_ROOT
149install -m 644 gmp-mparam.h ${RPM_BUILD_ROOT}%{_includedir}
150
151rm -f $RPM_BUILD_ROOT%{_libdir}/lib{gmp,mp,gmpxx}.la
152rm -f $RPM_BUILD_ROOT%{_infodir}/dir
153/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}
154ln -sf libgmpxx.so.4 $RPM_BUILD_ROOT%{_libdir}/libgmpxx.so
155cd ..
156
157%if %{SSE2}
158cd build-sse2
159export LD_LIBRARY_PATH=`pwd`/.libs
160mkdir $RPM_BUILD_ROOT%{_libdir}/sse2
161install -m 755 .libs/libgmp.so.3.* $RPM_BUILD_ROOT%{_libdir}/sse2
162cp -a .libs/libgmp.so.3 $RPM_BUILD_ROOT%{_libdir}/sse2
163chmod 755 $RPM_BUILD_ROOT%{_libdir}/sse2/libgmp.so.3
164install -m 755 .libs/libgmpxx.so.4.* $RPM_BUILD_ROOT%{_libdir}/sse2
165cp -a .libs/libgmpxx.so.4 $RPM_BUILD_ROOT%{_libdir}/sse2
166chmod 755 $RPM_BUILD_ROOT%{_libdir}/sse2/libgmpxx.so.4
167install -m 755 .libs/libmp.so.3.* $RPM_BUILD_ROOT%{_libdir}/sse2
168cp -a .libs/libmp.so.3 $RPM_BUILD_ROOT%{_libdir}/sse2
169chmod 755 $RPM_BUILD_ROOT%{_libdir}/sse2/libmp.so.3
170cd ..
171%endif
172
173# Rename gmp.h to gmp-<arch>.h and gmp-mparam.h to gmp-mparam-<arch>.h to
174# avoid file conflicts on multilib systems and install wrapper include files
175# gmp.h and gmp-mparam-<arch>.h
176basearch=%{_arch}
177# always use i386 for iX86
178%ifarch %{ix86}
179basearch=i386
180%endif
181# always use arm for arm*
182%ifarch %{arm}
183basearch=arm
184%endif
185# Rename files and install wrappers
186
187mv %{buildroot}/%{_includedir}/gmp.h %{buildroot}/%{_includedir}/gmp-${basearch}.h
188install -m644 %{SOURCE2} %{buildroot}/%{_includedir}/gmp.h
189mv %{buildroot}/%{_includedir}/gmp-mparam.h %{buildroot}/%{_includedir}/gmp-mparam-${basearch}.h
190install -m644 %{SOURCE3} %{buildroot}/%{_includedir}/gmp-mparam.h
191
192
193%check
194%ifnarch ppc
195cd base
196export LD_LIBRARY_PATH=`pwd`/.libs
197make %{?_smp_mflags} check
198cd ..
199%endif
200
201%if %{SSE2}
202cd build-sse2
203export LD_LIBRARY_PATH=`pwd`/.libs
204make %{?_smp_mflags} check
205cd ..
206%endif
207
208
209%post -p /sbin/ldconfig
210
211%postun -p /sbin/ldconfig
212
213%post devel
214/sbin/install-info %{_infodir}/gmp.info.gz %{_infodir}/dir
215
216%preun devel
217if [ "$1" = 0 ]; then
218        /sbin/install-info --delete %{_infodir}/gmp.info.gz %{_infodir}/dir
219fi
220
221%post -n compat32-%{name} -p /sbin/ldconfig
222
223%postun -n compat32-%{name} -p /sbin/ldconfig
224
225%clean
226[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
227
228
229%files
230%defattr(-,root,root)
231%doc COPYING COPYING.LIB NEWS README
232%{_libdir}/libgmp.so.*
233%{_libdir}/libmp.so.*
234%{_libdir}/libgmpxx.so.*
235%if %{SSE2}
236%{_libdir}/sse2/*
237%endif
238
239%files devel
240%defattr(-,root,root)
241%{_libdir}/libmp.so
242%{_libdir}/libgmp.so
243%{_libdir}/libgmpxx.so
244#{_libdir}/libmpfr.a
245%{_includedir}/*.h
246%{_infodir}/gmp.info*
247#{_infodir}/mpfr.info*
248
249%files static
250%defattr(-,root,root,-)
251%doc README
252%{_libdir}/libmp.a
253%{_libdir}/libgmp.a
254%{_libdir}/libgmpxx.a
255
256# compat32
257%if %{build_compat32}
258%files -n compat32-%{name}
259%defattr(-,root,root)
260%{_libdir}/libgmp.so.*
261%{_libdir}/libmp.so.*
262%{_libdir}/libgmpxx.so.*
263%if %{SSE2}
264%{_libdir}/sse2/*
265%endif
266
267%files -n compat32-%{name}-devel
268%defattr(-,root,root)
269%{_libdir}/libmp.so
270%{_libdir}/libgmp.so
271%{_libdir}/libgmpxx.so
272#{_libdir}/libmpfr.a
273
274%files -n compat32-%{name}-static
275%defattr(-,root,root,-)
276%doc README
277%{_libdir}/libmp.a
278%{_libdir}/libgmp.a
279%{_libdir}/libgmpxx.a
280%endif
281
282%changelog
283* Sun Apr 17 2011 Shu KONNO <owa@bg.wakwak.com> 4.3.1-2
284- rebuilt with rpm-4.8.1-3
285
286* Sat Nov 28 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.1-1
287- new upstream release
288- split static libraries to subpackage
289
290* Sun Jun 28 2009 NAKAMURA Kenta <kenta@vinelinux.org> 4.2.2-5
291- added compat32 package for x86_64 arch support
292- run autoreconf to get autotools right
293
294* Mon May 19 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-4
295- applied new versioning policy
296- added Patch3 from upstream
297
298* Wed Oct 24 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-3vl2
299- remove --enable-mpfr
300  (mpfr has been splitted since gmp 4.2)
301
302* Wed Oct 24 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.2-3vl1
303- new upstream release
304  * Mon Sep 24 2007 Ivana Varekova <varekova@redhat.com> 4.2.2-3
305  - fix libgmpxx.so link
306  * Thu Sep 20 2007 Ivana Varekova <varekova@redhat.com> 4.2.2-2
307  - fix check tag
308  * Thu Nov  2 2006 Thomas Woerner <twoerner@redhat.com> 4.1.4-10
309  - fixed arch order in gmp.h and gmp-mparam.h wrapper for all architectures
310- re-include libraries using SSE2 on x86 arch
311- updated URL
312
313* Wed May 09 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1.4-6vl2
314- rebuilt with new toolchain
315
316* Sat Feb 11 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.1.4-6vl1
317- new upstream release
318  * Mon Apr 18 2005 Thomas Woerner <twoerner@redhat.com> 4.1.4-6
319  - fixed __setfpucw call in mpfr-test.h
320  * Sun Sep 26 2004 Florian La Roche <Florian.LaRoche@redhat.de>
321  - disable ppc64 patch, now fixed upstream
322  * Wed Mar 31 2004 Thomas Woerner <twoerner@redhat.com> 4.1.2-14
323  - dropped RPATH (#118506)
324- exclude libraries using SSE2 in default settings.
325
326* Fri Mar 12 2004 KOBAYASHI R. Taizo <tkoba@vinelinux.org> 4.1.2-13vl1
327- modified for Vine
328
329* Mon Jan 20 2003 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1-1vl3
330- added Obsoletes: gmp4(-devel)
331
332* Wed Jan 15 2003 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1-1vl2
333- rebuilt against new toolchain
334
335* Fri May 31 2002 KOBAYASHI R. Taizo <tkoba@vinelinux.org>
336- modified for Vine
337
338* Sat May 25 2002 Florian La Roche <Florian.LaRoche@redhat.de>
339- update to version 4.1
340- patch s390 gmp-mparam.h to match other archs.
341
342* Thu May 23 2002 Tim Powers <timp@redhat.com>
343- automated rebuild
344
345* Mon Mar 11 2002 Trond Eivind Glomsrød <teg@redhat.com> 4.0.1-3
346- Use standard %%configure macro and edit %%{_tmppath}
347
348* Tue Feb 26 2002 Trond Eivind Glomsrød <teg@redhat.com> 4.0.1-2
349- Rebuild
350
351* Tue Jan 22 2002 Florian La Roche <Florian.LaRoche@redhat.de>
352- update to 4.0.1
353- bzip2 src
354
355* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
356- automated rebuild
357
358* Sun Jun 24 2001 Elliot Lee <sopwith@redhat.com>
359- Bump release + rebuild.
360
361* Mon Feb 05 2001 Philipp Knirsch <pknirsch@redhat.de>
362- Fixed bugzilla bug #25515 where GMP wouldn't work on IA64 as IA64 is not
363correctly identified as a 64 bit platform.
364
365* Mon Dec 18 2000 Preston Brown <pbrown@redhat.com>
366- include bsd mp library
367
368* Tue Oct 17 2000 Florian La Roche <Florian.LaRoche@redhat.de>
369- update to 3.1.1
370
371* Sun Sep  3 2000 Florian La Roche <Florian.LaRoche@redhat.com>
372- update to 3.1
373
374* Sat Aug 19 2000 Preston Brown <pbrown@redhat.com>
375- devel subpackage depends on main package so that .so symlink is OK.
376
377* Thu Jul 13 2000 Prospector <bugzilla@redhat.com>
378- automatic rebuild
379
380* Sat Jun  3 2000 Nalin Dahyabhai <nalin@redhat.com>
381- switch to the configure and makeinstall macros
382- FHS-compliance fixing
383- move docs to non-devel package
384
385* Fri Apr 28 2000 Bill Nottingham <notting@redhat.com>
386- libtoolize for ia64
387
388* Fri Apr 28 2000 Florian La Roche <Florian.LaRoche@redhat.com>
389- update to 3.0.1
390
391* Thu Apr 27 2000 Jakub Jelinek <jakub@redhat.com>
392- sparc64 fixes for 3.0
393
394* Wed Apr 26 2000 Florian La Roche <Florian.LaRoche@redhat.com>
395- update to 3.0
396
397* Mon Feb 14 2000 Matt Wilson <msw@redhat.com>
398- #include <string.h> in files that use string functions
399
400* Wed Feb 02 2000 Cristian Gafton <gafton@redhat.com>
401- fix description and summary
402
403* Mon Dec 06 1999 Michael K. Johnson <johnsonm@redhat.com>
404- s/GPL/LGPL/
405- build as non-root (#7604)
406
407* Mon Sep 06 1999 Jakub Jelinek <jj@ultra.linux.cz>
408- merge in some debian gmp fixes
409- Ulrich Drepper's __gmp_scale2 fix
410- my mpf_set_q fix
411- sparc64 fixes
412
413* Wed Apr 28 1999 Cristian Gafton <gafton@redhat.com>
414- add sparc patch for PIC handling
415
416* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com>
417- auto rebuild in the new build environment (release 8)
418
419* Thu Feb 11 1999 Michael Johnson <johnsonm@redhat.com>
420- include the private header file gmp-mparam.h because several
421  apps seem to assume that they are building against the gmp
422  source tree and require it.  Sigh.
423
424* Tue Jan 12 1999 Michael K. Johnson <johnsonm@redhat.com>
425- libtoolize to work on arm
426
427* Thu Sep 10 1998 Cristian Gafton <gafton@redhat.com>
428- yet another touch of the spec file
429
430* Wed Sep  2 1998 Michael Fulbright <msf@redhat.com>
431- looked over before inclusion in RH 5.2
432
433* Sat May 24 1998 Dick Porter <dick@cymru.net>
434- Patch Makefile.in, not Makefile
435- Don't specify i586, let configure decide the arch
436
437* Sat Jan 24 1998 Marc Ewing <marc@redhat.com>
438- started with package from Toshio Kuratomi <toshiok@cats.ucsc.edu>
439- cleaned up file list
440- fixed up install-info support
441
Note: See TracBrowser for help on using the repository browser.