File: 0001-include-LDFLAGS-and-CPPFLAGS.patch

package info (click to toggle)
seccure 0.5-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, buster, forky, sid, trixie
  • size: 268 kB
  • sloc: ansic: 2,236; xml: 192; makefile: 100
file content (32 lines) | stat: -rw-r--r-- 1,009 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From: Tomasz Buchert <tomasz@debian.org>
Date: Thu, 3 Sep 2015 11:16:18 +0200
Subject: include-LDFLAGS-and-CPPFLAGS

The build process should respect {C,LD,CPP}FLAGS.
---
 Makefile | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index 4271303..cbd4d47 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,6 @@
-CFLAGS = -O2 -Wall -Wextra -std=c89 -pedantic -D_POSIX_C_SOURCE=200112 # -D NOBEEP
+CFLAGS ?= -O2
+CFLAGS += -Wall -Wextra -std=c89 -pedantic -D_POSIX_C_SOURCE=200112 # -D NOBEEP
+CFLAGS += $(CPPFLAGS)
 LIBS = -lgcrypt
 
 default: binaries # doc
@@ -29,9 +31,8 @@ rebuild: clean default
 
 
 seccure-key: seccure.o numtheory.o ecc.o serialize.o protocol.o curves.o aes256ctr.o
-	$(CC) $(CFLAGS) -o seccure-key seccure.o numtheory.o ecc.o \
+	$(CC) $(CFLAGS) $(LDFLAGS) -o seccure-key seccure.o numtheory.o ecc.o \
 	curves.o serialize.o protocol.o aes256ctr.o $(LIBS)
-	strip seccure-key
 
 seccure-encrypt: seccure-key
 	ln -f seccure-key seccure-encrypt