summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetri Hintukainen <phintuka@users.sourceforge.net>2011-09-12 13:53:41 +0300
committerPetri Hintukainen <phintuka@users.sourceforge.net>2011-09-12 13:53:41 +0300
commit11b8b9c11c4c5a662482bd7e7e9ac08f02d9ced5 (patch)
tree7fd9038dce7762595403e74c36e417bb1574f707
parent5c65559286bd49e9d329b08737ace4626be2a275 (diff)
downloadxine-lib-11b8b9c11c4c5a662482bd7e7e9ac08f02d9ced5.tar.gz
xine-lib-11b8b9c11c4c5a662482bd7e7e9ac08f02d9ced5.tar.bz2
Use AC_LANG_SOURCE
-rw-r--r--configure.ac16
-rw-r--r--m4/attributes.m410
-rw-r--r--m4/directx.m44
-rw-r--r--m4/dl.m44
4 files changed, 17 insertions, 17 deletions
diff --git a/configure.ac b/configure.ac
index 8367a68af..35bdd954b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1859,7 +1859,7 @@ if test "x$enable_vcd" = "xyes"; then
AC_MSG_CHECKING([bitfield ordering in structs])
dnl basic compile test for all platforms
- AC_COMPILE_IFELSE([
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([
int main() {
struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; }
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
@@ -1869,11 +1869,11 @@ int main() {
switch (0) case 0: case sizeof(bf) == 1:;
return 0;
}
-], [], AC_MSG_ERROR([compiler doesn't support bitfield structs]))
+])], [], AC_MSG_ERROR([compiler doesn't support bitfield structs]))
dnl run test
- AC_RUN_IFELSE([
+ AC_RUN_IFELSE([AC_LANG_SOURCE([
int main() {
struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; }
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
@@ -1882,8 +1882,8 @@ int main() {
bf = { 1,1,1,1 };
if (sizeof (bf) != 1) return 1;
return *((unsigned char*) &bf) != 0x4b; }
-], bf_lsbf=1, [
- AC_RUN_IFELSE([
+])], bf_lsbf=1, [
+ AC_RUN_IFELSE([AC_LANG_SOURCE([
int main() {
struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; }
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
@@ -1892,7 +1892,7 @@ int main() {
bf = { 1,1,1,1 };
if (sizeof (bf) != 1) return 1;
return *((unsigned char*) &bf) != 0xa5; }
-], bf_lsbf=0, AC_MSG_ERROR([unsupported bitfield ordering]))
+])], bf_lsbf=0, AC_MSG_ERROR([unsupported bitfield ordering]))
],
[case "$host" in
*-*-mingw32* | *-*-cygwin*)
@@ -2248,10 +2248,10 @@ AC_CHECK_HEADERS(assert.h byteswap.h malloc.h execinfo.h ucontext.h sys/mman.h s
AC_REPLACE_FUNCS(asprintf basename gettimeofday setenv strcasestr strndup strpbrk strsep strtok_r timegm unsetenv memmem)
AC_LIBSOURCE(hstrerror.c)
-AC_LINK_IFELSE([#include <netdb.h>
+AC_LINK_IFELSE([AC_LANG_SOURCE([#include <netdb.h>
int main(void) {
hstrerror(0);
-}], ac_cv_function_system_hstrerror="yes")
+}])], ac_cv_function_system_hstrerror="yes")
AC_CHECK_LIB([resolv], [hstrerror], [
ac_cv_function_system_hstrerror="yes"
NET_LIBS="-lresolv $NET_LIBS"
diff --git a/m4/attributes.m4 b/m4/attributes.m4
index 4f0442865..3d9c256a0 100644
--- a/m4/attributes.m4
+++ b/m4/attributes.m4
@@ -39,7 +39,7 @@ AC_DEFUN([CC_CHECK_CFLAGS_SILENT], [
AC_CACHE_VAL(AS_TR_SH([cc_cv_cflags_$1]),
[ac_save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $1"
- AC_COMPILE_IFELSE([int a;],
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([int a;])],
[eval "AS_TR_SH([cc_cv_cflags_$1])='yes'"],
[eval "AS_TR_SH([cc_cv_cflags_$1])='no'"])
CFLAGS="$ac_save_CFLAGS"
@@ -89,7 +89,7 @@ AC_DEFUN([CC_CHECK_LDFLAGS], [
AS_TR_SH([cc_cv_ldflags_$1]),
[ac_save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS $1"
- AC_LINK_IFELSE([int main() { return 1; }],
+ AC_LINK_IFELSE([AC_LANG_SOURCE([int main() { return 1; }])],
[eval "AS_TR_SH([cc_cv_ldflags_$1])='yes'"],
[eval "AS_TR_SH([cc_cv_ldflags_$1])="])
LDFLAGS="$ac_save_LDFLAGS"
@@ -154,7 +154,7 @@ AC_DEFUN([CC_CHECK_ATTRIBUTE], [
AS_TR_SH([cc_cv_attribute_$1]),
[ac_save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $cc_cv_werror"
- AC_COMPILE_IFELSE([$3],
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([$3])],
[eval "AS_TR_SH([cc_cv_attribute_$1])='yes'"],
[eval "AS_TR_SH([cc_cv_attribute_$1])='no'"])
CFLAGS="$ac_save_CFLAGS"
@@ -302,11 +302,11 @@ AC_DEFUN([CC_ATTRIBUTE_ALIGNED], [
[ac_save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $cc_cv_werror"
for cc_attribute_align_try in 64 32 16 8 4 2; do
- AC_COMPILE_IFELSE([
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([
int main() {
static char c __attribute__ ((aligned($cc_attribute_align_try))) = 0;
return c;
- }], [cc_cv_attribute_aligned=$cc_attribute_align_try; break])
+ }])], [cc_cv_attribute_aligned=$cc_attribute_align_try; break])
done
CFLAGS="$ac_save_CFLAGS"
])
diff --git a/m4/directx.m4 b/m4/directx.m4
index 743403c72..d64c13fc4 100644
--- a/m4/directx.m4
+++ b/m4/directx.m4
@@ -28,7 +28,7 @@ ac_save_CPPFLAGS="$CPPFLAGS"
ac_save_LIBS="$LIBS"
CPPFLAGS="$CPPFLAGS $DIRECTX_CPPFLAGS"
LIBS="$LIBS $DIRECTX_VIDEO_LIBS $DIRECTX_AUDIO_LIBS"
-AC_COMPILE_IFELSE(
+AC_COMPILE_IFELSE([AC_LANG_SOURCE(
[
#include <stddef.h>
@@ -42,7 +42,7 @@ int main() {
return 0;
}
- ],
+ ])],
[have_directx=yes
AC_DEFINE(HAVE_DIRECTX,1,[Define this if you have DirectX])],,)
CPPFLAGS=$ac_save_CPPFLAGS
diff --git a/m4/dl.m4 b/m4/dl.m4
index 0b6b72311..87d16c17f 100644
--- a/m4/dl.m4
+++ b/m4/dl.m4
@@ -23,7 +23,7 @@ AC_DEFUN([AM_DL], [
ac_save_LIBS="$LIBS"
CPPFLAGS="-I${srcdir}/win32/include $CPPFLAGS"
LIBS="$LIBS -lkernel32"
- AC_COMPILE_IFELSE([
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([
#include <stddef.h>
#include <dlfcn.h>
@@ -31,7 +31,7 @@ int main() {
dlopen(NULL, 0);
return 0;
}
-],
+])],
[DYNAMIC_LD_LIBS=-lkernel32
have_dl=yes
AC_MSG_RESULT(yes)],