changeset 15101:8523df595d42

maint: Add DO NOT EDIT messages to build system for src/*.in.h. * build-aux/common.mk (do_subst_config_val, do_subst_default_val): Add new sed expansion rule for NO_EDIT_WARNING. * Makefile.am (version.h rule): Add new sed expansion rule for NO_EDIT_WARNING. * interp-core/module.mk (mxarray.h): Add new sed expansion rule for NO_EDIT_WARNING. * mxarray.in.h, defaults.in.h, oct-conf.in.h, version.in.h: Add %NO_EDIT_WARNING% to top-of-file for expansion by build system.
author Rik <rik@octave.org>
date Fri, 03 Aug 2012 16:45:17 -0700
parents d7f8b0b91cb2
children 2512448babac
files build-aux/common.mk src/Makefile.am src/interp-core/module.mk src/interp-core/mxarray.in.h src/interpfcn/defaults.in.h src/oct-conf.in.h src/version.in.h
diffstat 7 files changed, 8 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/build-aux/common.mk
+++ b/build-aux/common.mk
@@ -454,6 +454,7 @@
 define do_subst_config_vals
 echo "making $@ from $<"
 $(SED) < $< \
+  -e "s|%NO_EDIT_WARNING%|DO NOT EDIT!  Generated automatically from $(<F) by Make.|" \
   -e "s|%NO_OCT_FILE_STRIP%|${NO_OCT_FILE_STRIP}|" \
   -e "s|%OCTAVE_BINDIR%|\"${bindir}\"|" \
   -e "s|%OCTAVE_CONF_ALL_CFLAGS%|\"${ALL_CFLAGS}\"|" \
@@ -606,6 +607,7 @@
 define do_subst_default_vals
 echo "making $@ from $<"
 $(SED) < $< > $@-t \
+  -e "s|%NO_EDIT_WARNING%|DO NOT EDIT!  Generated automatically from $(<F) by Make.|" \
   -e "s|%OCTAVE_ARCHLIBDIR%|\"${archlibdir}\"|" \
   -e "s|%OCTAVE_BINDIR%|\"${bindir}\"|" \
   -e "s|%OCTAVE_CANONICAL_HOST_TYPE%|\"${canonical_host_type}\"|" \
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -264,6 +264,7 @@
 
 version.h: version.in.h Makefile
 	$(SED) < $< \
+	  -e "s|%NO_EDIT_WARNING%|DO NOT EDIT!  Generated automatically from $(<F) by Make.|" \
 	  -e "s|%OCTAVE_API_VERSION_NUMBER%|${OCTAVE_API_VERSION_NUMBER}|" \
 	  -e "s|%OCTAVE_API_VERSION%|\"${OCTAVE_API_VERSION}\"|" \
 	  -e "s|%OCTAVE_COPYRIGHT%|\"${OCTAVE_COPYRIGHT}\"|" \
--- a/src/interp-core/module.mk
+++ b/src/interp-core/module.mk
@@ -125,6 +125,7 @@
 
 interp-core/mxarray.h: interp-core/mxarray.in.h Makefile
 	$(SED) < $< \
+	  -e "s|%NO_EDIT_WARNING%|DO NOT EDIT!  Generated automatically from $(<F) by Make.|" \
 	  -e "s|%OCTAVE_IDX_TYPE%|${OCTAVE_IDX_TYPE}|" > $@-t
 	mv $@-t $@
 
--- a/src/interp-core/mxarray.in.h
+++ b/src/interp-core/mxarray.in.h
@@ -1,4 +1,4 @@
-// DO NOT EDIT!  Generated automatically from mxarray.in.h by configure
+// %NO_EDIT_WARNING%
 /*
 
 Copyright (C) 2001-2012 Paul Kienzle
--- a/src/interpfcn/defaults.in.h
+++ b/src/interpfcn/defaults.in.h
@@ -1,4 +1,4 @@
-// DO NOT EDIT!  Generated automatically from defaults.in.h by configure
+// %NO_EDIT_WARNING%
 /*
 
 Copyright (C) 1993-2012 John W. Eaton
--- a/src/oct-conf.in.h
+++ b/src/oct-conf.in.h
@@ -1,4 +1,4 @@
-// DO NOT EDIT!  Generated automatically from oct-conf.in.h by configure
+// %NO_EDIT_WARNING%
 /*
 
 Copyright (C) 1996-2012 John W. Eaton
--- a/src/version.in.h
+++ b/src/version.in.h
@@ -1,4 +1,4 @@
-// DO NOT EDIT!  Generated automatically from version.in.h by configure
+// %NO_EDIT_WARNING%
 /*
 
 Copyright (C) 1992-2012 John W. Eaton