CVS commit: src/sys/conf

2015-11-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Nov 27 20:59:47 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
use commands() instead of target() because assym.mk creates all the targets
unconditionally.


To generate a diff of this commit:
cvs rdiff -u -r1.248 -r1.249 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.248 src/sys/conf/Makefile.kern.inc:1.249
--- src/sys/conf/Makefile.kern.inc:1.248	Fri Nov 27 15:33:55 2015
+++ src/sys/conf/Makefile.kern.inc	Fri Nov 27 15:59:47 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.248 2015/11/27 20:33:55 christos Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.249 2015/11/27 20:59:47 christos Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -367,7 +367,7 @@ DEPS+=	${SRCS:R:S/$/.d/g}
 
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${SSRCS}
-.if !target(${_s:T:R}.d)
+.if !commands(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s}
 	${_MKTARGET_CREATE}
 	${MKDEP} -f ${.TARGET}.tmp -- ${MKDEP_AFLAGS} \
@@ -377,7 +377,7 @@ ${_s:T:R}.d: ${_s}
 .endfor
 
 .for _s in ${CSRCS}
-.if !target(${_s:T:R}.d)
+.if !commands(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s}
 	${_MKTARGET_CREATE}
 	${MKDEP} -f ${.TARGET}.tmp -- ${MKDEP_CFLAGS} \



CVS commit: src/sys/conf

2015-11-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Nov 27 20:59:47 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
use commands() instead of target() because assym.mk creates all the targets
unconditionally.


To generate a diff of this commit:
cvs rdiff -u -r1.248 -r1.249 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-11-13 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Nov 14 07:31:13 UTC 2015

Modified Files:
src/sys/conf: std

Log Message:
Always include the "vfs" attribute (module).  Although all of the
ufs/xxx file systems depend on the vfs attribute, it is not required
that any file system actually be built-in to the kernel.  (At least
on some architectures, file system modules can be loaded at boot
time.)


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/conf/std

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



CVS commit: src/sys/conf

2015-11-13 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Nov 14 07:31:13 UTC 2015

Modified Files:
src/sys/conf: std

Log Message:
Always include the "vfs" attribute (module).  Although all of the
ufs/xxx file systems depend on the vfs attribute, it is not required
that any file system actually be built-in to the kernel.  (At least
on some architectures, file system modules can be loaded at boot
time.)


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/conf/std

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

Modified files:

Index: src/sys/conf/std
diff -u src/sys/conf/std:1.20 src/sys/conf/std:1.21
--- src/sys/conf/std:1.20	Fri Oct 31 07:38:36 2014
+++ src/sys/conf/std	Sat Nov 14 07:31:13 2015
@@ -1,4 +1,4 @@
-# $NetBSD: std,v 1.20 2014/10/31 07:38:36 uebayasi Exp $
+# $NetBSD: std,v 1.21 2015/11/14 07:31:13 pgoyette Exp $
 #
 # standard MI 'options'
 #
@@ -11,6 +11,14 @@
 #
 select	kern
 
+# Always include the "vfs" attribute (module).  Although all of the
+# ufs/xxx file systems depend on the vfs attribute, it is not required
+# that any file system actually be built-in to the kernel.  (At least
+# on some architectures, file system modules can be loaded at boot
+# time.)
+
+select vfs
+
 select	net		# XXX Clean up dependency
 
 # the following options are on-by-default to keep



CVS commit: src/sys/conf

2015-09-11 Thread Nathanial Sloss
Module Name:src
Committed By:   nat
Date:   Fri Sep 11 15:56:56 UTC 2015

Modified Files:
src/sys/conf: splash.mk

Log Message:
Fix splashscreen_image option to include splash_image.o

OK from christos@


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/splash.mk

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

Modified files:

Index: src/sys/conf/splash.mk
diff -u src/sys/conf/splash.mk:1.1 src/sys/conf/splash.mk:1.2
--- src/sys/conf/splash.mk:1.1	Sun Aug 30 07:33:53 2015
+++ src/sys/conf/splash.mk	Fri Sep 11 15:56:56 2015
@@ -1,7 +1,7 @@
-# $NetBSD: splash.mk,v 1.1 2015/08/30 07:33:53 uebayasi Exp $
+# $NetBSD: splash.mk,v 1.2 2015/09/11 15:56:56 nat Exp $
 
 # Option for embedding a splashscreen image.
 .if defined(SPLASHSCREEN_IMAGE) 
 .include "${S}/dev/splash/splash.mk"
-init_main.o: splash_image.o
+OBJS+= splash_image.o
 .endif



CVS commit: src/sys/conf

2015-09-11 Thread Nathanial Sloss
Module Name:src
Committed By:   nat
Date:   Fri Sep 11 15:56:56 UTC 2015

Modified Files:
src/sys/conf: splash.mk

Log Message:
Fix splashscreen_image option to include splash_image.o

OK from christos@


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/splash.mk

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



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep 10 09:30:02 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Simplify the dependency line further.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/conf/assym.mk

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

Modified files:

Index: src/sys/conf/assym.mk
diff -u src/sys/conf/assym.mk:1.3 src/sys/conf/assym.mk:1.4
--- src/sys/conf/assym.mk:1.3	Wed Sep  9 03:27:15 2015
+++ src/sys/conf/assym.mk	Thu Sep 10 09:30:01 2015
@@ -1,4 +1,4 @@
-# $NetBSD: assym.mk,v 1.3 2015/09/09 03:27:15 uebayasi Exp $
+# $NetBSD: assym.mk,v 1.4 2015/09/10 09:30:01 uebayasi Exp $
 
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
@@ -7,11 +7,7 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
 	mv -f assym.h.tmp assym.h
 
