summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar aeb 2001-05-14 00:57:05 +0000
committerGravatar aeb 2001-05-14 00:57:05 +0000
commitfdc1945dabaca07a9f2d5cf97d845f6fb3be58da (patch)
treef058654562b869d7ce8320c821fc66c1e2dd8a69
parentFix Makefile.am to include libraw1394.m4 in distribution. (diff)
Fix macros so that they actually work.
git-svn-id: svn://svn.linux1394.org/libraw1394/trunk@59 53a565d1-3bb7-0310-b661-cf11e63c67ab
Diffstat (limited to '')
-rw-r--r--libraw1394.m430
1 files changed, 18 insertions, 12 deletions
diff --git a/libraw1394.m4 b/libraw1394.m4
index dbdefc0..333aee9 100644
--- a/libraw1394.m4
+++ b/libraw1394.m4
@@ -17,7 +17,7 @@ dnl
dnl AC_LIB_RAW1394_HEADERS([ACTION_IF_FOUND[,ACTION_IF_NOT_FOUND]])
dnl
AC_DEFUN(AC_LIB_RAW1394_HEADERS, [
-AC_REQUIRE(AC_LIB_RAW1394_FLAGS)
+AC_REQUIRE([AC_LIB_RAW1394_FLAGS])
ac_libraw1394_save_cppflags=$CPPFLAGS
CPPFLAGS="$LIBRAW1394_CPPFLAGS $CPPFLAGS"
@@ -27,7 +27,11 @@ AC_CHECK_HEADER(libraw1394/raw1394.h, ac_libraw1394_headers=yes)
CPPFLAGS=$ac_libraw1394_save_cppflags
-if test $ac_libraw1394_headers = yes ; then $1; else $2; fi
+if test $ac_libraw1394_headers = yes ; then
+ ifelse([$1], , :, $1)
+else
+ ifelse([$2], , :, $2)
+fi
])
@@ -35,7 +39,8 @@ dnl
dnl AC_LIB_RAW1394_LIBVERSION(MINIMUMVERSION[,ACTION_IF_FOUND[,ACTION_IF_NOT_FOUND]])
dnl
AC_DEFUN(AC_LIB_RAW1394_LIBVERSION, [
-AC_REQUIRE(AC_LIB_RAW1394_HEADERS)
+AC_REQUIRE([AC_PROG_CC])
+AC_REQUIRE([AC_LIB_RAW1394_FLAGS])
ac_libraw1394_save_cppflags=$CPPFLAGS
ac_libraw1394_save_cflags=$CFLAGS
@@ -45,7 +50,7 @@ CFLAGS="$LIBRAW1394_CFLAGS $CFLAGS"
LIBS="$LIBRAW1394_LIBS $LIBS"
ac_libraw1394_versiontest_success=no
-ac_libraw1394_ver_symbol=`echo __libraw1394_version_$0 | sed 's/\./_/g'`
+ac_libraw1394_ver_symbol=`echo __libraw1394_version_$1 | sed 's/\./_/g'`
AC_TRY_LINK([], [{
extern char $ac_libraw1394_ver_symbol;
@@ -56,7 +61,11 @@ CPPFLAGS=$ac_libraw1394_save_cppflags
CFLAGS=$ac_libraw1394_save_cflags
LIBS=$ac_libraw1394_save_libs
-if test $ac_libraw1394_versiontest_success = yes; then $1; else $2; fi
+if test $ac_libraw1394_versiontest_success = yes; then
+ ifelse([$2], , :, $2)
+else
+ ifelse([$3], , :, $3)
+fi
])
@@ -64,8 +73,6 @@ dnl
dnl AC_LIB_RAW1394_RUNTEST(MINIMUMVERSION[,ACTION_IF_FOUND
dnl [,ACTION_IF_NOT_FOUND[,ACTION_IF_CROSS_COMPILING]]])
AC_DEFUN(AC_LIB_RAW1394_RUNTEST, [
-AC_REQUIRE(AC_LIB_RAW1394_HEADERS)
-
ac_libraw1394_save_cppflags=$CPPFLAGS
ac_libraw1394_save_cflags=$CFLAGS
ac_libraw1394_save_libs=$LIBS
@@ -73,7 +80,6 @@ CPPFLAGS="$LIBRAW1394_CPPFLAGS $CPPFLAGS"
CFLAGS="$LIBRAW1394_CFLAGS $CFLAGS"
LIBS="$LIBRAW1394_LIBS $LIBS"
-
dnl This program compares two version strings and returns with code 0 if
dnl req_ver <= lib_ver, returns 1 otherwise.
dnl
@@ -113,12 +119,12 @@ CFLAGS=$ac_libraw1394_save_cflags
LIBS=$ac_libraw1394_save_libs
if test $ac_libraw1394_run = yes; then
- $2
+ ifelse([$2], , :, $2)
elif test $ac_libraw1394_run = no; then
- $3
+ ifelse([$3], , :, $3)
else
ifelse([$4], ,
- AC_MSG_ERROR([$0 called without directions for cross compiling]),
+ AC_MSG_ERROR([no default for cross compiling in libraw1394 runtest macro]),
[$4])
fi
])
@@ -132,7 +138,7 @@ dnl
AC_DEFUN(AC_LIB_RAW1394, [
AC_LIB_RAW1394_FLAGS
-AC_LIB_RAW1394_HEADERS(ac_libraw1394_found=yes, ac_libraw1394_found=no
+AC_LIB_RAW1394_HEADERS(ac_libraw1394_found=yes, ac_libraw1394_found=no)
if test $ac_libraw1394_found = yes ; then
a0ec6234582c8baf97&follow=1'>Ooops...libtool works a bit different than I thought, but atleast it worksGravatar bencollins 2-6/+1 2003-07-13Generate and install the pdf in the Debian package.Gravatar bencollins 3-3/+4 2003-07-13Don't run configure at the end of autogen.sh. Also, remove autom4te.cache.Gravatar bencollins 1-1/+1 2003-07-13Update Debian maintainerGravatar bencollins 1-1/+2 2003-07-13Update Debian changelog.Gravatar bencollins 1-0/+8 2003-07-13File doesn't really seem needed. The NEWS file gives a good overview, andGravatar bencollins 1-4/+0 2003-07-13Fix compiler warnings.Gravatar bencollins 4-12/+22 2003-07-13Updates from 0.10.0 release.Gravatar bencollins 4-5/+14 2003-04-23add libtoolize to bootstrapGravatar ddennedy 1-1/+10 2003-04-21added Dan Maas' rawiso docsGravatar ddennedy 1-32/+295 2003-04-07new_handle_on_port() error path fix from Jim RadfordGravatar dmaas 1-1/+3 2003-03-26add raw1394_new_handle_on_port() convenience functionGravatar dmaas 2-1/+41 2003-02-22Updates for new rawiso ioctl interface.Gravatar bencollins 3-37/+125 2003-01-15add iso_xmit_sync() and iso_xmit_write(); clean up iso handling a bitGravatar dmaas 5-39/+161 2003-01-15implement tag matching for rawiso receptionGravatar dmaas 3-4/+12 2003-01-06back out previous commit - don't drop the legacy API just yetGravatar dmaas 6-173/+130 2003-01-05emulate legacy ISO reception API on top of new rawiso APIGravatar dmaas 7-131/+174 2002-12-24update iso API for multi-channel reception and new packet buffer layoutGravatar dmaas 4-123/+236 2002-12-20oops, irq_interval needs to be signedGravatar anonymous 1-1/+1 2002-12-20dmaas - renamed exported arm definitions into the raw1394_ namespace; brought...Gravatar anonymous 3-124/+48 2002-12-16rawiso updates:Gravatar dmaas 3-18/+25 2002-11-18fix cplusplus extern C blockGravatar ddennedy 1-4/+4 2002-11-18merged rawiso branchGravatar ddennedy 7-6/+488