[Libreoffice-commits] .: liblangtag/liblangtag-0.4.0-configure-atomic-cflag-pollution.patch liblangtag/liblangtag-0.4.0-windows.patch liblangtag/makefile.mk

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Nov 7 14:10:23 PST 2012


 liblangtag/liblangtag-0.4.0-configure-atomic-cflag-pollution.patch |   62 ++++++++++
 liblangtag/liblangtag-0.4.0-windows.patch                          |   62 ----------
 liblangtag/makefile.mk                                             |    2 
 3 files changed, 64 insertions(+), 62 deletions(-)

New commits:
commit 7c0606c94246909807433d91fc79b0c2ac6f95bb
Author: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
Date:   Wed Nov 7 15:52:47 2012 +0100

    check for builtins pollutes CFLAGS and in turn breaks pthread check
    
    since the -march=i486 is not supported on PPC, all further compile
    checks done in liblangtag's configure break.
    So moving the corresponding patch out of the windows patch in a generic
    one and also apply that for Mac.
    
    Change-Id: I65716bc9d7ff19976e5e82ae869c7594978e93e3
    Reviewed-on: https://gerrit.libreoffice.org/999
    Reviewed-by: Michael Stahl <mstahl at redhat.com>
    Tested-by: Michael Stahl <mstahl at redhat.com>