-.if !defined(___USE_SUFFIX_RULES___)
-${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
-.else
-${SRCS:M*.[sS]}: assym.h
-.endif
+${SRCS:M*.[sS]:C|\.[Ss]|.o|}: assym.h
 
 assym.d: assym.h
 	${_MKTARGET_CREATE}



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep 10 09:30:02 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Simplify the dependency line further.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/conf/assym.mk

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



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep 10 13:11:39 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc assym.mk

Log Message:
Fix dependency of *.d -> assym.h in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.244 -r1.245 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r1.4 -r1.5 src/sys/conf/assym.mk

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



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep 10 13:11:39 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc assym.mk

Log Message:
Fix dependency of *.d -> assym.h in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.244 -r1.245 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r1.4 -r1.5 src/sys/conf/assym.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.244 src/sys/conf/Makefile.kern.inc:1.245
--- src/sys/conf/Makefile.kern.inc:1.244	Mon Sep  7 15:55:06 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep 10 13:11:39 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.244 2015/09/07 15:55:06 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.245 2015/09/10 13:11:39 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -358,7 +358,7 @@ DEPS=	${SRCS:R:S/$/.d/g}
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${SSRCS}
 .if !target(${_s:T:R}.d)
-${_s:T:R}.d: ${_s} assym.h
+${_s:T:R}.d: ${_s}
 	${_MKTARGET_CREATE}
 	${MKDEP} -f ${.TARGET}.tmp -- ${MKDEP_AFLAGS} \
 	${CPPFLAGS} ${CPPFLAGS.${_s:T}} ${_s}

Index: src/sys/conf/assym.mk
diff -u src/sys/conf/assym.mk:1.4 src/sys/conf/assym.mk:1.5
--- src/sys/conf/assym.mk:1.4	Thu Sep 10 09:30:01 2015
+++ src/sys/conf/assym.mk	Thu Sep 10 13:11:39 2015
@@ -1,4 +1,4 @@
-# $NetBSD: assym.mk,v 1.4 2015/09/10 09:30:01 uebayasi Exp $
+# $NetBSD: assym.mk,v 1.5 2015/09/10 13:11:39 uebayasi Exp $
 
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
@@ -7,7 +7,13 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
 	mv -f assym.h.tmp assym.h
 
+.if !defined(___USE_SUFFIX_RULES___)
+${SRCS:T:M*.[sS]:C|\.[Ss]|.o|}: assym.h
+${SRCS:T:M*.[sS]:C|\.[Ss]|.d|}: assym.h
+.else
 ${SRCS:M*.[sS]:C|\.[Ss]|.o|}: assym.h
+${SRCS:M*.[sS]:C|\.[Ss]|.d|}: assym.h
+.endif
 
 assym.d: assym.h
 	${_MKTARGET_CREATE}



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Fri Sep 11 01:40:52 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Indent.


To generate a diff of this commit:
cvs rdiff -u -r1.245 -r1.246 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-10 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Fri Sep 11 01:40:52 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Indent.


To generate a diff of this commit:
cvs rdiff -u -r1.245 -r1.246 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.245 src/sys/conf/Makefile.kern.inc:1.246
--- src/sys/conf/Makefile.kern.inc:1.245	Thu Sep 10 13:11:39 2015
+++ src/sys/conf/Makefile.kern.inc	Fri Sep 11 01:40:52 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.245 2015/09/10 13:11:39 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.246 2015/09/11 01:40:52 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -250,7 +250,7 @@ TARGETSFX=	.gdb
 LINKFLAGS+=	${LINKFLAGS_NORMAL}
 .endif
 
-SYSTEM_LD_HEAD+=${SYSTEM_LD_HEAD_EXTRA}
+SYSTEM_LD_HEAD+=	${SYSTEM_LD_HEAD_EXTRA}
 SYSTEM_LD_TAIL_STAGE1=	${SYSTEM_LD_TAIL}
 SYSTEM_LD_TAIL_STAGE2=	${SYSTEM_LD_TAIL}
 .if defined(COPY_SYMTAB)



CVS commit: src/sys/conf

2015-09-08 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  9 03:16:14 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Restore *.[sS] -> assym.h dependency in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/assym.mk

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

Modified files:

Index: src/sys/conf/assym.mk
diff -u src/sys/conf/assym.mk:1.1 src/sys/conf/assym.mk:1.2
--- src/sys/conf/assym.mk:1.1	Sun Sep  6 06:13:16 2015
+++ src/sys/conf/assym.mk	Wed Sep  9 03:16:14 2015
@@ -1,4 +1,4 @@
-# $NetBSD: assym.mk,v 1.1 2015/09/06 06:13:16 uebayasi Exp $
+# $NetBSD: assym.mk,v 1.2 2015/09/09 03:16:14 uebayasi Exp $
 
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
@@ -6,7 +6,12 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
 	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
 	mv -f assym.h.tmp assym.h
+
+.if !defined(___USE_SUFFIX_RULES___)
 ${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
+.else
+${ALLFILES:M*.[sS]}: assym.h
+.endif
 
 assym.d: assym.h
 	${_MKTARGET_CREATE}



CVS commit: src/sys/conf

2015-09-08 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  9 03:16:14 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Restore *.[sS] -> assym.h dependency in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/assym.mk

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



CVS commit: src/sys/conf

2015-09-08 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  9 03:27:15 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Improve previous.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/conf/assym.mk

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

Modified files:

Index: src/sys/conf/assym.mk
diff -u src/sys/conf/assym.mk:1.2 src/sys/conf/assym.mk:1.3
--- src/sys/conf/assym.mk:1.2	Wed Sep  9 03:16:14 2015
+++ src/sys/conf/assym.mk	Wed Sep  9 03:27:15 2015
@@ -1,4 +1,4 @@
-# $NetBSD: assym.mk,v 1.2 2015/09/09 03:16:14 uebayasi Exp $
+# $NetBSD: assym.mk,v 1.3 2015/09/09 03:27:15 uebayasi Exp $
 
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
@@ -10,7 +10,7 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 .if !defined(___USE_SUFFIX_RULES___)
 ${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
 .else
-${ALLFILES:M*.[sS]}: assym.h
+${SRCS:M*.[sS]}: assym.h
 .endif
 
 assym.d: assym.h



CVS commit: src/sys/conf

2015-09-08 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  9 03:27:15 UTC 2015

Modified Files:
src/sys/conf: assym.mk

Log Message:
Improve previous.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/conf/assym.mk

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



CVS commit: src/sys/conf

2015-09-07 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Mon Sep  7 15:55:06 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Preserve the order of files in ${ALLFILES} -> ${OBJS} conversion.


To generate a diff of this commit:
cvs rdiff -u -r1.243 -r1.244 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.243 src/sys/conf/Makefile.kern.inc:1.244
--- src/sys/conf/Makefile.kern.inc:1.243	Sun Sep  6 15:20:59 2015
+++ src/sys/conf/Makefile.kern.inc	Mon Sep  7 15:55:06 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.243 2015/09/06 15:20:59 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.244 2015/09/07 15:55:06 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -265,34 +265,30 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ## (6) port independent targets and dependencies: assym.h, vers.o
 ##
 
+.if !defined(___USE_SUFFIX_RULES___)
+
+# Generate list of *.o files to pass to ${LD}, preserving order.
+#	x/y/z/a.[csS] -> a.[csS]
+#	a.[csS] -> a.o
+OBJS=	${ALLFILES:C|^.*/([^/]*\.[csS])$$|\1|:C|^(.*)\.[csS]$$|\1.o|}
+
 CFILES=	${ALLFILES:M*.c}
 SFILES=	${ALLFILES:M*.[sS]}
 OFILES=	${ALLFILES:M*.o}
-
-.if !defined(___USE_SUFFIX_RULES___)
-COBJS=	${CFILES:T:R:C|$|.o|}
-SOBJS=	${SFILES:T:R:C|$|.o|}
-OOBJS=	${OFILES}
 # absolute, generated (build directory), relative (under $S)
 _CFILES=${CFILES:M/*} ${CFILES:N/*:N*/*} ${CFILES:N/*:M*/*:C|^|$S/|}
 _SFILES=${SFILES:M/*} ${SFILES:N/*:N*/*} ${SFILES:N/*:M*/*:C|^|$S/|}
 _MD_CFILES=${MD_CFILES}
 _MD_SFILES=${MD_SFILES}
-.else
-COBJS=	${CFILES:R:C|$|.o|}
-SOBJS=	${SFILES:R:C|$|.o|}
-OOBJS=	${OFILES}
-_CFILES=${CFILES}
-_SFILES=${SFILES}
-_MD_CFILES=${MD_CFILES:C|^$S/||}
-_MD_SFILES=${MD_SFILES:C|^$S/||}
-.endif # ___USE_SUFFIX_RULES___
-
-OBJS=	${COBJS} ${SOBJS} ${OOBJS}
 CSRCS=	${_MD_CFILES} ${_CFILES}
 SSRCS=	${_MD_SFILES} ${_SFILES}
 SRCS=	${CSRCS} ${SSRCS}
 
+.else # ___USE_SUFFIX_RULES___
+OBJS=	${ALLFILES:C|\.[csS]$$|.o|}
+SRCS=	${ALLFILES:M*.[csS]}
+.endif # ___USE_SUFFIX_RULES___
+
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${_CFILES}
 .if !commands(${_s:T:R}.o)
@@ -354,9 +350,9 @@ dependall: depend .WAIT all
 MKDEP_AFLAGS?=	${AFLAGS}
 MKDEP_CFLAGS?=	${CFLAGS}
 .if !defined(___USE_SUFFIX_RULES___)
-DEPS=	${SRCS:T:u:R:S/$/.d/g}
+DEPS=	${SRCS:T:R:S/$/.d/g}
 .else
-DEPS=	${SRCS:u:R:S/$/.d/g}
+DEPS=	${SRCS:R:S/$/.d/g}
 .endif
 
 .if !defined(___USE_SUFFIX_RULES___)



CVS commit: src/sys/conf

2015-09-07 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Mon Sep  7 15:55:06 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Preserve the order of files in ${ALLFILES} -> ${OBJS} conversion.


To generate a diff of this commit:
cvs rdiff -u -r1.243 -r1.244 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 06:13:16 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: assym.mk newvers.mk

Log Message:
Clean up.  Move assym.h/vers.c related code out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.239 -r1.240 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/assym.mk src/sys/conf/newvers.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.239 src/sys/conf/Makefile.kern.inc:1.240
--- src/sys/conf/Makefile.kern.inc:1.239	Sun Sep  6 04:42:06 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 06:13:16 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.239 2015/09/06 04:42:06 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.240 2015/09/06 06:13:16 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -307,6 +307,9 @@ _MD_SFILES=${MD_SFILES:C|^$S/||}
 .endif # ___USE_SUFFIX_RULES___
 
 OBJS=	${COBJS} ${SOBJS} ${OOBJS}
+CSRCS=	${_MD_CFILES} ${_CFILES}
+SSRCS=	${_MD_SFILES} ${_SFILES}
+SRCS=	${CSRCS} ${SSRCS}
 
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${_CFILES}
@@ -324,33 +327,6 @@ ${_s:T:R}.o: ${_s}
 .endfor
 .endif # !___USE_SUFFIX_RULES___
 
-assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
-	${_MKTARGET_CREATE}
-	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf | \
-	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
-	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
-	mv -f assym.h.tmp assym.h
-${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
-
-MKREPRO?=no
-
-.if ${MKREPRO} == "yes"
-_NVFLAGS=${NVFLAGS} -r
-.else
-_NVFLAGS=${NVFLAGS}
-.endif
-
-.if !target(vers.o)
-newvers: vers.o
-vers.o: ${SYSTEM_OBJ:O} Makefile $S/conf/newvers.sh \
-		$S/conf/osrelease.sh ${_NETBSD_VERSION_DEPENDS}
-	${_MKMSG_CREATE} vers.c
-	${HOST_SH} $S/conf/newvers.sh ${_NVFLAGS}
-	${_MKTARGET_COMPILE}
-	${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} -c vers.c
-	${COMPILE_CTFCONVERT}
-.endif
-
 ##
 ## (7) misc targets: install, clean(dir), depend(all), lint, links, tags,
 ##   cscope, mkid
@@ -395,9 +371,6 @@ dependall: depend .WAIT all
 .if !target(.depend)
 MKDEP_AFLAGS?=	${AFLAGS}
 MKDEP_CFLAGS?=	${CFLAGS}
-SSRCS=${_MD_SFILES} ${_SFILES}
-CSRCS=${_MD_CFILES} ${_CFILES}
-SRCS=${SSRCS} ${CSRCS}
 .if !defined(___USE_SUFFIX_RULES___)
 DEPS=	${SRCS:T:u:R:S/$/.d/g}
 .else
@@ -426,16 +399,6 @@ ${_s:T:R}.d: ${_s}
 .endfor
 .endif # !___USE_SUFFIX_RULES___
 
-assym.d: assym.h
-	${_MKTARGET_CREATE}
-	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} | \
-	${GENASSYM} -- ${MKDEP} -f assym.dep -- \
-	${CFLAGS:N-Wa,*} ${CPPFLAGS} ${GENASSYM_CPPFLAGS}
-	${TOOL_SED} -e 's/.*\.o:.*\.c/assym.h:/' < assym.dep >${.TARGET}
-	rm -f assym.dep
-
-DEPS+=	assym.d
-
 .depend: ${DEPS}
 	${_MKTARGET_CREATE}
 	echo "${.ALLSRC}" | ${MKDEP} -D
@@ -466,6 +429,8 @@ install-kernel-${MACHINE_NAME}:
 .endif
 .endif
 
+.include "${S}/conf/assym.mk"
+.include "${S}/conf/newvers.mk"
 .include "${S}/conf/splash.mk"
 .include "${S}/conf/mdroot.mk"
 .include "${S}/conf/lint.mk"
@@ -520,13 +485,6 @@ build_kernel: .USE
 ##
 
 .if defined(___USE_SUFFIX_RULES___)
-.SUFFIXES: .genassym .assym.h
-.genassym.assym.h:
-	${_MKTARGET_CREATE}
-	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
-	${GENASSYM_CPPFLAGS} < $< > $@
-	mv -f $@.tmp $@
-
 .SUFFIXES: .s .d
 .s.d:
 	${_MKTARGET_CREATE}

Added files:

Index: src/sys/conf/assym.mk
diff -u /dev/null src/sys/conf/assym.mk:1.1
--- /dev/null	Sun Sep  6 06:13:16 2015
+++ src/sys/conf/assym.mk	Sun Sep  6 06:13:16 2015
@@ -0,0 +1,28 @@
+# $NetBSD: assym.mk,v 1.1 2015/09/06 06:13:16 uebayasi Exp $
+
+assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
+	${_MKTARGET_CREATE}
+	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf | \
+	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
+	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
+	mv -f assym.h.tmp assym.h
+${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
+
+assym.d: assym.h
+	${_MKTARGET_CREATE}
+	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} | \
+	${GENASSYM} -- ${MKDEP} -f assym.dep -- \
+	${CFLAGS:N-Wa,*} ${CPPFLAGS} ${GENASSYM_CPPFLAGS}
+	${TOOL_SED} -e 's/.*\.o:.*\.c/assym.h:/' < assym.dep >${.TARGET}
+	rm -f assym.dep
+
+DEPS+=	assym.d
+
+.if defined(___USE_SUFFIX_RULES___)
+.SUFFIXES: .genassym .assym.h
+.genassym.assym.h:
+	${_MKTARGET_CREATE}
+	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
+	${GENASSYM_CPPFLAGS} < $< > $@
+	mv -f $@.tmp $@
+.endif # ___USE_SUFFIX_RULES___
Index: src/sys/conf/newvers.mk
diff -u /dev/null src/sys/conf/newvers.mk:1.1
--- /dev/null	Sun Sep  6 06:13:16 2015
+++ src/sys/conf/newvers.mk	Sun 

CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 06:13:16 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: assym.mk newvers.mk

Log Message:
Clean up.  Move assym.h/vers.c related code out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.239 -r1.240 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/assym.mk src/sys/conf/newvers.mk

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



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 06:41:14 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: ldscript.mk

Log Message:
Move ldscript related code out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.240 -r1.241 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/ldscript.mk

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



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 06:41:14 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: ldscript.mk

Log Message:
Move ldscript related code out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.240 -r1.241 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/ldscript.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.240 src/sys/conf/Makefile.kern.inc:1.241
--- src/sys/conf/Makefile.kern.inc:1.240	Sun Sep  6 06:13:16 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 06:41:14 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.240 2015/09/06 06:13:16 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.241 2015/09/06 06:41:14 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -219,24 +219,6 @@ SYSTEM_LD?=	${_MKSHMSG} "   link  ${.CUR
 		${SYSTEM_OBJ:N*swap*netbsd*} ${EXTRA_OBJ} vers.o \
 		${OBJS:M*swap${.TARGET}.o}
 
-# Give MD generated ldscript dependency on ${SYSTEM_OBJ}
-.if defined(KERNLDSCRIPT)
-.if target(${KERNLDSCRIPT})
-${KERNLDSCRIPT}: ${SYSTEM_OBJ}
-.endif
-.endif
-
-.if defined(KERNLDSCRIPT)
-.for k in ${KERNELS}
-EXTRA_CLEAN+=	${k}.ldscript
-${k}: ${k}.ldscript
-${k}.ldscript: ${KERNLDSCRIPT} assym.h
-	${_MKTARGET_CREATE}
-	${CPP} -I. ${KERNLDSCRIPT} | grep -v '^#' | grep -v '^$$' >$@
-.endfor
-LINKSCRIPT=	-T ${.TARGET}.ldscript
-.endif
-
 TEXTADDR?=	${LOADADDRESS}			# backwards compatibility
 LINKTEXT?=	${TEXTADDR:C/.+/-Ttext &/}
 LINKDATA?=	${DATAADDR:C/.+/-Tdata &/}
@@ -429,6 +411,7 @@ install-kernel-${MACHINE_NAME}:
 .endif
 .endif
 
+.include "${S}/conf/ldscript.mk"
 .include "${S}/conf/assym.mk"
 .include "${S}/conf/newvers.mk"
 .include "${S}/conf/splash.mk"

Added files:

Index: src/sys/conf/ldscript.mk
diff -u /dev/null src/sys/conf/ldscript.mk:1.1
--- /dev/null	Sun Sep  6 06:41:14 2015
+++ src/sys/conf/ldscript.mk	Sun Sep  6 06:41:14 2015
@@ -0,0 +1,19 @@
+# $NetBSD: ldscript.mk,v 1.1 2015/09/06 06:41:14 uebayasi Exp $
+
+# Give MD generated ldscript dependency on ${SYSTEM_OBJ}
+.if defined(KERNLDSCRIPT)
+.if target(${KERNLDSCRIPT})
+${KERNLDSCRIPT}: ${SYSTEM_OBJ}
+.endif
+.endif
+
+.if defined(KERNLDSCRIPT)
+.for k in ${KERNELS}
+EXTRA_CLEAN+=	${k}.ldscript
+${k}: ${k}.ldscript
+${k}.ldscript: ${KERNLDSCRIPT} assym.h
+	${_MKTARGET_CREATE}
+	${CPP} -I. ${KERNLDSCRIPT} | grep -v '^#' | grep -v '^$$' >$@
+.endfor
+LINKSCRIPT=	-T ${.TARGET}.ldscript
+.endif



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 14:35:01 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Don't pass ``-DCOPY_SYMTAB'' to ${CC}; it's replaced with opt_copy_symtab.h.


To generate a diff of this commit:
cvs rdiff -u -r1.241 -r1.242 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 14:35:01 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Don't pass ``-DCOPY_SYMTAB'' to ${CC}; it's replaced with opt_copy_symtab.h.


To generate a diff of this commit:
cvs rdiff -u -r1.241 -r1.242 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.241 src/sys/conf/Makefile.kern.inc:1.242
--- src/sys/conf/Makefile.kern.inc:1.241	Sun Sep  6 06:41:14 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 14:35:01 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.241 2015/09/06 06:41:14 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.242 2015/09/06 14:35:01 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -447,12 +447,12 @@ build_kernel: .USE
 ${k}: $S/kern/kern_ksyms_buf.c
 .endfor
 build_kernel: .USE
-	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
+	${CC} ${CFLAGS} ${CPPFLAGS} \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf.o
 	${SYSTEM_LD_HEAD}
 	${SYSTEM_LD} kern_ksyms_buf.o
 	${SYSTEM_LD_TAIL_STAGE1}
-	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
+	${CC} ${CFLAGS} ${CPPFLAGS} \
 	-DSYMTAB_SPACE=$$(${DBSYM} -P ${.TARGET}${TARGETSFX}) \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf_real.o
 	${SYSTEM_LD_HEAD}



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 15:20:59 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc ldscript.mk

Log Message:
More build ordering.


To generate a diff of this commit:
cvs rdiff -u -r1.242 -r1.243 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/ldscript.mk

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



CVS commit: src/sys/conf

2015-09-06 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 15:20:59 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc ldscript.mk

Log Message:
More build ordering.


To generate a diff of this commit:
cvs rdiff -u -r1.242 -r1.243 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/ldscript.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.242 src/sys/conf/Makefile.kern.inc:1.243
--- src/sys/conf/Makefile.kern.inc:1.242	Sun Sep  6 14:35:01 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 15:20:59 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.242 2015/09/06 14:35:01 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.243 2015/09/06 15:20:59 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -203,7 +203,7 @@ _MD_OBJS=	${MD_OBJS}
 
 SYSTEM_LIB=	${MD_LIBS} ${SYSLIBCOMPAT} ${LIBKERN}
 SYSTEM_OBJ?=	${_MD_OBJS} ${OBJS} ${SYSTEM_LIB}
-SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ}
+SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ:O}
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o
 .else
@@ -381,7 +381,7 @@ ${_s:T:R}.d: ${_s}
 .endfor
 .endif # !___USE_SUFFIX_RULES___
 
-.depend: ${DEPS}
+.depend: ${DEPS:O}
 	${_MKTARGET_CREATE}
 	echo "${.ALLSRC}" | ${MKDEP} -D
 .endif

Index: src/sys/conf/ldscript.mk
diff -u src/sys/conf/ldscript.mk:1.1 src/sys/conf/ldscript.mk:1.2
--- src/sys/conf/ldscript.mk:1.1	Sun Sep  6 06:41:14 2015
+++ src/sys/conf/ldscript.mk	Sun Sep  6 15:20:59 2015
@@ -1,9 +1,9 @@
-# $NetBSD: ldscript.mk,v 1.1 2015/09/06 06:41:14 uebayasi Exp $
+# $NetBSD: ldscript.mk,v 1.2 2015/09/06 15:20:59 uebayasi Exp $
 
 # Give MD generated ldscript dependency on ${SYSTEM_OBJ}
 .if defined(KERNLDSCRIPT)
 .if target(${KERNLDSCRIPT})
-${KERNLDSCRIPT}: ${SYSTEM_OBJ}
+${KERNLDSCRIPT}: ${SYSTEM_OBJ:O}
 .endif
 .endif
 



CVS commit: src/sys/conf

2015-09-05 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 02:05:11 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Allow MD to link libraries.  Build rules are written in MD makefiles until
config(1) will support library properly.


To generate a diff of this commit:
cvs rdiff -u -r1.237 -r1.238 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.237 src/sys/conf/Makefile.kern.inc:1.238
--- src/sys/conf/Makefile.kern.inc:1.237	Fri Sep  4 06:10:47 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 02:05:11 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.237 2015/09/04 06:10:47 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.238 2015/09/06 02:05:11 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -211,7 +211,8 @@ _MD_OBJS=	${MD_OBJS}
 # load lines for config "xxx" will be emitted as:
 # xxx: ${SYSTEM_DEP} swap.o vers.o build_kernel
 
-SYSTEM_OBJ?=	${_MD_OBJS} ${OBJS} ${SYSLIBCOMPAT} ${LIBKERN}
+SYSTEM_LIB=	${MD_LIBS} ${SYSLIBCOMPAT} ${LIBKERN}
+SYSTEM_OBJ?=	${_MD_OBJS} ${OBJS} ${SYSTEM_LIB}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ}
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o



