From 746c18e91a106563aaa8e488f96b5b210a11fb7e Mon Sep 17 00:00:00 2001 From: Marc-Andre Lureau Date: Sat, 31 May 2008 14:58:30 +0300 Subject: [PATCH] libtool 2.2 patch --- Makefile.am | 2 ++ configure.in | 40 +++++++++++++++++++--------------------- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/Makefile.am b/Makefile.am index 0458998..2ef5148 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,5 @@ +ACLOCAL_AMFLAGS = -I m4 + DIST_SUBDIRS = src boilerplate test perf doc util SUBDIRS = src doc # libpng is required for our test programs diff --git a/configure.in b/configure.in index b3383a5..4d15ae0 100644 --- a/configure.in +++ b/configure.in @@ -1,4 +1,4 @@ -AC_PREREQ(2.58) +AC_PREREQ(2.62) dnl cairo package version number, (as distinct from shared library version) dnl For the minor number: odd => unstable series @@ -10,10 +10,11 @@ m4_define(cairo_version_minor, 6) m4_define(cairo_version_micro, 5) AC_INIT([cairo], - cairo_version_major.cairo_version_minor.cairo_version_micro, - [http://bugs.freedesktop.org/enter_bug.cgi?product=cairo]) + [cairo_version_major.cairo_version_minor.cairo_version_micro], + [http://bugs.freedesktop.org/enter_bug.cgi?product=cairo]) AC_CONFIG_SRCDIR(src/cairo.h) AC_CONFIG_HEADERS(config.h) +AC_CONFIG_MACRO_DIR([m4]) dnl automake 1.8 requires autoconf 2.58 dnl automake 1.7 requires autoconf 2.54 @@ -26,23 +27,23 @@ dnl =========================================================================== # libtool shared library version # Increment if the interface has additions, changes, removals. -LT_CURRENT=19 +m4_define([lt_current],[19]) # Increment any time the source changes; set to # 0 if you increment CURRENT -LT_REVISION=5 +m4_define([lt_revision],[5]) # Increment if any interfaces have been added; set to 0 # if any interfaces have been removed. removal has # precedence over adding, so set to 0 if both happened. -LT_AGE=17 +m4_define([lt_age],[17]) dnl =========================================================================== -VERSION_INFO="$LT_CURRENT:$LT_REVISION:$LT_AGE" +VERSION_INFO=lt_current:lt_revision:lt_age AC_SUBST(VERSION_INFO) -LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE` +LT_CURRENT_MINUS_AGE=m4_eval(lt_current - lt_age) AC_SUBST(LT_CURRENT_MINUS_AGE) CAIRO_VERSION_MAJOR=cairo_version_major() @@ -60,10 +61,11 @@ AC_PATH_PROG(XARGS, xargs) dnl =========================================================================== AC_PROG_CC +AM_PROG_CC_C_O AC_PROG_CPP -AC_LIBTOOL_WIN32_DLL -AC_PROG_LIBTOOL dnl required version (1.4) DON'T REMOVE! -AC_STDC_HEADERS + +LT_INIT([win32-dll]) +AC_HEADER_STDC AC_C_INLINE case $host_os in @@ -108,7 +110,7 @@ AC_DEFUN([_CHECK_FUNCS_WITH_FLAGS], dnl =========================================================================== -AC_CHECK_LIBM +LT_LIB_M LIBS="$LIBS $LIBM" AC_CHECK_FUNCS(vasnprintf ctime_r drand48) @@ -135,10 +137,9 @@ dnl AC_MSG_CHECKING([for native atomic primitives]) cairo_atomic_primitives="none" -AC_TRY_LINK([int atomic_add(int i) { return __sync_fetch_and_add (&i, 1); }], [], - AC_DEFINE(CAIRO_HAS_INTEL_ATOMIC_PRIMITIVES, 1, [Enable if your compiler supports the Intel __sync_* atomic primitives]) +AC_LINK_IFELSE([AC_LANG_PROGRAM([[int atomic_add(int i) { return __sync_fetch_and_add (&i, 1); }]], [[]])],[AC_DEFINE(CAIRO_HAS_INTEL_ATOMIC_PRIMITIVES, 1, Enable if your compiler supports the Intel __sync_* atomic primitives) cairo_atomic_primitives="Intel" - ) + ],[]) AC_MSG_RESULT([$cairo_atomic_primitives]) @@ -459,9 +460,7 @@ CAIRO_BACKEND_ENABLE(beos, BeOS/Zeta, beos, BEOS_SURFACE, no, [ esac ]) -if test "x$use_beos" = "xyes"; then - AC_PROG_CXX -fi +AC_PROG_CXX dnl =========================================================================== @@ -822,9 +821,8 @@ CAIRO_CFLAGS="$CAIRO_CFLAGS $WARN_CFLAGS" AC_MSG_CHECKING([how to enable unused result warnings]) warn_unused_result="" if echo $WARN_CFLAGS | grep -e '-Wno-attributes' >/dev/null; then - AC_TRY_COMPILE([__attribute__((__warn_unused_result__)) - int f (int i) { return i; }], [], - [warn_unused_result="__attribute__((__warn_unused_result__))"]) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[__attribute__((__warn_unused_result__)) + int f (int i) { return i; }]], [[]])],[warn_unused_result="__attribute__((__warn_unused_result__))"],[]) fi AC_DEFINE_UNQUOTED([WARN_UNUSED_RESULT], [$warn_unused_result], [Define to the value your compiler uses to support the warn-unused-result attribute]) -- 1.5.5.1.119.gc0d6