summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorDarren Salt <linux@youmustbejoking.demon.co.uk>2005-05-14 23:17:10 +0000
committerDarren Salt <linux@youmustbejoking.demon.co.uk>2005-05-14 23:17:10 +0000
commit2429be34b4fb386ab17935c0edab3cfc217c6c1f (patch)
tree69f509d6d4b244a73cd0e2ebb2e8ca255a414dd1 /m4
parent4c7a0ab13f7e1522127b0f46752d08b0252d86f7 (diff)
downloadxine-lib-2429be34b4fb386ab17935c0edab3cfc217c6c1f.tar.gz
xine-lib-2429be34b4fb386ab17935c0edab3cfc217c6c1f.tar.bz2
Define __inline__ if necessary.
(This assumes that if the compiler isn't gcc, __inline__ isn't supported.) CVS patchset: 7540 CVS date: 2005/05/14 23:17:10
Diffstat (limited to 'm4')
-rw-r--r--m4/_xine.m422
1 files changed, 21 insertions, 1 deletions
diff --git a/m4/_xine.m4 b/m4/_xine.m4
index 5fae550d8..f59d0baae 100644
--- a/m4/_xine.m4
+++ b/m4/_xine.m4
@@ -2,6 +2,7 @@ dnl AC_C_ALWAYS_INLINE
dnl Define inline to something appropriate, including the new always_inline
dnl attribute from gcc 3.1
dnl Thanks to Michel LESPINASSE <walken@zoy.org>
+dnl __inline__ "check" added by Darren Salt
AC_DEFUN([AC_C_ALWAYS_INLINE],
[AC_C_INLINE
if test x"$GCC" = x"yes" -a x"$ac_cv_c_inline" = x"inline"; then
@@ -22,7 +23,26 @@ AC_DEFUN([AC_C_ALWAYS_INLINE],
])
AC_DEFINE_UNQUOTED([inline],[inline __attribute__ ((__always_inline__))])
fi
- fi])
+ ac_cv_c___inline__=''
+ else
+ # FIXME: test the compiler to see if it supports __inline__
+ # instead of assuming that if it isn't gcc, it doesn't
+ case "$ac_cv_c_inline" in
+ yes)
+ ac_cv_c___inline__=inline
+ ;;
+ inline|__inline__)
+ ac_cv_c___inline__=''
+ ;;
+ *)
+ ac_cv_c___inline__="$ac_cv_c_inline"
+ ;;
+ esac
+ fi
+ if test x"$ac_cv_c___inline__" != x; then
+ AC_DEFINE_UNQUOTED([__inline__],[$ac_cv_c___inline__],[Define if the compiler doesn't recognise __inline__])
+ fi
+])
dnl
dnl Check for minimum version of libtool