On 1/19/2016 5:56 AM, Dag-Erling Smørgrav wrote: > Bryan Drewery <[email protected]> writes: >> Log: >> 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. > > This doesn't work. Try the following: > > $ cd /usr/src/secure/lib/libssh > $ make depend && make > $ touch /usr/src/crypto/openssh/ssh_namespace.h > $ make
Well, it sort of works with WITH_FAST_DEPEND which will be default very shortly. > ~/git/freebsd/secure/lib/libssh # make -j15 > ~/git/freebsd/secure/lib/libssh # touch > ../../../crypto/openssh/ssh_namespace.h > ~/git/freebsd/secure/lib/libssh # make > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.authfd.o > -MTauthfd.o -std=gnu99 -fstack-protector-strong -Wno-pointer-sign - > -const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/authfd > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.authfile.o > -MTauthfile.o -std=gnu99 -fstack-protector-strong -Wno-pointer-si > used-const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/au > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.bufaux.o > -MTbufaux.o -std=gnu99 -fstack-protector-strong -Wno-pointer-sign - > -const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/bufaux > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.bufbn.o -MTbufbn.o > -std=gnu99 -fstack-protector-strong -Wno-pointer-sign -Wn > onst-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/bufbn.c > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.buffer.o > -MTbuffer.o -std=gnu99 -fstack-protector-strong -Wno-pointer-sign - > -const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/buffer > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.canohost.o > -MTcanohost.o -std=gnu99 -fstack-protector-strong -Wno-pointer-si > used-const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/ca > /usr/local/bin/ccache cc -O2 -pipe -DHAVE_LDNS=1 > -I/root/git/freebsd/secure/lib/libssh/../../../contrib/ldns > -I/root/git/freebsd/secure/lib/libssh/../../../crypto/openssh -include > ssh_namespace.h -include krb5_config.h -MD -MP -MF.depend.channels.o > -MTchannels.o -std=gnu99 -fstack-protector-strong -Wno-pointer-si > used-const-variable -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion > -Wno-unused-local-typedef -Wno-switch -Wno-switch-enum > -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments -c > /root/git/freebsd/secure/lib/libssh/../../../crypto/openssh/ch > ^Cmake: *** channels.o removed > > The second "make" should rebuild everything, but it doesn't. Also, > > $ grep -c ssh_namespace $(make -V.OBJDIR)/.depend > 0 > That is expected. The dependency is defined in bsd.lib.mk. Granted it is dependent on .depend existing, but I am going to remove that check so it is always defined. -- Regards, Bryan Drewery
signature.asc
Description: OpenPGP digital signature
