1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
Upstream-Status: Submitted
dropbear: fix static build
A more appropriate fix is to remove @CRYPTLIB@ from the objs
line, since it will cause problems with target checking,
this change also meets the goals of the orignal change which
was to not link libcrypt to all binaries.
svr-authpasswd.o: In function `svr_auth_password':
svr-authpasswd.c:(.text+0xfc): undefined reference to `crypt'
collect2: ld returned 1 exit status
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Index: dropbear-2011.54/Makefile.in
===================================================================
--- dropbear-2011.54.orig/Makefile.in 2011-11-08 04:48:15.000000000 -0800
+++ dropbear-2011.54/Makefile.in 2011-12-27 13:44:41.644354442 -0800
@@ -56,7 +56,7 @@
loginrec.h atomicio.h x11fwd.h agentfwd.h tcpfwd.h compat.h \
listener.h fake-rfc2553.h
-dropbearobjs=$(COMMONOBJS) $(CLISVROBJS) $(SVROBJS) @CRYPTLIB@
+dropbearobjs=$(COMMONOBJS) $(CLISVROBJS) $(SVROBJS)
dbclientobjs=$(COMMONOBJS) $(CLISVROBJS) $(CLIOBJS)
dropbearkeyobjs=$(COMMONOBJS) $(KEYOBJS)
dropbearconvertobjs=$(COMMONOBJS) $(CONVERTOBJS)
@@ -158,7 +158,10 @@
dropbearkey: $(dropbearkeyobjs)
dropbearconvert: $(dropbearconvertobjs)
-dropbear dbclient dropbearkey dropbearconvert: $(HEADERS) $(LIBTOM_DEPS) Makefile
+dropbear: $(HEADERS) $(LIBTOM_DEPS) Makefile
+ $(CC) $(LDFLAGS) -o $@$(EXEEXT) $($@objs) $(LIBS) @CRYPTLIB@
+
+dbclient dropbearkey dropbearconvert: $(HEADERS) $(LIBTOM_DEPS) Makefile
$(CC) $(LDFLAGS) -o $@$(EXEEXT) $($@objs) $(LIBS)
# scp doesn't use the libs so is special.
@@ -169,14 +172,14 @@
# multi-binary compilation.
MULTIOBJS=
ifeq ($(MULTI),1)
- MULTIOBJS=dbmulti.o $(sort $(foreach prog, $(PROGRAMS), $($(prog)objs))) @CRYPTLIB@
+ MULTIOBJS=dbmulti.o $(sort $(foreach prog, $(PROGRAMS), $($(prog)objs)))
CFLAGS+=$(addprefix -DDBMULTI_, $(PROGRAMS)) -DDROPBEAR_MULTI
endif
dropbearmulti: multilink
multibinary: $(HEADERS) $(MULTIOBJS) $(LIBTOM_DEPS) Makefile
- $(CC) $(LDFLAGS) -o dropbearmulti$(EXEEXT) $(MULTIOBJS) $(LIBS)
+ $(CC) $(LDFLAGS) -o dropbearmulti$(EXEEXT) $(MULTIOBJS) $(LIBS) @CRYPTLIB@
multilink: multibinary $(addprefix link, $(PROGRAMS))
|