Skip to contentSkip to conversation

package/thrift: reorders alphabetically the dependencies.

PATCH New Romain Naour 3 participants 13 messages Apr 6, 2015 – Apr 8, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/4 package/thrift: reorders alphabetically the dependencies.

---
 package/thrift/thrift.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
package/thrift/thrift.mk +3 -2
index 094f8d0..409b04d 100644
@@ -8,8 +8,9 @@ THRIFT_VERSION = 0.9.2
 THRIFT_SITE = http://www.us.apache.org/dist/thrift/$(THRIFT_VERSION)
 THRIFT_DEPENDENCIES = host-pkgconf host-thrift boost libevent openssl zlib
 THRIFT_INSTALL_STAGING = YES
-HOST_THRIFT_DEPENDENCIES = host-boost host-libevent host-openssl host-pkgconf \
-	host-zlib host-bison host-flex
+HOST_THRIFT_DEPENDENCIES = host-bison host-boost host-flex host-libevent \
+	host-openssl host-pkgconf host-zlib
+
 THRIFT_CONF_OPTS = --with-sysroot=$(STAGING_DIR) \
 	--with-boost \
 	--with-boost-libdir=$(STAGING_DIR)/usr/lib \
Signature · 1 line
1.9.3
#1 lore raw

PATCH 2/4 package/thrift: fix libtool warning

Backport an upstream patch.

---
 ...-check-minimum-required-version-of-automa.patch | 45 ++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +45 -0
new file mode 100644
index 0000000..2019706
@@ -0,0 +1,45 @@
+From 9b03d2b02d32302008d2bd0218b31b9a0ca5a748 Mon Sep 17 00:00:00 2001
+From: Jens Geyer <[email protected]>
+Date: Fri, 3 Apr 2015 12:37:03 +0200
+Subject: [PATCH] THRIFT-3071 check minimum required version of automake in
+ bootstrap.sh Client: Build process Patch: James E. King, III
+ <[email protected]>
+
+This closes #421
+
+- remove a warning when using libtool
+
+"libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([./aclocal])' to configure.ac,"
+
+[Romain:
+  - remove the part for bootstrap.sh which is not
+    bundled in thrift archive.
+  - fix the comment]
+Signed-off-by: Romain Naour <[email protected]>
+---
+ configure.ac | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 5fa611e..8daeb03 100755
+--- a/configure.ac
++++ b/configure.ac
+@@ -18,6 +18,7 @@
+ #
+ 
+ AC_PREREQ(2.65)
++AC_CONFIG_MACRO_DIR([./aclocal])
+ 
+ AC_INIT([thrift], [0.9.2])
+ 
+@@ -540,6 +541,7 @@ AC_CHECK_FUNCS([memset])
+ AC_CHECK_FUNCS([mkdir])
+ AC_CHECK_FUNCS([realpath])
+ AC_CHECK_FUNCS([select])
++AC_CHECK_FUNCS([setlocale])
+ AC_CHECK_FUNCS([socket])
+ AC_CHECK_FUNCS([strchr])
+ AC_CHECK_FUNCS([strdup])
+-- 
+1.9.3
+
Signature · 1 line
1.9.3
#2 lore raw

PATCH 2/4 package/thrift: fix libtool warning

Quoted 3 lines · Romain Naour

Backport an upstream patch.

Minor comments below

Quoted 11 lines
---
 ...-check-minimum-required-version-of-automa.patch | 45 ++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +0 -0
new file mode 100644
index 0000000..2019706

package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch line 6

Quoted 6 lines
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +6 -0
@@ -0,0 +1,45 @@
+From 9b03d2b02d32302008d2bd0218b31b9a0ca5a748 Mon Sep 17 00:00:00 2001
+From: Jens Geyer <[email protected]>
+Date: Fri, 3 Apr 2015 12:37:03 +0200
+Subject: [PATCH] THRIFT-3071 check minimum required version of automake in
+ bootstrap.sh Client: Build process Patch: James E. King, III
+ <[email protected]>

Something went wrong with the subject line here. Upstream has the Client: and
Patch: lines below the subject.

package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch line 17

