From 55a422e224005bacfaf6e2c89f50007968ab4e91 Mon Sep 17 00:00:00 2001 From: Lokesh Mandvekar Date: Jun 30 2017 15:28:29 +0000 Subject: containernetworking-cni-0.5.2-2 - upstream moved to github.com/containernetworking/plugins - built commit dcf7368 - provides: containernetworking-plugins - use vendored deps because they're a lot less of a PITA - excludearch: s390x for now (rhbz#1466865) Signed-off-by: Lokesh Mandvekar --- diff --git a/.gitignore b/.gitignore index fb20fc9..b36ed84 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /cni-0799f57.tar.gz /cni-137b497.tar.gz +/plugins-dcf7368.tar.gz diff --git a/containernetworking-cni.spec b/containernetworking-cni.spec index 0892bf6..5ea38f6 100644 --- a/containernetworking-cni.spec +++ b/containernetworking-cni.spec @@ -1,8 +1,7 @@ - %if 0%{?fedora} -%global with_devel 1 -%global with_bundled 0 -%global with_debug 1 +%global with_devel 0 +%global with_bundled 1 +%global with_debug 0 %global with_check 0 %global with_unit_test 1 %else @@ -26,27 +25,28 @@ %global provider github %global provider_tld com %global project containernetworking -%global repo cni +%global repo plugins # https://github.com/containernetworking/cni %global provider_prefix %{provider}.%{provider_tld}/%{project}/%{repo} %global import_path %{provider_prefix} -%global commit 137b4975ecab6e1f0c24c1e3c228a50a3cfba75e +%global commit dcf7368eeab15e2affc6256f0bb1e84dd46a34de %global shortcommit %(c=%{commit}; echo ${c:0:7}) #################################### Name: containernetworking-cni Version: 0.5.2 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Libraries for writing CNI plugin License: ASL 2.0 URL: https://%{provider_prefix} Source0: https://%{provider_prefix}/archive/%{commit}/%{repo}-%{shortcommit}.tar.gz #################################### -# e.g. el6 has ppc64 arch without gcc-go, so EA tag is required -ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}} +#ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}} +# Fails to build on s390x rhbz#1466865 +ExcludeArch: s390x -#################################### +################################### # If go_compiler is not set to 1, there is no virtual provide. Use golang instead. BuildRequires: %{?go_compiler:compiler(go-compiler)}%{!?go_compiler:golang} @@ -62,6 +62,8 @@ BuildRequires: golang(golang.org/x/sys/unix) BuildRequires: golang(github.com/coreos/go-iptables/iptables) %endif +Provides: containernetworking-plugins = %{version}-%{release} + %description The CNI (Container Network Interface) project consists of a specification and libraries for writing plugins to configure network interfaces in Linux @@ -155,40 +157,12 @@ providing packages with %{import_path} prefix. ################### %build -mkdir -p src/%{provider}.%{provider_tld}/%{project} -ln -s ../../../ src/%{import_path} - -%if ! 0%{?with_bundled} -export GOPATH=$(pwd):%{gopath} -%else -export GOPATH=$(pwd):%{gopath} -%endif - -################### -# TODO: Fix ./build tooling to make make this less brittle. -%gobuild -o bin/cnitool %{import_path}/cnitool -%gobuild -o bin/plugins/dhcp %{import_path}/plugins/ipam/dhcp -%gobuild -o bin/plugins/host-local %{import_path}/plugins/ipam/host-local -%gobuild -o bin/plugins/bridge %{import_path}/plugins/main/bridge -%gobuild -o bin/plugins/ipvlan %{import_path}/plugins/main/ipvlan -%gobuild -o bin/plugins/loopback %{import_path}/plugins/main/loopback -%gobuild -o bin/plugins/macvlan %{import_path}/plugins/main/macvlan -%gobuild -o bin/plugins/ptp %{import_path}/plugins/main/ptp -%gobuild -o bin/plugins/flannel %{import_path}/plugins/meta/flannel -%gobuild -o bin/plugins/tuning %{import_path}/plugins/meta/tuning -%gobuild -o bin/plugins/noop %{import_path}/plugins/test/noop +./build.sh ################### %install -install -d -p %{buildroot}%{_bindir} -install -p -m 0755 bin/cnitool %{buildroot}%{_bindir} - install -d -p %{buildroot}%{_libexecdir}/cni/ -install -p -m 755 -t %{buildroot}%{_libexecdir}/cni/ bin/plugins/* - -#mkdir -p %{buildroot}/opt/cni/bin -#install -d -m 0755 -p %{buildroot}/opt/cni/bin -#ln -sf %{buildroot}%{_libexecdir}/cni/ %{buildroot}/opt/cni/bin +install -p -m 0755 bin/* %{buildroot}/%{_libexecdir}/cni # source codes for building projects %if 0%{?with_devel} @@ -286,7 +260,6 @@ ln -sf /usr/libexec/cni/* /opt/cni/bin %files %license LICENSE %doc *.md -%{_bindir}/cnitool %{_libexecdir}/cni/* %ghost /opt/cni/bin/bridge %ghost /opt/cni/bin/loopback @@ -319,6 +292,13 @@ ln -sf /usr/libexec/cni/* /opt/cni/bin #################################### %changelog +* Fri Jun 30 2017 Lokesh Mandvekar - 0.5.2-2 +- upstream moved to github.com/containernetworking/plugins +- built commit dcf7368 +- provides: containernetworking-plugins +- use vendored deps because they're a lot less of a PITA +- excludearch: s390x for now (rhbz#1466865) + * Mon Jun 12 2017 Timothy St. Clair - 0.5.2-1 - Update to 0.5.2 - Softlink to default /opt/cni/bin directories diff --git a/sources b/sources index e2a3e53..5f6eae2 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (cni-137b497.tar.gz) = 372129673991df57d3df2a9bd6cd3b71df9907570976041d0cb34aa4f42b5aab5a5b972d868c5cb01d3b09d578e5d82578ca653a8c2bad0ab841f36400bccb43 +SHA512 (plugins-dcf7368.tar.gz) = 59b035790870e4349ad9c4ad34c655618bdba7fce8927c2efbcf0f205d7365e0e2b5a853335282f3193b4b8d9ebb41152a828d2d12d3613421a303e6feb8e1ab