[packages/wireguard-tools] handle CFLAGS without patch

atler atler at pld-linux.org
Sun Jul 25 22:17:31 CEST 2021


commit c13964653f5064351c75eac8ef453a376a449d70
Author: Jan Palus <atler at pld-linux.org>
Date:   Sun Jul 25 21:50:32 2021 +0200

    handle CFLAGS without patch

 opt.patch            | 11 -----------
 wireguard-tools.spec |  4 +---
 2 files changed, 1 insertion(+), 14 deletions(-)
---
diff --git a/wireguard-tools.spec b/wireguard-tools.spec
index edae8c9..1f50a1c 100644
--- a/wireguard-tools.spec
+++ b/wireguard-tools.spec
@@ -6,7 +6,6 @@ License:	GPL v2
 Group:		Networking/Daemons
 Source0:	https://git.zx2c4.com/wireguard-tools/snapshot/%{name}-%{version}.tar.xz
 # Source0-md5:	b058e5e7eb9f38dbdd553a19c6e5dd22
-Patch0:		opt.patch
 URL:		https://www.wireguard.com/
 BuildRequires:	rpm-build >= 4.6
 BuildRequires:	rpmbuild(macros) >= 1.701
@@ -39,12 +38,11 @@ This package provides bash-completion for WireGuard.
 
 %prep
 %setup -q
-%patch0 -p1
 
 %build
+CFLAGS="%{rpmcflags} %{rpmcppflags}" \
 %{__make} -C src \
 	CC="%{__cc}" \
-	OPTFLAGS="%{rpmcflags} %{rpmcppflags}" \
 	RUNSTATEDIR=%{_rundir} \
 	V=1
 
diff --git a/opt.patch b/opt.patch
deleted file mode 100644
index 98b62e6..0000000
--- a/opt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- wireguard-tools-1.0.20200513/src/Makefile~	2020-05-14 02:29:41.000000000 +0200
-+++ wireguard-tools-1.0.20200513/src/Makefile	2020-05-23 23:35:01.028509121 +0200
-@@ -37,7 +37,7 @@ endif
- 
- PLATFORM ?= $(shell uname -s | tr '[:upper:]' '[:lower:]')
- 
--CFLAGS ?= -O3
-+CFLAGS += $(OPTFLAGS)
- ifneq ($(wildcard uapi/$(PLATFORM)/.),)
- CFLAGS += -idirafter uapi/$(PLATFORM)
- endif
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/wireguard-tools.git/commitdiff/4263a5e0708cf39a551917612349de616e7c1fd0



More information about the pld-cvs-commit mailing list