From dec49e4d5e77bc418511656ebba9b0b833804a39 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Sat, 13 Oct 2018 21:09:42 +0900 Subject: [PATCH] Replaced _BSD_SOURCE, _SVID_SOURCE with _DEFAULT_SOURCE. Removed AC_CHECK_GNU_EXTENSIONS. Signed-off-by: Michele Calgaro --- acinclude.m4 | 32 ++------------------------ doc/Makefile | 4 ++-- doc/kmyfirewall/Makefile | 4 ++-- kmyfirewall/installer/openbsd/Makefile | 4 ++-- 4 files changed, 8 insertions(+), 36 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index ce592e6..4c1a20a 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2872,34 +2872,6 @@ AC_DEFUN([AC_CHECK_BOOL], AC_DEFINE_UNQUOTED(HAVE_BOOL, 1, [You _must_ have bool]) ]) -AC_DEFUN([AC_CHECK_GNU_EXTENSIONS], -[ -AC_MSG_CHECKING(if you need GNU extensions) -AC_CACHE_VAL(ac_cv_gnu_extensions, -[ -cat > conftest.c << EOF -#include - -#ifdef __GNU_LIBRARY__ -yes -#endif -EOF - -if (eval "$ac_cpp conftest.c") 2>&5 | - egrep "yes" >/dev/null 2>&1; then - rm -rf conftest* - ac_cv_gnu_extensions=yes -else - ac_cv_gnu_extensions=no -fi -]) - -AC_MSG_RESULT($ac_cv_gnu_extensions) -if test "$ac_cv_gnu_extensions" = "yes"; then - AC_DEFINE_UNQUOTED(_GNU_SOURCE, 1, [Define if you need to use the GNU extensions]) -fi -]) - AC_DEFUN([KDE_CHECK_COMPILER_FLAG], [ AC_MSG_CHECKING([whether $CXX supports -$1]) @@ -3197,8 +3169,8 @@ AC_DEFUN([AC_CHECK_COMPILERS], CXXFLAGS="-Wall -W -Wpointer-arith $CXXFLAGS" case $host in *-*-linux-gnu) - CFLAGS="-std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_BSD_SOURCE $CFLAGS" - CXXFLAGS="-ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts $CXXFLAGS" + CFLAGS="-std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE $CFLAGS" + CXXFLAGS="-ansi -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -Wcast-align -Wchar-subscripts $CXXFLAGS" KDE_CHECK_COMPILER_FLAG(Wmissing-format-attribute, [CXXFLAGS="$CXXFLAGS -Wformat-security -Wmissing-format-attribute"]) KDE_CHECK_C_COMPILER_FLAG(Wmissing-format-attribute, [CFLAGS="$CFLAGS -Wformat-security -Wmissing-format-attribute"]) ;; diff --git a/doc/Makefile b/doc/Makefile index 9c57b71..3a87b6f 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -81,14 +81,14 @@ AUTOMAKE = ${SHELL} /home/animal/devel/KDE-SVN/kmyfirewall-1.1.0/admin/missing - AWK = mawk CC = gcc CCDEPMODE = depmode=gcc3 -CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -g3 -fno-inline -Wformat-security -Wmissing-format-attribute +CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -g3 -fno-inline -Wformat-security -Wmissing-format-attribute CONF_FILES = $(top_srcdir)/./admin/configure.in.min $(top_srcdir)/configure.in.in CPP = gcc -E CPPFLAGS = -DTQT_THREAD_SUPPORT -D_REENTRANT CXX = g++ CXXCPP = g++ -E CXXDEPMODE = depmode=gcc3 -CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -fno-builtin -g3 -fno-inline -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common +CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -fno-builtin -g3 -fno-inline -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common CYGPATH_W = echo DCOPIDL = ${prefix}/bin/dcopidl DCOPIDL2CPP = ${prefix}/bin/dcopidl2cpp diff --git a/doc/kmyfirewall/Makefile b/doc/kmyfirewall/Makefile index d89d08d..27d0a35 100644 --- a/doc/kmyfirewall/Makefile +++ b/doc/kmyfirewall/Makefile @@ -65,14 +65,14 @@ AUTOMAKE = ${SHELL} /home/animal/devel/KDE-SVN/kmyfirewall-1.1.0/admin/missing - AWK = mawk CC = gcc CCDEPMODE = depmode=gcc3 -CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -g3 -fno-inline -Wformat-security -Wmissing-format-attribute +CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -g3 -fno-inline -Wformat-security -Wmissing-format-attribute CONF_FILES = $(top_srcdir)/./admin/configure.in.min $(top_srcdir)/configure.in.in CPP = gcc -E CPPFLAGS = -DTQT_THREAD_SUPPORT -D_REENTRANT CXX = g++ CXXCPP = g++ -E CXXDEPMODE = depmode=gcc3 -CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -fno-builtin -g3 -fno-inline -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common +CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -fno-builtin -g3 -fno-inline -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common CYGPATH_W = echo DCOPIDL = ${prefix}/bin/dcopidl DCOPIDL2CPP = ${prefix}/bin/dcopidl2cpp diff --git a/kmyfirewall/installer/openbsd/Makefile b/kmyfirewall/installer/openbsd/Makefile index cf9a8c5..872da05 100644 --- a/kmyfirewall/installer/openbsd/Makefile +++ b/kmyfirewall/installer/openbsd/Makefile @@ -119,14 +119,14 @@ AUTOMAKE = ${SHELL} /home/agi/debian/kmyfirewall/kmyfirewall-1.1.1/admin/missing AWK = gawk CC = i486-linux-gnu-gcc CCDEPMODE = depmode=gcc3 -CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -DNDEBUG -O2 -Wall -g -O2 -Wformat-security -Wmissing-format-attribute +CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -DNDEBUG -O2 -Wall -g -O2 -Wformat-security -Wmissing-format-attribute CONF_FILES = $(top_srcdir)/./admin/configure.in.min $(top_srcdir)/configure.in.in CPP = i486-linux-gnu-gcc -E CPPFLAGS = -DTQT_THREAD_SUPPORT -D_REENTRANT CXX = i486-linux-gnu-g++ CXXCPP = i486-linux-gnu-g++ -E CXXDEPMODE = depmode=gcc3 -CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -DNDEBUG -DNO_DEBUG -O2 -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common +CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -DNDEBUG -DNO_DEBUG -O2 -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common CYGPATH_W = echo DCOPIDL = ${prefix}/bin/dcopidl DCOPIDL2CPP = ${prefix}/bin/dcopidl2cpp