chiark / gitweb /
Makefiles: Break some settings out into common.make
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 12 Oct 2019 20:46:45 +0000 (21:46 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 12 Oct 2019 22:29:26 +0000 (23:29 +0100)
No functional change.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
.gitignore
Makefile.in
common.make.in [new file with mode: 0644]
configure
configure.in

index acfaeb78eaafef8b4d3ec6fa22799db163e4d6f5..3fbf47f0a378c4b11c99dca32d5030ed0277f943 100644 (file)
@@ -14,6 +14,7 @@ conffile.yy.[ch]
 /config.status
 /stamp-h
 /Makefile
+/common.make
 
 msgcode-test
 msgcode-test.confirm
index 6bc02efe3f7eda8b6ddf87443f15512e79e1ee35..d2ca9b31133d6bd376b04ed2335cdfa93a690d30 100644 (file)
 PACKAGE:=secnet
 VERSION=0.4.5
 
-@SET_MAKE@
-
-srcdir:=@srcdir@
 VPATH:=@srcdir@
 
-SHELL:=/bin/sh
-RM:=@RM@
-CC:=@CC@
+include common.make
+
 INSTALL:=@INSTALL@
 INSTALL_PROGRAM:=@INSTALL_PROGRAM@
 INSTALL_SCRIPT:=@INSTALL_SCRIPT@
@@ -43,14 +39,6 @@ datarootdir:=@datarootdir@
 transform:=@program_transform_name@
 mandir:=@mandir@
 
-CFLAGS:=-Wall @WRITESTRINGS@ @CFLAGS@ -Werror \
-       -W -Wno-unused -Wno-unused-parameter \
-       -Wno-pointer-sign -Wstrict-prototypes -Wmissing-prototypes \
-       -Wmissing-declarations -Wnested-externs -Wredundant-decls \
-       -Wpointer-arith -Wformat=2 -Winit-self \
-       -Wswitch-enum -Wunused-variable -Wunused-function -Wbad-function-cast \
-       -Wno-strict-aliasing -fno-strict-aliasing \
-       -MMD
 ALL_CFLAGS:=@DEFS@ -I$(srcdir) -I. $(CFLAGS) $(EXTRA_CFLAGS)
 CPPFLAGS:=@CPPFLAGS@ -DDATAROOTDIR='"$(datarootdir)"' $(EXTRA_CPPFLAGS)
 LDFLAGS:=@LDFLAGS@ $(EXTRA_LDFLAGS)
diff --git a/common.make.in b/common.make.in
new file mode 100644 (file)
index 0000000..7b22334
--- /dev/null
@@ -0,0 +1,35 @@
+# common makefile settings for secnet
+#
+# This file is part of secnet.
+# See README for full list of copyright holders.
+#
+# secnet is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+# 
+# secnet is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# General Public License for more details.
+# 
+# You should have received a copy of the GNU General Public License
+# version 3 along with secnet; if not, see
+# https://www.gnu.org/licenses/gpl.html.
+
+@SET_MAKE@
+
+srcdir:=@srcdir@
+
+SHELL:=/bin/sh
+RM:=@RM@
+CC:=@CC@
+
+CFLAGS:=-Wall @WRITESTRINGS@ @CFLAGS@ -Werror \
+       -W -Wno-unused -Wno-unused-parameter \
+       -Wno-pointer-sign -Wstrict-prototypes -Wmissing-prototypes \
+       -Wmissing-declarations -Wnested-externs -Wredundant-decls \
+       -Wpointer-arith -Wformat=2 -Winit-self \
+       -Wswitch-enum -Wunused-variable -Wunused-function -Wbad-function-cast \
+       -Wno-strict-aliasing -fno-strict-aliasing \
+       -MMD
index 698cc7a2833c2258cb6a61c6152cfe11e9d85b94..dbfe51d99130d7765c1cfb00fefacd0068c6e51d 100755 (executable)
--- a/configure
+++ b/configure
@@ -4735,7 +4735,7 @@ else
 $as_echo "$as_me: WARNING: Disabling IPv6 support" >&2;}
 fi
 
-ac_config_files="$ac_config_files Makefile"
+ac_config_files="$ac_config_files Makefile common.make"
 
 ac_config_commands="$ac_config_commands default"
 
@@ -5436,6 +5436,7 @@ do
   case $ac_config_target in
     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
+    "common.make") CONFIG_FILES="$CONFIG_FILES common.make" ;;
     "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
 
   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
index ca814072a44e1d34b94cc851a24dd405986e9734..223997691a6322e33a4f716515311054390d67e3 100644 (file)
@@ -96,7 +96,7 @@ else
     AC_MSG_WARN([Disabling IPv6 support])
 fi
 
-AC_OUTPUT(Makefile,echo timestamp >stamp-h)
+AC_OUTPUT(Makefile common.make, echo timestamp >stamp-h)
 
 AH_TOP([
 #ifndef _CONFIG_H