summaryrefslogtreecommitdiff
path: root/rhel/openvswitch.spec.in
diff options
context:
space:
mode:
authorAlexey I. Froloff <raorn@altlinux.org>2011-11-03 10:30:04 -0700
committerBen Pfaff <blp@nicira.com>2011-11-17 09:14:48 -0800
commit0fb426263e7834f7403eefd860cf5d36d43f8c45 (patch)
tree83b9a07a140522c59ab3828952248d342403c865 /rhel/openvswitch.spec.in
parentdf2a06abbe1d9f4788fa794d0c7f0250dee2bda7 (diff)
downloadopenvswitch-0fb426263e7834f7403eefd860cf5d36d43f8c45.tar.gz
rhel: Add Red Hat network scripts integration.
[Spec file changes and some documentation updates by Ben Pfaff.]
Diffstat (limited to 'rhel/openvswitch.spec.in')
-rw-r--r--rhel/openvswitch.spec.in27
1 files changed, 16 insertions, 11 deletions
diff --git a/rhel/openvswitch.spec.in b/rhel/openvswitch.spec.in
index 2cf9535a5..46f65e237 100644
--- a/rhel/openvswitch.spec.in
+++ b/rhel/openvswitch.spec.in
@@ -35,17 +35,19 @@ make %{_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
-install -d -m 755 $RPM_BUILD_ROOT/etc
-install -d -m 755 $RPM_BUILD_ROOT/etc/init.d
-install -m 755 rhel/etc_init.d_openvswitch \
- $RPM_BUILD_ROOT/etc/init.d/openvswitch
-install -d -m 755 $RPM_BUILD_ROOT/etc/sysconfig
-install -d -m 755 $RPM_BUILD_ROOT/etc/logrotate.d
-install -m 755 rhel/etc_logrotate.d_openvswitch \
- $RPM_BUILD_ROOT/etc/logrotate.d/openvswitch
-install -d -m 755 $RPM_BUILD_ROOT/usr/share/openvswitch/scripts
-install -m 755 rhel/usr_share_openvswitch_scripts_sysconfig.template \
- $RPM_BUILD_ROOT/usr/share/openvswitch/scripts/sysconfig.template
+for base in \
+ etc_init.d_openvswitch \
+ etc_logrotate.d_openvswitch \
+ etc_sysconfig_network-scripts_ifup-ovs \
+ etc_sysconfig_network-scripts_ifdown-ovs \
+ usr_share_openvswitch_scripts_sysconfig.template; do
+ dst=$RPM_BUILD_ROOT/$(echo $base | sed 's,_,/,g')
+ install -d -m755 "$(dirname $dst)"
+ install rhel/$base "$dst"
+done
+docdir=$RPM_BUILD_ROOT/usr/share/doc/openvswitch-%{version}
+install -d -m755 "$docdir"
+install rhel/README.RHEL "$docdir"
install python/compat/uuid.py $RPM_BUILD_ROOT/usr/share/openvswitch/python
install python/compat/argparse.py $RPM_BUILD_ROOT/usr/share/openvswitch/python
@@ -100,6 +102,8 @@ exit 0
%defattr(-,root,root)
/etc/init.d/openvswitch
/etc/logrotate.d/openvswitch
+/etc/sysconfig/network-scripts/ifup-ovs
+/etc/sysconfig/network-scripts/ifdown-ovs
/etc/openvswitch/bugtool-plugins/*
/usr/bin/ovs-appctl
/usr/bin/ovs-benchmark
@@ -142,4 +146,5 @@ exit 0
/usr/share/openvswitch/scripts/ovs-save
/usr/share/openvswitch/scripts/sysconfig.template
/usr/share/openvswitch/vswitch.ovsschema
+/usr/share/doc/openvswitch-%{version}/README.RHEL
/var/lib/openvswitch