From 775741546f6975f7672aef4252cd70703c762e9f Mon Sep 17 00:00:00 2001 From: Lokesh Mandvekar Date: Jan 27 2021 16:25:01 +0000 Subject: do not build for armv7hl also update CGO_CFLAGS formatting Signed-off-by: Lokesh Mandvekar --- diff --git a/oci-seccomp-bpf-hook.spec b/oci-seccomp-bpf-hook.spec index 8ec4de8..8b4a7fe 100644 --- a/oci-seccomp-bpf-hook.spec +++ b/oci-seccomp-bpf-hook.spec @@ -38,7 +38,7 @@ go build -buildmode pie -compiler gc -tags="rpm_crashtraceback libtrust_openssl %define built_tag v1.2.1 # use the same arch definitions as present in the bcc package -ExclusiveArch: x86_64 %{power64} aarch64 s390x armv7hl +ExclusiveArch: x86_64 %{power64} aarch64 s390x Name: oci-seccomp-bpf-hook Version: 1.2.2 @@ -73,13 +73,7 @@ sed -i '/$(HOOK_DIR)\/%{name}.json/d' Makefile %build export GO111MODULE=off export GOPATH=$(pwd):$(pwd)/_build -export CGO_CFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall \ - -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 \ - -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 \ - -ffat-lto-objects -fexceptions \ - -fasynchronous-unwind-tables -fstack-protector-strong \ - -fstack-clash-protection -D_GNU_SOURCE \ - -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64" +export CGO_CFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -ffat-lto-objects -fexceptions -fasynchronous-unwind-tables -fstack-protector-strong -fstack-clash-protection -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64" %ifarch x86_64 export CGO_CFLAGS="$CGO_CFLAGS -m64 -mtune=generic" %if 0%{?fedora} || 0%{?centos} >= 8