Quoted 11 lines
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +11 -0
+
+This closes #421
+
+- remove a warning when using libtool
+
+"libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([./aclocal])' to configure.ac,"
+
+[Romain:
+  - remove the part for bootstrap.sh which is not
+    bundled in thrift archive.
+  - fix the comment]

Well, that fixing was no success :-) Anyway it should be

- fix the commit log accordingly

Please also add a reference to the upstream commit, e.g.

4aa95df383bfa13c46a4dc0b41672ec29d476300 upstream

or

https://git-wip-us.apache.org/repos/asf?p=thrift.git;h=4aa95df383bfa13c46a4dc0b41672ec29d476300

Regards,
Arnout

Quoted 29 lines
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +28 -0
+Signed-off-by: Romain Naour <[email protected]>
+---
+ configure.ac | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 5fa611e..8daeb03 100755
+--- a/configure.ac
++++ b/configure.ac
+@@ -18,6 +18,7 @@
+ #
+ 
+ AC_PREREQ(2.65)
++AC_CONFIG_MACRO_DIR([./aclocal])
+ 
+ AC_INIT([thrift], [0.9.2])
+ 
+@@ -540,6 +541,7 @@ AC_CHECK_FUNCS([memset])
+ AC_CHECK_FUNCS([mkdir])
+ AC_CHECK_FUNCS([realpath])
+ AC_CHECK_FUNCS([select])
++AC_CHECK_FUNCS([setlocale])
+ AC_CHECK_FUNCS([socket])
+ AC_CHECK_FUNCS([strchr])
+ AC_CHECK_FUNCS([strdup])
+-- 
+1.9.3
+
Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
#3 lore raw

PATCH 2/4 package/thrift: fix libtool warning

Hi Arnout,

Le 06/04/2015 22:14, Arnout Vandecappelle a ?crit :

Quoted 14 lines · Romain Naour
Quoted 3 lines

Backport an upstream patch.

Minor comments below

Quoted 5 lines
---
 ...-check-minimum-required-version-of-automa.patch | 45 ++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch
Quoted 15 lines

package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch line 6

Quoted 12 lines
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +6 -0
new file mode 100644
index 0000000..2019706
@@ -0,0 +1,45 @@
+From 9b03d2b02d32302008d2bd0218b31b9a0ca5a748 Mon Sep 17 00:00:00 2001
+From: Jens Geyer <[email protected]>
+Date: Fri, 3 Apr 2015 12:37:03 +0200
+Subject: [PATCH] THRIFT-3071 check minimum required version of automake in
+ bootstrap.sh Client: Build process Patch: James E. King, III
+ <[email protected]>

Something went wrong with the subject line here. Upstream has the Client: and
Patch: lines below the subject.

Ok, I see. The commit tittle is correct in my git tree but the formatted patch is wrong...

I had to add a new line between title and Client line...

Quoted 14 lines

package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch line 17

Quoted 12 lines
package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch new file +11 -0
+
+This closes #421
+
+- remove a warning when using libtool
+
+"libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([./aclocal])' to configure.ac,"
+
+[Romain:
+  - remove the part for bootstrap.sh which is not
+    bundled in thrift archive.
+  - fix the comment]

Well, that fixing was no success :-) Anyway it should be

Indeed :) Sorry

Quoted 4 lines

- fix the commit log accordingly

Quoted 8 lines

Please also add a reference to the upstream commit, e.g.

4aa95df383bfa13c46a4dc0b41672ec29d476300 upstream

or

https://git-wip-us.apache.org/repos/asf?p=thrift.git;h=4aa95df383bfa13c46a4dc0b41672ec29d476300

Thanks for the review, I'll resend an updated version after having some comments on patch 3/4 and 4/4 which are the aim of this series.

Best regards,
Romain

Quoted 5 lines

Regards,
Arnout

#4 lore raw

PATCH 2/4 package/thrift: fix libtool warning

In reply to Romain Naour

Dear Romain Naour,

Quoted 7 lines · Romain Naour

Backport an upstream patch.

---
 ...-check-minimum-required-version-of-automa.patch | 45 ++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/thrift/0004-THRIFT-3071-check-minimum-required-version-of-automa.patch

