Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 788046 - dev-libs/xapian-1.4.17 fails to compile with gcc-11: " 'numeric_limits' is not a member of 'std'"
Summary: dev-libs/xapian-1.4.17 fails to compile with gcc-11: " 'numeric_limits' is no...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Anthony Basile
Keywords: PATCH
Depends on: 790266
Blocks: gcc-11
  Show dependency tree
Reported: 2021-05-03 23:21 UTC by Jack
Modified: 2021-06-14 22:11 UTC (History)
1 user (show)

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

build.log (xapian-build.log,596.44 KB, text/x-log)
2021-05-03 23:22 UTC, Jack
patch (xapian-fix-gcc11.patch,192 bytes, patch)
2021-05-03 23:24 UTC, Jack
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jack 2021-05-03 23:21:41 UTC
I'll attach full build log and patch, but emerge stops with

/var/tmp/portage/dev-libs/xapian-1.4.17/work/xapian-core-1.4.17/api/ error: 'numeric_limits' was not declared in this scope

adding "#include <limits>" to that file allows successful emerge.

Reproducible: Always
Comment 1 Jack 2021-05-03 23:22:47 UTC
Created attachment 705870 [details]
Comment 2 Jack 2021-05-03 23:24:03 UTC
Created attachment 705873 [details, diff]
Comment 3 Larry the Git Cow gentoo-dev 2021-06-14 22:11:37 UTC
The bug has been closed via the following commit(s):

commit d836910165befa9b9cf98d3258784711176d96b3
Author:     Sam James <>
AuthorDate: 2021-06-14 18:46:42 +0000
Commit:     Sam James <>
CommitDate: 2021-06-14 22:11:12 +0000

    dev-libs/xapian: fix build with GCC 11 in 1.4.17
    Note that 1.4.18 already seems to work but we may as well include the patch
    given somebody posted it.
    Signed-off-by: Sam James <>

 .../xapian/files/xapian-1.4.17-gcc11-missing-include.patch    | 11 +++++++++++
 dev-libs/xapian/xapian-1.4.17.ebuild                          |  4 ++++
 2 files changed, 15 insertions(+)