Accepting request 888698 from devel:kubic
OBS-URL: https://build.opensuse.org/request/show/888698 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/cni?expand=0&rev=11
This commit is contained in:
parent
bcda5c0d51
commit
3f90db3491
6
build.sh
6
build.sh
@ -13,10 +13,10 @@ export GO15VENDOREXPERIMENT=1
|
||||
export GOPATH=${PWD}/gopath
|
||||
|
||||
echo "Building API"
|
||||
go build "$@" ${REPO_PATH}/libcni
|
||||
go build -buildmode=pie "$@" ${REPO_PATH}/libcni
|
||||
|
||||
echo "Building reference CLI"
|
||||
go build -o ${PWD}/bin/cnitool "$@" ${REPO_PATH}/cnitool
|
||||
go build -buildmode=pie -o ${PWD}/bin/cnitool "$@" ${REPO_PATH}/cnitool
|
||||
|
||||
echo "Building plugins"
|
||||
PLUGINS="plugins/test/*"
|
||||
@ -24,6 +24,6 @@ for d in $PLUGINS; do
|
||||
if [ -d $d ]; then
|
||||
plugin=$(basename $d)
|
||||
echo " " $plugin
|
||||
go build -o ${PWD}/bin/$plugin "$@" ${REPO_PATH}/$d
|
||||
go build -buildmode=pie -o ${PWD}/bin/$plugin "$@" ${REPO_PATH}/$d
|
||||
fi
|
||||
done
|
||||
|
14
cni.changes
14
cni.changes
@ -1,3 +1,17 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat Apr 24 09:19:04 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- use buildmode=pie (cnitool is installed into sbindir)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Mar 16 05:16:27 UTC 2021 - Jeff Kowalczyk <jkowalczyk@suse.com>
|
||||
|
||||
- Set GO111MODULE=auto to build with go1.16+
|
||||
* Default changed to GO111MODULE=on in go1.16
|
||||
* Set temporarily until using upstream release with go.mod
|
||||
* Drop BuildRequires: golang-packaging not currently using macros
|
||||
* Add BuildRequires: golang(API) >= 1.13 recommended dependency expression
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Oct 1 12:47:37 UTC 2020 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
|
||||
|
||||
|
11
cni.spec
11
cni.spec
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package cni
|
||||
#
|
||||
# Copyright (c) 2020 SUSE LLC
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -30,16 +30,16 @@ URL: https://github.com/containernetworking/cni
|
||||
Source: %{name}-%{version}.tar.xz
|
||||
Source1: 99-loopback.conf
|
||||
Source2: build.sh
|
||||
BuildRequires: golang-packaging
|
||||
BuildRequires: shadow
|
||||
BuildRequires: systemd-rpm-macros
|
||||
BuildRequires: xz
|
||||
BuildRequires: golang(API) >= 1.13
|
||||
Recommends: cni-plugins
|
||||
Requires(post): %fillup_prereq
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
%{?systemd_requires}
|
||||
# Make sure that the binary is not getting stripped.
|
||||
%{go_nostrip}
|
||||
# Remove stripping of Go binaries.
|
||||
%define __arch_install_post export NO_BRP_STRIP_DEBUG=true
|
||||
|
||||
%description
|
||||
The CNI (Container Network Interface) project consists of a
|
||||
@ -55,6 +55,9 @@ range of support and the specification is simple to implement.
|
||||
cp %{SOURCE2} build.sh
|
||||
|
||||
%build
|
||||
# go1.16+ default is GO111MODULE=on set to auto temporarily
|
||||
# until using upstream release with go.mod
|
||||
export GO111MODULE=auto
|
||||
sh ./build.sh
|
||||
|
||||
%install
|
||||
|
Loading…
Reference in New Issue
Block a user