aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDavid M. Syzdek <syzdek@bindlebinaries.com>2019-10-17 20:02:14 -0800
committerDavid M. Syzdek <syzdek@bindlebinaries.com>2019-10-17 20:02:14 -0800
commitc220f68b352eddd32d379d96a8e2c4db764239ec (patch)
treecbb0825bfd30764f0cdefd605a2a128da0ca7631
parent1b3db4abb1dc1eda4205b1414ec361493f9b61a6 (diff)
downloadbindletools-c220f68b352eddd32d379d96a8e2c4db764239ec.tar.gz
bindletools-c220f68b352eddd32d379d96a8e2c4db764239ec.tar.bz2
bindletools-c220f68b352eddd32d379d96a8e2c4db764239ec.tar.xz
bindletools-c220f68b352eddd32d379d96a8e2c4db764239ec.zip
Rolling back GCC source compile test
-rw-r--r--build-aux/bindletest-gccwarnings.c6
-rw-r--r--m4/bindle-gcc.m416
2 files changed, 6 insertions, 16 deletions
diff --git a/build-aux/bindletest-gccwarnings.c b/build-aux/bindletest-gccwarnings.c
deleted file mode 100644
index 4595fd9..0000000
--- a/build-aux/bindletest-gccwarnings.c
+++ /dev/null
@@ -1,6 +0,0 @@
1#include <stdio.h>
2int main(void);
3int main(void)
4{
5 return(0);
6}
diff --git a/m4/bindle-gcc.m4 b/m4/bindle-gcc.m4
index 66e5855..95c7e68 100644
--- a/m4/bindle-gcc.m4
+++ b/m4/bindle-gcc.m4
@@ -143,21 +143,17 @@ AC_DEFUN([AC_BINDLE_ENABLE_WARNINGS],[dnl
143 fi 143 fi
144 144
145 # creates test source code 145 # creates test source code
146 ac_bindle_warnsource=${ac_aux_dir}/bindletest-gccwarnings.c 146 AC_LANG_CONFTEST(
147 if test ! -f ${ac_bindle_warnsource};then 147 [AC_LANG_PROGRAM(
148 AC_LANG_CONFTEST( 148 [[int main(void);]],
149 [AC_LANG_PROGRAM( 149 [[return(0);]]
150 [[int main(void);]], 150 )])
151 [[//return(0);]]
152 )])
153 ac_bindle_warnsource=configtest.c
154 fi
155 151
156 # loops throough options 152 # loops throough options
157 CFLAGS_WARNINGS="" 153 CFLAGS_WARNINGS=""
158 for ac_bindle_warning in ${ac_bindle_warnings_list};do 154 for ac_bindle_warning in ${ac_bindle_warnings_list};do
159 AC_MSG_CHECKING(for gcc flag ${ac_bindle_warning}) 155 AC_MSG_CHECKING(for gcc flag ${ac_bindle_warning})
160 ${ac_bindle_cc} ${CFLAGS_WARNINGS} ${ac_bindle_warning} ${ac_bindle_warnsource} -o conftest.o > /dev/null 2>&1 156 ${ac_bindle_cc} ${CFLAGS_WARNINGS} ${ac_bindle_warning} conftest.c -o conftest.o > /dev/null 2>&1
161 if test "x$?" == "x0";then 157 if test "x$?" == "x0";then
162 CFLAGS_WARNINGS="${CFLAGS_WARNINGS} ${ac_bindle_warning}" 158 CFLAGS_WARNINGS="${CFLAGS_WARNINGS} ${ac_bindle_warning}"
163 AC_MSG_RESULT(yes) 159 AC_MSG_RESULT(yes)