Replace unneeded manual dependency on header by adding it to SRCS.

bsd.lib.mk and bsd.prog.mk already depend all objs on headers in SRCS if
there is not yet a depend file.  The headers in SRCS are never built or
installed.  After 'make depend' the header was already added as a proper
dependency on the objects where needed.

MFC after:	2 weeks
Sponsored by:	EMC / Isilon Storage Division
This commit is contained in:
bdrewery 2015-12-07 16:08:09 +00:00
parent 3f5871ee5c
commit b044b9943f
13 changed files with 18 additions and 36 deletions

View File

@ -12,11 +12,10 @@ SRCS+= roaming_dummy.c
WARNS?= 3
CFLAGS+= -I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
LIBADD= ssh
.include <bsd.lib.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -38,9 +38,11 @@ LIBADD+= ldns
.endif
CFLAGS+= -I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if ${MK_KERBEROS_SUPPORT} != "no"
CFLAGS+= -include krb5_config.h
SRCS+= krb5_config.h
.endif
NO_LINT=
@ -50,8 +52,3 @@ LIBADD+= crypto crypt z
.include <bsd.lib.mk>
.PATH: ${SSHDIR} ${SSHDIR}/openbsd-compat
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h
.if ${MK_KERBEROS_SUPPORT} != "no"
${OBJS} ${POBJS} ${SOBJS}: krb5_config.h
.endif

View File

@ -6,6 +6,7 @@ PROG= sftp-server
SRCS= sftp-server.c sftp-common.c sftp-server-main.c
MAN= sftp-server.8
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -23,5 +24,3 @@ CFLAGS+= -DHAVE_LDNS=1
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -6,6 +6,7 @@ PROG= ssh-keysign
SRCS= ssh-keysign.c roaming_dummy.c readconf.c
MAN= ssh-keysign.8
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
BINMODE=4555
LIBADD= ssh
@ -21,5 +22,3 @@ LIBADD+= crypto
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -6,6 +6,7 @@ PROG= ssh-pkcs11-helper
SRCS= ssh-pkcs11.c ssh-pkcs11-helper.c
MAN= ssh-pkcs11-helper.8
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -25,5 +26,3 @@ LIBADD+= crypto
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= scp
SRCS= scp.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -22,5 +23,3 @@ CFLAGS+= -DHAVE_LDNS=1
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= sftp
SRCS= sftp.c sftp-client.c sftp-common.c sftp-glob.c progressmeter.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -22,5 +23,3 @@ CFLAGS+= -DHAVE_LDNS=1
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= ssh-add
SRCS+= ssh-add.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -22,5 +23,3 @@ CFLAGS+= -DHAVE_LDNS=1
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= ssh-agent
SRCS= ssh-agent.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -24,5 +25,3 @@ LIBADD+= crypto
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= ssh-keygen
SRCS= ssh-keygen.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
.if !defined(NO_SHARED)
# required when linking with a dynamic libssh
@ -22,5 +23,3 @@ LIBADD+= crypto
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -5,6 +5,7 @@
PROG= ssh-keyscan
SRCS= ssh-keyscan.c roaming_dummy.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
LIBADD= ssh
@ -17,5 +18,3 @@ CFLAGS+= -DHAVE_LDNS=1
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h

View File

@ -3,7 +3,6 @@
.include <src.opts.mk>
PROG= ssh
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
LINKS= ${BINDIR}/ssh ${BINDIR}/slogin
MAN= ssh.1 ssh_config.5
MLINKS= ssh.1 slogin.1
@ -15,6 +14,9 @@ SRCS= ssh.c readconf.c clientloop.c sshtty.c \
# gss-genr.c really belongs in libssh; see src/secure/lib/libssh/Makefile
SRCS+= gss-genr.c
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
LIBADD= ssh
.if ${MK_LDNS} != "no"
@ -23,6 +25,7 @@ CFLAGS+= -DHAVE_LDNS=1
.if ${MK_KERBEROS_SUPPORT} != "no"
CFLAGS+= -include krb5_config.h
SRCS+= krb5_config.h
LIBADD+= gssapi
.endif
@ -35,8 +38,3 @@ CFLAGS+= -DXAUTH_PATH=\"${LOCALBASE}/bin/xauth\"
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h
.if ${MK_KERBEROS_SUPPORT} != "no"
${OBJS} ${POBJS} ${SOBJS}: krb5_config.h
.endif

View File

@ -24,6 +24,7 @@ SRCS+= gss-genr.c
MAN= sshd.8 sshd_config.5
CFLAGS+=-I${SSHDIR} -include ssh_namespace.h
SRCS+= ssh_namespace.h
# pam should always happen before ssh here for static linking
LIBADD= pam ssh util wrap
@ -41,6 +42,7 @@ LIBADD+= bsm
.if ${MK_KERBEROS_SUPPORT} != "no"
CFLAGS+= -include krb5_config.h
SRCS+= krb5_config.h
LIBADD+= gssapi_krb5 gssapi krb5
.endif
@ -53,8 +55,3 @@ CFLAGS+= -DXAUTH_PATH=\"${LOCALBASE}/bin/xauth\"
.include <bsd.prog.mk>
.PATH: ${SSHDIR}
${OBJS} ${POBJS} ${SOBJS}: ssh_namespace.h
.if ${MK_KERBEROS_SUPPORT} != "no"
${OBJS} ${POBJS} ${SOBJS}: krb5_config.h
.endif