media/libcubeb/src/cubeb_log.cpp:76:17: undefined reference to `std::__1::__thread_struct::__thread_struct()'

RESOLVED FIXED in Firefox 55

Status

()

P3
normal
Rank:
35
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: jbeich, Assigned: jbeich)

Tracking

({regression})

Trunk
mozilla55
Unspecified
FreeBSD
regression
Points:
---

Firefox Tracking Flags

(firefox52 unaffected, firefox-esr52 unaffected, firefox53 unaffected, firefox54 unaffected, firefox55 fixed)

Details

MozReview Requests

()

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(1 attachment)

(Assignee)

Description

a year ago
$ c++ -v
FreeBSD clang version 4.0.0 (tags/RELEASE_400/final 297347) (based on LLVM 4.0.0)
Target: x86_64-unknown-freebsd12.0
Thread model: posix
InstalledDir: /usr/bin

$ cat /usr/include/c++/v1/__libcpp_version
4000

$ ./mach bootstrap
$ ./mach build
[...]
../../build/unix/gold/ld: error: objdir/toolkit/library/../../media/libcubeb/src/cubeb_log.o: requires dynamic R_X86_64_PC32 reloc against '_ZNSt3__115__thread_structC1Ev' which may overflow at runtime; recompile with -fPIC
../../build/unix/gold/ld: error: objdir/toolkit/library/../../media/libcubeb/src/cubeb_log.o: requires dynamic R_X86_64_PC32 reloc against '_ZNSt3__115__thread_structD1Ev' which may overflow at runtime; recompile with -fPIC
../../build/unix/gold/ld: error: read-only segment has dynamic relocations
../../build/unix/gold/ld: error: hidden symbol '_ZNSt3__115__thread_structC1Ev' is not defined locally
../../build/unix/gold/ld: error: hidden symbol '_ZNSt3__16thread6detachEv' is not defined locally
../../build/unix/gold/ld: error: hidden symbol '_ZNSt3__16threadD1Ev' is not defined locally
../../build/unix/gold/ld: error: hidden symbol '_ZNSt3__115__thread_structD1Ev' is not defined locally
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
[...]
/usr/bin/ld.lld: error: /usr/include/c++/v1/thread:356: can't create dynamic relocation R_X86_64_PC32 against symbol 'std::__1::__thread_struct::__thread_struct()' defined in /usr/lib/libc++.so.1
/usr/bin/ld.lld: error: media/libcubeb/src/cubeb_log.cpp:96: can't create dynamic relocation R_X86_64_PC32 against symbol 'std::__1::thread::detach()' defined in /usr/lib/libc++.so.1
/usr/bin/ld.lld: error: media/libcubeb/src/cubeb_log.cpp:76: can't create dynamic relocation R_X86_64_PC32 against symbol 'std::__1::thread::~thread()' defined in /usr/lib/libc++.so.1
/usr/bin/ld.lld: error: /usr/include/c++/v1/memory:2397: can't create dynamic relocation R_X86_64_PC32 against symbol 'std::__1::__thread_struct::~__thread_struct()' defined in /usr/lib/libc++.so.1
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
[...]
../../media/libcubeb/src/cubeb_log.o: In function `thread<(lambda at media/libcubeb/src/cubeb_log.cpp:76:17), void>':
/usr/include/c++/v1/thread:356: undefined reference to `std::__1::__thread_struct::__thread_struct()'
../../media/libcubeb/src/cubeb_log.o: In function `cubeb_async_logger::run()':
media/libcubeb/src/cubeb_log.cpp:96: undefined reference to `std::__1::thread::detach()'
media/libcubeb/src/cubeb_log.cpp:76: undefined reference to `std::__1::thread::~thread()'
../../media/libcubeb/src/cubeb_log.o: In function `std::__1::default_delete<std::__1::__thread_struct>::operator()(std::__1::__thread_struct*) const':
/usr/include/c++/v1/memory:2397: undefined reference to `std::__1::__thread_struct::~__thread_struct()'
/usr/bin/ld.bfd: libxul.so: hidden symbol `_ZNSt3__16threadD1Ev' isn't defined
/usr/bin/ld.bfd: final link failed: Bad value
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
Comment hidden (mozreview-request)
Comment hidden (mozreview-request)

Comment 3

a year ago
mozreview-review
Comment on attachment 8848175 [details]
Bug 1348021 - Unbreak config/gcc_hidden.h build with libc++ after bug 1341238.

https://reviewboard.mozilla.org/r/121124/#review123450

You want to add this header to `config/stl-headers` instead.  Please try that and retest.
Attachment #8848175 - Flags: review?(nfroyd) → review-
(Assignee)

Comment 4

a year ago
mozreview-review-reply
Comment on attachment 8848175 [details]
Bug 1348021 - Unbreak config/gcc_hidden.h build with libc++ after bug 1341238.

https://reviewboard.mozilla.org/r/121124/#review123450

Builds fine. I wasn't aware `config/stl-headers` is merged with `config/system-headers` during build.
Comment hidden (mozreview-request)
Rank: 35
Priority: -- → P3

Comment 6

a year ago
mozreview-review
Comment on attachment 8848175 [details]
Bug 1348021 - Unbreak config/gcc_hidden.h build with libc++ after bug 1341238.

https://reviewboard.mozilla.org/r/121124/#review123922
Attachment #8848175 - Flags: review?(nfroyd) → review+
(Assignee)

Updated

a year ago
Keywords: checkin-needed
Assignee: nobody → jbeich

Comment 7

a year ago
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/caad1c77790b
Unbreak config/gcc_hidden.h build with libc++ after bug 1341238. r=froydnj
Keywords: checkin-needed

Comment 8

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/caad1c77790b
Status: NEW → RESOLVED
Last Resolved: a year ago
status-firefox55: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
status-firefox52: --- → unaffected
status-firefox53: --- → unaffected
status-firefox54: --- → unaffected
status-firefox-esr52: --- → unaffected
You need to log in before you can comment on or make changes to this bug.