CVS commit: src/sys/conf

2015-09-05 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 02:05:11 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Allow MD to link libraries.  Build rules are written in MD makefiles until
config(1) will support library properly.


To generate a diff of this commit:
cvs rdiff -u -r1.237 -r1.238 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-05 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 04:42:06 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: ssp.mk

Log Message:
Clean up.  Move SSP-specific adjustment out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.238 -r1.239 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/ssp.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.238 src/sys/conf/Makefile.kern.inc:1.239
--- src/sys/conf/Makefile.kern.inc:1.238	Sun Sep  6 02:05:11 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Sep  6 04:42:06 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.238 2015/09/06 02:05:11 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.239 2015/09/06 04:42:06 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -104,16 +104,6 @@ CFLAGS+=	-fno-strict-aliasing
 CFLAGS+=	-fno-common
 .endif
 
-.if ${USE_SSP:Uno} == "yes"
-COPTS.kern_ssp.c+=	-fno-stack-protector -D__SSP__
-.endif
-
-# for multi-cpu machines, cpu_hatch() straddles the init of
-# __stack_chk_guard, so ensure stack protection is disabled
-.if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64"
-COPTS.cpu.c+=		-fno-stack-protector
-.endif
-
 # Use the per-source COPTS variables to add -g to just those
 # files that match the shell patterns given in ${DEBUGLIST}
 #
@@ -296,25 +286,27 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 CFILES=	${ALLFILES:M*.c}
 SFILES=	${ALLFILES:M*.[sS]}
 OFILES=	${ALLFILES:M*.o}
+
 .if !defined(___USE_SUFFIX_RULES___)
-OBJS.c=	${CFILES:T:R:C|$|.o|}
-OBJS.s=	${SFILES:T:R:C|$|.o|}
-OBJS.o=	${OFILES}
+COBJS=	${CFILES:T:R:C|$|.o|}
+SOBJS=	${SFILES:T:R:C|$|.o|}
+OOBJS=	${OFILES}
 # absolute, generated (build directory), relative (under $S)
 _CFILES=${CFILES:M/*} ${CFILES:N/*:N*/*} ${CFILES:N/*:M*/*:C|^|$S/|}
 _SFILES=${SFILES:M/*} ${SFILES:N/*:N*/*} ${SFILES:N/*:M*/*:C|^|$S/|}
 _MD_CFILES=${MD_CFILES}
 _MD_SFILES=${MD_SFILES}
 .else
-OBJS.c=	${CFILES:R:C|$|.o|}
-OBJS.s=	${SFILES:R:C|$|.o|}
-OBJS.o=	${OFILES}
+COBJS=	${CFILES:R:C|$|.o|}
+SOBJS=	${SFILES:R:C|$|.o|}
+OOBJS=	${OFILES}
 _CFILES=${CFILES}
 _SFILES=${SFILES}
 _MD_CFILES=${MD_CFILES:C|^$S/||}
 _MD_SFILES=${MD_SFILES:C|^$S/||}
 .endif # ___USE_SUFFIX_RULES___
-OBJS=	${OBJS.c} ${OBJS.s} ${OBJS.o}
+
+OBJS=	${COBJS} ${SOBJS} ${OOBJS}
 
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${_CFILES}
@@ -479,22 +471,12 @@ install-kernel-${MACHINE_NAME}:
 .include "${S}/conf/lint.mk"
 .include "${S}/conf/cscope.mk"
 .include "${S}/conf/gdbinit.mk"
+.include "${S}/conf/ssp.mk"
 
 ##
 ## the kernel
 ##
 
-# The following files use alloca(3) or variable array allocations.
-# Their full name is noted as documentation.
-VARSTACK=kern/uipc_socket.c miscfs/genfs/genfs_vnops.c \
-nfs/nfs_bio.c uvm/uvm_bio.c \
-uvm/uvm_pager.c dev/ic/aic7xxx.c dev/ic/aic79xx.c arch/xen/i386/gdt.c \
-dev/ofw/ofw_subr.c
-
-.for __varstack in ${VARSTACK}
-COPTS.${__varstack:T} += -Wno-stack-protector
-.endfor
-
 AFLAGS+=	${AOPTS.${.IMPSRC:T}}
 CFLAGS+=	${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}}
 CPPFLAGS+=	${CPPFLAGS.${.IMPSRC:T}}

Added files:

Index: src/sys/conf/ssp.mk
diff -u /dev/null src/sys/conf/ssp.mk:1.1
--- /dev/null	Sun Sep  6 04:42:06 2015
+++ src/sys/conf/ssp.mk	Sun Sep  6 04:42:06 2015
@@ -0,0 +1,28 @@
+# $NetBSD: ssp.mk,v 1.1 2015/09/06 04:42:06 uebayasi Exp $
+
+.if ${USE_SSP:Uno} == "yes"
+COPTS.kern_ssp.c+=	-fno-stack-protector -D__SSP__
+.endif
+
+# for multi-cpu machines, cpu_hatch() straddles the init of
+# __stack_chk_guard, so ensure stack protection is disabled
+.if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64"
+COPTS.cpu.c+=		-fno-stack-protector
+.endif
+
+# The following files use alloca(3) or variable array allocations.
+# Their full name is noted as documentation.
+VARSTACK= \
+	arch/xen/i386/gdt.c \
+	dev/ic/aic79xx.c \
+	dev/ic/aic7xxx.c \
+	dev/ofw/ofw_subr.c \
+	kern/uipc_socket.c \
+	miscfs/genfs/genfs_vnops.c \
+	nfs/nfs_bio.c \
+	uvm/uvm_bio.c \
+	uvm/uvm_pager.c \
+
+.for __varstack in ${VARSTACK}
+COPTS.${__varstack:T} += -Wno-stack-protector
+.endfor



CVS commit: src/sys/conf

2015-09-05 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Sep  6 04:42:06 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: ssp.mk

Log Message:
Clean up.  Move SSP-specific adjustment out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.238 -r1.239 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/ssp.mk

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



Re: CVS commit: src/sys/conf

2015-09-03 Thread Joerg Sonnenberger
On Thu, Sep 03, 2015 at 02:56:35PM +0900, Masao Uebayashi wrote:
> Because ${OBJS} affects not only build order but also link order.

and that's exactly why it *should* be sorted. Please don't introduce
sources of instability to the build process.

Joerg


CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 06:10:53 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Sort dependendy to keep alphabetical build order.


To generate a diff of this commit:
cvs rdiff -u -r1.231 -r1.232 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.231 src/sys/conf/Makefile.kern.inc:1.232
--- src/sys/conf/Makefile.kern.inc:1.231	Thu Sep  3 06:09:46 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 06:10:53 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.231 2015/09/03 06:09:46 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.232 2015/09/03 06:10:53 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -343,7 +343,7 @@ _NVFLAGS=${NVFLAGS}
 
 .if !target(vers.o)
 newvers: vers.o
-vers.o: ${SYSTEM_OBJ} Makefile $S/conf/newvers.sh \
+vers.o: ${SYSTEM_OBJ:O} Makefile $S/conf/newvers.sh \
 		$S/conf/osrelease.sh ${_NETBSD_VERSION_DEPENDS}
 	${_MKMSG_CREATE} vers.c
 	${HOST_SH} $S/conf/newvers.sh ${_NVFLAGS}
@@ -494,7 +494,7 @@ CPPFLAGS+=	${CPPFLAGS.${.IMPSRC:T}}
 CWARNFLAGS+=	${CWARNFLAGS.${.IMPSRC:T}}
 
 .for k in ${KERNELS}
-${k}: ${SYSTEM_DEP} vers.o build_kernel
+${k}: ${SYSTEM_DEP:O} vers.o build_kernel
 .endfor
 
 .if !defined(COPY_SYMTAB)



CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 06:10:53 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Sort dependendy to keep alphabetical build order.


To generate a diff of this commit:
cvs rdiff -u -r1.231 -r1.232 src/sys/conf/Makefile.kern.inc

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



Re: CVS commit: src/sys/conf

2015-09-03 Thread David Holland
On Thu, Sep 03, 2015 at 02:56:35PM +0900, Masao Uebayashi wrote:
 > Because ${OBJS} affects not only build order but also link order.

And this matters why, in the absence of e.g. profile-driven function
layout?

(although it might be interesting to see if running ${OBJS} through
lorder/tsort improves the output kernel)

-- 
David A. Holland
dholl...@netbsd.org


CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 06:24:15 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Kernel depends on swap.o too.


To generate a diff of this commit:
cvs rdiff -u -r1.232 -r1.233 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.232 src/sys/conf/Makefile.kern.inc:1.233
--- src/sys/conf/Makefile.kern.inc:1.232	Thu Sep  3 06:10:53 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 06:24:15 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.232 2015/09/03 06:10:53 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.233 2015/09/03 06:24:15 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -494,7 +494,7 @@ CPPFLAGS+=	${CPPFLAGS.${.IMPSRC:T}}
 CWARNFLAGS+=	${CWARNFLAGS.${.IMPSRC:T}}
 
 .for k in ${KERNELS}
-${k}: ${SYSTEM_DEP:O} vers.o build_kernel
+${k}: ${SYSTEM_DEP:O} swap${k}.o vers.o build_kernel
 .endfor
 
 .if !defined(COPY_SYMTAB)



Re: CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
I got some errors from common/lib/libc/arch/arm/features.mk.  Will
revisit later.


CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 06:24:15 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Kernel depends on swap.o too.


To generate a diff of this commit:
cvs rdiff -u -r1.232 -r1.233 src/sys/conf/Makefile.kern.inc

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



Re: CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
On Thu, Sep 3, 2015 at 11:32 PM, Joerg Sonnenberger
 wrote:
> On Thu, Sep 03, 2015 at 02:56:35PM +0900, Masao Uebayashi wrote:
>> Because ${OBJS} affects not only build order but also link order.
>
> and that's exactly why it *should* be sorted. Please don't introduce
> sources of instability to the build process.

config(1) outputs ${CFILES}/${SFILES} in the order it parses files.*
and sees "file ...".  It is stable.


Re: CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
My plan is to order objects following module dependency for kernel constructors.


CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 12:31:16 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Prepare for relative ${MD_OBJS}.


To generate a diff of this commit:
cvs rdiff -u -r1.234 -r1.235 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-03 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 12:31:16 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Prepare for relative ${MD_OBJS}.


