pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk Double-check that the files named in GNU_MISSING_OV...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/02b0bb1f8eaf
branches:  trunk
changeset: 468312:02b0bb1f8eaf
user:      jlam <jlam%pkgsrc.org@localhost>
date:      Thu Feb 12 13:39:57 2004 +0000

description:
Double-check that the files named in GNU_MISSING_OVERRIDE actually exist
before replacing them.

diffstat:

 mk/bsd.pkg.mk |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (25 lines):

diff -r 72a7eb2542ea -r 02b0bb1f8eaf mk/bsd.pkg.mk
--- a/mk/bsd.pkg.mk     Thu Feb 12 13:34:29 2004 +0000
+++ b/mk/bsd.pkg.mk     Thu Feb 12 13:39:57 2004 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: bsd.pkg.mk,v 1.1390 2004/02/12 13:30:04 jlam Exp $
+#      $NetBSD: bsd.pkg.mk,v 1.1391 2004/02/12 13:39:57 jlam Exp $
 #
 # This file is in the public domain.
 #
@@ -2460,10 +2460,12 @@
 .PHONY: do-gnu-missing-override
 do-gnu-missing-override:
 .  for file in ${GNU_MISSING_OVERRIDE}
-       ${_PKG_SILENT}${_PKG_DEBUG}${RM} -f ${WRKSRC}/${file}
        ${_PKG_SILENT}${_PKG_DEBUG}                                     \
-       ${CP} ${_PKGSRCDIR}/mk/gnu-config/missing ${WRKSRC}/${file}
-       ${_PKG_SILENT}${_PKG_DEBUG}${CHMOD} +x ${WRKSRC}/${file}
+       if [ -f ${WRKSRC}/${file} ]; then                               \
+               ${RM} -f ${WRKSRC}/${file};                             \
+               ${CP} ${_PKGSRCDIR}/mk/gnu-config/missing ${WRKSRC}/${file}; \
+               ${CHMOD} +x ${WRKSRC}/${file};                          \
+       fi
 .  endfor
 .endif
 



Home | Main Index | Thread Index | Old Index