Skip to content

Commit fd2d8e4

Browse files
authored
Merge pull request #24 from aurel32/ldflags
Allow overriding LDFLAGS Makefile variables
2 parents 08c5173 + d787dbb commit fd2d8e4

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

detok/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ INCLUDES = -I../shared
3131

3232
# Normal Flags:
3333
CFLAGS ?= -O2 -Wall #-Wextra
34-
LDFLAGS =
34+
LDFLAGS ?=
3535

3636
# Coverage:
3737
#CFLAGS := $(CFLAGS) -fprofile-arcs -ftest-coverage

romheaders/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ DESTDIR ?= /usr/local
2828
CC ?= gcc
2929
STRIP ?= strip
3030
CFLAGS ?= -O2 -Wall -Wextra
31+
LDFLAGS ?=
3132
INCLUDES = -I../shared
3233

3334
SOURCES = romheaders.c ../shared/classcodes.c
@@ -37,7 +38,7 @@ SOURCES = romheaders.c ../shared/classcodes.c
3738
all: romheaders
3839

3940
romheaders: $(SOURCES)
40-
$(CC) $(CFLAGS) $(INCLUDES) $(SOURCES) -o $@
41+
$(CC) $(LDFLAGS) $(CFLAGS) $(INCLUDES) $(SOURCES) -o $@
4142
$(STRIP) romheaders
4243

4344
clean:

toke/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ INCLUDES = -I../shared
3131

3232
# Normal flags
3333
CFLAGS ?= -O2 -Wall #-Wextra
34-
LDFLAGS =
34+
LDFLAGS ?=
3535

3636
# Coverage:
3737
#CFLAGS := $(CFLAGS) -fprofile-arcs -ftest-coverage

0 commit comments

Comments
 (0)