To generate a diff of this commit:
cvs rdiff -u -r1.234 -r1.235 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.234 src/sys/conf/Makefile.kern.inc:1.235
--- src/sys/conf/Makefile.kern.inc:1.234	Thu Sep  3 09:28:00 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 12:31:16 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.234 2015/09/03 09:28:00 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.235 2015/09/03 12:31:16 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -196,6 +196,9 @@ SYSLIBCOMPATLN?=	${COMPATLIBLN}
 
 .if !defined(___USE_SUFFIX_RULES___)
 MI_CFILES=	devsw.c ioconf.c
+_MD_OBJS=	${MD_OBJS:T}
+.else
+_MD_OBJS=	${MD_OBJS}
 .endif
 
 # the need for a MI_SFILES variable is dubitable at best
@@ -212,7 +215,7 @@ MI_OBJS=${MI_CFILES:S/.c/.o/}
 # load lines for config "xxx" will be emitted as:
 # xxx: ${SYSTEM_DEP} swap.o vers.o build_kernel
 
-SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS} ${SYSLIBCOMPAT} ${LIBKERN}
+SYSTEM_OBJ?=	${_MD_OBJS} ${MI_OBJS} ${OBJS} ${SYSLIBCOMPAT} ${LIBKERN}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ}
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o
@@ -300,12 +303,16 @@ OBJS.o=	${OFILES}
 # absolute, generated (build directory), relative (under $S)
 _CFILES=${CFILES:M/*} ${CFILES:N/*:N*/*} ${CFILES:N/*:M*/*:C|^|$S/|}
 _SFILES=${SFILES:M/*} ${SFILES:N/*:N*/*} ${SFILES:N/*:M*/*:C|^|$S/|}
+_MD_CFILES=${MD_CFILES}
+_MD_SFILES=${MD_SFILES}
 .else
 OBJS.c=	${CFILES:R:C|$|.o|}
 OBJS.s=	${SFILES:R:C|$|.o|}
 OBJS.o=	${OFILES}
 _CFILES=${CFILES}
 _SFILES=${SFILES}
+_MD_CFILES=${MD_CFILES:C|^$S/||}
+_MD_SFILES=${MD_SFILES:C|^$S/||}
 .endif # ___USE_SUFFIX_RULES___
 OBJS=	${OBJS.c} ${OBJS.s} ${OBJS.o}
 
@@ -331,7 +338,7 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
 	${GENASSYM_CPPFLAGS} > assym.h.tmp && \
 	mv -f assym.h.tmp assym.h
-${MD_SFILES:C/\.[Ss]/.o/} ${SFILES:C/\.[Ss]/.o/}: assym.h
+${_MD_SFILES:C/\.[Ss]/.o/} ${_SFILES:C/\.[Ss]/.o/}: assym.h
 
 MKREPRO?=no
 
@@ -396,8 +403,8 @@ dependall: depend .WAIT all
 .if !target(.depend)
 MKDEP_AFLAGS?=	${AFLAGS}
 MKDEP_CFLAGS?=	${CFLAGS}
-SSRCS=${MD_SFILES} ${_SFILES}
-CSRCS=${MD_CFILES} ${MI_CFILES} ${_CFILES}
+SSRCS=${_MD_SFILES} ${_SFILES}
+CSRCS=${_MD_CFILES} ${MI_CFILES} ${_CFILES}
 SRCS=${SSRCS} ${CSRCS}
 .if !defined(___USE_SUFFIX_RULES___)
 DEPS=	${SRCS:T:u:R:S/$/.d/g}



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 15:29:23 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Clean up `swap.o' handling.


To generate a diff of this commit:
cvs rdiff -u -r1.222 -r1.223 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 15:29:23 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Clean up `swap.o' handling.


To generate a diff of this commit:
cvs rdiff -u -r1.222 -r1.223 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.222 src/sys/conf/Makefile.kern.inc:1.223
--- src/sys/conf/Makefile.kern.inc:1.222	Wed Sep  2 14:17:03 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Sep  2 15:29:23 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.222 2015/09/02 14:17:03 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.223 2015/09/02 15:29:23 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -223,6 +223,7 @@ SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJ
 .else
 SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS:O} ${SYSLIBCOMPAT} ${LIBKERN}
 .endif
+SYSTEM_OBJ_NOSWAP=	${SYSTEM_OBJ:N*swapnetbsd*}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ} .gdbinit
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o
@@ -230,14 +231,10 @@ SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS
 SYSTEM_CTFMERGE= ${_MKSHECHO}
 .endif
 SYSTEM_LD_HEAD?=@rm -f $@
-SYSTEM_LD?=	@do_system_ld() { \
-		target=$$1; shift; \
-		${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}"; \
+SYSTEM_LD?=	${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}"; \
 		${_MKSHECHO}\
-		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} '$${SYSTEM_OBJ}' '$${EXTRA_OBJ}' vers.o swap$${target}.o $$@; \
-		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o swap$${target}.o $$@; \
-		}; \
-		do_system_ld
+		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} '$${SYSTEM_OBJ_NOSWAP}' '$${EXTRA_OBJ}' vers.o '$${OBJS:M*swap${.TARGET}.o}'; \
+		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} ${SYSTEM_OBJ_NOSWAP} ${EXTRA_OBJ} vers.o ${OBJS:M*swap${.TARGET}.o}
 
 # Give MD generated ldscript dependency on ${SYSTEM_OBJ}
 .if defined(KERNLDSCRIPT)
@@ -304,16 +301,17 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ##
 
 .if !defined(___USE_SUFFIX_RULES___)
-OBJS=	${CFILES:T:R:C|$|.o|:N*swapnetbsd*} \
+OBJS=	${CFILES:T:R:C|$|.o|} \
 	${SFILES:T:R:C|$|.o|} \
 	${OFILES}
-_CFILES=${CFILES:M/*} ${CFILES:N*swapnetbsd*:N/*:C|^|$S/|}
-_SFILES=${SFILES:M/*} ${SFILES:N/*:C|^|$S/|}
+# absolute, generated (build directory), relative (under $S)
+_CFILES=${CFILES:M/*} ${CFILES:N/*:N*/*} ${CFILES:N/*:M*/*:C|^|$S/|}
+_SFILES=${SFILES:M/*} ${SFILES:N/*:N*/*} ${SFILES:N/*:M*/*:C|^|$S/|}
 .else
-OBJS=	${CFILES:R:C|$|.o|:N*swapnetbsd*} \
+OBJS=	${CFILES:R:C|$|.o|} \
 	${SFILES:R:C|$|.o|} \
 	${OFILES}
-_CFILES=${CFILES:N*swapnetbsd*}
+_CFILES=${CFILES}
 _SFILES=${SFILES}
 .endif # ___USE_SUFFIX_RULES___
 
@@ -504,7 +502,7 @@ CWARNFLAGS+=	${CWARNFLAGS.${.IMPSRC:T}}
 .if !defined(COPY_SYMTAB)
 build_kernel: .USE
 	${SYSTEM_LD_HEAD}
-	${SYSTEM_LD} ${.TARGET}
+	${SYSTEM_LD}
 	${SYSTEM_LD_TAIL_STAGE2}
 .else
 .for k in ${KERNELS}
@@ -514,13 +512,13 @@ build_kernel: .USE
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf.o
 	${SYSTEM_LD_HEAD}
-	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf.o
+	${SYSTEM_LD} kern_ksyms_buf.o
 	${SYSTEM_LD_TAIL_STAGE1}
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-DSYMTAB_SPACE=$$(${DBSYM} -P ${.TARGET}${TARGETSFX}) \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf_real.o
 	${SYSTEM_LD_HEAD}
-	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf_real.o
+	${SYSTEM_LD} kern_ksyms_buf_real.o
 	${SYSTEM_LD_TAIL_STAGE2}
 .endif
 



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 15:35:52 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Build param.c under conf/ using suffix rules in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.223 -r1.224 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.223 src/sys/conf/Makefile.kern.inc:1.224
--- src/sys/conf/Makefile.kern.inc:1.223	Wed Sep  2 15:29:23 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Sep  2 15:35:52 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.223 2015/09/02 15:29:23 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.224 2015/09/02 15:35:52 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -194,18 +194,22 @@ SYSLIBCOMPATLN?=	${COMPATLIBLN}
 ## MD_CFILES, MD_SFILES, and MD_OBJS, along with build rules for same.
 ##
 
-MI_CFILES=	param.c
 .if !defined(___USE_SUFFIX_RULES___)
+MI_CFILES=	param.c
 MI_CFILES+=	devsw.c ioconf.c
+.else
+MI_CFILES=	conf/param.c
 .endif
 
 # the need for a MI_SFILES variable is dubitable at best
 MI_OBJS=${MI_CFILES:S/.c/.o/}
 
+.if !defined(___USE_SUFFIX_RULES___)
 param.c: $S/conf/param.c
 	${_MKTARGET_CREATE}
 	rm -f param.c
 	cp $S/conf/param.c .
