# norootforbuild Name: openvswitch Summary: Utilities for configuring vswitch Version: 1.1.0 License: GPL v2 or later Release: 0 Group: Productivity/Networking/System Source: %{name}-%{version}.tar.bz2 BuildRoot: %{_tmppath}/%{name}-%{version}-root Requires: logrotate Patch0: ovs-suse.patch %description virtual switching for the large scale data center virtualization environment %package -n openvswitch-KMP Group: Productivity/Networking/System License: GPL v2 or later Summary: Kernel module Requires: kernel-default kernel-desktop BuildRequires: perl-base autoconf automake libtool kernel-source kernel-syms module-init-tools %suse_kernel_module_package ec2 xen xenpae vmi um BuildRequires: openssl libopenssl-devel python-base ncurses-devel pcre-devel pkg-config pcre-devel pyxml %description -n openvswitch-KMP Kernel modules supporting the openvswitch datapath %prep %setup %patch0 -p1 set -- * mkdir source mv "$@" source/ mkdir obj %build export EXTRA_CFLAGS='-DVERSION=\"%version\"' pushd source bash -x boot.sh popd for flavor in %flavors_to_build; do rm -rf obj/$flavor cp -r source obj/$flavor pushd obj/$flavor ./configure --enable-ssl=yes --with-logdir=/var/log --with-l26=/usr/src/linux-obj/%_target_cpu/$flavor --with-l26-source=/usr/src/linux cd datapath/linux-2.6 make popd done pwd ls source pushd source %configure --with-logdir=/var/log make %{?_smp_mflags} popd %install export INSTALL_MOD_PATH=$RPM_BUILD_ROOT export INSTALL_MOD_DIR=updates for flavor in %flavors_to_build; do pushd obj/$flavor/datapath/linux-2.6 make -C /usr/src/linux-obj/%_target_cpu/$flavor modules_install M=$PWD popd done pushd source make install DESTDIR=$RPM_BUILD_ROOT INSTALL="%{__install} -p" install -d -m 755 $RPM_BUILD_ROOT/etc install -d -m 755 $RPM_BUILD_ROOT/etc/init.d install -m 755 xenserver/etc_init.d_openvswitch \ $RPM_BUILD_ROOT/etc/init.d/openvswitch install -m 755 xenserver/etc_init.d_openvswitch-xapi-update \ $RPM_BUILD_ROOT/etc/init.d/openvswitch-xapi-update install -d -m 755 $RPM_BUILD_ROOT/etc/sysconfig install -d -m 755 $RPM_BUILD_ROOT/etc/logrotate.d install -m 644 xenserver/etc_logrotate.d_openvswitch \ $RPM_BUILD_ROOT/etc/logrotate.d/openvswitch install -d -m 755 $RPM_BUILD_ROOT/etc/profile.d install -m 644 xenserver/etc_profile.d_openvswitch.sh \ $RPM_BUILD_ROOT/etc/profile.d/openvswitch.sh install -d -m 755 $RPM_BUILD_ROOT/etc/xapi.d/plugins install -m 755 xenserver/etc_xapi.d_plugins_openvswitch-cfg-update \ $RPM_BUILD_ROOT/etc/xapi.d/plugins/openvswitch-cfg-update install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts install -m 644 vswitchd/vswitch.ovsschema \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/vswitch.ovsschema install -m 755 xenserver/opt_xensource_libexec_interface-reconfigure \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/interface-reconfigure install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigure.py \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigure.py install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureBridge.py \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigureBridge.py install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigureVswitch.py install -m 755 xenserver/etc_xensource_scripts_vif \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/vif install -m 755 xenserver/usr_share_openvswitch_scripts_ovs-external-ids \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/ovs-external-ids install -m 755 xenserver/usr_share_openvswitch_scripts_refresh-xs-network-uuids \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/refresh-xs-network-uuids install -m 755 xenserver/usr_sbin_xen-bugtool \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/xen-bugtool install -m 755 xenserver/usr_sbin_brctl \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/brctl install -m 644 xenserver/usr_share_openvswitch_scripts_sysconfig.template \ $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/sysconfig.template install -d -m 755 $RPM_BUILD_ROOT%{_libdir}/xsconsole/plugins-base install -m 644 \ xenserver/usr_lib_xsconsole_plugins-base_XSFeatureVSwitch.py \ $RPM_BUILD_ROOT%{_libdir}/xsconsole/plugins-base/XSFeatureVSwitch.py install -m 644 xenserver/uuid.py $RPM_BUILD_ROOT%{_datadir}/openvswitch/python popd # Get rid of stuff we don't want to make RPM happy. rm \ $RPM_BUILD_ROOT%{_bindir}/ovs-controller \ $RPM_BUILD_ROOT%{_bindir}/ovs-discover \ $RPM_BUILD_ROOT%{_bindir}/ovs-kill \ $RPM_BUILD_ROOT%{_bindir}/ovs-openflowd \ $RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-controller.8 \ $RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-discover.8 \ $RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-kill.8 \ $RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-openflowd.8 \ %files %defattr(-,root,root) %{_sysconfdir}/init.d/openvswitch %{_sysconfdir}/init.d/openvswitch-xapi-update %{_sysconfdir}/xapi.d/plugins/openvswitch-cfg-update %config %{_sysconfdir}/logrotate.d/openvswitch %config %{_sysconfdir}/profile.d/openvswitch.sh %dir %{_datadir}/openvswitch %dir %{_sysconfdir}/xapi.d %dir %{_sysconfdir}/xapi.d/plugins %{_datadir}/openvswitch/python/ovs/__init__.py %{_datadir}/openvswitch/python/ovs/daemon.py %{_datadir}/openvswitch/python/ovs/db/__init__.py %{_datadir}/openvswitch/python/ovs/db/data.py %{_datadir}/openvswitch/python/ovs/db/error.py %{_datadir}/openvswitch/python/ovs/db/idl.py %{_datadir}/openvswitch/python/ovs/db/parser.py %{_datadir}/openvswitch/python/ovs/db/schema.py %{_datadir}/openvswitch/python/ovs/db/types.py %{_datadir}/openvswitch/python/ovs/dirs.py %{_datadir}/openvswitch/python/ovs/fatal_signal.py %{_datadir}/openvswitch/python/ovs/json.py %{_datadir}/openvswitch/python/ovs/jsonrpc.py %{_datadir}/openvswitch/python/ovs/ovsuuid.py %{_datadir}/openvswitch/python/ovs/poller.py %{_datadir}/openvswitch/python/ovs/process.py %{_datadir}/openvswitch/python/ovs/reconnect.py %{_datadir}/openvswitch/python/ovs/socket_util.py %{_datadir}/openvswitch/python/ovs/stream.py %{_datadir}/openvswitch/python/ovs/timeval.py %{_datadir}/openvswitch/python/ovs/util.py %{_datadir}/openvswitch/python/uuid.py %{_datadir}/openvswitch/scripts/ovs-external-ids %{_datadir}/openvswitch/scripts/refresh-xs-network-uuids %{_datadir}/openvswitch/scripts/interface-reconfigure %{_datadir}/openvswitch/scripts/InterfaceReconfigure.py %{_datadir}/openvswitch/scripts/InterfaceReconfigureBridge.py %{_datadir}/openvswitch/scripts/InterfaceReconfigureVswitch.py %{_datadir}/openvswitch/scripts/vif %{_datadir}/openvswitch/scripts/xen-bugtool %{_datadir}/openvswitch/scripts/brctl %{_datadir}/openvswitch/scripts/sysconfig.template %{_datadir}/openvswitch/vswitch.ovsschema %{_sbindir}/ovs-brcompatd %{_sbindir}/ovs-vswitchd %{_sbindir}/ovsdb-server %{_bindir}/ovs-pki %{_bindir}/ovs-appctl %{_bindir}/ovs-dpctl %{_bindir}/ovs-ofctl %{_bindir}/ovs-vsctl %{_bindir}/ovsdb-client %{_bindir}/ovsdb-tool %{_libdir}/xsconsole/plugins-base/XSFeatureVSwitch.py %{_datadir}/man/man1/ovsdb-client.1.gz %{_datadir}/man/man1/ovsdb-server.1.gz %{_datadir}/man/man1/ovsdb-tool.1.gz %{_datadir}/man/man5/ovs-vswitchd.conf.db.5.gz %{_datadir}/man/man8/ovs-pki.8.gz %{_datadir}/man/man8/ovs-appctl.8.gz %{_datadir}/man/man8/ovs-brcompatd.8.gz %{_datadir}/man/man8/ovs-dpctl.8.gz %{_datadir}/man/man8/ovs-ofctl.8.gz %{_datadir}/man/man8/ovs-parse-leaks.8.gz %{_datadir}/man/man8/ovs-vsctl.8.gz %{_datadir}/man/man8/ovs-vswitchd.8.gz %changelog # * Tue April 13 2010 pmullaney@novell.com # - Initial Package, Version 0.99.2 # * Sun Sept 12 2010 pmullaney@novell.com # - Updated Package, Version 1.0.1