Lines 1-15
Link Here
|
1 |
--- Makefile.orig 2018-07-16 12:17:05 UTC |
1 |
--- Makefile.orig 2021-04-06 13:54:58 UTC |
2 |
+++ Makefile |
2 |
+++ Makefile |
3 |
@@ -8,9 +8,9 @@ WARNFLAGS = -Wall -Wextra -std=gnu99 -pe |
3 |
@@ -7,18 +7,7 @@ OPTFLAGS = $(shell getconf LFS_CFLAGS) -D_FORTIFY_SOUR |
|
|
4 |
WARNFLAGS = -Wall -Wextra -std=gnu99 -pedantic -Wformat -Werror=format-security |
4 |
DEBUGFLAGS = -g |
5 |
DEBUGFLAGS = -g |
5 |
CFLAGS += $(OPTFLAGS) $(WARNFLAGS) $(DEBUGFLAGS) |
6 |
CFLAGS += $(OPTFLAGS) $(WARNFLAGS) $(DEBUGFLAGS) |
6 |
OS := $(shell uname) |
7 |
- |
7 |
-ifneq ($(OS), Darwin) |
8 |
-# Determine extra LDFLAGS |
8 |
- LDFLAGS += -Wl,-z,relro |
9 |
-OS := $(shell uname) |
|
|
10 |
-ifeq ($(findstring Darwin,$(OS)),Darwin) |
11 |
- skip_ldflags = yes |
12 |
-endif |
13 |
-ifeq ($(findstring CYGWIN,$(OS)),CYGWIN) |
14 |
- skip_ldflags = yes |
15 |
-endif |
16 |
-ifndef skip_ldflags |
17 |
- LDFLAGS += -Wl,-z,relro |
9 |
-endif |
18 |
-endif |
10 |
+.if ${OS} != Darwin |
|
|
11 |
+LDFLAGS += -Wl,-z,relro |
19 |
+LDFLAGS += -Wl,-z,relro |
12 |
+.endif |
|
|
13 |
|
14 |
|
15 |
|
20 |
|
|
|
21 |
all: pcap pcap_kuznet pcapng |
22 |
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) pcapfix.c pcap.o pcap_kuznet.o pcapng.o -o pcapfix |