+.endif
 
 ##
 ## (5) link settings



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 15:35:52 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Build param.c under conf/ using suffix rules in `-S' mode.


To generate a diff of this commit:
cvs rdiff -u -r1.223 -r1.224 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 01:30:18 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Stop ordering objects alphabetically now that I am sure I can fix fallouts.


To generate a diff of this commit:
cvs rdiff -u -r1.226 -r1.227 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.226 src/sys/conf/Makefile.kern.inc:1.227
--- src/sys/conf/Makefile.kern.inc:1.226	Thu Sep  3 01:09:38 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 01:30:18 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.226 2015/09/03 01:09:38 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.227 2015/09/03 01:30:18 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -212,11 +212,7 @@ MI_OBJS=${MI_CFILES:S/.c/.o/}
 # load lines for config "xxx" will be emitted as:
 # xxx: ${SYSTEM_DEP} swap.o vers.o build_kernel
 
-.if !empty(OBJS:Mnetbsd.ko)
 SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS} ${SYSLIBCOMPAT} ${LIBKERN}
-.else
-SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS:O} ${SYSLIBCOMPAT} ${LIBKERN}
-.endif
 SYSTEM_OBJ_NOSWAP=	${SYSTEM_OBJ:N*swap*netbsd*}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ} .gdbinit
 .if defined(CTFMERGE)



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 01:30:18 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Stop ordering objects alphabetically now that I am sure I can fix fallouts.


To generate a diff of this commit:
cvs rdiff -u -r1.226 -r1.227 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 01:40:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Simplify.  Wrap long lines.


To generate a diff of this commit:
cvs rdiff -u -r1.227 -r1.228 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 01:40:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Simplify.  Wrap long lines.


To generate a diff of this commit:
cvs rdiff -u -r1.227 -r1.228 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.227 src/sys/conf/Makefile.kern.inc:1.228
--- src/sys/conf/Makefile.kern.inc:1.227	Thu Sep  3 01:30:18 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 01:40:06 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.227 2015/09/03 01:30:18 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.228 2015/09/03 01:40:06 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -213,7 +213,6 @@ MI_OBJS=${MI_CFILES:S/.c/.o/}
 # xxx: ${SYSTEM_DEP} swap.o vers.o build_kernel
 
 SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS} ${SYSLIBCOMPAT} ${LIBKERN}
-SYSTEM_OBJ_NOSWAP=	${SYSTEM_OBJ:N*swap*netbsd*}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ} .gdbinit
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o
@@ -223,8 +222,12 @@ SYSTEM_CTFMERGE= ${_MKSHECHO}
 SYSTEM_LD_HEAD?=@rm -f $@
 SYSTEM_LD?=	${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}"; \
 		${_MKSHECHO}\
-		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} '$${SYSTEM_OBJ_NOSWAP}' '$${EXTRA_OBJ}' vers.o '$${OBJS:M*swap${.TARGET}.o}'; \
-		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} ${SYSTEM_OBJ_NOSWAP} ${EXTRA_OBJ} vers.o ${OBJS:M*swap${.TARGET}.o}
+		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} \
+		'$${SYSTEM_OBJ:N*swap*netbsd*}' '$${EXTRA_OBJ}' vers.o \
+		${OBJS:M*swap${.TARGET}.o}; \
+		${LD} -Map ${.TARGET}.map --cref ${LINKFLAGS} -o ${.TARGET} \
+		${SYSTEM_OBJ:N*swap*netbsd*} ${EXTRA_OBJ} vers.o \
+		${OBJS:M*swap${.TARGET}.o}
 
 # Give MD generated ldscript dependency on ${SYSTEM_OBJ}
 .if defined(KERNLDSCRIPT)



re: CVS commit: src/sys/conf

2015-09-02 Thread matthew green
"Masao Uebayashi" writes:
> Module Name:  src
> Committed By: uebayasi
> Date: Thu Sep  3 01:30:18 UTC 2015
> 
> Modified Files:
>   src/sys/conf: Makefile.kern.inc
> 
> Log Message:
> Stop ordering objects alphabetically now that I am sure I can fix fallouts.

what's this about?  why are you commiting something that you
believe has fallout coming.


.mrg.


CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 04:17:55 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Rename ${COMPILE.c} to ${KCOMPILE.c} to avoid potential conflicts with those
in sys.mk.  Define .go/.po suffix rules.


To generate a diff of this commit:
cvs rdiff -u -r1.229 -r1.230 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.229 src/sys/conf/Makefile.kern.inc:1.230
--- src/sys/conf/Makefile.kern.inc:1.229	Thu Sep  3 03:47:25 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 04:17:55 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.229 2015/09/03 03:47:25 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.230 2015/09/03 04:17:55 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -137,28 +137,28 @@ COMPILE_CTFCONVERT=	${_MKSHECHO}\
 COMPILE_CTFCONVERT=	${_MKSHNOECHO}
 .endif
 
-COMPILE.c=	${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} -c $< -o $@
-COMPILE.s=	${CC} ${AFLAGS} ${AFLAGS.${<:T}} ${CPPFLAGS} -c $< -o $@
-LINK.o=		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
+KCOMPILE.c=	${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} -c $< -o $@
+KCOMPILE.s=	${CC} ${AFLAGS} ${AFLAGS.${<:T}} ${CPPFLAGS} -c $< -o $@
+KLINK.o=	${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
 
 # compile rules: rules are named ${TYPE}_${SUFFIX} where TYPE is NORMAL or
 # NOPROF and SUFFIX is the file suffix, capitalized (e.g. C for a .c file).
 NORMAL_C?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO} ${COMPILE.c} ${PROF} && \
-		${COMPILE.c} ${PROF} && \
+		${_MKSHECHO} ${KCOMPILE.c} ${PROF} && \
+		${KCOMPILE.c} ${PROF} && \
 		${COMPILE_CTFCONVERT}
 NOPROF_C?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO} ${COMPILE.c} && \
-		${COMPILE.c} && \
+		${_MKSHECHO} ${KCOMPILE.c} && \
+		${KCOMPILE.c} && \
 		${COMPILE_CTFCONVERT}
 NORMAL_S?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO} ${COMPILE.s} && \
-		${COMPILE.s}
+		${_MKSHECHO} ${KCOMPILE.s} && \
+		${KCOMPILE.s}
  
 # link rules: 
 LINK_O?=	@${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO} ${LINK.o} && \
-		${LINK.o}
+		${_MKSHECHO} ${KLINK.o} && \
+		${KLINK.o}
 
 ##
 ## (3) libkern and compat
@@ -294,19 +294,20 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ##
 
 .if !defined(___USE_SUFFIX_RULES___)
-OBJS=	${CFILES:T:R:C|$|.o|} \
-	${SFILES:T:R:C|$|.o|} \
-	${OFILES}
+OBJS.c=	${CFILES:T:R:C|$|.o|}
+OBJS.s=	${SFILES:T:R:C|$|.o|}
+OBJS.o=	${OFILES}
 # absolute, generated (build directory), relative (under $S)
 _CFILES=${CFILES:M/*} ${CFILES:N/*:N*/*} ${CFILES:N/*:M*/*:C|^|$S/|}
 _SFILES=${SFILES:M/*} ${SFILES:N/*:N*/*} ${SFILES:N/*:M*/*:C|^|$S/|}
 .else
-OBJS=	${CFILES:R:C|$|.o|} \
-	${SFILES:R:C|$|.o|} \
-	${OFILES}
+OBJS.c=	${CFILES:R:C|$|.o|}
+OBJS.s=	${SFILES:R:C|$|.o|}
+OBJS.o=	${OFILES}
 _CFILES=${CFILES}
 _SFILES=${SFILES}
 .endif # ___USE_SUFFIX_RULES___
+OBJS=	${OBJS.c} ${OBJS.s} ${OBJS.o}
 
 .if !defined(___USE_SUFFIX_RULES___)
 .for _s in ${_CFILES}
@@ -548,17 +549,49 @@ build_kernel: .USE
 	${MKDEP} -f $@.tmp -- ${MKDEP_CFLAGS} ${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
 	mv -f $@.tmp $@
 
-.SUFFIXES: .c .o
+.SUFFIXES: .c .o .go .po
 .c.o:
-	${NORMAL_C}
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.c}
+	@${KCOMPILE.c}
+	@${COMPILE_CTFCONVERT}
+.c.go:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.c} -g
+	@${KCOMPILE.c} -g
+	@${COMPILE_CTFCONVERT}
+.c.po:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.c} -pg
+	@${KCOMPILE.c} -pg
+	@${COMPILE_CTFCONVERT}
 
-.SUFFIXES: .s .o
+.SUFFIXES: .s .o .go .po
 .s.o:
-	${NORMAL_S}
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s}
+	@${KCOMPILE.s}
+.s.go:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s} -g
+	@${KCOMPILE.s} -g
+.s.po:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s} -pg
+	@${KCOMPILE.s} -pg
 
-.SUFFIXES: .S .o
 .S.o:
-	${NORMAL_S}
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s}
+	@${KCOMPILE.s}
+.S.go:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s} -g
+	@${KCOMPILE.s} -g
+.S.po:
+	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}"
+	@${_MKSHECHO} ${KCOMPILE.s} -pg
+	@${KCOMPILE.s} -pg
 .endif # ___USE_SUFFIX_RULES___
 
 ##



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 04:17:55 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Rename ${COMPILE.c} to ${KCOMPILE.c} to avoid potential conflicts with those
in sys.mk.  Define .go/.po suffix rules.


To generate a diff of this commit:
cvs rdiff -u -r1.229 -r1.230 src/sys/conf/Makefile.kern.inc

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



Re: CVS commit: src/sys/conf

2015-09-02 Thread David Holland
On Thu, Sep 03, 2015 at 01:30:18AM +, Masao Uebayashi wrote:
 > Module Name: src
 > Committed By:uebayasi
 > Date:Thu Sep  3 01:30:18 UTC 2015
 > 
 > Modified Files:
 >  src/sys/conf: Makefile.kern.inc
 > 
 > Log Message:
 > Stop ordering objects alphabetically now that I am sure I can fix fallouts.

Why change this? It is useful to be able to estimate how far along
your build is by what's being built.

-- 
David A. Holland
dholl...@netbsd.org


re: CVS commit: src/sys/conf

2015-09-02 Thread matthew green
"Masao Uebayashi" writes:
> Module Name:  src
> Committed By: uebayasi
> Date: Thu Sep  3 04:17:55 UTC 2015
> 
> Modified Files:
>   src/sys/conf: Makefile.kern.inc
> 
> Log Message:
> Rename ${COMPILE.c} to ${KCOMPILE.c} to avoid potential conflicts with those
> in sys.mk.  Define .go/.po suffix rules.

isn't the goal to *replace* what sys.mk has?


.mrg.


Re: CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Because ${OBJS} affects not only build order but also link order.


CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 03:47:25 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Refactor.


To generate a diff of this commit:
cvs rdiff -u -r1.228 -r1.229 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.228 src/sys/conf/Makefile.kern.inc:1.229
--- src/sys/conf/Makefile.kern.inc:1.228	Thu Sep  3 01:40:06 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Sep  3 03:47:25 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.228 2015/09/03 01:40:06 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.229 2015/09/03 03:47:25 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -137,28 +137,28 @@ COMPILE_CTFCONVERT=	${_MKSHECHO}\
 COMPILE_CTFCONVERT=	${_MKSHNOECHO}
 .endif
 
+COMPILE.c=	${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} -c $< -o $@
+COMPILE.s=	${CC} ${AFLAGS} ${AFLAGS.${<:T}} ${CPPFLAGS} -c $< -o $@
+LINK.o=		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
+
 # compile rules: rules are named ${TYPE}_${SUFFIX} where TYPE is NORMAL or
 # NOPROF and SUFFIX is the file suffix, capitalized (e.g. C for a .c file).
 NORMAL_C?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO}\
-		${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $< -o $@ && \
-		${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $< -o $@ && \
+		${_MKSHECHO} ${COMPILE.c} ${PROF} && \
+		${COMPILE.c} ${PROF} && \
 		${COMPILE_CTFCONVERT}
 NOPROF_C?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO}\
-		${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} -c $< -o $@ && \
-		${CC} ${COPTS.${<:T}} ${CFLAGS} ${CPPFLAGS} -c $< -o $@ && \
+		${_MKSHECHO} ${COMPILE.c} && \
+		${COMPILE.c} && \
 		${COMPILE_CTFCONVERT}
 NORMAL_S?=	@${_MKSHMSG} "compile  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO}\
-		${CC} ${AFLAGS} ${AFLAGS.${<:T}} ${CPPFLAGS} -c $< -o $@ && \
-		${CC} ${AFLAGS} ${AFLAGS.${<:T}} ${CPPFLAGS} -c $< -o $@
+		${_MKSHECHO} ${COMPILE.s} && \
+		${COMPILE.s}
  
 # link rules: 
 LINK_O?=	@${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}" && \
-		${_MKSHECHO}\
-		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC} && \
-		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
+		${_MKSHECHO} ${LINK.o} && \
+		${LINK.o}
 
 ##
 ## (3) libkern and compat



Re: CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
According to make(1), $< (${.IMPSRC}) is not set in explicit rules.
If so, existing logic of using explicit rules around ${NORMAL_C} can
be said to be just wrong.


CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Sep  3 03:47:25 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Refactor.


To generate a diff of this commit:
cvs rdiff -u -r1.228 -r1.229 src/sys/conf/Makefile.kern.inc

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



Re: CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Fallouts should not happen.


CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 23:03:41 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Fix link of kernels whose name don't start with "netbsd*".


To generate a diff of this commit:
cvs rdiff -u -r1.224 -r1.225 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.224 src/sys/conf/Makefile.kern.inc:1.225
--- src/sys/conf/Makefile.kern.inc:1.224	Wed Sep  2 15:35:52 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Sep  2 23:03:41 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.224 2015/09/02 15:35:52 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.225 2015/09/02 23:03:41 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -227,7 +227,7 @@ SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJ
 .else
 SYSTEM_OBJ?=	${MD_OBJS} ${MI_OBJS} ${OBJS:O} ${SYSLIBCOMPAT} ${LIBKERN}
 .endif
-SYSTEM_OBJ_NOSWAP=	${SYSTEM_OBJ:N*swapnetbsd*}
+SYSTEM_OBJ_NOSWAP=	${SYSTEM_OBJ:N*swap*netbsd*}
 SYSTEM_DEP+=	Makefile ${SYSTEM_OBJ} .gdbinit
 .if defined(CTFMERGE)
 SYSTEM_CTFMERGE= ${CTFMERGE} ${CTFMFLAGS} -o ${.TARGET} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 23:03:41 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Fix link of kernels whose name don't start with "netbsd*".


To generate a diff of this commit:
cvs rdiff -u -r1.224 -r1.225 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 12:38:48 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Add swap.o to common ${SYSTEM_LD} as it is always linked.


To generate a diff of this commit:
cvs rdiff -u -r1.219 -r1.220 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.219 src/sys/conf/Makefile.kern.inc:1.220
--- src/sys/conf/Makefile.kern.inc:1.219	Wed Sep  2 03:22:41 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Sep  2 12:38:48 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.219 2015/09/02 03:22:41 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.220 2015/09/02 12:38:48 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -248,8 +248,8 @@ SYSTEM_LD?=	@do_system_ld() { \
 		target=$$1; shift; \
 		${_MKSHMSG} "   link  ${.CURDIR:T}/${.TARGET}"; \
 		${_MKSHECHO}\
-		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} '$${SYSTEM_OBJ}' '$${EXTRA_OBJ}' vers.o $$@; \
-		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o $$@; \
+		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} '$${SYSTEM_OBJ}' '$${EXTRA_OBJ}' vers.o swap$${target}.o $$@; \
+		${LD} -Map $${target}.map --cref ${LINKFLAGS} -o $${target} ${SYSTEM_OBJ} ${EXTRA_OBJ} vers.o swap$${target}.o $$@; \
 		}; \
 		do_system_ld
 
@@ -482,11 +482,7 @@ CWARNFLAGS+=	${CWARNFLAGS.${.IMPSRC:T}}
 .if !defined(COPY_SYMTAB)
 build_kernel: .USE
 	${SYSTEM_LD_HEAD}
-.if !defined(___USE_SUFFIX_RULES___)
-	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o
-.else
 	${SYSTEM_LD} ${.TARGET}
-.endif
 	${SYSTEM_LD_TAIL_STAGE2}
 .else
 .for k in ${KERNELS}
@@ -496,21 +492,13 @@ build_kernel: .USE
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf.o
 	${SYSTEM_LD_HEAD}
-.if !defined(___USE_SUFFIX_RULES___)
-	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o kern_ksyms_buf.o
-.else
 	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf.o
-.endif
 	${SYSTEM_LD_TAIL_STAGE1}
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-DSYMTAB_SPACE=$$(${DBSYM} -P ${.TARGET}${TARGETSFX}) \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf_real.o
 	${SYSTEM_LD_HEAD}
-.if !defined(___USE_SUFFIX_RULES___)
-	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o kern_ksyms_buf_real.o
-.else
 	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf_real.o
-.endif
 	${SYSTEM_LD_TAIL_STAGE2}
 .endif
 



CVS commit: src/sys/conf

2015-09-02 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 12:38:48 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Add swap.o to common ${SYSTEM_LD} as it is always linked.


To generate a diff of this commit:
cvs rdiff -u -r1.219 -r1.220 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 03:22:41 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Clean up some rules and make them less error prone.


To generate a diff of this commit:
cvs rdiff -u -r1.218 -r1.219 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.218 src/sys/conf/Makefile.kern.inc:1.219
--- src/sys/conf/Makefile.kern.inc:1.218	Tue Sep  1 23:04:35 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Sep  2 03:22:41 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.218 2015/09/01 23:04:35 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.219 2015/09/02 03:22:41 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -397,8 +397,9 @@ DEPS=	${SRCS:T:u:R:S/$/.d/g}
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s} assym.h
 	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
+	${MKDEP} -f ${.TARGET}.tmp -- ${MKDEP_AFLAGS} \
 	${CPPFLAGS} ${CPPFLAGS.${_s:T}} ${_s}
+	mv -f ${.TARGET}.tmp ${.TARGET}
 .endif
 .endfor
 
@@ -406,8 +407,9 @@ ${_s:T:R}.d: ${_s} assym.h
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s}
 	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_CFLAGS} \
+	${MKDEP} -f ${.TARGET}.tmp -- ${MKDEP_CFLAGS} \
 	${CPPFLAGS} ${CPPFLAGS.${_s:T}} ${_s}
+	mv -f ${.TARGET}.tmp ${.TARGET}
 .endif
 .endfor
 
@@ -523,28 +525,27 @@ build_kernel: .USE
 .SUFFIXES: .genassym .assym.h
 .genassym.assym.h:
 	${_MKTARGET_CREATE}
-	cat $< | \
-	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
-	${GENASSYM_CPPFLAGS} > $@.tmp && \
+	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
+	${GENASSYM_CPPFLAGS} < $< > $@
 	mv -f $@.tmp $@
 
 .SUFFIXES: .s .d
 .s.d:
 	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
-	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	${MKDEP} -f $@.tmp -- ${MKDEP_AFLAGS} ${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	mv -f $@.tmp $@
 
 .SUFFIXES: .S .d
 .S.d:
 	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
-	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	${MKDEP} -f $@.tmp -- ${MKDEP_AFLAGS} ${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	mv -f $@.tmp $@
 
 .SUFFIXES: .c .d
 .c.d:
 	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_CFLAGS} \
-	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	${MKDEP} -f $@.tmp -- ${MKDEP_CFLAGS} ${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+	mv -f $@.tmp $@
 
 .SUFFIXES: .c .o
 .c.o:



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Sep  2 03:22:41 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Clean up some rules and make them less error prone.


To generate a diff of this commit:
cvs rdiff -u -r1.218 -r1.219 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Tue Sep  1 23:04:35 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Define suffix rules at the end to override system definitions.  Provide them
only if ___USE_SUFFIX_RULES___ is defined (config -S).


To generate a diff of this commit:
cvs rdiff -u -r1.217 -r1.218 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.217 src/sys/conf/Makefile.kern.inc:1.218
--- src/sys/conf/Makefile.kern.inc:1.217	Tue Sep  1 16:04:04 2015
+++ src/sys/conf/Makefile.kern.inc	Tue Sep  1 23:04:35 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.217 2015/09/01 16:04:04 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.218 2015/09/01 23:04:35 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -174,14 +174,6 @@ ${_s:T:R}.o: ${_s}
 .endif
 .endfor
 
-.SUFFIXES: .c .o
-.c.o:
-	${NORMAL_C}
-
-.SUFFIXES: .S .o
-.S.o:
-	${NORMAL_S}
-
 ##
 ## (3) libkern and compat
 ##
@@ -325,14 +317,6 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ## (6) port independent targets and dependencies: assym.h, vers.o
 ##
 
-.SUFFIXES: .genassym .assym.h
-.genassym.assym.h:
-	${_MKTARGET_CREATE}
-	cat $< | \
-	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
-	${GENASSYM_CPPFLAGS} > $@.tmp && \
-	mv -f $@.tmp $@
-
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
 	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf | \
@@ -409,12 +393,6 @@ CSRCS=${MD_CFILES} ${MI_CFILES} ${CFILES
 SRCS=${SSRCS} ${CSRCS}
 DEPS=	${SRCS:T:u:R:S/$/.d/g}
 
-.SUFFIXES: .S .d
-.S.d:
-	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
-	${CPPFLAGS} ${CPPFLAGS.${_s:T}} $<
-
 .for _s in ${SSRCS}
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s} assym.h
@@ -424,12 +402,6 @@ ${_s:T:R}.d: ${_s} assym.h
 .endif
 .endfor
 
-.SUFFIXES: .c .d
-.c.d:
-	${_MKTARGET_CREATE}
-	${MKDEP} -f ${.TARGET} -- ${MKDEP_CFLAGS} \
-	${CPPFLAGS} ${CPPFLAGS.${_s:T}} $<
-
 .for _s in ${CSRCS}
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s}
@@ -544,5 +516,49 @@ build_kernel: .USE
 .include 
 
 ##
+## suffix rules
+##
+
+.if defined(___USE_SUFFIX_RULES___)
+.SUFFIXES: .genassym .assym.h
+.genassym.assym.h:
+	${_MKTARGET_CREATE}
+	cat $< | \
+	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
+	${GENASSYM_CPPFLAGS} > $@.tmp && \
+	mv -f $@.tmp $@
+
+.SUFFIXES: .s .d
+.s.d:
+	${_MKTARGET_CREATE}
+	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
+	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+
+.SUFFIXES: .S .d
+.S.d:
+	${_MKTARGET_CREATE}
+	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
+	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+
+.SUFFIXES: .c .d
+.c.d:
+	${_MKTARGET_CREATE}
+	${MKDEP} -f ${.TARGET} -- ${MKDEP_CFLAGS} \
+	${CPPFLAGS} ${CPPFLAGS.${<:T}} $<
+
+.SUFFIXES: .c .o
+.c.o:
+	${NORMAL_C}
+
+.SUFFIXES: .s .o
+.s.o:
+	${NORMAL_S}
+
+.SUFFIXES: .S .o
+.S.o:
+	${NORMAL_S}
+.endif # ___USE_SUFFIX_RULES___
+
+##
 ## the end
 ##



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Tue Sep  1 23:04:35 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Define suffix rules at the end to override system definitions.  Provide them
only if ___USE_SUFFIX_RULES___ is defined (config -S).


To generate a diff of this commit:
cvs rdiff -u -r1.217 -r1.218 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Tue Sep  1 16:04:04 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Experimental suffix-rules build (disabled by default).


To generate a diff of this commit:
cvs rdiff -u -r1.216 -r1.217 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.216 src/sys/conf/Makefile.kern.inc:1.217
--- src/sys/conf/Makefile.kern.inc:1.216	Sun Aug 30 21:16:10 2015
+++ src/sys/conf/Makefile.kern.inc	Tue Sep  1 16:04:04 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.216 2015/08/30 21:16:10 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.217 2015/09/01 16:04:04 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -216,7 +216,11 @@ SYSLIBCOMPATLN?=	${COMPATLIBLN}
 ## MD_CFILES, MD_SFILES, and MD_OBJS, along with build rules for same.
 ##
 
-MI_CFILES=devsw.c ioconf.c param.c
+MI_CFILES=	param.c
+.if !defined(___USE_SUFFIX_RULES___)
+MI_CFILES+=	devsw.c ioconf.c
+.endif
+
 # the need for a MI_SFILES variable is dubitable at best
 MI_OBJS=${MI_CFILES:S/.c/.o/}
 
@@ -504,7 +508,11 @@ CWARNFLAGS+=	${CWARNFLAGS.${.IMPSRC:T}}
 .if !defined(COPY_SYMTAB)
 build_kernel: .USE
 	${SYSTEM_LD_HEAD}
+.if !defined(___USE_SUFFIX_RULES___)
 	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o
+.else
+	${SYSTEM_LD} ${.TARGET}
+.endif
 	${SYSTEM_LD_TAIL_STAGE2}
 .else
 .for k in ${KERNELS}
@@ -514,13 +522,21 @@ build_kernel: .USE
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf.o
 	${SYSTEM_LD_HEAD}
+.if !defined(___USE_SUFFIX_RULES___)
 	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o kern_ksyms_buf.o
+.else
+	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf.o
+.endif
 	${SYSTEM_LD_TAIL_STAGE1}
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-DSYMTAB_SPACE=$$(${DBSYM} -P ${.TARGET}${TARGETSFX}) \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf_real.o
 	${SYSTEM_LD_HEAD}
+.if !defined(___USE_SUFFIX_RULES___)
 	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o kern_ksyms_buf_real.o
+.else
+	${SYSTEM_LD} ${.TARGET} kern_ksyms_buf_real.o
+.endif
 	${SYSTEM_LD_TAIL_STAGE2}
 .endif
 



CVS commit: src/sys/conf

2015-09-01 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Tue Sep  1 16:04:04 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Experimental suffix-rules build (disabled by default).


To generate a diff of this commit:
cvs rdiff -u -r1.216 -r1.217 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 07:35:11 UTC 2015

Modified Files:
src/sys/conf: files

Log Message:
Typo.


To generate a diff of this commit:
cvs rdiff -u -r1.1142 -r1.1143 src/sys/conf/files

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

Modified files:

Index: src/sys/conf/files
diff -u src/sys/conf/files:1.1142 src/sys/conf/files:1.1143
--- src/sys/conf/files:1.1142	Sun Aug 30 05:24:04 2015
+++ src/sys/conf/files	Sun Aug 30 07:35:11 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: files,v 1.1142 2015/08/30 05:24:04 uebayasi Exp $
+#	$NetBSD: files,v 1.1143 2015/08/30 07:35:11 uebayasi Exp $
 #	@(#)files.newconf	7.5 (Berkeley) 5/10/93
 
 version 	20150832
@@ -290,7 +290,7 @@ defflag	opt_md.h		MEMORY_DISK_HOOKS MEMO
 MEMORY_DISK_DYNAMIC
 defparam opt_md.h		MEMORY_DISK_SERVER=1 MEMORY_DISK_ROOT_SIZE
 MEMORY_DISK_RBFLAGS
-defparam opt_memory_disk_image	makeoptions_MEMORY_DISK_IMAGE
+defparam opt_memory_disk_image.h	makeoptions_MEMORY_DISK_IMAGE
 
 defflag opt_tftproot.h		TFTPROOT TFTPROOT_DEBUG
 



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 07:35:11 UTC 2015

Modified Files:
src/sys/conf: files

Log Message:
Typo.


To generate a diff of this commit:
cvs rdiff -u -r1.1142 -r1.1143 src/sys/conf/files

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



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 07:52:30 UTC 2015

Modified Files:
src/sys/conf: files

Log Message:
Generate opt_diagnostic.h for DIAGNOSTIC; define unused _DIAGNOSTIC until
thoroughly populated.


To generate a diff of this commit:
cvs rdiff -u -r1.1143 -r1.1144 src/sys/conf/files

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

Modified files:

Index: src/sys/conf/files
diff -u src/sys/conf/files:1.1143 src/sys/conf/files:1.1144
--- src/sys/conf/files:1.1143	Sun Aug 30 07:35:11 2015
+++ src/sys/conf/files	Sun Aug 30 07:52:30 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: files,v 1.1143 2015/08/30 07:35:11 uebayasi Exp $
+#	$NetBSD: files,v 1.1144 2015/08/30 07:52:30 uebayasi Exp $
 #	@(#)files.newconf	7.5 (Berkeley) 5/10/93
 
 version 	20150832
@@ -28,6 +28,7 @@ defflag	opt_modular.h		MODULAR
 defflag	opt_modular.h		MODULAR_DEFAULT_AUTOLOAD
 defflagKEYLOCK
 defparam opt_syslimits.h	CHILD_MAX OPEN_MAX
+defflag opt_diagnostic.h	_DIAGNOSTIC
 
 defparam opt_copy_symtab.h	makeoptions_COPY_SYMTAB
 



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 07:33:53 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: splash.mk

Log Message:
Move splash logic, keep Makefile.kern.inc clean.


To generate a diff of this commit:
cvs rdiff -u -r1.213 -r1.214 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/splash.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.213 src/sys/conf/Makefile.kern.inc:1.214
--- src/sys/conf/Makefile.kern.inc:1.213	Sun Aug 30 05:24:04 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Aug 30 07:33:53 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.213 2015/08/30 05:24:04 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.214 2015/08/30 07:33:53 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -359,12 +359,6 @@ vers.o: ${SYSTEM_OBJ} Makefile $S/conf/n
 	${COMPILE_CTFCONVERT}
 .endif
 
-# Option for embedding a splashscreen image.
-.if defined(SPLASHSCREEN_IMAGE) 
-.include ${S}/dev/splash/splash.mk
-init_main.o: splash_image.o
-.endif
-
 ##
 ## (7) misc targets: install, clean(dir), depend(all), lint, links, tags,
 ##   cscope, mkid
@@ -484,6 +478,7 @@ install-kernel-${MACHINE_NAME}:
 .endif
 .endif
 
+.include ${S}/conf/splash.mk
 .include ${S}/conf/mdroot.mk
 .include ${S}/conf/lint.mk
 .include ${S}/conf/cscope.mk

Added files:

Index: src/sys/conf/splash.mk
diff -u /dev/null src/sys/conf/splash.mk:1.1
--- /dev/null	Sun Aug 30 07:33:53 2015
+++ src/sys/conf/splash.mk	Sun Aug 30 07:33:53 2015
@@ -0,0 +1,7 @@
+# $NetBSD: splash.mk,v 1.1 2015/08/30 07:33:53 uebayasi Exp $
+
+# Option for embedding a splashscreen image.
+.if defined(SPLASHSCREEN_IMAGE) 
+.include ${S}/dev/splash/splash.mk
+init_main.o: splash_image.o
+.endif



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 07:33:53 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: splash.mk

Log Message:
Move splash logic, keep Makefile.kern.inc clean.


To generate a diff of this commit:
cvs rdiff -u -r1.213 -r1.214 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/splash.mk

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



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 21:16:10 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Fix Define compile rules in sys/conf/Makefile.kern.inc 

Use `.if !commands(xxx)' to check if `xxx' has a defined, overriden rule,
instead of `.if !targets(xxx)'.  The latter evaluates as true even when `xxx'
has an empty rule to define a dependency.


