1 Summary: Foreign Function Interface library (cross MinGW32 version)
2 Summary(pl.UTF-8): Biblioteka Foreign Function Interface (wersja skrośna MinGW32)
3 Name: crossmingw32-libffi
8 #Source0Download: https://github.com/libffi/libffi/releases/
9 Source0: https://github.com/libffi/libffi/releases/download/v%{version}/libffi-%{version}.tar.gz
10 # Source0-md5: 294b921e6cf9ab0fbaea4b639f8fdbe8
11 URL: http://www.sourceware.org/libffi/
12 BuildRequires: crossmingw32-gcc
13 BuildRequires: texinfo
14 Requires: crossmingw32-runtime
15 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17 %define no_install_post_strip 1
18 %define _enable_debug_packages 0
20 %define target i386-mingw32
21 %define target_platform i386-pc-mingw32
23 %define _sysprefix /usr
24 %define _prefix %{_sysprefix}/%{target}
25 %define _libdir %{_prefix}/lib
26 %define _pkgconfigdir %{_prefix}/lib/pkgconfig
27 %define _dlldir /usr/share/wine/windows/system
28 %define __cc %{target}-gcc
29 %define __pkgconfig_provides %{nil}
30 %define __pkgconfig_requires %{nil}
33 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
36 # -z options are invalid for mingw linker, most of -f options are Linux-specific
37 %define filterout_ld -Wl,-z,.*
38 %define filterout_c -f[-a-z0-9=]*
41 The libffi library provides a portable, high level programming
42 interface to various calling conventions. This allows a programmer to
43 call any function specified by a call interface description at
46 Ffi stands for Foreign Function Interface. A foreign function
47 interface is the popular name for the interface that allows code
48 written in one language to call code written in another language. The
49 libffi library really only provides the lowest, machine dependent
50 layer of a fully featured foreign function interface. A layer must
51 exist above libffi that handles type conversions for values passed
52 between the two languages.
54 This package contains the cross version for MinGW32.
56 %description -l pl.UTF-8
57 Biblioteka libffi dostarcza przenośny, wysokopoziomowy interfejs do
58 różnych konwencji wywołań funkcji. Pozwala to programiście wywołać
59 dowolną funkcję podaną przez opis interfejsu wywołania w czasie
62 FFI to skrót od Foreign Function Interface, czyli interfejsu do obcych
63 funkcji. Jest to potoczna nazwa interfejsu pozwalającego programowi
64 napisanemu w jednym języku wywoływać kod napisany w innym języku.
65 Biblioteka libffi daje tylko najniższą, zależną od maszyny warstwę
66 pełnego interfejsu. Potrzebne są wyższe warstwy do obsługi konwersji
67 typów dla wartości przekazywanych pomiędzy różnymi językami.
69 Ten pakiet zawiera wersję skrośną dla MinGW32.
72 Summary: Static libffi library (cross MinGW32 version)
73 Summary(pl.UTF-8): Statyczna biblioteka libffi (wersja skrośna MinGW32)
74 Group: Development/Libraries
75 Requires: %{name} = %{version}-%{release}
78 Static libffi library (cross MinGW32 version).
80 %description static -l pl.UTF-8
81 Statyczna biblioteka libffi (wersja skrośna MinGW32).
84 Summary: Foreign Function Interface DLL library for Windows
85 Summary(pl.UTF-8): Biblioteka DLL Foreign Function Interface dla Windows
86 Group: Applications/Emulators
90 Foreign Function Interface DLL library for Windows.
92 %description dll -l pl.UTF-8
93 Biblioteka DLL Foreign Function Interface dla Windows.
96 %setup -q -n libffi-%{version}
106 rm -rf $RPM_BUILD_ROOT
109 DESTDIR=$RPM_BUILD_ROOT
111 install -d $RPM_BUILD_ROOT%{_dlldir}
112 %{__mv} $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
115 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
116 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
119 %{__rm} -r $RPM_BUILD_ROOT{%{_mandir},%{_infodir}}
122 rm -rf $RPM_BUILD_ROOT
125 %defattr(644,root,root,755)
126 %doc ChangeLog* LICENSE README.md
127 %{_libdir}/libffi.dll.a
130 %{_includedir}/ffitarget.h
131 %{_pkgconfigdir}/libffi.pc
134 %defattr(644,root,root,755)
138 %defattr(644,root,root,755)
139 %{_dlldir}/libffi-8.dll