Fixing installation of Kyuafiles

Simon J. Gerraty sjg at juniper.net
Fri Jan 10 01:10:49 UTC 2014


On Thu, 9 Jan 2014 23:45:09 +0000, Julio Merino writes:
>If there is a simpler way than my patch, sure, by all means! I kinda
>feel that what I did is a hack, hence this email asking for advice :-P

if you want to stick to generated files, allowing for setting knobs in
makefile that influence them, would address both issues.  But unless
this is a more generic issue, may not be worth it.

Another alternative is:

.if ${KYUAFILE:tl} != "no"
FILES+=		Kyuafile
.if ${KYUAFILE:tl} == "auto"
.NOPATH: Kyuafile
.elif ${.OBJDIR} != ${.CURDIR} && exists(${.CURDIR}/Kyuafile)
# remove any generated file *now*
x!= rm -f ${.OBJDIR}/Kyuafile; echo
.endif
.endif

etc.  You could make that

.elif ${.OBJDIR} != ${.CURDIR} && exists(${.CURDIR}/Kyuafile) && exists(${.OBJDIR}/Kyuafile)

if the gratuitous rm -f bothers you.




More information about the freebsd-testing mailing list