diff --git a/liblangtag/liblangtag-0.4.0-configure-atomic-cflag-pollution.patch b/liblangtag/liblangtag-0.4.0-configure-atomic-cflag-pollution.patch
new file mode 100644
index 0000000..92efbfd
--- /dev/null
+++ b/liblangtag/liblangtag-0.4.0-configure-atomic-cflag-pollution.patch
@@ -0,0 +1,62 @@
+--- misc/liblangtag-0.4.0/configure.ac
++++ misc/build/liblangtag-0.4.0/configure.ac
+@@ -173,8 +173,9 @@
+ __sync_synchronize();
+ j = __sync_fetch_and_sub(&i, 1);
+ return j;
+-       ]])], [AC_MSG_ERROR([liblangtag has to be built with -march=i486 or later.])]
+-       [lt_cv_has_atomic=no])])
++       ]])], [AC_MSG_ERROR([liblangtag has to be built with -march=i486 or later.])],
++       [lt_cv_has_atomic=no
++        CFLAGS="$_save_cflags"])])
+ ])
+ if test "x$lt_cv_has_atomic" = "xyes"; then
+ 	AC_DEFINE(LT_HAVE_ATOMIC_BUILTINS, 1, [Have buit-in atomic functions])
+@@ -291,8 +291,14 @@
+ dnl ======================================================================
+ dnl check another libraries
+ dnl ======================================================================
++case $host_os in
++  cygwin* | mingw*)
++    ;;
+-AX_PTHREAD([],
++  *)
++    AX_PTHREAD([],
+ 	[AC_MSG_ERROR([*** pthread library are required])])
++    ;;
++esac
+ 
+ GOBJECT_INTROSPECTION_CHECK([1.30.0])
+ if test "x$enable_introspection" != "xyes"; then
+--- misc/liblangtag-0.4.0/configure
++++ misc/build/liblangtag-0.4.0/configure
+@@ -12604,7 +12604,9 @@
+ _ACEOF
+ if ac_fn_c_try_link "$LINENO"; then :
+   as_fn_error $? "liblangtag has to be built with -march=i486 or later." "$LINENO" 5
++else
+        lt_cv_has_atomic=no
++       CFLAGS="$_save_cflags"
+ fi
+ rm -f core conftest.err conftest.$ac_objext \
+     conftest$ac_exeext conftest.$ac_ext
+@@ -13201,6 +13201,10 @@
+ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ ac_compiler_gnu=$ac_cv_c_compiler_gnu
+ 
++case $host_os in
++  cygwin* | mingw*)
++    ;;
++  *)
+ ax_pthread_ok=no
+ 
+ # We used to check for pthread.h first, but this fails if pthread.h
+@@ -13582,6 +13582,8 @@
+         ax_pthread_ok=no
+         as_fn_error $? "*** pthread library are required" "$LINENO" 5
+ fi
++;;
++esac
+ ac_ext=c
+ ac_cpp='$CPP $CPPFLAGS'
+ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
diff --git a/liblangtag/liblangtag-0.4.0-windows.patch b/liblangtag/liblangtag-0.4.0-windows.patch
index fef4a48..1f07bd0 100644
--- a/liblangtag/liblangtag-0.4.0-windows.patch
+++ b/liblangtag/liblangtag-0.4.0-windows.patch
@@ -1,65 +1,3 @@
---- misc/liblangtag-0.4.0/configure.ac
-+++ misc/build/liblangtag-0.4.0/configure.ac
-@@ -173,8 +173,9 @@
- __sync_synchronize();
- j = __sync_fetch_and_sub(&i, 1);
- return j;
--       ]])], [AC_MSG_ERROR([liblangtag has to be built with -march=i486 or later.])]
--       [lt_cv_has_atomic=no])])
-+       ]])], [AC_MSG_ERROR([liblangtag has to be built with -march=i486 or later.])],
-+       [lt_cv_has_atomic=no
-+        CFLAGS="$_save_cflags"])])
- ])
- if test "x$lt_cv_has_atomic" = "xyes"; then
- 	AC_DEFINE(LT_HAVE_ATOMIC_BUILTINS, 1, [Have buit-in atomic functions])
-@@ -291,8 +291,14 @@
- dnl ======================================================================
- dnl check another libraries
- dnl ======================================================================
-+case $host_os in
-+  cygwin* | mingw*)
-+    ;;
--AX_PTHREAD([],
-+  *)
-+    AX_PTHREAD([],
- 	[AC_MSG_ERROR([*** pthread library are required])])
-+    ;;
-+esac
- 
- GOBJECT_INTROSPECTION_CHECK([1.30.0])
- if test "x$enable_introspection" != "xyes"; then
---- misc/liblangtag-0.4.0/configure
-+++ misc/build/liblangtag-0.4.0/configure
-@@ -12607,7 +12607,9 @@
- _ACEOF
- if ac_fn_c_try_link "$LINENO"; then :
-   as_fn_error $? "liblangtag has to be built with -march=i486 or later." "$LINENO" 5
-+else
-        lt_cv_has_atomic=no
-+       CFLAGS="$_save_cflags"
- fi
- rm -f core conftest.err conftest.$ac_objext \
-     conftest$ac_exeext conftest.$ac_ext
-@@ -13203,6 +13203,10 @@
- ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
- ac_compiler_gnu=$ac_cv_c_compiler_gnu
- 
-+case $host_os in
-+  cygwin* | mingw*)
-+    ;;
-+  *)
- ax_pthread_ok=no
- 
- # We used to check for pthread.h first, but this fails if pthread.h
-@@ -13584,6 +13584,8 @@
-         ax_pthread_ok=no
-         as_fn_error $? "*** pthread library are required" "$LINENO" 5
- fi
-+;;
-+esac
- ac_ext=c
- ac_cpp='$CPP $CPPFLAGS'
- ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 --- misc/liblangtag-0.4.0/liblangtag/lt-macros.h
 +++ misc/build/liblangtag-0.4.0/liblangtag/lt-macros.h
 @@ -14,7 +14,9 @@
diff --git a/liblangtag/makefile.mk b/liblangtag/makefile.mk
index c223582..2ac05e6 100644
--- a/liblangtag/makefile.mk
+++ b/liblangtag/makefile.mk
@@ -39,12 +39,14 @@ ADDITIONAL_FILES=\
 	msvs2010$/liblangtag.sln msvs2010$/liblangtag.vcxproj
 
 PATCH_FILES=liblangtag-0.4.0-msvc-warning.patch
+PATCH_FILES+=liblangtag-0.4.0-configure-atomic-cflag-pollution.patch
 PATCH_FILES+=liblangtag-0.4.0-windows.patch
 PATCH_FILES+=liblangtag-0.4.0-reg2xml-encoding-problem.patch
 PATCH_FILES+=liblangtag-0.4.0-windows2.patch
 PATCH_FILES+=liblangtag-0.4.0-msvcprojects.patch
 .IF "$(OS)" == "MACOSX"
 PATCH_FILES=liblangtag-0.4.0-mac.patch
+PATCH_FILES+=liblangtag-0.4.0-configure-atomic-cflag-pollution.patch
 .END
 CONFIGURE_DIR=.
 BUILD_DIR=$(CONFIGURE_DIR)


More information about the Libreoffice-commits mailing list