To generate a diff of this commit:
cvs rdiff -u -r1.215 -r1.216 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.215 src/sys/conf/Makefile.kern.inc:1.216
--- src/sys/conf/Makefile.kern.inc:1.215	Sun Aug 30 14:06:17 2015
+++ src/sys/conf/Makefile.kern.inc	Sun Aug 30 21:16:10 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.215 2015/08/30 14:06:17 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.216 2015/08/30 21:16:10 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -161,14 +161,14 @@ LINK_O?=	@${_MKSHMSG}link  ${.CURDI
 		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
 
 .for _s in ${CFILES}
-.if !target(${_s:T:R}.o)
+.if !commands(${_s:T:R}.o)
 ${_s:T:R}.o: ${_s}
 	${NORMAL_C}
 .endif
 .endfor
 
 .for _s in ${SFILES}
-.if !target(${_s:T:R}.o)
+.if !commands(${_s:T:R}.o)
 ${_s:T:R}.o: ${_s}
 	${NORMAL_S}
 .endif



CVS commit: src/sys/conf

2015-08-30 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sun Aug 30 21:16:10 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Fix Define compile rules in sys/conf/Makefile.kern.inc 

Use `.if !commands(xxx)' to check if `xxx' has a defined, overriden rule,
instead of `.if !targets(xxx)'.  The latter evaluates as true even when `xxx'
has an empty rule to define a dependency.


To generate a diff of this commit:
cvs rdiff -u -r1.215 -r1.216 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 14:43:38 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
I don't see how uipc_proto.c can change its content by Makefile, don't depend
on Makefile.  vfs_conf.c doesn't even exist, remove it too.


To generate a diff of this commit:
cvs rdiff -u -r1.203 -r1.204 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:37:18 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
genassym.cf and machdep.c are _KERNEL_OPT'ed, don't depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:07:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: kern.ldscript

Log Message:
Define two suffix rules, .c - .o and .S - .o, using ${NORMAL_C} and
${NORMAL_S} respectively.  Use the .c rule to build devsw.c, ioconf.c, and
param.c.  Other .c/.S files have explicit rules in the generated `Makefile',
and unaffected.


To generate a diff of this commit:
cvs rdiff -u -r1.208 -r1.209 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/kern.ldscript

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.208 src/sys/conf/Makefile.kern.inc:1.209
--- src/sys/conf/Makefile.kern.inc:1.208	Sat Aug 29 15:58:38 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 16:07:07 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.208 2015/08/29 15:58:38 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.209 2015/08/29 16:07:07 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -163,6 +163,14 @@ LINK_O?=	@${_MKSHMSG}link  ${.CURDI
 		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}  \
 		${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC}
 
+.SUFFIXES: .c .o
+.c.o:
+	${NORMAL_C}
+
+.SUFFIXES: .S .o
+.S.o:
+	${NORMAL_S}
+
 ##
 ## (3) libkern and compat
 ##
@@ -196,6 +204,7 @@ SYSLIBCOMPATLN?=	${COMPATLIBLN}
 ## Each port should have a corresponding section with settings for
 ## MD_CFILES, MD_SFILES, and MD_OBJS, along with build rules for same.
 ##
+
 MI_CFILES=devsw.c ioconf.c param.c
 # the need for a MI_SFILES variable is dubitable at best
 MI_OBJS=${MI_CFILES:S/.c/.o/}
@@ -205,11 +214,6 @@ param.c: $S/conf/param.c
 	rm -f param.c
 	cp $S/conf/param.c .
 
-.for _cfile in ${MI_CFILES}
-${_cfile:T:R}.o: ${_cfile}
-	${NORMAL_C}
-.endfor
-
 ##
 ## (5) link settings
 ##

Added files:




CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:07:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: kern.ldscript

Log Message:
Define two suffix rules, .c - .o and .S - .o, using ${NORMAL_C} and
${NORMAL_S} respectively.  Use the .c rule to build devsw.c, ioconf.c, and
param.c.  Other .c/.S files have explicit rules in the generated `Makefile',
and unaffected.


To generate a diff of this commit:
cvs rdiff -u -r1.208 -r1.209 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/kern.ldscript

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:27:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: cscope.mk gdbinit.mk lint.mk

Log Message:
Move less important part out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.209 -r1.210 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/cscope.mk src/sys/conf/gdbinit.mk \
src/sys/conf/lint.mk

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:27:07 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc
Added Files:
src/sys/conf: cscope.mk gdbinit.mk lint.mk

Log Message:
Move less important part out of Makefile.kern.inc.


To generate a diff of this commit:
cvs rdiff -u -r1.209 -r1.210 src/sys/conf/Makefile.kern.inc
cvs rdiff -u -r0 -r1.1 src/sys/conf/cscope.mk src/sys/conf/gdbinit.mk \
src/sys/conf/lint.mk

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.209 src/sys/conf/Makefile.kern.inc:1.210
--- src/sys/conf/Makefile.kern.inc:1.209	Sat Aug 29 16:07:07 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 16:27:07 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.209 2015/08/29 16:07:07 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.210 2015/08/29 16:27:07 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -446,51 +446,14 @@ DEPS+=	assym.d
 .endif
 
 ##
-## lint
+## install
 ##
 
-.if !target(lint)
-ALLSFILES?=	${MD_SFILES} ${SFILES}
-LINTSTUBS?=	${ALLSFILES:T:R:C/^.*$/LintStub_.c/g}
-KERNLINTFLAGS?=	-bcehnxzFS
-NORMAL_LN?=	${LINT} ${KERNLINTFLAGS} ${CPPFLAGS:M-[IDU]*} -i $ -o $@
-
-_lsrc=${CFILES} ${LINTSTUBS} ${MI_CFILES} ${MD_CFILES}
-LOBJS?= ${_lsrc:T:S/.c$/.ln/g} ${LIBKERNLN} ${SYSLIBCOMPATLN}
-
-.for _sfile in ${ALLSFILES}
-LintStub_${_sfile:T:R}.c: ${_sfile} assym.h
-	${_MKTARGET_COMPILE}
-	${CC} -E -C ${AFLAGS} ${CPPFLAGS} ${_sfile} | \
-	  ${TOOL_AWK} -f $S/kern/genlintstub.awk ${.TARGET}
-.endfor
-
-.for _cfile in ${CFILES} ${LINTSTUBS} ${MI_CFILES} ${MD_CFILES}
-${_cfile:T:R}.ln: ${_cfile}
-	${_MKTARGET_COMPILE}
-	${NORMAL_LN}
-.endfor
-
-lint: ${LOBJS}
-	${LINT} ${KERNLINTFLAGS} ${CPPFLAGS:M-[IDU]*} ${LOBJS}
-.endif
-
-# Attempt to do a syntax-only compile of the entire kernel as one entity.
-# Alas, bugs in the GCC C frontend prevent this from completely effective
-# but information can be gleaned from the output.
-syntax-only: ${CFILES} ${MD_CFILES}
-	${CC} -fsyntax-only -combine ${CFLAGS} ${CPPFLAGS} \
-		${CFILES} ${MD_CFILES}
-
 # List of kernel images that will be installed into the root file system.
 # Some platforms may need to install more than one (e.g. a netbsd.aout file
 # to be loaded directly by the firmware), so this can be overriden by them.
 KERNIMAGES?=	netbsd
 
-##
-## install
-##
-
 .if !target(install)
 # The install target can be redefined by putting a
 # install-kernel-${MACHINE_NAME} target into /etc/mk.conf
@@ -507,81 +470,9 @@ install-kernel-${MACHINE_NAME}:
 .endif
 .endif
 
-##
-## tags
-##
-
-.if !target(tags)
-tags:
-	@echo see $S/kern/Makefile for tags
-.endif
-
-##
-## cscope
-##
-
-EXTRA_CLEAN+= cscope.out cscope.tmp
-.if !target(cscope.out)
-cscope.out: Makefile depend
-	${_MKTARGET_CREATE}
-	@${TOOL_SED} 's/[^:]*://;s/^ *//;s/ *\\ *$$//;' lib/kern/.depend \
-	| tr -s ' ' '\n' \
-	| ${TOOL_SED} ';s|^../../||;' \
-	 cscope.tmp
-	@${TOOL_SED} 's/[^:]*://;s/^ *//;s/ *\\ *$$//;' lib/compat/.depend \
-	| tr -s ' ' '\n' \
-	| ${TOOL_SED} 's|^../../||;' \
-	 cscope.tmp
-	@echo ${SRCS} | cat - cscope.tmp | tr -s ' ' '\n' | sort -u | \
-	${CSCOPE} -k -i - -b `echo ${INCLUDES} | ${TOOL_SED} s/-nostdinc//`
-#	cscope doesn't write cscope.out if it's uptodate, so ensure
-#	make doesn't keep calling cscope when not needed.
-	@rm -f cscope.tmp; touch cscope.out
-.endif
-
-.if !target(cscope)
-cscope: cscope.out
-	@${CSCOPE} -d
-.endif
-
-EXTRA_CLEAN+= ID
-.if !target(mkid)
-.PHONY: mkid
-mkid: ID
-
-ID: Makefile depend
-	${_MKTARGET_CREATE}
-	@${MKID} \
-	`${TOOL_SED} 's/[^:]*://;s/^ *//;s/ * *$$//;' \
-			lib/kern/.depend lib/compat/.depend \
-		| tr ' ' '\n' \
-		| ${TOOL_SED} s|^../../|| \
-		| sort -u` \
-	`${TOOL_SED} 's/[^:]*://;s/^ *//;s/ * *$$//;' \
-			.depend \
-		| tr ' ' '\n' \
-		| sort -u`
-
-.endif
-
-##
-## .gdbinit
-##
-
-.include ${S}/gdbscripts/Makefile.inc
-
-EXTRA_CLEAN+= .gdbinit
-.gdbinit: Makefile ${S}/gdbscripts/Makefile.inc
-	${_MKTARGET_CREATE}
-	rm -f .gdbinit
-.for __gdbinit in ${SYS_GDBINIT}
-	echo source ${S}/gdbscripts/${__gdbinit}  .gdbinit
-.endfor
-.if defined(GDBINIT)  !empty(GDBINIT)
-.for __gdbinit in ${GDBINIT}
-	echo source ${__gdbinit}  .gdbinit
-.endfor
-.endif
+.include ${S}/conf/lint.mk
+.include ${S}/conf/cscope.mk
+.include ${S}/conf/gdbinit.mk
 
 ##
 ## the kernel

Added files:

Index: src/sys/conf/cscope.mk
diff -u /dev/null src/sys/conf/cscope.mk:1.1
--- /dev/null	Sat Aug 29 16:27:07 2015
+++ src/sys/conf/cscope.mk	Sat Aug 29 16:27:07 2015
@@ -0,0 +1,49 @@
+# $NetBSD: cscope.mk,v 1.1 2015/08/29 16:27:07 uebayasi Exp $
+
+##
+## cscope
+##
+
+EXTRA_CLEAN+= cscope.out cscope.tmp
+.if !target(cscope.out)
+cscope.out: Makefile 

CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:06:35 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
conf.c doesn't exist.

autoconf.c exists, but it's just a C file, no need to depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.204 -r1.205 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.204 src/sys/conf/Makefile.kern.inc:1.205
--- src/sys/conf/Makefile.kern.inc:1.204	Sat Aug 29 14:43:38 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 15:06:35 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.204 2015/08/29 14:43:38 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.205 2015/08/29 15:06:35 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -362,9 +362,6 @@ md_root.o: md_root_image.h
 # depend on MEMORY_DISK_IMAGE configuration
 md_root.o: Makefile
 
-# depend on root or device configuration
-autoconf.o conf.o: Makefile
-
 # depend on maxusers and CPU configuration
 assym.h machdep.o: Makefile
 



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:06:35 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
conf.c doesn't exist.

autoconf.c exists, but it's just a C file, no need to depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.204 -r1.205 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:58:38 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Now that MAXUSERS is in opt_param.h, param.o doesn't depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.207 -r1.208 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.207 src/sys/conf/Makefile.kern.inc:1.208
--- src/sys/conf/Makefile.kern.inc:1.207	Sat Aug 29 15:51:53 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 15:58:38 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.207 2015/08/29 15:51:53 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.208 2015/08/29 15:58:38 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -205,8 +205,6 @@ param.c: $S/conf/param.c
 	rm -f param.c
 	cp $S/conf/param.c .
 
-param.o: Makefile
-
 .for _cfile in ${MI_CFILES}
 ${_cfile:T:R}.o: ${_cfile}
 	${NORMAL_C}



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:58:38 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Now that MAXUSERS is in opt_param.h, param.o doesn't depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.207 -r1.208 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:10:01 UTC 2015

Removed Files:
src/sys/conf: kern.ldscript

Log Message:
Revert a mistakenly added file.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r0 src/sys/conf/kern.ldscript

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 16:10:01 UTC 2015

Removed Files:
src/sys/conf: kern.ldscript

Log Message:
Revert a mistakenly added file.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r0 src/sys/conf/kern.ldscript

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



CVS commit: src/sys/conf

2015-08-29 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 15:37:18 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
genassym.cf and machdep.c are _KERNEL_OPT'ed, don't depend on Makefile.


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.205 src/sys/conf/Makefile.kern.inc:1.206
--- src/sys/conf/Makefile.kern.inc:1.205	Sat Aug 29 15:06:35 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 15:37:18 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.205 2015/08/29 15:06:35 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.206 2015/08/29 15:37:18 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -362,9 +362,6 @@ md_root.o: md_root_image.h
 # depend on MEMORY_DISK_IMAGE configuration
 md_root.o: Makefile
 
-# depend on maxusers and CPU configuration
-assym.h machdep.o: Makefile
-
 ##
 ## (7) misc targets: install, clean(dir), depend(all), lint, links, tags,
 ##   cscope, mkid



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 04:46:27 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Specify explicit output (-o) to ${LINT} too.


To generate a diff of this commit:
cvs rdiff -u -r1.197 -r1.198 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.197 src/sys/conf/Makefile.kern.inc:1.198
--- src/sys/conf/Makefile.kern.inc:1.197	Sat Aug 29 04:43:05 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 04:46:27 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.197 2015/08/29 04:43:05 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.198 2015/08/29 04:46:27 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -438,7 +438,7 @@ DEPS+=	assym.d
 ALLSFILES?=	${MD_SFILES} ${SFILES}
 LINTSTUBS?=	${ALLSFILES:T:R:C/^.*$/LintStub_.c/g}
 KERNLINTFLAGS?=	-bcehnxzFS
-NORMAL_LN?=	${LINT} ${KERNLINTFLAGS} ${CPPFLAGS:M-[IDU]*} -i $
+NORMAL_LN?=	${LINT} ${KERNLINTFLAGS} ${CPPFLAGS:M-[IDU]*} -i $ -o $@
 
 _lsrc=${CFILES} ${LINTSTUBS} ${MI_CFILES} ${MD_CFILES}
 LOBJS?= ${_lsrc:T:S/.c$/.ln/g} ${LIBKERNLN} ${SYSLIBCOMPATLN}



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 04:46:27 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Specify explicit output (-o) to ${LINT} too.


To generate a diff of this commit:
cvs rdiff -u -r1.197 -r1.198 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 04:43:05 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Specifiy explicit output (-o) to ${CC}.


To generate a diff of this commit:
cvs rdiff -u -r1.196 -r1.197 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.196 src/sys/conf/Makefile.kern.inc:1.197
--- src/sys/conf/Makefile.kern.inc:1.196	Thu Aug 27 06:28:09 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 04:43:05 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.196 2015/08/27 06:28:09 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.197 2015/08/29 04:43:05 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -144,18 +144,18 @@ COMPILE_CTFCONVERT=	${_MKSHNOECHO}
 # NOPROF and SUFFIX is the file suffix, capitalized (e.g. C for a .c file).
 NORMAL_C?=	@${_MKSHMSG} compile  ${.CURDIR:T}/${.TARGET}  \
 		${_MKSHECHO}\
-		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $  \
-		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $  \
+		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $ -o $@  \
+		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $ -o $@  \
 		${COMPILE_CTFCONVERT}
 NOPROF_C?=	@${_MKSHMSG} compile  ${.CURDIR:T}/${.TARGET}  \
 		${_MKSHECHO}\
-		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} -c $  \
-		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} -c $  \
+		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} -c $ -o $@  \
+		${CC} ${COPTS.${:T}} ${CFLAGS} ${CPPFLAGS} -c $ -o $@  \
 		${COMPILE_CTFCONVERT}
 NORMAL_S?=	@${_MKSHMSG} compile  ${.CURDIR:T}/${.TARGET}  \
 		${_MKSHECHO}\