Applied, after taking into account Arnout's comments (hopefully correctly).

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#5 lore raw

PATCH 3/4 package/autoconf-archive: bump to version v2015.02.24

In reply to Romain Naour

Fix the AX_CXX_COMPILE_STDCXX_11 macro which was broken in the previous release.

---
This will break packages that really depends on C++11 (like thrift).

---
 package/autoconf-archive/autoconf-archive.hash | 2 +-
 package/autoconf-archive/autoconf-archive.mk   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
package/autoconf-archive/autoconf-archive.hash +1 -1
index 9f975d5..c310f5a 100644
@@ -1,2 +1,2 @@
 # Computed locally
-sha256 dfd460d23a9690322dee29a355ea285b5774f37383d3741cf77a4ad6a11a7e81  autoconf-archive-2015.02.04.tar.xz
+sha256 69715bdd078f552ca85e498a94543e11cb8bcdf0359e659b84d84d19372b0dc5  autoconf-archive-2015.02.24.tar.xz
package/autoconf-archive/autoconf-archive.mk +1 -1
index 4479348..bd3b0c8 100644
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-AUTOCONF_ARCHIVE_VERSION = 2015.02.04
+AUTOCONF_ARCHIVE_VERSION = 2015.02.24
 AUTOCONF_ARCHIVE_SOURCE = autoconf-archive-$(AUTOCONF_ARCHIVE_VERSION).tar.xz
 AUTOCONF_ARCHIVE_SITE = $(BR2_GNU_MIRROR)/autoconf-archive
 AUTOCONF_ARCHIVE_LICENSE = GPLv3+ with exception
Signature · 1 line
1.9.3
#6 lore raw

PATCH 3/4 package/autoconf-archive: bump to version v2015.02.24

Quoted 4 lines · Romain Naour

Fix the AX_CXX_COMPILE_STDCXX_11 macro which was broken in the previous release.

I checked that libsigrok (which really depends on this package) still works,
but of course there could be other hidden dependencies like thrift.

Regards,
Arnout

Quoted 29 lines

---
This will break packages that really depends on C++11 (like thrift).

---
 package/autoconf-archive/autoconf-archive.hash | 2 +-
 package/autoconf-archive/autoconf-archive.mk   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
package/autoconf-archive/autoconf-archive.hash +1 -1
index 9f975d5..c310f5a 100644
@@ -1,2 +1,2 @@
 # Computed locally
-sha256 dfd460d23a9690322dee29a355ea285b5774f37383d3741cf77a4ad6a11a7e81  autoconf-archive-2015.02.04.tar.xz
+sha256 69715bdd078f552ca85e498a94543e11cb8bcdf0359e659b84d84d19372b0dc5  autoconf-archive-2015.02.24.tar.xz
package/autoconf-archive/autoconf-archive.mk +1 -1
index 4479348..bd3b0c8 100644
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-AUTOCONF_ARCHIVE_VERSION = 2015.02.04
+AUTOCONF_ARCHIVE_VERSION = 2015.02.24
 AUTOCONF_ARCHIVE_SOURCE = autoconf-archive-$(AUTOCONF_ARCHIVE_VERSION).tar.xz
 AUTOCONF_ARCHIVE_SITE = $(BR2_GNU_MIRROR)/autoconf-archive
 AUTOCONF_ARCHIVE_LICENSE = GPLv3+ with exception
Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
#7 lore raw

PATCH 3/4 package/autoconf-archive: bump to version v2015.02.24

In reply to Romain Naour

Dear Romain Naour,

Quoted 4 lines · Romain Naour

Fix the AX_CXX_COMPILE_STDCXX_11 macro which was broken in the previous release.

Applied, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#8 lore raw

PATCH 4/4 package/thrift: add dependency on host-autoconf-archive

In reply to Romain Naour

The ax_cxx_compile_stdcxx_11 macro bundled in thrift package is brocken and out of date.
Remove it and use the one provided by autoconf-archive package.

Related to:
[thrift]
http://autobuild.buildroot.net/results/21e/21e3fff1e0d714f94ac7e621289d1a59bc02a05f/build-end.log
[host-thrift]
http://autobuild.buildroot.net/results/b89/b89ffc2bff699eb10bb6abd92369a43d4900354d/build-end.log

