* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/glog/files/, dev-cpp/glog/
@ 2017-01-22 18:30 David Seifert
0 siblings, 0 replies; 3+ messages in thread
From: David Seifert @ 2017-01-22 18:30 UTC (permalink / raw
To: gentoo-commits
commit: 55f695f858b914faf5f7a4c188f6fc18d5b4bb66
Author: David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Sun Jan 22 18:28:05 2017 +0000
Commit: David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Sun Jan 22 18:30:22 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55f695f8
dev-cpp/glog: Bump to EAPI 6 and add GCC 5 patch
Gentoo-bug: 555030
Package-Manager: Portage-2.3.3, Repoman-2.3.1
.../glog/files/glog-0.3.4-fix-build-system.patch | 142 +++++++++++++++++++++
.../files/glog-0.3.4-fix-gcc5-demangling.patch | 56 ++++++++
dev-cpp/glog/glog-0.3.4-r1.ebuild | 51 ++++++++
3 files changed, 249 insertions(+)
diff --git a/dev-cpp/glog/files/glog-0.3.4-fix-build-system.patch b/dev-cpp/glog/files/glog-0.3.4-fix-build-system.patch
new file mode 100644
index 00000000..cd38111
--- /dev/null
+++ b/dev-cpp/glog/files/glog-0.3.4-fix-build-system.patch
@@ -0,0 +1,142 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -11,7 +11,7 @@
+ AC_CONFIG_SRCDIR(README)
+ AC_CONFIG_MACRO_DIR([m4])
+ AM_INIT_AUTOMAKE
+-AM_CONFIG_HEADER(src/config.h)
++AC_CONFIG_HEADERS([src/config.h])
+
+ AC_LANG(C++)
+
+@@ -21,7 +21,7 @@
+ AC_PROG_CXX
+ AM_CONDITIONAL(GCC, test "$GCC" = yes) # let the Makefile know if we're gcc
+
+-AC_PROG_LIBTOOL
++LT_INIT
+ AC_SUBST(LIBTOOL_DEPS)
+
+ # Check whether some low-level functions/files are available
+@@ -128,32 +128,48 @@
+ fi
+
+ # Check if there is google-gflags library installed.
+-SAVE_CFLAGS="$CFLAGS"
+-SAVE_LIBS="$LIBS"
+-AC_ARG_WITH(gflags, AS_HELP_STRING[--with-gflags=GFLAGS_DIR],
+- GFLAGS_CFLAGS="-I${with_gflags}/include"
+- GFLAGS_LIBS="-L${with_gflags}/lib -lgflags"
+- CFLAGS="$CFLAGS $GFLAGS_CFLAGS"
+- LIBS="$LIBS $GFLAGS_LIBS"
+-)
+-AC_CHECK_LIB(gflags, main, ac_cv_have_libgflags=1, ac_cv_have_libgflags=0)
+-if test x"$ac_cv_have_libgflags" = x"1"; then
+- AC_DEFINE(HAVE_LIB_GFLAGS, 1, [define if you have google gflags library])
+- if test x"$GFLAGS_LIBS" = x""; then
+- GFLAGS_LIBS="-lgflags"
+- fi
+-else
+- GFLAGS_CFLAGS=
+- GFLAGS_LIBS=
+-fi
+-CFLAGS="$SAVE_CFLAGS"
+-LIBS="$SAVE_LIBS"
++AC_ARG_ENABLE([gflags],
++ AS_HELP_STRING([--enable-gflags], [Enable google-gflags]))
++
++ac_cv_have_libgflags=0
++AS_IF([test "x$enable_gflags" != "xno"], [
++ SAVE_CFLAGS="$CFLAGS"
++ SAVE_LIBS="$LIBS"
++ AC_ARG_WITH([gflags], AS_HELP_STRING([--with-gflags=GFLAGS_DIR]),[
++ GFLAGS_CFLAGS="-I${with_gflags}/include"
++ GFLAGS_LIBS="-L${with_gflags}/lib -lgflags"
++ CFLAGS="$CFLAGS $GFLAGS_CFLAGS"
++ LIBS="$LIBS $GFLAGS_LIBS"
++ ])
++
++ AC_CHECK_LIB(gflags, main, ac_cv_have_libgflags=1, ac_cv_have_libgflags=0)
++ CFLAGS="$SAVE_CFLAGS"
++ LIBS="$SAVE_LIBS"
++])
++
++AS_IF([test "x$ac_cv_have_libgflags" = "x1"], [
++ AC_DEFINE([HAVE_LIB_GFLAGS], [1], [define if you have google gflags library])
++ AS_IF([test "x$GFLAGS_LIBS" = "x"], [
++ GFLAGS_LIBS="-lgflags"
++ ])
++], [
++ GFLAGS_CFLAGS=
++ GFLAGS_LIBS=
++])
+
+ # TODO(hamaji): Use official m4 macros provided by testing libraries
+ # once the m4 macro of Google Mocking becomes ready.
+ # Check if there is Google Test library installed.
+-AC_CHECK_PROG(GTEST_CONFIG, gtest-config, "yes")
+-AC_CHECK_LIB(gtest, main, have_gtest_lib="yes")
++AC_ARG_ENABLE([gtest-config],
++ AS_HELP_STRING([--enable-gtest-config], [Enable looking for gtest-config]))
++
++AS_IF([test "x$enable_gtest_config" != "xno"], [
++ AC_CHECK_PROG(GTEST_CONFIG, gtest-config, "yes")
++ AC_CHECK_LIB(gtest, main, have_gtest_lib="yes")
++], [
++ have_gtest_lib="no"
++])
++
+ if test x"$GTEST_CONFIG" = "xyes" -a x"$have_gtest_lib" = "xyes"; then
+ GTEST_CFLAGS=`gtest-config --cppflags --cxxflags`
+ GTEST_LIBS=`gtest-config --ldflags --libs`
+@@ -178,17 +194,13 @@
+ AM_CONDITIONAL(HAVE_GMOCK, test x"$GMOCK_CONFIG" = "xyes")
+
+ # We want to link in libunwind if it exists
+-UNWIND_LIBS=
+-# Unfortunately, we need to check the header file in addition to the
+-# lib file to check if libunwind is available since libunwind-0.98
+-# doesn't install all necessary header files.
+-if test x"$ac_cv_have_libunwind_h" = x"1"; then
+- AC_CHECK_LIB(unwind, backtrace, UNWIND_LIBS=-lunwind)
+-fi
+-AC_SUBST(UNWIND_LIBS)
+-if test x"$UNWIND_LIBS" != x""; then
+- AC_DEFINE(HAVE_LIB_UNWIND, 1, [define if you have libunwind])
+-fi
++AC_ARG_ENABLE([unwind],
++ AS_HELP_STRING([--enable-unwind], [Enable libunwind]))
++
++AS_IF([test "x$enable_unwind" != "xno"], [
++ PKG_CHECK_MODULES([UNWIND], [libunwind > 0.98])
++ AC_DEFINE([HAVE_LIB_UNWIND], [1], [define if you have libunwind])
++])
+
+ # We'd like to use read/write locks in several places in the code.
+ # See if our pthreads support extends to that. Note: for linux, it
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -40,12 +40,11 @@
+ nodist_gloginclude_HEADERS = src/glog/logging.h src/glog/raw_logging.h src/glog/vlog_is_on.h src/glog/stl_logging.h
+ noinst_HEADERS = src/glog/logging.h.in src/glog/raw_logging.h.in src/glog/vlog_is_on.h.in src/glog/stl_logging.h.in
+
+-docdir = $(prefix)/share/doc/$(PACKAGE)-$(VERSION)
+ ## This is for HTML and other documentation you want to install.
+ ## Add your documentation files (in doc/) in addition to these
+ ## top-level boilerplate files. Also add a TODO file if you have one.
+-dist_doc_DATA = AUTHORS COPYING ChangeLog INSTALL NEWS README README.windows \
+- doc/designstyle.css doc/glog.html
++dist_doc_DATA = AUTHORS ChangeLog INSTALL NEWS README
++dist_html_DATA = doc/designstyle.css doc/glog.html
+
+ ## The libraries (.so's) you want to install
+ lib_LTLIBRARIES =
+@@ -215,7 +214,7 @@
+
+ ## This should always include $(TESTS), but may also include other
+ ## binaries that you compile but don't want automatically installed.
+-noinst_PROGRAMS = $(TESTS) $(TEST_BINARIES)
++check_PROGRAMS = $(TESTS) $(TEST_BINARIES)
+
+ rpm: dist-gzip packages/rpm.sh packages/rpm/rpm.spec
+ @cd packages && ./rpm.sh ${PACKAGE} ${VERSION}
diff --git a/dev-cpp/glog/files/glog-0.3.4-fix-gcc5-demangling.patch b/dev-cpp/glog/files/glog-0.3.4-fix-gcc5-demangling.patch
new file mode 100644
index 00000000..fd1518c
--- /dev/null
+++ b/dev-cpp/glog/files/glog-0.3.4-fix-gcc5-demangling.patch
@@ -0,0 +1,56 @@
+From b1639e3014996fbc7635870e013559c54e7e3b2f Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?David=20Mart=C3=ADnez=20Moreno?= <ender@debian.org>
+Date: Thu, 13 Aug 2015 09:31:26 -0700
+Subject: [PATCH] Fix ABI demangling for the GCC 5.x case.
+
+When glog is compiled with gcc-5.2 in cxx11 ABI mode, it barfs about unmangled symbols. This patches it getting inspiration from binutils and demangle.cc itself, although it may be totally wrong or maybe have to use ParseAbiTag in more places. I haven't read the spec for the symbols, though.
+
+This patch makes the demangle unit test pass correctly.
+---
+ src/demangle.cc | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
+
+diff --git a/src/demangle.cc b/src/demangle.cc
+index e858181..0f0c831 100644
+--- a/src/demangle.cc
++++ b/src/demangle.cc
+@@ -439,6 +439,7 @@ static bool ParseExprPrimary(State *state);
+ static bool ParseLocalName(State *state);
+ static bool ParseDiscriminator(State *state);
+ static bool ParseSubstitution(State *state);
++static bool ParseAbiTag(State *state);
+
+ // Implementation note: the following code is a straightforward
+ // translation of the Itanium C++ ABI defined in BNF with a couple of
+@@ -567,6 +568,8 @@ static bool ParseNestedName(State *state) {
+ static bool ParsePrefix(State *state) {
+ bool has_something = false;
+ while (true) {
++ if (ParseAbiTag(state))
++ continue;
+ MaybeAppendSeparator(state);
+ if (ParseTemplateParam(state) ||
+ ParseSubstitution(state) ||
+@@ -585,6 +588,22 @@ static bool ParsePrefix(State *state) {
+ return true;
+ }
+
++// <abi-tag> ::= B <source-name>
++static bool ParseAbiTag(State *state) {
++ State copy = *state;
++
++ Append(state, "[", 1);
++ if (ParseOneCharToken(state, 'B') &&
++ ParseSourceName(state))
++ {
++ Append(state, "]", 1);
++ return true;
++ }
++
++ *state = copy;
++ return false;
++}
++
+ // <unqualified-name> ::= <operator-name>
+ // ::= <ctor-dtor-name>
+ // ::= <source-name>
diff --git a/dev-cpp/glog/glog-0.3.4-r1.ebuild b/dev-cpp/glog/glog-0.3.4-r1.ebuild
new file mode 100644
index 00000000..5f87cea
--- /dev/null
+++ b/dev-cpp/glog/glog-0.3.4-r1.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit autotools multilib-minimal
+
+DESCRIPTION="Google's C++ logging library"
+HOMEPAGE="https://github.com/google/glog"
+SRC_URI="https://github.com/google/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="gflags static-libs test unwind"
+
+RDEPEND="
+ gflags? ( >=dev-cpp/gflags-2.0-r1[${MULTILIB_USEDEP}] )
+ unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )"
+DEPEND="${RDEPEND}
+ test? (
+ >=dev-cpp/gmock-1.7.0-r1[${MULTILIB_USEDEP}]
+ >=dev-cpp/gtest-1.6.0-r2[${MULTILIB_USEDEP}]
+ )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.3.2-avoid-inline-asm.patch
+ "${FILESDIR}"/${PN}-0.3.4-fix-build-system.patch
+ "${FILESDIR}"/${PN}-0.3.4-fix-gcc5-demangling.patch
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE="${S}" econf \
+ $(use_enable gflags) \
+ $(use_enable static-libs static) \
+ $(use_enable test gtest-config) \
+ $(use_enable unwind)
+}
+
+multilib_src_install_all() {
+ einstalldocs
+
+ # package provides .pc files
+ find "${D}" -name '*.la' -delete || die
+}
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/glog/files/, dev-cpp/glog/
@ 2019-08-11 15:57 Thomas Deutschmann
0 siblings, 0 replies; 3+ messages in thread
From: Thomas Deutschmann @ 2019-08-11 15:57 UTC (permalink / raw
To: gentoo-commits
commit: 928b17486c5c731485befc769175476ee877c6fb
Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Sun Aug 11 15:56:55 2019 +0000
Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Sun Aug 11 15:57:18 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=928b1748
dev-cpp/glog: bump to v0.4.0
Closes: https://bugs.gentoo.org/682622
Package-Manager: Portage-2.3.71, Repoman-2.3.17
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>
dev-cpp/glog/Manifest | 1 +
dev-cpp/glog/files/glog-0.4.0-errnos.patch | 99 ++++++++++++++++++++++
.../glog/files/glog-0.4.0-fix-test-on-ports.patch | 19 +++++
dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch | 35 ++++++++
dev-cpp/glog/glog-0.4.0.ebuild | 43 ++++++++++
5 files changed, 197 insertions(+)
diff --git a/dev-cpp/glog/Manifest b/dev-cpp/glog/Manifest
index 605c93ac9ab..76e694662c0 100644
--- a/dev-cpp/glog/Manifest
+++ b/dev-cpp/glog/Manifest
@@ -1,3 +1,4 @@
DIST glog-0.3.3.tar.gz 509676 BLAKE2B 21d8893ff535c0e8c1de27214f535aaea99727128d80f421da096969c19504da6a296054db2931232b4fd372446f96189464e4000f44c5720152085aa9976978 SHA512 95418ff0857415a0fbc15caeb22a13f3b6736618adcc3c30e054626f1397bc58399c45f68784c70b1f5dc594ebc6ea66e386896beab5c20be72dd53b25f5a4ac
DIST glog-0.3.4.tar.gz 522508 BLAKE2B 4a188d5998005b29afc52f2ea548f33e06a68da993bb74960e5aedb214ec52ef9e9fc39efb1a34f38f217b92df7db064ff01d58df36c3e4ad789becc97335ec2 SHA512 139525b546a9eccacc9bebf7cc3053ba52229e9488485ad45344c3d3134ca819d3b571250c0e3a6d84097009c8be89b0f4fa16ef5ec838ffcc237ae11c3a034c
DIST glog-0.3.5.tar.gz 532275 BLAKE2B a455f3ff8fc7cf2861a4351a0305db9455bb79977e57c49b6269b3fa2c147cd9627bfaf4c7aaa04fe4a49158d79abeb5b985813fe8c473d6005e915335c0d693 SHA512 a54a3b8b4b7660d7558ba5168c659bc3c8323c30908a4f6a4bbc6f9cd899350f3243aabc720daebfdeb799b276b51ba1eaa1a0f83149c4e1a038d552ada1ed72
+DIST glog-0.4.0.tar.gz 200955 BLAKE2B 083da6117af3e85697724942bfcb5a7831d447666945b06b149d8d324231b10923887bd8c507e8027136d12bffd30a657cb225df8c449f234381e3876f132953 SHA512 b585f1819ade2075f6b61dc5aaca5c3f9d25601dba2bd08b6c49b96ac5f79db23c6b7f2042df003f7130497dd7241fcaa8b107d1f97385cb66ce52d3c554b176
diff --git a/dev-cpp/glog/files/glog-0.4.0-errnos.patch b/dev-cpp/glog/files/glog-0.4.0-errnos.patch
new file mode 100644
index 00000000000..c55716db1ba
--- /dev/null
+++ b/dev-cpp/glog/files/glog-0.4.0-errnos.patch
@@ -0,0 +1,99 @@
+Index: b/src/googletest.h
+===================================================================
+--- a/src/googletest.h
++++ b/src/googletest.h
+@@ -437,6 +437,18 @@ static inline void StringReplace(string*
+ }
+ }
+
++static inline void IntReplace(string* str,
++ const string& oldsub,
++ int newsub) {
++ size_t pos = str->find(oldsub);
++ if (pos != string::npos) {
++ std::ostringstream ss;
++ ss << newsub;
++ const std::string x = ss.str();
++ str->replace(pos, oldsub.size(), x.c_str());
++ }
++}
++
+ static inline string Munge(const string& filename) {
+ FILE* fp = fopen(filename.c_str(), "rb");
+ CHECK(fp != NULL) << filename << ": couldn't open";
+@@ -452,9 +464,13 @@ static inline string Munge(const string&
+
+ StringReplace(&line, "__SUCCESS__", StrError(0));
+ StringReplace(&line, "__ENOENT__", StrError(ENOENT));
++ IntReplace(&line, "__ENOENT_NUM__", ENOENT);
+ StringReplace(&line, "__EINTR__", StrError(EINTR));
++ IntReplace(&line, "__EINTR_NUM__", EINTR);
+ StringReplace(&line, "__ENXIO__", StrError(ENXIO));
++ IntReplace(&line, "__ENXIO_NUM__", ENXIO);
+ StringReplace(&line, "__ENOEXEC__", StrError(ENOEXEC));
++ IntReplace(&line, "__ENOEXEC_NUM__", ENOEXEC);
+ result += line + "\n";
+ }
+ fclose(fp);
+Index: b/src/logging_unittest.cc
+===================================================================
+--- a/src/logging_unittest.cc
++++ b/src/logging_unittest.cc
+@@ -238,6 +238,17 @@ int main(int argc, char **argv) {
+ return 0;
+ }
+
++static int errnoForIteration(int i) {
++ switch (i) {
++ case 0: return 0;
++ case 2: return ENOENT;
++ case 4: return EINTR;
++ case 6: return ENXIO;
++ case 8: return ENOEXEC;
++ }
++ return -1;
++}
++
+ void TestLogging(bool check_counts) {
+ int64 base_num_infos = LogMessage::num_messages(GLOG_INFO);
+ int64 base_num_warning = LogMessage::num_messages(GLOG_WARNING);
+@@ -246,7 +257,7 @@ void TestLogging(bool check_counts) {
+ LOG(INFO) << string("foo ") << "bar " << 10 << ' ' << 3.4;
+ for ( int i = 0; i < 10; ++i ) {
+ int old_errno = errno;
+- errno = i;
++ errno = errnoForIteration(i);
+ PLOG_EVERY_N(ERROR, 2) << "Plog every 2, iteration " << COUNTER;
+ errno = old_errno;
+
+Index: b/src/logging_unittest.err
+===================================================================
+--- a/src/logging_unittest.err
++++ b/src/logging_unittest.err
+@@ -51,21 +51,21 @@ WDATE TIME__ THREADID logging_unittest.c
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 1
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log if less than 3 every 2, iteration 1
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 2
+-EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 3: __ENOENT__ [2]
++EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 3: __ENOENT__ [__ENOENT_NUM__]
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 3
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log if less than 3 every 2, iteration 3
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 4
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 4
+-EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 5: __EINTR__ [4]
++EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 5: __EINTR__ [__EINTR_NUM__]
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 4, iteration 5
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 5
+ WDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 5, iteration 6
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 6
+-EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 7: __ENXIO__ [6]
++EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 7: __ENXIO__ [__ENXIO_NUM__]
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 7
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 7
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 8
+-EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 9: __ENOEXEC__ [8]
++EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 9: __ENOEXEC__ [__ENOEXEC_NUM__]
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 4, iteration 9
+ IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 9
+ EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 10
+
diff --git a/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch b/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch
new file mode 100644
index 00000000000..392ae8ca781
--- /dev/null
+++ b/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch
@@ -0,0 +1,19 @@
+Index: google-glog-0.3.2/src/signalhandler_unittest.sh
+===================================================================
+--- google-glog-0.3.2.orig/src/signalhandler_unittest.sh 2013-03-13 13:49:37.820188111 -0400
++++ google-glog-0.3.2/src/signalhandler_unittest.sh 2013-03-13 14:07:11.980204520 -0400
+@@ -65,10 +65,10 @@
+ exit 0
+ fi
+
+-# The PC cannot be obtained in signal handlers on PowerPC correctly.
+-# We just skip the test for PowerPC.
+-if [ x`uname -p` = x"powerpc" ]; then
+- echo "PASS (We don't test the signal handler on PowerPC.)"
++# This test only works correctly on i386 and amd64.
++# We just skip the test when not on those platforms.
++if [ x`uname -m` != x"x86_64" -a x`uname -m` != x"i686" ]; then
++ echo "PASS (We only test the signal handler on i386 or amd64.)"
+ exit 0
+ fi
+
diff --git a/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch b/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch
new file mode 100644
index 00000000000..e53318ac66f
--- /dev/null
+++ b/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch
@@ -0,0 +1,35 @@
+Description: fix FTBFS on x32
+Author: Guillaume Morin <guillaume@morinfr.org>
+Forwarded: no
+Last-Update: 2019-08-05
+
+---
+
+--- google-glog-0.3.4.orig/src/symbolize_unittest.cc
++++ google-glog-0.3.4/src/symbolize_unittest.cc
+@@ -313,8 +313,12 @@ extern "C" {
+ inline void* always_inline inline_func() {
+ void *pc = NULL;
+ #ifdef TEST_X86_32_AND_64
++#if __x86_64__ || (__x86_64__ && __ILP32__)
++ __asm__ __volatile__("call 1f; 1: popq %q0" : "=r"(pc));
++#else
+ __asm__ __volatile__("call 1f; 1: pop %0" : "=r"(pc));
+ #endif
++#endif
+ return pc;
+ }
+
+@@ -322,8 +326,12 @@ void* ATTRIBUTE_NOINLINE non_inline_func
+ void* ATTRIBUTE_NOINLINE non_inline_func() {
+ void *pc = NULL;
+ #ifdef TEST_X86_32_AND_64
++#if __x86_64__ || (__x86_64__ && __ILP32__)
++ __asm__ __volatile__("call 1f; 1: popq %q0" : "=r"(pc));
++#else
+ __asm__ __volatile__("call 1f; 1: pop %0" : "=r"(pc));
+ #endif
++#endif
+ return pc;
+ }
+
diff --git a/dev-cpp/glog/glog-0.4.0.ebuild b/dev-cpp/glog/glog-0.4.0.ebuild
new file mode 100644
index 00000000000..c5097b33e78
--- /dev/null
+++ b/dev-cpp/glog/glog-0.4.0.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+inherit autotools multilib-minimal
+
+DESCRIPTION="Google's C++ logging library"
+HOMEPAGE="https://github.com/google/glog"
+SRC_URI="https://github.com/google/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="static-libs test"
+RESTRICT="test"
+
+RDEPENDS="sys-libs/libunwind[${MULTILIB_USEDEP}]"
+DEPEND="${RDEPEND}
+ test? ( >=dev-cpp/gtest-1.8.0[${MULTILIB_USEDEP}] )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.4.0-fix-x32-build.patch
+ "${FILESDIR}"/${PN}-0.4.0-errnos.patch
+ "${FILESDIR}"/${PN}-0.4.0-fix-test-on-ports.patch
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE="${S}" econf \
+ $(use_enable static-libs static)
+}
+
+multilib_src_install_all() {
+ einstalldocs
+
+ # package provides .pc files
+ find "${D}" -name '*.la' -delete || die
+}
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/glog/files/, dev-cpp/glog/
@ 2024-06-09 18:54 Matt Turner
0 siblings, 0 replies; 3+ messages in thread
From: Matt Turner @ 2024-06-09 18:54 UTC (permalink / raw
To: gentoo-commits
commit: 9f9389f384e8db5558abcecd343742f67480817f
Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Sun Jun 9 18:47:52 2024 +0000
Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Sun Jun 9 18:54:37 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9f9389f3
dev-cpp/glog: Drop old versions
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
dev-cpp/glog/Manifest | 1 -
dev-cpp/glog/files/glog-0.4.0-errnos.patch | 99 ----------------------
.../glog/files/glog-0.4.0-fix-test-on-ports.patch | 19 -----
dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch | 35 --------
dev-cpp/glog/glog-0.4.0.ebuild | 46 ----------
5 files changed, 200 deletions(-)
diff --git a/dev-cpp/glog/Manifest b/dev-cpp/glog/Manifest
index 30b5047877a8..27d44dcf6c41 100644
--- a/dev-cpp/glog/Manifest
+++ b/dev-cpp/glog/Manifest
@@ -1,3 +1,2 @@
-DIST glog-0.4.0.tar.gz 200955 BLAKE2B 083da6117af3e85697724942bfcb5a7831d447666945b06b149d8d324231b10923887bd8c507e8027136d12bffd30a657cb225df8c449f234381e3876f132953 SHA512 b585f1819ade2075f6b61dc5aaca5c3f9d25601dba2bd08b6c49b96ac5f79db23c6b7f2042df003f7130497dd7241fcaa8b107d1f97385cb66ce52d3c554b176
DIST glog-0.5.0.tar.gz 183346 BLAKE2B 9109a9a4bd3c74ba5d4c1d9ed44ffe0e16d5d3b9b12bf9dd5d31c6e728292ea50f39b4e1b96d55fbb35653a448af4dc8a978e266a2b0f34261c5108099e90845 SHA512 445e4338f3d81cd0b065f2da9c6ce343c243263ca144cea424ef97531a4e9e09c06ffd6942ac01c5213a8003c75cfbbede3c4028d12f0134f23ff29314769c1a
DIST glog-0.6.0.tar.gz 193267 BLAKE2B b42112cdfd54280ce7a9592c3af6b6e10dcb854fe9dbe0db7445c60801d1c12a240c4b3709b45e41aedeb8876d2e08fc3368296e088be6a66126858888cc274e SHA512 fd2c42583d0dd72c790a8cf888f328a64447c5fb9d99b2e2a3833d70c102cb0eb9ae874632c2732424cc86216c8a076a3e24b23a793eaddb5da8a1dc52ba9226
diff --git a/dev-cpp/glog/files/glog-0.4.0-errnos.patch b/dev-cpp/glog/files/glog-0.4.0-errnos.patch
deleted file mode 100644
index c55716db1ba2..000000000000
--- a/dev-cpp/glog/files/glog-0.4.0-errnos.patch
+++ /dev/null
@@ -1,99 +0,0 @@
-Index: b/src/googletest.h
-===================================================================
---- a/src/googletest.h
-+++ b/src/googletest.h
-@@ -437,6 +437,18 @@ static inline void StringReplace(string*
- }
- }
-
-+static inline void IntReplace(string* str,
-+ const string& oldsub,
-+ int newsub) {
-+ size_t pos = str->find(oldsub);
-+ if (pos != string::npos) {
-+ std::ostringstream ss;
-+ ss << newsub;
-+ const std::string x = ss.str();
-+ str->replace(pos, oldsub.size(), x.c_str());
-+ }
-+}
-+
- static inline string Munge(const string& filename) {
- FILE* fp = fopen(filename.c_str(), "rb");
- CHECK(fp != NULL) << filename << ": couldn't open";
-@@ -452,9 +464,13 @@ static inline string Munge(const string&
-
- StringReplace(&line, "__SUCCESS__", StrError(0));
- StringReplace(&line, "__ENOENT__", StrError(ENOENT));
-+ IntReplace(&line, "__ENOENT_NUM__", ENOENT);
- StringReplace(&line, "__EINTR__", StrError(EINTR));
-+ IntReplace(&line, "__EINTR_NUM__", EINTR);
- StringReplace(&line, "__ENXIO__", StrError(ENXIO));
-+ IntReplace(&line, "__ENXIO_NUM__", ENXIO);
- StringReplace(&line, "__ENOEXEC__", StrError(ENOEXEC));
-+ IntReplace(&line, "__ENOEXEC_NUM__", ENOEXEC);
- result += line + "\n";
- }
- fclose(fp);
-Index: b/src/logging_unittest.cc
-===================================================================
---- a/src/logging_unittest.cc
-+++ b/src/logging_unittest.cc
-@@ -238,6 +238,17 @@ int main(int argc, char **argv) {
- return 0;
- }
-
-+static int errnoForIteration(int i) {
-+ switch (i) {
-+ case 0: return 0;
-+ case 2: return ENOENT;
-+ case 4: return EINTR;
-+ case 6: return ENXIO;
-+ case 8: return ENOEXEC;
-+ }
-+ return -1;
-+}
-+
- void TestLogging(bool check_counts) {
- int64 base_num_infos = LogMessage::num_messages(GLOG_INFO);
- int64 base_num_warning = LogMessage::num_messages(GLOG_WARNING);
-@@ -246,7 +257,7 @@ void TestLogging(bool check_counts) {
- LOG(INFO) << string("foo ") << "bar " << 10 << ' ' << 3.4;
- for ( int i = 0; i < 10; ++i ) {
- int old_errno = errno;
-- errno = i;
-+ errno = errnoForIteration(i);
- PLOG_EVERY_N(ERROR, 2) << "Plog every 2, iteration " << COUNTER;
- errno = old_errno;
-
-Index: b/src/logging_unittest.err
-===================================================================
---- a/src/logging_unittest.err
-+++ b/src/logging_unittest.err
-@@ -51,21 +51,21 @@ WDATE TIME__ THREADID logging_unittest.c
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 1
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log if less than 3 every 2, iteration 1
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 2
--EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 3: __ENOENT__ [2]
-+EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 3: __ENOENT__ [__ENOENT_NUM__]
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 3
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log if less than 3 every 2, iteration 3
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 4
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 4
--EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 5: __EINTR__ [4]
-+EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 5: __EINTR__ [__EINTR_NUM__]
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 4, iteration 5
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 5
- WDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 5, iteration 6
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 6
--EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 7: __ENXIO__ [6]
-+EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 7: __ENXIO__ [__ENXIO_NUM__]
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 7
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 7
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 8
--EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 9: __ENOEXEC__ [8]
-+EDATE TIME__ THREADID logging_unittest.cc:LINE] Plog every 2, iteration 9: __ENOEXEC__ [__ENOEXEC_NUM__]
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 4, iteration 9
- IDATE TIME__ THREADID logging_unittest.cc:LINE] Log if every 1, iteration 9
- EDATE TIME__ THREADID logging_unittest.cc:LINE] Log every 3, iteration 10
-
diff --git a/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch b/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch
deleted file mode 100644
index 392ae8ca7819..000000000000
--- a/dev-cpp/glog/files/glog-0.4.0-fix-test-on-ports.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Index: google-glog-0.3.2/src/signalhandler_unittest.sh
-===================================================================
---- google-glog-0.3.2.orig/src/signalhandler_unittest.sh 2013-03-13 13:49:37.820188111 -0400
-+++ google-glog-0.3.2/src/signalhandler_unittest.sh 2013-03-13 14:07:11.980204520 -0400
-@@ -65,10 +65,10 @@
- exit 0
- fi
-
--# The PC cannot be obtained in signal handlers on PowerPC correctly.
--# We just skip the test for PowerPC.
--if [ x`uname -p` = x"powerpc" ]; then
-- echo "PASS (We don't test the signal handler on PowerPC.)"
-+# This test only works correctly on i386 and amd64.
-+# We just skip the test when not on those platforms.
-+if [ x`uname -m` != x"x86_64" -a x`uname -m` != x"i686" ]; then
-+ echo "PASS (We only test the signal handler on i386 or amd64.)"
- exit 0
- fi
-
diff --git a/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch b/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch
deleted file mode 100644
index e53318ac66ff..000000000000
--- a/dev-cpp/glog/files/glog-0.4.0-fix-x32-build.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Description: fix FTBFS on x32
-Author: Guillaume Morin <guillaume@morinfr.org>
-Forwarded: no
-Last-Update: 2019-08-05
-
----
-
---- google-glog-0.3.4.orig/src/symbolize_unittest.cc
-+++ google-glog-0.3.4/src/symbolize_unittest.cc
-@@ -313,8 +313,12 @@ extern "C" {
- inline void* always_inline inline_func() {
- void *pc = NULL;
- #ifdef TEST_X86_32_AND_64
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ __asm__ __volatile__("call 1f; 1: popq %q0" : "=r"(pc));
-+#else
- __asm__ __volatile__("call 1f; 1: pop %0" : "=r"(pc));
- #endif
-+#endif
- return pc;
- }
-
-@@ -322,8 +326,12 @@ void* ATTRIBUTE_NOINLINE non_inline_func
- void* ATTRIBUTE_NOINLINE non_inline_func() {
- void *pc = NULL;
- #ifdef TEST_X86_32_AND_64
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ __asm__ __volatile__("call 1f; 1: popq %q0" : "=r"(pc));
-+#else
- __asm__ __volatile__("call 1f; 1: pop %0" : "=r"(pc));
- #endif
-+#endif
- return pc;
- }
-
diff --git a/dev-cpp/glog/glog-0.4.0.ebuild b/dev-cpp/glog/glog-0.4.0.ebuild
deleted file mode 100644
index 9b10f2e2fc95..000000000000
--- a/dev-cpp/glog/glog-0.4.0.ebuild
+++ /dev/null
@@ -1,46 +0,0 @@
-# Copyright 2011-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="7"
-
-inherit autotools multilib-minimal
-
-DESCRIPTION="Google's C++ logging library"
-HOMEPAGE="https://github.com/google/glog"
-SRC_URI="https://github.com/google/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-# -sparc as libunwind is not ported on sparc
-KEYWORDS="amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 -sparc x86 ~amd64-linux ~x86-linux"
-IUSE="gflags static-libs test"
-RESTRICT="test"
-
-RDEPEND="sys-libs/libunwind[${MULTILIB_USEDEP}]
- gflags? ( dev-cpp/gflags[${MULTILIB_USEDEP}] )"
-DEPEND="${RDEPEND}
- test? ( >=dev-cpp/gtest-1.8.0[${MULTILIB_USEDEP}] )"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-0.4.0-fix-x32-build.patch
- "${FILESDIR}"/${PN}-0.4.0-errnos.patch
- "${FILESDIR}"/${PN}-0.4.0-fix-test-on-ports.patch
-)
-
-src_prepare() {
- default
- eautoreconf
-}
-
-multilib_src_configure() {
- ECONF_SOURCE="${S}" econf \
- $(use_enable static-libs static) \
- ac_cv_lib_gflags_main="$(usex gflags)"
-}
-
-multilib_src_install_all() {
- einstalldocs
-
- # package provides .pc files
- find "${D}" -name '*.la' -delete || die
-}
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-06-09 18:54 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-09 18:54 [gentoo-commits] repo/gentoo:master commit in: dev-cpp/glog/files/, dev-cpp/glog/ Matt Turner
-- strict thread matches above, loose matches on Subject: below --
2019-08-11 15:57 Thomas Deutschmann
2017-01-22 18:30 David Seifert
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox