1 # $NetBSD: Makefile,v 1.14 2014/10/19 16:30:59 christos Exp $ 2 3 .include <bsd.own.mk> 4 5 .include "../Makefile.inc" 6 7 LIB= ssh 8 SRCS=\ 9 addrmatch.c \ 10 atomicio.c \ 11 authfd.c \ 12 authfile.c \ 13 bcrypt_pbkdf.c \ 14 blocks.c \ 15 blowfish.c \ 16 bufaux.c \ 17 bufbn.c \ 18 bufec.c \ 19 buffer.c \ 20 canohost.c \ 21 channels.c \ 22 cipher-3des1.c \ 23 cipher-bf1.c \ 24 cipher-chachapoly.c \ 25 cipher.c \ 26 chacha.c \ 27 cleanup.c \ 28 compat.c \ 29 compress.c \ 30 crc32.c \ 31 deattack.c \ 32 dh.c \ 33 dispatch.c \ 34 dns.c \ 35 ed25519.c \ 36 fatal.c \ 37 fe25519.c \ 38 ge25519.c \ 39 hash.c \ 40 hmac.c \ 41 hostfile.c \ 42 kex.c \ 43 kexdh.c \ 44 kexdhc.c \ 45 kexecdh.c \ 46 kexecdhc.c \ 47 kexgex.c \ 48 kexgexc.c \ 49 key.c \ 50 krl.c \ 51 log.c \ 52 mac.c \ 53 match.c \ 54 misc.c \ 55 monitor_fdpass.c \ 56 msg.c \ 57 nchan.c \ 58 packet.c \ 59 poly1305.c \ 60 progressmeter.c \ 61 readpass.c \ 62 roaming_dummy.c \ 63 rsa.c \ 64 sc25519.c \ 65 smult_curve25519_ref.c \ 66 sshbuf-getput-basic.c \ 67 sshbuf-misc.c \ 68 sshbuf-getput-crypto.c \ 69 sshbuf.c \ 70 ssherr.c \ 71 sshkey.c \ 72 ssh-ed25519.c \ 73 ssh-pkcs11.c \ 74 ttymodes.c \ 75 uidswap.c \ 76 uuencode.c \ 77 verify.c \ 78 xmalloc.c 79 80 OPENSSL_SRCS=\ 81 digest-openssl.c \ 82 kexc25519.c \ 83 kexc25519c.c \ 84 kexc25519s.c \ 85 ssh-dss.c \ 86 ssh-ecdsa.c \ 87 ssh-rsa.c 88 89 # umac.c 90 SRCS+= fmt_scaled.c strtonum.c 91 SRCS+= readpassphrase.c getpeereid.c getrrsetbyname.c 92 COPTS.monitor_fdpass.c = -Wno-stack-protector 93 94 .if WITH_OPENSSL 95 SRCS+= ${OPENSSL_SRCS} 96 .else 97 SRCS+= digest-libc.c 98 .endif 99 100 CPPFLAGS+= -DHAVE_BLF_H 101 102 SSHDIST= ${NETBSDSRCDIR}/crypto/external/bsd/openssh/dist 103 CPPFLAGS+= -I${SSHDIST} 104 .PATH: ${SSHDIST} 105 106 LIBDPLIBS+= crypto ${NETBSDSRCDIR}/crypto/external/bsd/openssl/lib/libcrypto \ 107 crypt ${NETBSDSRCDIR}/lib/libcrypt \ 108 z ${NETBSDSRCDIR}/lib/libz 109 110 .for f in dns channels hostfile ssh-pkcs11 111 COPTS.${f}.c+= -Wno-pointer-sign 112 .endfor 113 114 # XXX 115 COPTS.channels.c+= -fno-strict-aliasing 116 117 .include <bsd.lib.mk> 118