Skip to content
Snippets Groups Projects
Commit 7c59bc5e authored by Niels Möller's avatar Niels Möller
Browse files

* config.make.in: Insert $(PRE_CPPFLAGS) and $(PRE_LDFLAGS) before

$(CPPFLAGS) and $(LDFLAGS). This mechanism replaces $(INCLUDES).

* examples/Makefile.in (PRE_CPPFLAGS, PRE_LDFLAGS): Use these
flags to get -I.. and -L.. early on the command line.
* testsuite/Makefile.in: Likewise
* tools/Makefile.in: Likewise.

Rev: src/nettle/ChangeLog:1.283
Rev: src/nettle/config.make.in:1.4
Rev: src/nettle/examples/Makefile.in:1.4
Rev: src/nettle/testsuite/Makefile.in:1.4
Rev: src/nettle/tools/Makefile.in:1.5
parent afb21fbe
No related branches found
No related tags found
No related merge requests found
2004-10-20 Niels Mller <nisse@lysator.liu.se>
* config.make.in: Insert $(PRE_CPPFLAGS) and $(PRE_LDFLAGS) before
$(CPPFLAGS) and $(LDFLAGS). This mechanism replaces $(INCLUDES).
* examples/Makefile.in (PRE_CPPFLAGS, PRE_LDFLAGS): Use these
flags to get -I.. and -L.. early on the command line.
* testsuite/Makefile.in: Likewise
* tools/Makefile.in: Likewise.
2004-10-20 Niels Mller <niels@s3.kth.se>
* Makefile.in: In the assembler rules, there's no need to look in
......
......@@ -54,8 +54,11 @@ libdir = @libdir@
includedir = @includedir@
infodir = @infodir@
COMPILE = $(CC) $(CPPFLAGS) $(INCLUDES) $(DEFS) $(CFLAGS) $(CCPIC) $(DEP_FLAGS)
LINK = $(CC) $(CFLAGS) $(LDFLAGS)
# PRE_CPPFLAGS and PRE_LDFLAGS lets each Makefile.in prepend its own
# flags before CPPFLAGS and LDFLAGS.
COMPILE = $(CC) $(PRE_CPPFLAGS) $(CPPFLAGS) $(DEFS) $(CFLAGS) $(CCPIC) $(DEP_FLAGS)
LINK = $(CC) $(CFLAGS) $(PRE_LDFLAGS) $(LDFLAGS)
# Disable builtin rule
%$(EXEEXT) : %.c
......
......@@ -7,7 +7,8 @@ top_srcdir = @top_srcdir@
include ../config.make
INCLUDES = -I.. -I$(top_srcdir)
PRE_CPPFLAGS = -I.. -I$(top_srcdir)
PRE_LDFLAGS = -L..
OPENSSL_LIBFLAGS = @OPENSSL_LIBFLAGS@
TARGETS = nettle-benchmark @RSA_EXAMPLES@
......@@ -23,12 +24,12 @@ DISTFILES= $(SOURCES) Makefile.in $(TS_ALL) run-tests setup-env teardown-env \
all: $(TARGETS)
.c.$(OBJEXT):
$(COMPILE) -I.. -c $<
$(COMPILE) -c $<
.o$(EXEEXT):
$(LINK) $^ $(LIBS) -L.. -lnettle -o $@
$(LINK) $^ -lnettle $(LIBS) -o $@
nettle-benchmark: nettle-benchmark.o nettle-openssl.o ../libnettle.a
$(LINK) $^ $(LIBS) -L.. -lnettle $(OPENSSL_LIBFLAGS) -o $@
$(LINK) $^ -lnettle $(LIBS) $(OPENSSL_LIBFLAGS) -o $@
$(TARGETS) : io.o ../libnettle.a
......
......@@ -7,7 +7,8 @@ top_srcdir = @top_srcdir@
include ../config.make
INCLUDES = -I.. -I$(top_srcdir)
PRE_CPPFLAGS = -I.. -I$(top_srcdir)
PRE_LDFLAGS = -L..
TS_SOURCES = aes-test.c arcfour-test.c arctwo-test.c \
blowfish-test.c cast128-test.c \
......@@ -38,7 +39,7 @@ all: $(TARGETS)
$(COMPILE) -I.. -c $< && $(DEP_PROCESS)
.o$(EXEEXT):
$(LINK) $< testutils.o $(LIBS) -L.. -lnettle -o $@
$(LINK) $< testutils.o -lnettle $(LIBS) -o $@
# .c$(EXEEXT):
# $(COMPILE) -I..
# $(CC) $(CFLAGS) $(LDFLAGS) $*.o testutils.o -L.. -lnettle $(LIBS) -o $@
......
......@@ -7,7 +7,8 @@ top_srcdir = @top_srcdir@
include ../config.make
INCLUDES = -I.. -I$(top_srcdir)
PRE_CPPFLAGS = -I.. -I$(top_srcdir)
PRE_LDFLAGS = -L..
TARGETS = sexp-conv nettle-lfib-stream
......@@ -21,10 +22,10 @@ SOURCES = $(sexp_conv_SOURCES) nettle-lfib-stream.c
DISTFILES = $(SOURCES) Makefile.in getopt.h input.h misc.h output.h parse.h
sexp-conv: $(sexp_conv_SOURCES:.c=.$(OBJEXT)) ../libnettle.a
$(LINK) $^ $(LIBS) -L.. -lnettle -o $@
$(LINK) $^ -lnettle $(LIBS) -o $@
nettle-lfib-stream: nettle-lfib-stream.$(OBJEXT) ../libnettle.a
$(LINK) $^ $(LIBS) -L.. -lnettle -o $@
$(LINK) $^ -lnettle $(LIBS) -o $@
.c.$(OBJEXT):
$(COMPILE) -c $< && $(DEP_PROCESS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment