Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 625158 - dev-db/tokumx-2.0.2 : /.../collection_map.h:69:41: error: cannot convert const boost::shared_ptr<mongo::storage::Dictionary> to bool in return
Summary: dev-db/tokumx-2.0.2 : /.../collection_map.h:69:41: error: cannot convert con...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Tony Vroon (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-15 06:58 UTC by Toralf Förster
Modified: 2018-07-09 09:39 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,15.41 KB, text/plain)
2017-07-15 06:58 UTC, Toralf Förster
Details
dev-db:tokumx-2.0.2:20170715-061817.log.bz2 (dev-db:tokumx-2.0.2:20170715-061817.log.bz2,39.90 KB, application/x-bzip)
2017-07-15 06:58 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,156.56 KB, text/plain)
2017-07-15 06:58 UTC, Toralf Förster
Details
environment (environment,168.71 KB, text/plain)
2017-07-15 06:58 UTC, Toralf Förster
Details
etc.portage.tbz2 (etc.portage.tbz2,38.80 KB, application/x-bzip)
2017-07-15 06:58 UTC, Toralf Förster
Details
logs.tbz2 (logs.tbz2,23.53 KB, application/x-bzip)
2017-07-15 06:58 UTC, Toralf Förster
Details
temp.tbz2 (temp.tbz2,80.12 KB, application/x-bzip)
2017-07-15 06:59 UTC, Toralf Förster
Details
tokumx-2.0.2-gcc-7.patch (tokumx-2.0.2-gcc-7.patch,5.88 KB, patch)
2018-07-03 15:15 UTC, Tony Vroon (RETIRED)
Details | Diff
build.log.bz2 (build.log.bz2,111.36 KB, application/x-bzip)
2018-07-06 08:16 UTC, Tony Vroon (RETIRED)
Details
patch for 'undefined reference in libHotBackup.so' (tokumx-2.0.2-copier.cc.patch,1.51 KB, patch)
2018-07-06 11:50 UTC, Mariusz Ceier
Details | Diff
Fix for undefined reference in libHotBackup.so that also works with gcc-8.1.0 (tokumx-2.0.2-dont-use-fno-implicit-templates.patch,625 bytes, patch)
2018-07-06 19:18 UTC, Mariusz Ceier
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2017-07-15 06:58:38 UTC
                 from /var/tmp/portage/dev-db/tokumx-2.0.2/work/tokumx-enterprise-2.0.2/src/mongo/db/commands.cpp:37:
/var/tmp/portage/dev-db/tokumx-2.0.2/work/tokumx-enterprise-2.0.2/src/mongo/../mongo/db/collection_map.h: In member function ‘bool mongo::CollectionMap::allocated() const’:
/var/tmp/portage/dev-db/tokumx-2.0.2/work/tokumx-enterprise-2.0.2/src/mongo/../mongo/db/collection_map.h:69:41: error: cannot convert ‘const boost::shared_ptr<mongo::storage::Dictionary>’ to ‘bool’ in return
         bool allocated() const { return _metadb; }
                                         ^~~~~~~
In file included from /var/tmp/portage/dev-db/tokumx-2.0.2/work/tokumx-enterprise-2.0.2/src/mongo/../mongo/db/clientcursor.h:32:0,

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 13.0-systemd_20170711-225716

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-6.3.0 *

Available Python interpreters, in order of preference:
  [1]   python3.4
  [2]   python3.5 (fallback)
  [3]   python2.7 (fallback)
Available Ruby profiles:
  [1]   ruby21 (with Rubygems)
  [2]   ruby22 (with Rubygems) *
Comment 1 Toralf Förster gentoo-dev 2017-07-15 06:58:42 UTC
Created attachment 484688 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2017-07-15 06:58:45 UTC
Created attachment 484690 [details]
dev-db:tokumx-2.0.2:20170715-061817.log.bz2
Comment 3 Toralf Förster gentoo-dev 2017-07-15 06:58:48 UTC
Created attachment 484692 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2017-07-15 06:58:51 UTC
Created attachment 484694 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2017-07-15 06:58:55 UTC
Created attachment 484696 [details]
etc.portage.tbz2
Comment 6 Toralf Förster gentoo-dev 2017-07-15 06:58:58 UTC
Created attachment 484698 [details]
logs.tbz2
Comment 7 Toralf Förster gentoo-dev 2017-07-15 06:59:01 UTC
Created attachment 484700 [details]
temp.tbz2
Comment 8 Tony Vroon (RETIRED) gentoo-dev 2018-07-03 15:15:28 UTC
Created attachment 538162 [details, diff]
tokumx-2.0.2-gcc-7.patch

