]>
Commit | Line | Data |
---|---|---|
8a23aa4a | 1 | # NOTE: currently PLD libffi packages are built from gcc.spec |
47cf54c9 | 2 | # |
c645cb66 | 3 | # Conditional build: |
4 | %bcond_without static_libs # don't build static library | |
5 | # | |
e2b3d64a | 6 | Summary: Foreign Function Interface library |
31107309 | 7 | Summary(pl.UTF-8): Biblioteka Foreign Function Interface |
e2b3d64a | 8 | Name: libffi |
5b1583c0 JB |
9 | Version: 3.0.12 |
10 | Release: 0.1 | |
73a73a22 JB |
11 | Epoch: 7 |
12 | License: MIT-like | |
e2b3d64a | 13 | Group: Libraries |
73a73a22 | 14 | Source0: ftp://sourceware.org/pub/libffi/%{name}-%{version}.tar.gz |
5b1583c0 | 15 | # Source0-md5: da984c6756170d50f47925bb333cda71 |
73a73a22 | 16 | Patch0: %{name}-info.patch |
e2b3d64a | 17 | URL: http://sources.redhat.com/libffi/ |
16c35215 | 18 | BuildRequires: texinfo |
e2b3d64a MM |
19 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
20 | ||
21 | %description | |
02288106 JB |
22 | The libffi library provides a portable, high level programming |
23 | interface to various calling conventions. This allows a programmer to | |
24 | call any function specified by a call interface description at | |
25 | run-time. | |
26 | ||
27 | Ffi stands for Foreign Function Interface. A foreign function | |
28 | interface is the popular name for the interface that allows code | |
29 | written in one language to call code written in another language. The | |
30 | libffi library really only provides the lowest, machine dependent | |
31 | layer of a fully featured foreign function interface. A layer must | |
32 | exist above libffi that handles type conversions for values passed | |
05d32588 | 33 | between the two languages. |
e2b3d64a | 34 | |
4916b9d6 JR |
35 | %description -l pl.UTF-8 |
36 | Biblioteka libffi dostarcza przenośny, wysokopoziomowy interfejs do | |
37 | różnych konwencji wywołań funkcji. Pozwala to programiście wywołać | |
38 | dowolną funkcję podaną przez opis interfejsu wywołania w czasie | |
39 | działania programu. | |
02288106 | 40 | |
4916b9d6 JR |
41 | FFI to skrót od Foreign Function Interface, czyli interfejsu do obcych |
42 | funkcji. Jest to potoczna nazwa interfejsu pozwalającego programowi | |
43 | napisanemu w jednym języku wywoływać kod napisany w innym języku. | |
44 | Biblioteka libffi daje tylko najniższą, zależną od maszyny warstwę | |
45 | pełnego interfejsu. Potrzebne są wyższe warstwy do obsługi konwersji | |
46 | typów dla wartości przekazywanych pomiędzy różnymi językami. | |
e2b3d64a MM |
47 | |
48 | %package devel | |
02288106 | 49 | Summary: libffi development package |
31107309 | 50 | Summary(pl.UTF-8): libffi - część dla programistów |
02288106 | 51 | Group: Development/Libraries |
73a73a22 | 52 | Requires: %{name} = %{epoch}:%{version}-%{release} |
e2b3d64a MM |
53 | |
54 | %description devel | |
55 | Header files for libffi. | |
56 | ||
4916b9d6 JR |
57 | %description devel -l pl.UTF-8 |
58 | Pliki nagłówkowe do biblioteki libffi. | |
e2b3d64a MM |
59 | |
60 | %package static | |
02288106 | 61 | Summary: libffi static library |
31107309 | 62 | Summary(pl.UTF-8): Statyczna biblioteka libffi |
02288106 | 63 | Group: Development/Libraries |
73a73a22 | 64 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
e2b3d64a MM |
65 | |
66 | %description static | |
67 | Static version of libffi. | |
68 | ||
4916b9d6 | 69 | %description static -l pl.UTF-8 |
e2b3d64a MM |
70 | Statyczna wersja biblioteki libffi. |
71 | ||
72 | %prep | |
73 | %setup -q | |
168543c2 | 74 | %patch0 -p1 |
e2b3d64a MM |
75 | |
76 | %build | |
c645cb66 | 77 | %configure \ |
78 | %{!?with_static_libs:--disable-static} | |
168543c2 | 79 | |
e2b3d64a MM |
80 | %{__make} |
81 | ||
82 | %install | |
83 | rm -rf $RPM_BUILD_ROOT | |
e2b3d64a | 84 | |
73a73a22 JB |
85 | %{__make} install \ |
86 | DESTDIR=$RPM_BUILD_ROOT | |
e2b3d64a | 87 | |
e2b3d64a MM |
88 | %clean |
89 | rm -rf $RPM_BUILD_ROOT | |
90 | ||
91 | %post -p /sbin/ldconfig | |
92 | %postun -p /sbin/ldconfig | |
93 | ||
73a73a22 JB |
94 | %post devel -p /sbin/postshell |
95 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
96 | ||
97 | %postun devel -p /sbin/postshell | |
98 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
99 | ||
e2b3d64a MM |
100 | %files |
101 | %defattr(644,root,root,755) | |
73a73a22 JB |
102 | %doc ChangeLog* LICENSE README |
103 | %attr(755,root,root) %{_libdir}/libffi.so.*.*.* | |
300fca2e | 104 | %attr(755,root,root) %ghost %{_libdir}/libffi.so.6 |
e2b3d64a MM |
105 | |
106 | %files devel | |
107 | %defattr(644,root,root,755) | |
108 | %attr(755,root,root) %{_libdir}/libffi.so | |
73a73a22 JB |
109 | %{_libdir}/libffi.la |
110 | %{_libdir}/libffi-%{version} | |
111 | %{_pkgconfigdir}/libffi.pc | |
112 | %{_mandir}/man3/ffi*.3* | |
113 | %{_infodir}/libffi.info* | |
e2b3d64a | 114 | |
c645cb66 | 115 | %if %{with static_libs} |
e2b3d64a MM |
116 | %files static |
117 | %defattr(644,root,root,755) | |
73a73a22 | 118 | %{_libdir}/libffi.a |
c645cb66 | 119 | %endif |