1# $NetBSD: Makefile,v 1.34 2021/03/05 17:47:16 christos Exp $ 2 3.include <bsd.own.mk> 4 5.include "../Makefile.inc" 6 7CWARNFLAGS.clang+= -Wno-error=sizeof-array-div 8CWARNFLAGS.clang+= -Wno-error=format-nonliteral 9LIB= ssh 10SRCS=\ 11addr.c \ 12addrmatch.c \ 13atomicio.c \ 14authfd.c \ 15authfile.c \ 16bcrypt_pbkdf.c \ 17bitmap.c \ 18blowfish.c \ 19canohost.c \ 20chacha.c \ 21channels.c \ 22cipher-chachapoly.c \ 23cipher.c \ 24cleanup.c \ 25compat.c \ 26dh.c \ 27dispatch.c \ 28dns.c \ 29ed25519.c \ 30fatal.c \ 31fe25519.c \ 32freezero.c \ 33ge25519.c \ 34hash.c \ 35hmac.c \ 36hostfile.c \ 37kex.c \ 38kexdh.c \ 39kexecdh.c \ 40kexgen.c \ 41kexgex.c \ 42kexgexc.c \ 43kexsntrup761x25519.c \ 44krl.c \ 45log.c \ 46mac.c \ 47match.c \ 48misc.c \ 49monitor_fdpass.c \ 50msg.c \ 51nchan.c \ 52packet.c \ 53poly1305.c \ 54progressmeter.c \ 55readpass.c \ 56recallocarray.c \ 57sc25519.c \ 58smult_curve25519_ref.c \ 59sntrup761.c \ 60ssh-ed25519.c \ 61ssh-ed25519-sk.c \ 62ssh-pkcs11.c \ 63ssh-sk-client.c \ 64ssh-xmss.c \ 65sshbuf-getput-basic.c \ 66sshbuf-getput-crypto.c \ 67sshbuf-misc.c \ 68sshbuf-io.c \ 69sshbuf.c \ 70ssherr.c \ 71sshkey-xmss.c \ 72sshkey.c \ 73ttymodes.c \ 74uidswap.c \ 75umac.c \ 76umac128.c \ 77utf8.c \ 78verify.c \ 79xmalloc.c \ 80xmss_commons.c \ 81xmss_fast.c \ 82xmss_hash.c \ 83xmss_hash_address.c \ 84xmss_wots.c 85 86OPENSSL_SRCS=\ 87digest-openssl.c \ 88kexc25519.c \ 89ssh-dss.c \ 90ssh-ecdsa.c \ 91ssh-ecdsa-sk.c \ 92ssh-rsa.c 93 94SRCS+= fmt_scaled.c 95SRCS+= readpassphrase.c getpeereid.c getrrsetbyname.c 96COPTS.monitor_fdpass.c+=-Wno-stack-protector 97COPTS.xmss_fast.c+= -Wno-stack-protector 98COPTS.xmss_hash.c+= -Wno-stack-protector 99COPTS.xmss_wots.c+= -Wno-stack-protector 100COPTS.sntrup761.c+= -Wno-stack-protector 101 102.if WITH_OPENSSL 103SRCS+= ${OPENSSL_SRCS} 104.else 105SRCS+= digest-libc.c 106.endif 107 108CPPFLAGS+= -DHAVE_BLF_H 109 110CPPFLAGS+= -I${SSHDIST} 111.PATH: ${SSHDIST} 112 113LIBDPLIBS+= crypto ${NETBSDSRCDIR}/crypto/external/bsd/${EXTERNAL_OPENSSL_SUBDIR}/lib/libcrypto \ 114 crypt ${NETBSDSRCDIR}/lib/libcrypt \ 115 z ${NETBSDSRCDIR}/lib/libz 116 117.for f in dns channels hostfile ssh-pkcs11 118COPTS.${f}.c+= -Wno-pointer-sign 119.endfor 120 121# XXX 122COPTS.channels.c+= -fno-strict-aliasing 123 124# XXX 125.if ${MACHINE} == "vax" 126COPTS.poly1305.c+= -O0 127COPTS.umac.c+= -O0 128.endif 129 130COPTS.hostfile.c+= ${GCC_NO_FORMAT_TRUNCATION} 131COPTS.sshkey.c+= ${GCC_NO_FORMAT_TRUNCATION} 132 133.include <bsd.lib.mk> 134