This addresses nearly all issues, but bails out with an undefined reference in libHotBackup.so
Comment 9 Tony Vroon (RETIRED) gentoo-dev 2018-07-06 08:16:22 UTC
Created attachment 538542 [details]
build.log.bz2

Linking failure with GCC 7 patch set applied.
Comment 10 Mariusz Ceier 2018-07-06 11:50:17 UTC
Created attachment 538544 [details, diff]
patch for 'undefined reference in libHotBackup.so'

The attached patch replaces all push_back(strdup(...)) statements with the use of additional temporary variable that stores the result of strdup(...).

This change causes undefined symbol to disapear from libHotBackup.so and makes build successful (at least on my system).

PS. afterthought, maybe just a cast to char* would be enough though.
Comment 11 Mariusz Ceier 2018-07-06 19:18:08 UTC
Created attachment 538646 [details, diff]
Fix for undefined reference in libHotBackup.so that also works with gcc-8.1.0

Previous patch works only with gcc-7 due to unintended consequence of -O3 optimization. It doesn't work without -O3 nor with gcc-8.1.0.

This patch removes -fno-implicit-templates from compiler arguments and doesn't touch source code. I have tested it with gcc-7.3.0 and gcc-8.1.0.

It seems that it was added only because mysql was also compiling with it (according to the comment in CMakeLists.txt).
Comment 12 Larry the Git Cow gentoo-dev 2018-07-09 08:59:31 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=80b554b3f8965c2bfaed570d3e17927164c4228b

commit 80b554b3f8965c2bfaed570d3e17927164c4228b
Author:     Tony Vroon <chainsaw@gentoo.org>
AuthorDate: 2018-07-06 12:20:06 +0000
Commit:     Tony Vroon <chainsaw@gentoo.org>
CommitDate: 2018-07-09 08:59:26 +0000

    dev-db/tokumx: GCC 7 build breakage fixes.
    
    Unresolved symbol issue at final link addressed by Mariusz Ceier.
    Implicit casts of smart pointers to boolean made explicit by me.
    No revision bump.
    
    Closes: https://bugs.gentoo.org/625158
    Package-Manager: Portage-2.3.40, Repoman-2.3.9

 dev-db/tokumx/files/tokumx-2.0.2-gcc-7.patch       | 102 +++++++++++++++++++++
 .../files/tokumx-2.0.2-undefined-reference.patch   |  47 ++++++++++
 dev-db/tokumx/tokumx-2.0.2.ebuild                  |   9 +-
 3 files changed, 155 insertions(+), 3 deletions(-)
Comment 13 Tony Vroon (RETIRED) gentoo-dev 2018-07-09 09:07:47 UTC
Noting updating patch; will have to do a 2.0.2-r1 now.
Comment 14 Larry the Git Cow gentoo-dev 2018-07-09 09:39:02 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=44dd9ff5bceb535331c9c5c4dee596e224f177d0

commit 44dd9ff5bceb535331c9c5c4dee596e224f177d0
Author:     Tony Vroon <chainsaw@gentoo.org>
AuthorDate: 2018-07-09 09:38:46 +0000
Commit:     Tony Vroon <chainsaw@gentoo.org>
CommitDate: 2018-07-09 09:38:58 +0000

    dev-db/tokumx: Updated patching to avoid GCC 8 final link failure.
    
    Updated patch by Mariusz Ceier to avoid final link failure on GCC 8.
    It also seems significantly cleaner. Removing 2.0.2 and bumping up
    revision.
    
    Closes: https://bugs.gentoo.org/625158
    Package-Manager: Portage-2.3.40, Repoman-2.3.9

 .../files/tokumx-2.0.2-undefined-reference.patch   | 60 +++++-----------------
 ...{tokumx-2.0.2.ebuild => tokumx-2.0.2-r1.ebuild} |  1 -
 2 files changed, 14 insertions(+), 47 deletions(-)