Module Name:    src
Committed By:   apb
Date:           Sun Dec  9 15:22:54 UTC 2012

Modified Files:
        src/tools/compat: Makefile

Log Message:
Use a "find | while read" loop to install all *.h files anywhere
under ${.OBJDIR}/include, and remove the previous hack of touching a
"dummy" file in each subdirectory.  This should fix a problem on some
platforms where include files directly under ${.OBJDIR}/include (not in
a subdirectory) were not installed.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/tools/compat/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tools/compat/Makefile
diff -u src/tools/compat/Makefile:1.61 src/tools/compat/Makefile:1.62
--- src/tools/compat/Makefile:1.61	Sun Dec  2 12:34:51 2012
+++ src/tools/compat/Makefile	Sun Dec  9 15:22:54 2012
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.61 2012/12/02 12:34:51 apb Exp $
+#	$NetBSD: Makefile,v 1.62 2012/12/09 15:22:54 apb Exp $
 
 HOSTLIB=	nbcompat
 
@@ -106,12 +106,12 @@ install.includes: .PHONY
 	${_MKMSG_INSTALL} "${HOST_INCSDIR}/*"
 	${HOST_INSTALL_DIR} ${HOST_INCSDIR}
 	${HOST_INSTALL_DIR} ${HOST_INCSDIR}/compat
-	${HOST_INSTALL_FILE} ${INCFILES} ${HOST_INCSDIR}/compat/
 .for _d in ${INCSUBDIRS}
 	${HOST_INSTALL_DIR} ${HOST_INCSDIR}/compat/${_d}
-	touch include/${_d}/dummy # ensure dir is not empty
-	${HOST_INSTALL_FILE} include/${_d}/* ${HOST_INCSDIR}/compat/${_d}/
 .endfor
+	(cd include && find . -name '*.h' -print | while read f ; do \
+	    ${HOST_INSTALL_FILE} $$f ${HOST_INCSDIR}/compat/$$f ; \
+	 done)
 
 # Install defs.mk in ${TOOLDIR}/share/compat
 install.defs.mk: .PHONY ${HOST_SHAREDIR}/compat/defs.mk

Reply via email to