File: acinclude.m4

package info (click to toggle)
chmlib 2:0.40a-5
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 1,480 kB
  • sloc: sh: 10,113; ansic: 2,625; makefile: 85
file content (14 lines) | stat: -rw-r--r-- 385 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
dnl PR_CHECK_CC_OPT
dnl ---------------------
dnl Check whether the C compiler accepts the given option
AC_DEFUN([PR_CHECK_CC_OPT]
  [AC_MSG_CHECKING([whether ${CC-cc} accepts -[$1]])
   echo 'void f(){}' > conftest.c
   if test -z "`${CC-cc} -c -$1 conftest.c 2>&1`"; then
     AC_MSG_RESULT(yes)
     CFLAGS="$CFLAGS -$1"
   else
     AC_MSG_RESULT(no)
   fi
   rm -f conftest*
  ])