Makefile.in 1.49 KB
Newer Older
1
2
3
4
5
6
7
8
9
@SET_MAKE@

srcdir = @srcdir@
VPATH = @srcdir@

top_srcdir = @top_srcdir@

include ../config.make

10
11
PRE_CPPFLAGS = -I.. -I$(top_srcdir)
PRE_LDFLAGS = -L..
12

Niels Möller's avatar
Niels Möller committed
13
TARGETS = sexp-conv$(EXEEXT) nettle-lfib-stream$(EXEEXT) @RSA_TOOLS@
14
15
16
17
18
19

all: $(TARGETS)

sexp_conv_SOURCES = sexp-conv.c input.c output.c parse.c \
	getopt.c getopt1.c misc.c

Niels Möller's avatar
Niels Möller committed
20
SOURCES = $(sexp_conv_SOURCES) nettle-lfib-stream.c pkcs1-conv.c
21

22
DISTFILES = $(SOURCES) Makefile.in getopt.h input.h misc.h output.h parse.h
23

24
sexp_conv_OBJS = $(sexp_conv_SOURCES:.c=.$(OBJEXT))
25
sexp-conv$(EXEEXT): $(sexp_conv_OBJS) ../libnettle.a
26
	$(LINK) $(sexp_conv_OBJS) -lnettle $(LIBS) -o $@
27

28
nettle-lfib-stream$(EXEEXT): nettle-lfib-stream.$(OBJEXT) ../libnettle.a
29
	$(LINK) nettle-lfib-stream.$(OBJEXT) -lnettle $(LIBS) -o $@
30

Niels Möller's avatar
Niels Möller committed
31
32
33
pkcs1-conv$(EXEEXT): pkcs1-conv.$(OBJEXT) misc.$(OBJEXT) ../libnettle.a
	$(LINK) pkcs1-conv.$(OBJEXT) misc.$(OBJEXT) -lnettle $(LIBS) -o $@

34
.c.$(OBJEXT):
35
	$(COMPILE) -c $< && $(DEP_PROCESS)
36
37
38
39
40
41
42
43
44


Makefile: $(srcdir)/Makefile.in ../config.status
	cd .. && $(SHELL) ./config.status tools/$@

check:
	true

install: $(TARGETS)
45
46
47
48
49
50
51
	$(INSTALL) -d $(DESTDIR)$(bindir)
	$(INSTALL_PROGRAM) $(TARGETS) $(DESTDIR)$(bindir)

uninstall:
	for f in $(TARGETS) ; do \
	  rm -f $(DESTDIR)$(bindir)/$$f ; \
	done
52

53
54
# NOTE: I'd like to use $^, but that's a GNU extension. $? should be
# more portable, equivalent for phony targets.
55
distdir: $(DISTFILES)
56
	cp $? $(distdir)
57
58

clean:
59
	-rm -f $(TARGETS) *.o
60
61

distclean: clean
62
	-rm -f Makefile *.d
63

64
@DEP_INCLUDE@ $(SOURCES:.c=.$(OBJEXT).d)