]> git.sur5r.net Git - bacula/bacula/commitdiff
ebl Add detection of intptr_t and uintptr_t to configure process
authorEric Bollengier <eric@eb.homelinux.org>
Wed, 21 Jan 2009 13:12:21 +0000 (13:12 +0000)
committerEric Bollengier <eric@eb.homelinux.org>
Wed, 21 Jan 2009 13:12:21 +0000 (13:12 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@8391 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/autoconf/config.h.in
bacula/autoconf/configure.in
bacula/configure
bacula/technotes-2.5

index a78a5e39d33540e78271f26718c163446339c147..1b549320caf179377ececf1962b9e776607afd27 100644 (file)
 /* Define to `int' if <sys/types.h> doesn't define.  */
 #undef ssize_t
 
+/* Typedef to intxx if <stdint.h> doesn't declare. */
+#undef HAVE_INTPTR_T
+
+/* Typedef to uintxx if <stdint.h> doesn't declare. */
+#undef HAVE_UINTPTR_T
+
 /* Define if you want to use PostgreSQL */
 #undef HAVE_POSTGRESQL
 
index ed39ba53135a32ce3ecdbcff6f277fc576c6b07b..14857a46a4468b316cfbf602fbb86e7ce0199e55 100644 (file)
@@ -1862,6 +1862,7 @@ AC_TYPE_SIZE_T
 AC_TYPE_PID_T
 AC_TYPE_OFF_T
 AC_TYPE_INTPTR_T
+AC_TYPE_UINTPTR_T
 AC_CHECK_TYPE(ino_t, unsigned long)
 AC_CHECK_TYPE(dev_t, unsigned long)
 AC_CHECK_TYPE(daddr_t, long)
index df62b8dd46fe6c853fabe8c37eb0d3123a4a7731..135fccb22c4dc666b25a02e30186e372d766addd 100755 (executable)
@@ -33586,6 +33586,122 @@ else
 sed 's/^/| /' conftest.$ac_ext >&5
 
 
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+       test -z "$ac_type" && break
+     done
+fi
+
+
+
+  { echo "$as_me:$LINENO: checking for uintptr_t" >&5
+echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6; }
+if test "${ac_cv_type_uintptr_t+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+typedef uintptr_t ac__type_new_;
+int
+main ()
+{
+if ((ac__type_new_ *) 0)
+  return 0;
+if (sizeof (ac__type_new_))
+  return 0;
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_compile") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+  ac_cv_type_uintptr_t=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_cv_type_uintptr_t=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
+echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6; }
+if test $ac_cv_type_uintptr_t = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_UINTPTR_T 1
+_ACEOF
+
+else
+  for ac_type in 'unsigned int' 'unsigned long int' \
+       'unsigned long long int'; do
+       cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+int
+main ()
+{
+static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
+test_array [0] = 0
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_compile") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+
+cat >>confdefs.h <<_ACEOF
+#define uintptr_t $ac_type
+_ACEOF
+
+         ac_type=
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
index 19ae84519f8fd35376ee0f1a3010a72152801b72..8bcdfa561b33874725b1b7f147eb23e5b16463ad 100644 (file)
@@ -10,6 +10,8 @@ filepattern (restore with regex in bsr)
 mixed priorities
 
 General:
+21Jan09
+ebl  Add detection of intptr_t and uintptr_t to configure process
 20Jan09
 ebl  Change some cast to use intptr_t instead of long
 18Jan09