"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "m4/printf-posix.m4" between
libextractor-1.8.tar.gz and libextractor-1.9.tar.gz

About: GNU libextractor is a library used to extract meta-data from files of arbitrary type.

printf-posix.m4  (libextractor-1.8):printf-posix.m4  (libextractor-1.9)
# printf-posix.m4 serial 2 (gettext-0.13.1) # printf-posix.m4 serial 6 (gettext-0.18.2)
dnl Copyright (C) 2003 Free Software Foundation, Inc. dnl Copyright (C) 2003, 2007, 2009-2016 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it, dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved. dnl with or without modifications, as long as this notice is preserved.
dnl From Bruno Haible. dnl From Bruno Haible.
dnl Test whether the printf() function supports POSIX/XSI format strings with dnl Test whether the printf() function supports POSIX/XSI format strings with
dnl positions. dnl positions.
AC_DEFUN([gt_PRINTF_POSIX], AC_DEFUN([gt_PRINTF_POSIX],
[ [
AC_REQUIRE([AC_PROG_CC]) AC_REQUIRE([AC_PROG_CC])
AC_CACHE_CHECK([whether printf() supports POSIX/XSI format strings], AC_CACHE_CHECK([whether printf() supports POSIX/XSI format strings],
gt_cv_func_printf_posix, gt_cv_func_printf_posix,
[ [
AC_TRY_RUN([ AC_RUN_IFELSE(
[AC_LANG_SOURCE([[
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
/* The string "%2$d %1$d", with dollar characters protected from the shell's /* The string "%2$d %1$d", with dollar characters protected from the shell's
dollar expansion (possibly an autoconf bug). */ dollar expansion (possibly an autoconf bug). */
static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' }; static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
static char buf[100]; static char buf[100];
int main () int main ()
{ {
sprintf (buf, format, 33, 55); sprintf (buf, format, 33, 55);
return (strcmp (buf, "55 33") != 0); return (strcmp (buf, "55 33") != 0);
}], gt_cv_func_printf_posix=yes, gt_cv_func_printf_posix=no, }]])],
[ [gt_cv_func_printf_posix=yes],
AC_EGREP_CPP(notposix, [ [gt_cv_func_printf_posix=no],
#if defined __NetBSD__ || defined _MSC_VER || defined __MINGW32__ || defined __C [
YGWIN__ AC_EGREP_CPP([notposix], [
#if defined __NetBSD__ || defined __BEOS__ || defined _MSC_VER || defined __MING
W32__ || defined __CYGWIN__
notposix notposix
#endif #endif
], gt_cv_func_printf_posix="guessing no", ],
gt_cv_func_printf_posix="guessing yes") [gt_cv_func_printf_posix="guessing no"],
]) [gt_cv_func_printf_posix="guessing yes"])
])
]) ])
case $gt_cv_func_printf_posix in case $gt_cv_func_printf_posix in
*yes) *yes)
AC_DEFINE(HAVE_POSIX_PRINTF, 1, AC_DEFINE([HAVE_POSIX_PRINTF], [1],
[Define if your printf() function supports format strings with positions .]) [Define if your printf() function supports format strings with positions .])
;; ;;
esac esac
]) ])
 End of changes. 5 change blocks. 
12 lines changed or deleted 16 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)