6 # Thierry Parmentelat - INRIA
7 # Copyright (C) 2010 INRIA
10 %define name omf-resctl
14 %define plc_name %{name}-%{version}-%{taglevel}
15 %define actual_name omf-resctl-5.3-1ubuntu2-2
17 Summary: OMF Resource Controller - for slivers
22 Group: System Environment/Base
23 Source0: %{plc_name}.tar.bz2
24 BuildRoot: %{_tmppath}/%{plc_name}-buildroot
27 Packager: PlanetLab <devel@planet-lab.org>
28 Distribution: %{pldistro} %{plrelease}
29 URL: %(echo %{url} | cut -d ' ' -f 2)
35 Requires: wireless-tools
36 Requires: rpmlib(CompressedFileNames) <= 3.0.4-1
37 Requires: rpmlib(PayloadFilesHavePrefix) <= 4.0-1
45 The OMF Resource Controller (RC) is the experiment-side of the
46 Experiment Eontroller (EC) that lets experimenter control their
47 resources. It relies on an XMPP server for exchanging with its EC.
50 %define common_actual_name omf-common-5.3-1ubuntu3-2
52 %package -n omf-common
53 Summary: OMF common utilities
54 Group: System Environment/Base
55 %description -n omf-common
56 Provides utilities common to various OMF components
59 %define liblog4r_actual_name liblog4r-ruby1.8-1.2-1
62 Summary: A logging library for Ruby
63 Group: System Environment/Base
64 %description -n liblog4r
65 A logging library for Ruby, needed by OMF software
68 %define libxmpp4r_actual_name libxmpp4r-ruby1.8-1.0-1
71 Summary: XMPP/Jabber library for Ruby
72 Group: System Environment/Base
73 %description -n libxmpp4r
74 An XMPP/Jabber library for Ruby, needed by OMF software
77 %define imagezip_actual_name imagezip-1.0.0-3
80 Summary: filesystem image compression tool from EMULAB
81 Group: System Environment/Base
82 %description -n imagezip
83 filesystem image compression tool from EMULAB
91 rm -rf $RPM_BUILD_ROOT
96 (cd unwrap; rpm2cpio ../%{actual_name}.noarch.rpm | cpio -diu)
98 (cd unwrap ; rpm2cpio ../%{common_actual_name}.noarch.rpm | cpio -diu)
100 (cd unwrap; rpm2cpio ../%{liblog4r_actual_name}.noarch.rpm | cpio -diu)
102 (cd unwrap; rpm2cpio ../%{libxmpp4r_actual_name}.noarch.rpm | cpio -diu)
104 (cd unwrap; rpm2cpio ../%{imagezip_actual_name}.i386.rpm | cpio -diu)
106 # cleanup any svn sequels
107 find unwrap -type d -name .svn -print0 | xargs -0 rm -rf
110 rm -fr $RPM_BUILD_ROOT
112 install -D -m 600 omf-resctl.yaml.in $RPM_BUILD_ROOT/etc/omf-resctl-%{version}/omf-resctl.yaml.in
113 ln -s omf-resctl-%{version} $RPM_BUILD_ROOT/etc/omf-resctl
115 rsync -a unwrap/ $RPM_BUILD_ROOT
118 rm -rf $RPM_BUILD_ROOT
122 %defattr(-,root,root)
125 /usr/share/omf-resctl-%{version}
130 /sbin/chkconfig --add omf-resctl-%{version}
131 service omf-resctl-%{version} restart
135 %defattr(-,root,root)
136 /usr/share/omf-common-%{version}
137 /usr/share/doc/omf-common-%{version}
141 ln -s /usr/bin/ruby /usr/bin/ruby1.8
145 %defattr(-,root,root)
146 /usr/lib/ruby/1.8/log4r.rb
147 /usr/lib/ruby/1.8/log4r
148 /usr/share/doc/liblog4r-ruby1.8
152 %defattr(-,root,root)
153 /usr/lib/ruby/1.8/xmpp4r.rb
154 /usr/lib/ruby/1.8/xmpp4r
155 /usr/share/doc/libxmpp4r-ruby1.8
159 %defattr(-,root,root)
163 /usr/share/doc/imagezip