---
Now thrift will fail with non C++11 capable toolchains:
checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features by default... no checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features with -std=c++11... no checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features with -std=c++0x... no

---
 .../0005-aclocal-remove-c-11-check-macro.patch     | 158 +++++++++++++++++++++
 package/thrift/thrift.mk                           |   4 +-
 2 files changed, 160 insertions(+), 2 deletions(-)
 create mode 100644 package/thrift/0005-aclocal-remove-c-11-check-macro.patch
package/thrift/0005-aclocal-remove-c-11-check-macro.patch new file +158 -0
new file mode 100644
index 0000000..19c0c86
@@ -0,0 +1,158 @@
+From bffbd147b123782fe0112f3672ba621d755eb706 Mon Sep 17 00:00:00 2001
+From: Romain Naour <[email protected]>
+Date: Mon, 6 Apr 2015 18:35:12 +0200
+Subject: [PATCH] aclocal: remove c++11 check macro
+
+The ax_cxx_compile_stdcxx_11 macro is brocken and out of date.
+
+Remove it and use the one provided by autoconf-archive package.
+
+Signed-off-by: Romain Naour <[email protected]>
+---
+ aclocal/ax_cxx_compile_stdcxx_11.m4 | 134 ------------------------------------
+ 1 file changed, 134 deletions(-)
+ delete mode 100644 aclocal/ax_cxx_compile_stdcxx_11.m4
+
+diff --git a/aclocal/ax_cxx_compile_stdcxx_11.m4 b/aclocal/ax_cxx_compile_stdcxx_11.m4
+deleted file mode 100644
+index a4c9189..0000000
+--- a/aclocal/ax_cxx_compile_stdcxx_11.m4
++++ /dev/null
+@@ -1,134 +0,0 @@
+-# ============================================================================
+-#  http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_11.html
+-# ============================================================================
+-#
+-# SYNOPSIS
+-#
+-#   AX_CXX_COMPILE_STDCXX_11([ext|noext],[mandatory|optional])
+-#
+-# DESCRIPTION
+-#
+-#   Check for baseline language coverage in the compiler for the C++11
+-#   standard; if necessary, add switches to CXXFLAGS to enable support.
+-#
+-#   The first argument, if specified, indicates whether you insist on an
+-#   extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g.
+-#   -std=c++11).  If neither is specified, you get whatever works, with
+-#   preference for an extended mode.
+-#
+-#   The second argument, if specified 'mandatory' or if left unspecified,
+-#   indicates that baseline C++11 support is required and that the macro
+-#   should error out if no mode with that support is found.  If specified
+-#   'optional', then configuration proceeds regardless, after defining
+-#   HAVE_CXX11 if and only if a supporting mode is found.
+-#
+-# LICENSE
+-#
+-#   Copyright (c) 2008 Benjamin Kosnik <[email protected]>
+-#   Copyright (c) 2012 Zack Weinberg <[email protected]>
+-#   Copyright (c) 2013 Roy Stogner <[email protected]>
+-#
+-#   Copying and distribution of this file, with or without modification, are
+-#   permitted in any medium without royalty provided the copyright notice
+-#   and this notice are preserved. This file is offered as-is, without any
+-#   warranty.
+-
+-#serial 3
+-
+-m4_define([_AX_CXX_COMPILE_STDCXX_11_testbody], [
+-  template <typename T>
+-    struct check
+-    {
+-      static_assert(sizeof(int) <= sizeof(T), "not big enough");
+-    };
+-
+-    typedef check<check<bool>> right_angle_brackets;
+-
+-    int a;
+-    decltype(a) b;
+-
+-    typedef check<int> check_type;
+-    check_type c;
+-    check_type&& cr = static_cast<check_type&&>(c);
+-
+-    auto d = a;
+-])
+-
+-AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [dnl
+-  m4_if([$1], [], [],
+-        [$1], [ext], [],
+-        [$1], [noext], [],
+-        [m4_fatal([invalid argument `$1' to AX_CXX_COMPILE_STDCXX_11])])dnl
+-  m4_if([$2], [], [ax_cxx_compile_cxx11_required=true],
+-        [$2], [mandatory], [ax_cxx_compile_cxx11_required=true],
+-        [$2], [optional], [ax_cxx_compile_cxx11_required=false],
+-        [m4_fatal([invalid second argument `$2' to AX_CXX_COMPILE_STDCXX_11])])dnl
+-  AC_LANG_PUSH([C++])dnl
+-  ac_success=no
+-  AC_CACHE_CHECK(whether $CXX supports C++11 features by default,
+-  ax_cv_cxx_compile_cxx11,
+-  [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
+-    [ax_cv_cxx_compile_cxx11=yes],
+-    [ax_cv_cxx_compile_cxx11=no])])
+-  if test x$ax_cv_cxx_compile_cxx11 = xyes; then
+-    ac_success=yes
+-  fi
+-
+-  m4_if([$1], [noext], [], [dnl
+-  if test x$ac_success = xno; then
+-    for switch in -std=gnu++11; do
+-      cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch])
+-      AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch,
+-                     $cachevar,
+-        [ac_save_CXXFLAGS="$CXXFLAGS"
+-         CXXFLAGS="$CXXFLAGS $switch"
+-         AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
+-          [eval $cachevar=yes],
+-          [eval $cachevar=no])
+-         CXXFLAGS="$ac_save_CXXFLAGS"])
+-      if eval test x\$$cachevar = xyes; then
+-        CXXFLAGS="$CXXFLAGS $switch"
+-        ac_success=yes
+-        break
+-      fi
+-    done
+-  fi])
+-
+-  m4_if([$1], [ext], [], [dnl
+-  if test x$ac_success = xno; then
+-    for switch in -std=c++11; do
+-      cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch])
+-      AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch,
+-                     $cachevar,
+-        [ac_save_CXXFLAGS="$CXXFLAGS"
+-         CXXFLAGS="$CXXFLAGS $switch"
+-         AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
+-          [eval $cachevar=yes],
+-          [eval $cachevar=no])
+-         CXXFLAGS="$ac_save_CXXFLAGS"])
+-      if eval test x\$$cachevar = xyes; then
+-        CXXFLAGS="$CXXFLAGS $switch"
+-        ac_success=yes
+-        break
+-      fi
+-    done
+-  fi])
+-  AC_LANG_POP([C++])
+-  if test x$ax_cxx_compile_cxx11_required = xtrue; then
+-    if test x$ac_success = xno; then
+-      AC_MSG_ERROR([*** A compiler with support for C++11 language features is required.])
+-    fi
+-  else
+-    if test x$ac_success = xno; then
+-      HAVE_CXX11=0
+-      AC_MSG_NOTICE([No compiler with C++11 support was found])
+-    else
+-      HAVE_CXX11=1
+-      AC_DEFINE(HAVE_CXX11,1,
+-                [define if the compiler supports basic C++11 syntax])
+-    fi
+-
+-    AC_SUBST(HAVE_CXX11)
+-  fi
+-])
+-
+-- 
+1.9.3
+
package/thrift/thrift.mk +2 -2
index 409b04d..5d4c515 100644
@@ -8,8 +8,8 @@ THRIFT_VERSION = 0.9.2
 THRIFT_SITE = http://www.us.apache.org/dist/thrift/$(THRIFT_VERSION)
 THRIFT_DEPENDENCIES = host-pkgconf host-thrift boost libevent openssl zlib
 THRIFT_INSTALL_STAGING = YES
-HOST_THRIFT_DEPENDENCIES = host-bison host-boost host-flex host-libevent \
-	host-openssl host-pkgconf host-zlib
+HOST_THRIFT_DEPENDENCIES = host-autoconf-archive host-bison host-boost \
+	host-flex host-libevent host-openssl host-pkgconf host-zlib
 
 THRIFT_CONF_OPTS = --with-sysroot=$(STAGING_DIR) \
 	--with-boost \
Signature · 1 line
1.9.3
#9 lore raw

PATCH 4/4 package/thrift: add dependency on host-autoconf-archive

Quoted 9 lines · Romain Naour

The ax_cxx_compile_stdcxx_11 macro bundled in thrift package is brocken and out of date.
Remove it and use the one provided by autoconf-archive package.

Related to:
[thrift]
http://autobuild.buildroot.net/results/21e/21e3fff1e0d714f94ac7e621289d1a59bc02a05f/build-end.log
[host-thrift]
http://autobuild.buildroot.net/results/b89/b89ffc2bff699eb10bb6abd92369a43d4900354d/build-end.log

I fail to see what this really fixes... For both build failures, it failed
before this patch and it still fails after it... and it should fail since these compilers indeed are not fully C++11 compliant (missing virtual overrides which were added in gcc 4.7).

