File mono-librt.spec of Package mono-librt

#
# spec file for package mono-librt (Version 0.1.2)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2008 Novell Inc.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild

%{!?ext_man: %define ext_man .gz}

Name:           mono-librt
License:        MIT License (or similar)
Group:          Development/Languages/Mono
Summary:        Real Time Policy, Priority, Affinity and HRT Libraries for Mono
Url:            http://developer.novell.com/wiki/index.php/Rtmono
Version:        0.1.2
Release:        5
#!ExclusiveArch:  %ix86 x86_64 ppc hppa armv4l sparc s390 ia64 s390x
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch
Source0:        mono-librt-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Provides:       mono-librt = %{version}-%{release}
Requires:       mono-core >= 1.9
BuildRequires:  mono-devel >= 1.9
BuildRequires:  mono-nunit
# Only use recommends for 11.0 and up  
%if 0%{?suse_version} >= 1100  
Recommends:     monocyclic
%endif  

%description
This package includes two assemblies, Mono.LibRt and Mono.LibRt.HRT.
Mono.LibRt provides an API for real time policy and priority querying
and setting as well as processor affinity querying and setting. 
Mono.LibRt.HRT provides an API to the High Resolution Timers facilities
found on real time Linux and the modern Linux kernels.



Authors:
--------
    Alex Tsariounov <alext@novell.com>

%files
%defattr(-, root, root)
%doc AUTHORS COPYING COPYING.mono-librt NEWS README INSTALL 
%dir %_prefix/lib/mono-librt
%_prefix/lib/mono-librt/Mono.LibRt.dll
%_prefix/lib/mono-librt/Mono.LibRt.dll.mdb
%_prefix/lib/mono-librt/Mono.LibRt.HRT.dll
%_prefix/lib/mono-librt/Mono.LibRt.HRT.dll.mdb
%_prefix/share/pkgconfig/mono.librt.pc
%_prefix/share/pkgconfig/mono.librt.hrt.pc

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%package -n monocyclic
License:        GPL v2 only
Summary:        Mono latency measurement tool
Group:          Development/Languages/Mono
Requires:       mono-core mono-librt
BuildRequires:  mono-devel >= 1.9

%description -n monocyclic
Monocyclic is a port of the C-language based cyclictest tool to Mono. 
It requires the installation of the mono-librt libraries and is in fact
hosted in that same project.  Just like cyclictest for RT Linux,
monocyclic can be used to demonstrate latencies due to the Mono runtime
and the effects of running with real time priorities on those
latencies.  Monocyclic is primarily a real time Mono development tool.



Authors:
--------
    Alex Tsariounov <alext@novell.com>

%files -n monocyclic
%defattr(-, root, root)
%doc AUTHORS COPYING COPYING.monocyclic NEWS README INSTALL 
%_bindir/monocyclic
%_prefix/lib/mono-librt/monocyclic.exe

%prep
%setup

%build
./configure \
  --prefix=/usr \
  --libdir=%{_prefix}/lib \
  --libexecdir=%{_prefix}/lib \
  --localstatedir="%{_localstatedir}" \
  --mandir=%{_mandir} \
  --infodir=/usr/share/info \
  --sysconfdir=%{_sysconfdir}
make

%install
make DESTDIR="$RPM_BUILD_ROOT" install
install -d $RPM_BUILD_ROOT/usr/share
mv $RPM_BUILD_ROOT/%{_prefix}/lib/pkgconfig $RPM_BUILD_ROOT/usr/share

%clean
rm -rf ${RPM_BUILD_ROOT}

%changelog