A new user interface for you! Read more...

File libffi5.spec of Package libffi5

Name:                         libffi5
Version:                      3.0.5
Release:                      1
Summary:                      Foreign Function Interface library
License:                      GPLv2+
Group:                        Development/Libraries
Url:                          ftp://sources.redhat.com/pub/libffi/
Buildroot:                    %{_tmppath}/%{name}-%{version}-build
Requires:                     info
BuildRequires:                info
Source:                       libffi-3.0.5.tar.gz

%description
A foreign function interface is the popular name for the interface
that allows code written in one language to call code written in
another language.

%package devel
Summary:                      Development package for libffi
Group:                        Development/Libraries
Provides:                     libffi-devel
Requires:                     %{name} = %{version}

%description devel
This package contains all that is needed to develop/compile
applications that use the libffi libraries.


%prep
%setup -q -n libffi-3.0.5
%configure

%build
CFLAGS="$RPM_OPT_FLAGS" make

%install
DESTDIR=%{?buildroot:%{buildroot}}

make DESTDIR="$DESTDIR" install

mkdir -p "$DESTDIR/%{_includedir}"
mv "$DESTDIR"/"%{_libdir}"/libffi-3.0.5/include/* "$DESTDIR/%{_includedir}"
rm -rf "$DESTDIR/%{_libdir}/libffi-3.0.5"
rm -f "$DESTDIR/%{_infodir}/dir"

%{__strip} "$DESTDIR/%{_libdir}"/libffi.so*

%clean
[ -d "$RPM_BUILD_ROOT" ] && rm -rf "$RPM_BUILD_ROOT"


%post
/sbin/ldconfig

%postun
/sbin/ldconfig

%files
%defattr(-,root,root)
%doc LICENSE README ChangeLog*
%{_libdir}/libffi.so.5.0.6
%{_libdir}/libffi.so.5

%files devel
%defattr(-,root,root)
%{_includedir}/ffi.h
%{_includedir}/ffitarget.h
%{_libdir}/libffi.so
%{_libdir}/libffi.la
%{_libdir}/libffi.a
%{_mandir}/man3/ffi_call.3*
%{_mandir}/man3/ffi.3*
%{_mandir}/man3/ffi_prep_cif.3*
%{_infodir}/libffi.info*
%{_libdir}/pkgconfig/libffi.pc