-		${CC} ${AFLAGS} ${AFLAGS.${:T}} ${CPPFLAGS} -c $  \
-		${CC} ${AFLAGS} ${AFLAGS.${:T}} ${CPPFLAGS} -c $
+		${CC} ${AFLAGS} ${AFLAGS.${:T}} ${CPPFLAGS} -c $ -o $@  \
+		${CC} ${AFLAGS} ${AFLAGS.${:T}} ${CPPFLAGS} -c $ -o $@
  
 # link rules: 
 LINK_O?=	@${_MKSHMSG}link  ${.CURDIR:T}/${.TARGET}  \



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 04:43:05 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Specifiy explicit output (-o) to ${CC}.


To generate a diff of this commit:
cvs rdiff -u -r1.196 -r1.197 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 05:02:43 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Define some suffix rules.  Not used and harmless, because all rules are
explicit now.


To generate a diff of this commit:
cvs rdiff -u -r1.198 -r1.199 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 05:03:36 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Comment.


To generate a diff of this commit:
cvs rdiff -u -r1.199 -r1.200 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.199 src/sys/conf/Makefile.kern.inc:1.200
--- src/sys/conf/Makefile.kern.inc:1.199	Sat Aug 29 05:02:43 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 05:03:36 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.199 2015/08/29 05:02:43 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.200 2015/08/29 05:03:36 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -379,6 +379,11 @@ assym.h machdep.o: Makefile
 ## EXTRA_CLEAN.  Some ports may want different settings for
 ## KERNLINTFLAGS, MKDEP_CFLAGS, or MKDEP_AFLAGS.
 ##
