Sophie

Sophie

distrib > Mandriva > 2006.0 > i586 > by-pkgid > 26681d359260b26f07dbd82e5b7d0c50 > files > 3

vrb-0.4.0-5mdk.src.rpm

%define name vrb
%define version 0.4.0
%define release %mkrel 5
%define major 0
%define libname %mklibname %name %major

Summary: The Virtual Ring Buffer (VRB)
Name: %{name}
Version: %{version}
Release: %{release}
Source0: %{name}-%{version}.tar.bz2
Patch0: %name.sharedlib.patch.bz2
License: LGPL
Group: System/Libraries
Url: http://vrb.slashusr.org/
BuildRoot: %{_tmppath}/%{name}-buildroot

%description
The Virtual Ring Buffer (VRB) is an implementation of a character FIFO
ring buffer. It provides direct access to the buffer so the calling
program can construct output data in place, or parse input data in place,
without the extra step of copying data to or from a calling program
provided buffer area.

%package -n %libname
Summary: The Virtual Ring Buffer (VRB) library
Group: System/Libraries
Provides: lib%name = %version-%release

%description -n %libname
The Virtual Ring Buffer (VRB) is an implementation of a character FIFO
ring buffer. It provides direct access to the buffer so the calling
program can construct output data in place, or parse input data in place,
without the extra step of copying data to or from a calling program
provided buffer area.

%package -n %libname-devel
Summary: The Virtual Ring Buffer (VRB) development files
Group: Development/Other
Provides: lib%name-devel = %version-%release
Requires: %libname = %version-%release

%description -n %libname-devel
The Virtual Ring Buffer (VRB) is an implementation of a character FIFO
ring buffer. It provides direct access to the buffer so the calling
program can construct output data in place, or parse input data in place,
without the extra step of copying data to or from a calling program
provided buffer area.

%prep
%setup -q
%patch0 -p0

%build
echo %optflags > Compile.opt
./Configure --prefix=%buildroot/usr

# Don't try %make - This makefile is ugly
make

# We need to rebuild vrb against a clean lib
rm -f lib/libvrb.so
rm -f bin/vbuf
make build_pgm 

%install
rm -rf $RPM_BUILD_ROOT
%makeinstall

mkdir -p %buildroot%_mandir/man3
cp -p vrb/man/man3/*.3 %buildroot%_mandir/man3

%clean
rm -rf $RPM_BUILD_ROOT

%post -n %libname -p  /sbin/ldconfig

%postun -n %libname -p  /sbin/ldconfig

%files
%defattr(-,root,root)
%_bindir/*
%_mandir/man3/*

%files -n %libname
%defattr(-,root,root)
%_libdir/*.so.*

%files -n %libname-devel
%defattr(-,root,root)
%_libdir/*.so
%_includedir/*.h

%changelog
* Tue Mar 29 2005 Olivier Thauvin <nanardon@mandrake.org> 0.4.0-5mdk
- %%mkrel && rebuild

* Wed Jan  7 2004 Olivier Thauvin <nanardon@klama.mandrake.org> 0.4.0-4mdk
- fix build against lib

* Sun Dec 07 2003 Franck Villaume <fvill@freesurf.fr> 0.4.0-3mdk
- do the echo > Compile.opt before to run Configure
  now we have RPM_OPT_FLAGS support

* Tue Jun 03 2003 Olivier Thauvin <thauvin@aerov.jussieu.fr> 0.4.0-2mdk
- patch0 (compile lib as shared lib)

* Mon Jun 02 2003 Olivier Thauvin <thauvin@aerov.jussieu.fr> 0.4.0-1mdk
- 1st mandrake contrib