- Add %check directive to run the openvswitch testsuite on demand. The openvswitch contains hundreds of tests covering simple and complex openvswitch configuration so it's beneficial to run them during package builds. However, running the testsuite is not enabled by default. Also add the following upstream patch: * 0001-Remove-broken-pipe-warning-logs-from-ovsdb-server.lo.patch - Build a DPDK-enabled Open vSwitch (fate#319170) * Apply the following changes to the openvswitch.spec file - Add support for building with DPDK capabilities - Add conflicts between the two packages. - Add new 'open_virtual_switch-*' capabilities for openvswitch, openvswitch-switch, openvswitch-test packages which can be used by reverse dependencies to select between the two openvswitch implementations. * Add pre_checkin.sh to generate the openvswitch_dpdk.spec file based on the openvswitch.spec one. * Add upstream openvswitch-2.5.0-detect-dpdk-installation.patch patch to detect and link against a DPDK installation. OBS-URL: https://build.opensuse.org/request/show/402853 OBS-URL: https://build.opensuse.org/package/show/network/openvswitch?expand=0&rev=91
20 lines
587 B
Bash
20 lines
587 B
Bash
#!/bin/sh
|
|
|
|
# Start fresh
|
|
for f in spec changes; do
|
|
cp openvswitch.$f openvswitch_dpdk.$f || exit 1
|
|
done
|
|
|
|
#
|
|
#- Add comment about generated file
|
|
#- Fix {,sub-}package name, description, summary
|
|
#- Enable the dpdk conditional build
|
|
sed -i -e "/^Name:.*openvswitch$/i \
|
|
# Do NOT edit this auto generated file! Edit openvswitch.spec instead\n\
|
|
# and run 'pre_checkin.sh' before committing" \
|
|
-e "/^#\s*spec file/s/openvswitch$/&_dpdk/" \
|
|
-e "/^Name:/s/openvswitch/&_dpdk/g" \
|
|
-e "/^Summary:/s/^.*$/&\ \(DPDK\)/g" \
|
|
-e "/^%bcond_with\s*dpdk/s/with/&out/" \
|
|
openvswitch_dpdk.spec || exit 1
|