+
+##
+## clean
+##
+
 .if !target(__CLEANKERNEL)
 __CLEANKERNEL: .USE
 	${_MKMSG} ${.TARGET}ing the kernel objects
@@ -403,6 +408,10 @@ clean: __CLEANKERNEL
 depend: .depend
 dependall: depend .WAIT all
 
+##
+## depend
+##
+
 .if !target(.depend)
 MKDEP_AFLAGS?=	${AFLAGS}
 MKDEP_CFLAGS?=	${CFLAGS}
@@ -456,6 +465,10 @@ DEPS+=	assym.d
 	echo ${.ALLSRC} | ${MKDEP} -D
 .endif
 
+##
+## lint
+##
+
 .if !target(lint)
 ALLSFILES?=	${MD_SFILES} ${SFILES}
 LINTSTUBS?=	${ALLSFILES:T:R:C/^.*$/LintStub_.c/g}
@@ -494,6 +507,10 @@ syntax-only: ${CFILES} ${MD_CFILES}
 # to be loaded directly by the firmware), so this can be overriden by them.
 KERNIMAGES?=	netbsd
 
+##
+## install
+##
+
 .if !target(install)
 # The install target can be redefined by putting a
 # install-kernel-${MACHINE_NAME} target into /etc/mk.conf
@@ -510,11 +527,19 @@ install-kernel-${MACHINE_NAME}:
 .endif
 .endif
 
+##
+## tags
+##
+
 .if !target(tags)
 tags:
 	@echo see $S/kern/Makefile for tags
 .endif
 
+##
+## cscope
+##
+
 EXTRA_CLEAN+= cscope.out cscope.tmp
 .if !target(cscope.out)
 cscope.out: Makefile depend
@@ -559,6 +584,10 @@ ID: Makefile depend
 
 .endif
 
+##
+## .gdbinit
+##
+
 .include ${S}/gdbscripts/Makefile.inc
 
 EXTRA_CLEAN+= .gdbinit
@@ -574,6 +603,10 @@ EXTRA_CLEAN+= .gdbinit
 .endfor
 .endif
 
+##
+## the kernel
+##
+
 # The following files use alloca(3) or variable array allocations.
 # Their full name is noted as documentation.
 VARSTACK=kern/uipc_socket.c miscfs/genfs/genfs_vnops.c \



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 05:03:36 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Comment.


To generate a diff of this commit:
cvs rdiff -u -r1.199 -r1.200 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-28 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Sat Aug 29 05:02:43 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Define some suffix rules.  Not used and harmless, because all rules are
explicit now.


To generate a diff of this commit:
cvs rdiff -u -r1.198 -r1.199 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.198 src/sys/conf/Makefile.kern.inc:1.199
--- src/sys/conf/Makefile.kern.inc:1.198	Sat Aug 29 04:46:27 2015
+++ src/sys/conf/Makefile.kern.inc	Sat Aug 29 05:02:43 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.198 2015/08/29 04:46:27 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.199 2015/08/29 05:02:43 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -307,6 +307,15 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ##
 ## (6) port independent targets and dependencies: assym.h, vers.o
 ##
+
+.SUFFIXES: .genassym .assym.h
+.genassym.assym.h:
+	${_MKTARGET_CREATE}
+	cat $ | \
+	${GENASSYM} -- ${CC} ${CFLAGS:N-Wa,*} ${CPPFLAGS} ${PROF} \
+	${GENASSYM_CPPFLAGS}  $@.tmp  \
+	mv -f $@.tmp $@
+
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf
 	${_MKTARGET_CREATE}
 	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} $S/conf/genassym.cf | \
@@ -402,6 +411,12 @@ CSRCS=${MD_CFILES} ${MI_CFILES} ${CFILES
 SRCS=${SSRCS} ${CSRCS}
 DEPS=	${SRCS:T:u:R:S/$/.d/g}
 
+.SUFFIXES: .S .d
+.S.d:
+	${_MKTARGET_CREATE}
+	${MKDEP} -f ${.TARGET} -- ${MKDEP_AFLAGS} \
+	${CPPFLAGS} ${CPPFLAGS.${_s:T}} $
+
 .for _s in ${SSRCS}
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s} assym.h
@@ -410,6 +425,13 @@ ${_s:T:R}.d: ${_s} assym.h
 	${CPPFLAGS} ${CPPFLAGS.${_s:T}} ${_s}
 .endif
 .endfor
+
+.SUFFIXES: .c .d
+.c.d:
+	${_MKTARGET_CREATE}
+	${MKDEP} -f ${.TARGET} -- ${MKDEP_CFLAGS} \
+	${CPPFLAGS} ${CPPFLAGS.${_s:T}} $
+
 .for _s in ${CSRCS}
 .if !target(${_s:T:R}.d)
 ${_s:T:R}.d: ${_s}



CVS commit: src/sys/conf

2015-08-27 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Thu Aug 27 06:28:09 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
netbsd depends on $S/kern/kern_ksyms_buf.c; rarely updated but better safe.


To generate a diff of this commit:
cvs rdiff -u -r1.195 -r1.196 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.195 src/sys/conf/Makefile.kern.inc:1.196
--- src/sys/conf/Makefile.kern.inc:1.195	Thu Aug 27 03:20:13 2015
+++ src/sys/conf/Makefile.kern.inc	Thu Aug 27 06:28:09 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.195 2015/08/27 03:20:13 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.196 2015/08/27 06:28:09 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -583,6 +583,9 @@ build_kernel: .USE
 	${SYSTEM_LD} ${.TARGET} swap${.TARGET}.o
 	${SYSTEM_LD_TAIL_STAGE2}
 .else
+.for k in ${KERNELS}
+${k}: $S/kern/kern_ksyms_buf.c
+.endfor
 build_kernel: .USE
 	${CC} ${CFLAGS} ${CPPFLAGS} -DCOPY_SYMTAB \
 	-c $S/kern/kern_ksyms_buf.c -o kern_ksyms_buf.o



CVS commit: src/sys/conf

2015-08-25 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Aug 26 02:54:09 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Don't allow MD to override the assym.h generation rule.

(Nothing defines it except i386/bioscall/Makefile, but it is not part of
kernel build.)


To generate a diff of this commit:
cvs rdiff -u -r1.191 -r1.192 src/sys/conf/Makefile.kern.inc

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



CVS commit: src/sys/conf

2015-08-25 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Wed Aug 26 02:54:09 UTC 2015

Modified Files:
src/sys/conf: Makefile.kern.inc

Log Message:
Don't allow MD to override the assym.h generation rule.

(Nothing defines it except i386/bioscall/Makefile, but it is not part of
kernel build.)


To generate a diff of this commit:
cvs rdiff -u -r1.191 -r1.192 src/sys/conf/Makefile.kern.inc

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

Modified files:

Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.191 src/sys/conf/Makefile.kern.inc:1.192
--- src/sys/conf/Makefile.kern.inc:1.191	Tue Aug 25 08:01:18 2015
+++ src/sys/conf/Makefile.kern.inc	Wed Aug 26 02:54:09 2015
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.kern.inc,v 1.191 2015/08/25 08:01:18 uebayasi Exp $
+#	$NetBSD: Makefile.kern.inc,v 1.192 2015/08/26 02:54:09 uebayasi Exp $
 #
 # This file contains common `MI' targets and definitions and it is included
 # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -303,7 +303,6 @@ SYSTEM_LD_TAIL_STAGE2+=	${SYSTEM_LD_TAIL
 ##
 ## (6) port independent targets and dependencies: assym.h, vers.o
 ##
-.if !target(assym.h)
 assym.h: ${GENASSYM_CONF} ${GENASSYM_EXTRAS}
 	${_MKTARGET_CREATE}
 	cat ${GENASSYM_CONF} ${GENASSYM_EXTRAS} | \
@@ -311,7 +310,6 @@ assym.h: ${GENASSYM_CONF} ${GENASSYM_EXT
 	${GENASSYM_CPPFLAGS}  assym.h.tmp  \
 	mv -f assym.h.tmp assym.h
 ${MD_SFILES:C/\.[Ss]/.o/} ${SFILES:C/\.[Ss]/.o/}: assym.h
-.endif
 
 MKREPRO?=no
 



<    1   2   3   4   5   6   7   >