Oh, I get it, it will now fail consistently, instead of failing depending on
whether host-autoconf-archive has been installed or not...

But the stupid thing is, the build does succeed with these non-conforming
compilers, because thrift actually doesn't use that particular feature...

So perhaps it's better to patch configure.ac and ax_cxx_compile_stdcxx_11.m4 to
give the macro a different name, so that we can still compile thrift with gcc 4.5.

Still...

Quoted 19 lines

---
Now thrift will fail with non C++11 capable toolchains:
checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features by default... no checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features with -std=c++11... no checking whether /home/naourr/git/buildroot/test/thrift/host/usr/bin/powerpc-linux-gnu-g++ supports C++11 features with -std=c++0x... no

---
 .../0005-aclocal-remove-c-11-check-macro.patch     | 158 +++++++++++++++++++++
 package/thrift/thrift.mk                           |   4 +-
 2 files changed, 160 insertions(+), 2 deletions(-)
 create mode 100644 package/thrift/0005-aclocal-remove-c-11-check-macro.patch
package/thrift/0005-aclocal-remove-c-11-check-macro.patch new file +0 -0
new file mode 100644
index 0000000..19c0c86

package/thrift/0005-aclocal-remove-c-11-check-macro.patch line 8

Quoted 8 lines
package/thrift/0005-aclocal-remove-c-11-check-macro.patch new file +8 -0
@@ -0,0 +1,158 @@
+From bffbd147b123782fe0112f3672ba621d755eb706 Mon Sep 17 00:00:00 2001
+From: Romain Naour <[email protected]>
+Date: Mon, 6 Apr 2015 18:35:12 +0200
+Subject: [PATCH] aclocal: remove c++11 check macro
+
+The ax_cxx_compile_stdcxx_11 macro is brocken and out of date.
+
+Remove it and use the one provided by autoconf-archive package.

This is not needed, autoreconf will pick up the newer version automatically.

[snip]

package/thrift/thrift.mk THRIFT_VERSION = 0.9.2 · line 9

Quoted 7 lines
package/thrift/thrift.mk +0 -0
index 409b04d..5d4c515 100644
@@ -8,8 +8,8 @@ THRIFT_VERSION = 0.9.2
 THRIFT_SITE = http://www.us.apache.org/dist/thrift/$(THRIFT_VERSION)
 THRIFT_DEPENDENCIES = host-pkgconf host-thrift boost libevent openssl zlib

Missing dependency on host-autoconf-archive here.

Regards,
Arnout

Quoted 9 lines
package/thrift/thrift.mk +2 -2
 THRIFT_INSTALL_STAGING = YES
-HOST_THRIFT_DEPENDENCIES = host-bison host-boost host-flex host-libevent \
-	host-openssl host-pkgconf host-zlib
+HOST_THRIFT_DEPENDENCIES = host-autoconf-archive host-bison host-boost \
+	host-flex host-libevent host-openssl host-pkgconf host-zlib
 
 THRIFT_CONF_OPTS = --with-sysroot=$(STAGING_DIR) \
 	--with-boost \
Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
#10 lore raw

PATCH 4/4 package/thrift: add dependency on host-autoconf-archive

Hi Arnout,

Le 07/04/2015 01:15, Arnout Vandecappelle a ?crit :

Quoted 11 lines · Romain Naour
Quoted 9 lines

The ax_cxx_compile_stdcxx_11 macro bundled in thrift package is brocken and out of date.
Remove it and use the one provided by autoconf-archive package.

