Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 835744 - dev-cpp/folly-2022.03.14.00 fails to compile: Elf.cpp:235:27: error: ELFCLASSFOLLY_ELF_NATIVE_CLASS was not declared in this scope
Summary: dev-cpp/folly-2022.03.14.00 fails to compile: Elf.cpp:235:27: error: ELFCLASS...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Sam James
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2022-03-21 16:16 UTC by Agostino Sarubbo
Modified: 2022-08-12 18:40 UTC (History)
0 users

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


Attachments
build.log (build.log,284.19 KB, text/plain)
2022-03-21 16:16 UTC, Agostino Sarubbo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2022-03-21 16:16:28 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-cpp/folly-2022.03.14.00 fails to compile.
Discovered on: amd64 (internal ref: tinderbox_musl)

NOTE:
This machine uses MUSL libc
Comment 1 Agostino Sarubbo gentoo-dev 2022-03-21 16:16:30 UTC
Created attachment 767518 [details]
build.log

build log and emerge --info
Comment 2 Agostino Sarubbo gentoo-dev 2022-03-21 16:16:31 UTC
Error(s) that match a know pattern in addition to what has been reported in the summary:


-- Could NOT find Backtrace (missing: Backtrace_LIBRARY Backtrace_INCLUDE_DIR) 
-- Could NOT find LIBDWARF (missing: LIBDWARF_LIBRARY) 
FAILED: CMakeFiles/folly_base.dir/folly/experimental/symbolizer/Elf.cpp.o 
/var/tmp/portage/dev-cpp/folly-2022.03.14.00/work/folly-2022.03.14.00/folly/experimental/symbolizer/Elf.cpp:235:27: error: 'ELFCLASSFOLLY_ELF_NATIVE_CLASS' was not declared in this scope
Comment 3 Larry the Git Cow gentoo-dev 2022-08-12 18:40:37 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ad0d9de826a89b6ff0dec451e73bbeecd93e4a8

commit 4ad0d9de826a89b6ff0dec451e73bbeecd93e4a8
Author:     brahmajit das <listout@protonmail.com>
AuthorDate: 2022-08-10 10:37:58 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-08-12 18:39:43 +0000

    dev-cpp/folly: Fix musl build
    
    Fixes "ELFCLASSFOLLY_ELF_NATIVE_CLASS was not declared in this scope".
    
    Elf.cpp expects __ELF_NATIVE_CLASS to be defined at least for platforms
    besides FreeBSD-based ones, and so it defines FOLLY_ELF_NATIVE_CLASS
    with it. Without __ELF_NATIVE_CLASS (and apparently musl does not define
    it), FOLLY_ELF_NATIVE_CLASS is also not defined so what was supposed to
    be expanded to ELFCLASS32 or ELFCLASS64 ends up being
    ELFCLASSFOLLY_ELF_NATIVE_CLASS.
    
    Please refer: https://github.com/facebook/folly/issues/1478#issuecomment-719883898
    
    Closes: https://bugs.gentoo.org/835744
    Signed-off-by: brahmajit das <listout@protonmail.com>
    Closes: https://github.com/gentoo/gentoo/pull/26807
    Signed-off-by: Sam James <sam@gentoo.org>

 .../folly/files/folly-2022.07.04.00-musl-fix.patch | 36 ++++++++++++++++++++++
 dev-cpp/folly/folly-2022.07.04.00.ebuild           |  4 +++
 2 files changed, 40 insertions(+)