Mercurial > dropbear
annotate Makefile.in @ 590:a34a6a2e7c72
merge of '4b90e96a8a8afcc9feafc59cb47592a4a6d1cc30'
and '94427244d30e268c74ddade212e31ba01f6f0950'
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Wed, 21 Jul 2010 13:53:29 +0000 |
parents | 1151059c5eff |
children | a86044b99989 |
rev | line source |
---|---|
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
1 # This Makefile is for Dropbear SSH Server and Client |
161 | 2 # @configure_input@ |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
3 |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
4 # invocation: |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
5 # make PROGRAMS="dropbear dbclient scp" MULTI=1 STATIC=1 SCPPROGRESS=1 |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
6 # |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
7 # to make a multiple-program statically linked binary "staticdropbearmulti". |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
8 # This example will include dropbear, scp, dropbearkey, dropbearconvert, and |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
9 # dbclient functionality, and includes the progress-bar functionality in scp. |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
10 # Hopefully that seems intuitive. |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
11 |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
12 ifndef PROGRAMS |
73
0bf5cebe622c
Dropbearkey can now print out pubkey portions
Matt Johnston <matt@ucc.asn.au>
parents:
68
diff
changeset
|
13 PROGRAMS=dropbear dbclient dropbearkey dropbearconvert |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
14 endif |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
15 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
16 LTC=libtomcrypt/libtomcrypt.a |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
17 LTM=libtommath/libtommath.a |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
18 |
585
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
19 ifeq (@BUNDLED_LIBTOM@, 1) |
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
20 LIBTOM_DEPS=$(LTC) $(LTM) |
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
21 CFLAGS+=-I$(srcdir)/libtomcrypt/src/headers/ |
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
22 LIBS+=$(LTC) $(LTM) |
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
23 endif |
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
24 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
25 COMMONOBJS=dbutil.o buffer.o \ |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
26 dss.o bignum.o \ |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
27 signkey.o rsa.o random.o \ |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
28 queue.o \ |
551
c3f2ec71e3d4
New standard linked list to use, rather than adhoc SignKeyList or TCPFwdList
Matt Johnston <matt@ucc.asn.au>
parents:
547
diff
changeset
|
29 atomicio.o compat.o fake-rfc2553.o |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
30 |
23 | 31 SVROBJS=svr-kex.o svr-algo.o svr-auth.o sshpty.o \ |
475
52a644e7b8e1
* Patch from Frédéric Moulins adding options to authorized_keys.
Matt Johnston <matt@ucc.asn.au>
parents:
389
diff
changeset
|
32 svr-authpasswd.o svr-authpubkey.o svr-authpubkeyoptions.o svr-session.o svr-service.o \ |
62 | 33 svr-chansession.o svr-runopts.o svr-agentfwd.o svr-main.o svr-x11fwd.o\ |
520
5e344cdfbae2
- Use the right variable notation
Matt Johnston <matt@ucc.asn.au>
parents:
519
diff
changeset
|
34 svr-tcpfwd.o svr-authpam.o @CRYPTLIB@ |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
35 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
36 CLIOBJS=cli-algo.o cli-main.o cli-auth.o cli-authpasswd.o cli-kex.o \ |
55 | 37 cli-session.o cli-service.o cli-runopts.o cli-chansession.o \ |
547
cf376c696dfc
Make it compile, update for changes in channel structure.
Matt Johnston <matt@ucc.asn.au>
parents:
520
diff
changeset
|
38 cli-authpubkey.o cli-tcpfwd.o cli-channel.o cli-authinteract.o \ |
551
c3f2ec71e3d4
New standard linked list to use, rather than adhoc SignKeyList or TCPFwdList
Matt Johnston <matt@ucc.asn.au>
parents:
547
diff
changeset
|
39 cli-agentfwd.o list.o |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
40 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
41 CLISVROBJS=common-session.o packet.o common-algo.o common-kex.o \ |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
42 common-channel.o common-chansession.o termcodes.o loginrec.o \ |
65
02e4a7f614f8
Oops, forgot to call the actual code.
Matt Johnston <matt@ucc.asn.au>
parents:
64
diff
changeset
|
43 tcp-accept.o listener.o process-packet.o \ |
107 | 44 common-runopts.o circbuffer.o |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
45 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
46 KEYOBJS=dropbearkey.o gendss.o genrsa.o |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
47 |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
48 CONVERTOBJS=dropbearconvert.o keyimport.o |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
49 |
570
fb9a341e4454
- scp progressbar needs strlcat(), so add compat.o
Matt Johnston <matt@ucc.asn.au>
parents:
551
diff
changeset
|
50 SCPOBJS=scp.o progressmeter.o atomicio.o scpmisc.o compat.o |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
51 |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
52 HEADERS=options.h dbutil.h session.h packet.h algo.h ssh.h buffer.h kex.h \ |
68
eee77ac31ccc
cleaning up the pubkey defines
Matt Johnston <matt@ucc.asn.au>
parents:
67
diff
changeset
|
53 dss.h bignum.h signkey.h rsa.h random.h service.h auth.h \ |
23 | 54 debug.h channel.h chansession.h config.h queue.h sshpty.h \ |
68
eee77ac31ccc
cleaning up the pubkey defines
Matt Johnston <matt@ucc.asn.au>
parents:
67
diff
changeset
|
55 termcodes.h gendss.h genrsa.h runopts.h includes.h \ |
64 | 56 loginrec.h atomicio.h x11fwd.h agentfwd.h tcpfwd.h compat.h \ |
67 | 57 listener.h fake-rfc2553.h |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
58 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
59 dropbearobjs=$(COMMONOBJS) $(CLISVROBJS) $(SVROBJS) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
60 dbclientobjs=$(COMMONOBJS) $(CLISVROBJS) $(CLIOBJS) |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
61 dropbearkeyobjs=$(COMMONOBJS) $(KEYOBJS) |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
62 dropbearconvertobjs=$(COMMONOBJS) $(CONVERTOBJS) |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
63 scpobjs=$(SCPOBJS) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
64 |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
65 VPATH=@srcdir@ |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
66 srcdir=@srcdir@ |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
67 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
68 prefix=@prefix@ |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
69 exec_prefix=${prefix} |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
70 bindir=${exec_prefix}/bin |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
71 sbindir=${exec_prefix}/sbin |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
72 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
73 CC=@CC@ |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
74 AR=@AR@ |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
75 RANLIB=@RANLIB@ |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
76 STRIP=@STRIP@ |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
77 INSTALL=@INSTALL@ |
319 | 78 CPPFLAGS=@CPPFLAGS@ |
587
1151059c5eff
Work properly again with bundled libtom*. autoconf is a hassle.
Matt Johnston <matt@ucc.asn.au>
parents:
585
diff
changeset
|
79 CFLAGS+=-I. -I$(srcdir) $(CPPFLAGS) @CFLAGS@ |
585
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
80 LIBS+=@LIBS@ |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
81 LDFLAGS=@LDFLAGS@ |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
82 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
83 EXEEXT=@EXEEXT@ |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
84 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
85 # whether we're building client, server, or both for the common objects. |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
86 # evilness so we detect 'dropbear' by itself as a word |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
87 space:= $(empty) $(empty) |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
88 ifneq (,$(strip $(foreach prog, $(PROGRAMS), $(findstring ZdropbearZ, Z$(prog)Z)))) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
89 CFLAGS+= -DDROPBEAR_SERVER |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
90 endif |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
91 ifneq (,$(strip $(foreach prog, $(PROGRAMS), $(findstring ZdbclientZ, Z$(prog)Z)))) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
92 CFLAGS+= -DDROPBEAR_CLIENT |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
93 endif |
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
94 |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
95 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
96 # these are exported so that libtomcrypt's makefile will use them |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
97 export CC |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
98 export CFLAGS |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
99 export RANLIB AR STRIP |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
100 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
101 ifeq ($(STATIC), 1) |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
102 LDFLAGS+=-static |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
103 endif |
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
104 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
105 ifeq ($(MULTI), 1) |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
106 TARGETS=dropbearmulti |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
107 else |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
108 TARGETS=$(PROGRAMS) |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
109 endif |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
110 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
111 # for the scp progress meter. The -D doesn't affect anything else. |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
112 ifeq ($(SCPPROGRESS), 1) |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
113 CFLAGS+=-DPROGRESS_METER |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
114 endif |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
115 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
116 all: $(TARGETS) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
117 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
118 strip: $(TARGETS) |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
119 $(STRIP) $(addsuffix $(EXEEXT), $(TARGETS)) |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
120 |
132
c56d40d54538
use inst_ rather than inst, so it doesn't try to install "all".
Matt Johnston <matt@ucc.asn.au>
parents:
119
diff
changeset
|
121 install: $(addprefix inst_, $(TARGETS)) |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
122 |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
123 installdropbearmulti: insdbmulti $(addprefix insmulti, $(PROGRAMS)) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
124 |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
125 insdbmulti: dropbearmulti |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
126 $(INSTALL) -d -m 755 $(DESTDIR)$(bindir) |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
127 $(INSTALL) -m 755 dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
128 -chown root $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
129 -chgrp 0 $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT) |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
130 |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
131 insmultidropbear: dropbearmulti |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
132 -rm -f $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
133 -ln -s $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
134 |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
135 insmulti%: dropbearmulti |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
136 -rm -f $(DESTDIR)$(bindir)/$*$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
137 -ln -s $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir)/$*$(EXEEXT) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
138 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
139 # dropbear should go in sbin, so it needs a seperate rule |
132
c56d40d54538
use inst_ rather than inst, so it doesn't try to install "all".
Matt Johnston <matt@ucc.asn.au>
parents:
119
diff
changeset
|
140 inst_dropbear: dropbear |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
141 $(INSTALL) -d -m 755 $(DESTDIR)$(sbindir) |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
142 $(INSTALL) -m 755 dropbear$(EXEEXT) $(DESTDIR)$(sbindir) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
143 -chown root $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
144 -chgrp 0 $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
145 |
132
c56d40d54538
use inst_ rather than inst, so it doesn't try to install "all".
Matt Johnston <matt@ucc.asn.au>
parents:
119
diff
changeset
|
146 inst_%: $* |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
147 $(INSTALL) -d -m 755 $(DESTDIR)$(bindir) |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
148 $(INSTALL) -m 755 $*$(EXEEXT) $(DESTDIR)$(bindir) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
149 -chown root $(DESTDIR)$(bindir)/$*$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
150 -chgrp 0 $(DESTDIR)$(bindir)/$*$(EXEEXT) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
151 |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
152 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
153 # for some reason the rule further down doesn't like $($@objs) as a prereq. |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
154 dropbear: $(dropbearobjs) |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
155 dbclient: $(dbclientobjs) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
156 dropbearkey: $(dropbearkeyobjs) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
157 dropbearconvert: $(dropbearconvertobjs) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
158 |
585
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
159 dropbear dbclient dropbearkey dropbearconvert: $(HEADERS) $(LIBTOM_DEPS) Makefile |
366
59531221b846
Fix up separate-directory building for libtomcrypt
Matt Johnston <matt@ucc.asn.au>
parents:
319
diff
changeset
|
160 $(CC) $(LDFLAGS) -o $@$(EXEEXT) $($@objs) $(LIBS) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
161 |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
162 # scp doesn't use the libs so is special. |
33 | 163 scp: $(SCPOBJS) $(HEADERS) Makefile |
366
59531221b846
Fix up separate-directory building for libtomcrypt
Matt Johnston <matt@ucc.asn.au>
parents:
319
diff
changeset
|
164 $(CC) $(LDFLAGS) -o $@$(EXEEXT) $(SCPOBJS) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
165 |
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
166 |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
167 # multi-binary compilation. |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
168 MULTIOBJS= |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
169 ifeq ($(MULTI),1) |
30
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
170 MULTIOBJS=dbmulti.o $(sort $(foreach prog, $(PROGRAMS), $($(prog)objs))) |
223b0f5f8dce
Switching to the magical new Makefile, and new dbmulti style
Matt Johnston <matt@ucc.asn.au>
parents:
29
diff
changeset
|
171 CFLAGS+=$(addprefix -DDBMULTI_, $(PROGRAMS)) -DDROPBEAR_MULTI |
381
999a5eb4ed10
propagate from branch 'au.asn.ucc.matt.ltc.orig' (head 52840647ac7f5c707c3bd158d119a15734a7ef28)
Matt Johnston <matt@ucc.asn.au>
parents:
281
diff
changeset
|
172 endif |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
173 |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
174 dropbearmulti: multilink |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
175 |
585
d194db6f9453
Use system libtomcrypt/libtommath if available. Doesn't currently
Matt Johnston <matt@ucc.asn.au>
parents:
570
diff
changeset
|
176 multibinary: $(HEADERS) $(MULTIOBJS) $(LIBTOM_DEPS) Makefile |
366
59531221b846
Fix up separate-directory building for libtomcrypt
Matt Johnston <matt@ucc.asn.au>
parents:
319
diff
changeset
|
177 $(CC) $(LDFLAGS) -o dropbearmulti$(EXEEXT) $(MULTIOBJS) $(LIBS) |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
178 |
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
179 multilink: multibinary $(addprefix link, $(PROGRAMS)) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
180 |
82
8f26145a0997
do the symlinks for multi-binary compiles
Matt Johnston <matt@ucc.asn.au>
parents:
81
diff
changeset
|
181 link%: |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
182 -rm -f $*$(EXEEXT) |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
183 -ln -s dropbearmulti$(EXEEXT) $*$(EXEEXT) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
184 |
33 | 185 $(LTC): options.h |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
186 cd libtomcrypt && $(MAKE) clean && $(MAKE) |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
187 |
33 | 188 $(LTM): options.h |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
189 cd libtommath && $(MAKE) |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
190 |
366
59531221b846
Fix up separate-directory building for libtomcrypt
Matt Johnston <matt@ucc.asn.au>
parents:
319
diff
changeset
|
191 .PHONY : clean sizes thisclean distclean tidy ltc-clean ltm-clean |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
192 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
193 ltc-clean: |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
194 cd libtomcrypt && $(MAKE) clean |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
195 |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
196 ltm-clean: |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
197 cd libtommath && $(MAKE) clean |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
198 |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
199 sizes: dropbear |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
200 objdump -t dropbear|grep ".text"|cut -d "." -f 2|sort -rn |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
201 |
86 | 202 clean: ltc-clean ltm-clean thisclean |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
203 |
86 | 204 thisclean: |
174
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
205 -rm -f dropbear dbclient dropbearkey dropbearconvert scp scp-progress \ |
c753db8eb446
* don't add a 'static' prefix to binary names
Matt Johnston <matt@ucc.asn.au>
parents:
161
diff
changeset
|
206 dropbearmulti *.o *.da *.bb *.bbg *.prof |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
207 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
208 distclean: clean tidy |
29
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
209 -rm -f config.h |
0fcf63e1cb01
Totally reworked Makefile.in
Matt Johnston <matt@ucc.asn.au>
parents:
24
diff
changeset
|
210 -rm -f Makefile |
281
997e6f7dc01e
Just import the Dropbear 0.47 libtomcrypt changes
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
211 |
4
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
212 tidy: |
fe6bca95afa7
Makefile.in contains updated files required
Matt Johnston <matt@ucc.asn.au>
parents:
diff
changeset
|
213 -rm -f *~ *.gcov */*~ |