Related to:
[thrift]
http://autobuild.buildroot.net/results/21e/21e3fff1e0d714f94ac7e621289d1a59bc02a05f/build-end.log
[host-thrift]
http://autobuild.buildroot.net/results/b89/b89ffc2bff699eb10bb6abd92369a43d4900354d/build-end.log

Quoted 7 lines

I fail to see what this really fixes... For both build failures, it failed
before this patch and it still fails after it... and it should fail since these compilers indeed are not fully C++11 compliant (missing virtual overrides which were added in gcc 4.7).

Oh, I get it, it will now fail consistently, instead of failing depending on
whether host-autoconf-archive has been installed or not...

I added a link to the macro bug report for v2 to explain the issue.
http://savannah.gnu.org/patch/index.php?8287

Quoted 6 lines

But the stupid thing is, the build does succeed with these non-conforming
compilers, because thrift actually doesn't use that particular feature...

So perhaps it's better to patch configure.ac and ax_cxx_compile_stdcxx_11.m4 to
give the macro a different name, so that we can still compile thrift with gcc 4.5.

The macro accept a second argument to make C++11 optional:
AX_CXX_COMPILE_STDCXX_11([noext], [optional])

Thrift build fine but produce lot of warning about anonymous variadic macros but it just for some debug macro:
#define T_DEBUG(format_string,...)
"warning: anonymous variadic macros were introduced in C99"

And some warning about the use of --std=c++0x (C++03) long long which is available in gcc 4.5.
"warning: use of C++0x long long integer constant"

At least, it seems to be safe to make C++11 optional and use C++03 for this release...

Quoted 3 lines

Still...

[snip]

Quoted 6 lines

package/thrift/0005-aclocal-remove-c-11-check-macro.patch line 8

Quoted 4 lines
package/thrift/0005-aclocal-remove-c-11-check-macro.patch new file +4 -0
+
+The ax_cxx_compile_stdcxx_11 macro is brocken and out of date.
+
+Remove it and use the one provided by autoconf-archive package.

This is not needed, autoreconf will pick up the newer version automatically.

OK

Quoted 12 lines

[snip]

package/thrift/thrift.mk THRIFT_VERSION = 0.9.2 · line 9

Quoted 7 lines
package/thrift/thrift.mk +0 -0
index 409b04d..5d4c515 100644
@@ -8,8 +8,8 @@ THRIFT_VERSION = 0.9.2
 THRIFT_SITE = http://www.us.apache.org/dist/thrift/$(THRIFT_VERSION)
 THRIFT_DEPENDENCIES = host-pkgconf host-thrift boost libevent openssl zlib

Missing dependency on host-autoconf-archive here.

Ok

Best regards,
Romain

Quoted 6 lines

Regards,
Arnout

#11 lore raw

PATCH 1/4 package/thrift: reorders alphabetically the dependencies.

In reply to Romain Naour
Quoted 1 line · Romain Naour

Regards,
Arnout

Quoted 21 lines
---
 package/thrift/thrift.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
package/thrift/thrift.mk +3 -2
index 094f8d0..409b04d 100644
@@ -8,8 +8,9 @@ THRIFT_VERSION = 0.9.2
 THRIFT_SITE = http://www.us.apache.org/dist/thrift/$(THRIFT_VERSION)
 THRIFT_DEPENDENCIES = host-pkgconf host-thrift boost libevent openssl zlib
 THRIFT_INSTALL_STAGING = YES
-HOST_THRIFT_DEPENDENCIES = host-boost host-libevent host-openssl host-pkgconf \
-	host-zlib host-bison host-flex
+HOST_THRIFT_DEPENDENCIES = host-bison host-boost host-flex host-libevent \
+	host-openssl host-pkgconf host-zlib
+
 THRIFT_CONF_OPTS = --with-sysroot=$(STAGING_DIR) \
 	--with-boost \
 	--with-boost-libdir=$(STAGING_DIR)/usr/lib \
Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
#12 lore raw

PATCH 1/4 package/thrift: reorders alphabetically the dependencies.

In reply to Romain Naour

Dear Romain Naour,

Quoted 4 lines · Romain Naour
---
 package/thrift/thrift.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Applied, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com