Closed Bug 944454 Opened 11 years ago Closed 11 years ago

Fail to build FF on linux, error: hidden symbol 'FT_*' is not defined locally

Categories

(Firefox Build System :: General, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(firefox25 wontfix, firefox26 fixed, firefox27 fixed, firefox28 fixed, firefox-esr17 wontfix, firefox-esr24 fixed, b2g18 wontfix, b2g-v1.1hd wontfix, b2g-v1.2 fixed)

RESOLVED FIXED
mozilla28
Tracking Status
firefox25 --- wontfix
firefox26 --- fixed
firefox27 --- fixed
firefox28 --- fixed
firefox-esr17 --- wontfix
firefox-esr24 --- fixed
b2g18 --- wontfix
b2g-v1.1hd --- wontfix
b2g-v1.2 --- fixed

People

(Reporter: romaxa, Assigned: glandium)

References

Details

(Whiteboard: [qa-])

Attachments

(3 files)

cat mozconfig 
ac_add_options --enable-application=browser
mk_add_options MOZ_MAKE_FLAGS="-j8"
mk_add_options MOZ_OBJDIR="@TOPSRCDIR@/obj-build-ff-linux"
ac_add_options --enable-debug-symbols="-gdwarf-4"

cat /etc/issue
Debian GNU/Linux jessie/sid \n \l

http://hg.mozilla.org/mozilla-central/rev/7f14d602e0c5

./mach build 
linking libxul.so endup with
.....
z_src0.o is referenced by DSO /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/libpangoft2-1.0.so
 3:24.93 ../../build/unix/gold/ld: warning: hidden symbol 'hb_ot_tags_from_script' in /mozilla-central/obj-build-ff-linux/toolkit/library/../../gfx/harfbuzz/src/Unified_cpp_gfx_harfbuzz_src0.o is referenced by DSO /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/libpangoft2-1.0.so
....
 3:25.11 ../../build/unix/gold/ld: error: /mozilla-central/obj-build-ff-linux/toolkit/library/../../gfx/skia/SkFontHost_FreeType_common.o: requires dynamic R_X86_64_PC32 reloc against 'FT_Outline_Decompose' which may overflow at runtime; recompile with -fPIC
 3:25.11 ../../build/unix/gold/ld: error: read-only segment has dynamic relocations
 3:25.11 ../../build/unix/gold/ld: error: hidden symbol 'FT_Select_Charmap' is not defined locally
 3:25.11 ../../build/unix/gold/ld: error: hidden symbol 'FT_Get_Sfnt_Table' is not defined locally
 3:25.11 ../../build/unix/gold/ld: error: hidden symbol 'FT_Get_Sfnt_Table' is not defined locally
...
46:11.16 ../../build/unix/gold/ld: error: hidden symbol 'FT_Set_Char_Size' is not defined locally
46:11.16 ../../build/unix/gold/ld: error: hidden symbol 'FT_Set_Pixel_Sizes' is not defined locally
.....
46:11.25 collect2: error: ld returned 1 exit status
46:11.25 make[5]: *** [libxul.so] Error 1
46:11.25 make[4]: *** [toolkit/library/libs] Error 2
46:11.25 make[3]: *** [libs] Error 2
46:11.25 make[2]: *** [default] Error 2
46:11.25 make[1]: *** [realbuild] Error 2
46:11.25 make: *** [build] Error 2
46:11.27 753 compiler warnings present.
Summary: error: hidden symbol 'FT_*' is not defined locally → Fail to build FF on linux, error: hidden symbol 'FT_*' is not defined locally
Attached file autoconf.mk
So, before, all headers were in /usr/include/freetype2/freetype and included as "freetype/foo.h", and they are now all in /usr/include/freetype2 and included as "foo.h". Which breaks our wrapping.
Interestingly, this requires a clobber if and only if your objdir contains a failed build because of this bug.
Attachment #8340117 - Flags: review?(ted)
Assignee: nobody → mh+mozilla
Status: NEW → ASSIGNED
Comment on attachment 8340117 [details] [diff] [review]
Wrap non-prefixed freetype headers from newer freetype versions

works good for me
Attachment #8340117 - Flags: feedback+
Attachment #8340117 - Flags: review?(ted) → review+
For (future) reference, this freetype change seems to have landed in 2.5.1 with this commit: http://git.savannah.gnu.org/cgit/freetype/freetype2.git/commit/?id=fae382076409db198dfbff36ac4cbb97b05b30a1
Comment on attachment 8340117 [details] [diff] [review]
Wrap non-prefixed freetype headers from newer freetype versions

[Approval Request Comment]
Bug caused by (feature/regressing bug #): new upstream freetype release
User impact if declined: Build failure when building against freetype 2.5.1. This is likely to affect most linux distros soon.
Testing completed (on m-c, etc.): Tested by various people having the problem.
Risk to taking this patch (and alternatives if risky): Very low
String or IDL/UUID changes made by this patch: None
Attachment #8340117 - Flags: approval-mozilla-esr24?
Attachment #8340117 - Flags: approval-mozilla-beta?
Attachment #8340117 - Flags: approval-mozilla-aurora?
we're already done with landings to mozilla-beta for ff26 so this will have to wait and land after merge day for ff27 - given that this shipped for ff25 already we should be able to live with this. leaving the nominations so this can get picked up after Dec 9, 2013
Comment on attachment 8340117 [details] [diff] [review]
Wrap non-prefixed freetype headers from newer freetype versions

actually that was wrong, I can just approve for branches this can land on and minus for beta.
Attachment #8340117 - Flags: approval-mozilla-esr24?
Attachment #8340117 - Flags: approval-mozilla-esr24+
Attachment #8340117 - Flags: approval-mozilla-beta?
Attachment #8340117 - Flags: approval-mozilla-beta-
Attachment #8340117 - Flags: approval-mozilla-aurora?
Attachment #8340117 - Flags: approval-mozilla-aurora+
(In reply to Lukas Blakk [:lsblakk] from comment #9)
> we're already done with landings to mozilla-beta for ff26 so this will have
> to wait and land after merge day for ff27 - given that this shipped for ff25
> already we should be able to live with this. leaving the nominations so this
> can get picked up after Dec 9, 2013

Freetype 2.5.1 was released a week ago. Which means the bug didn't exist at the time ff25 was released. But it is affected, and while it's likely not much of a problem at this point, it is going to prevent linux distros that updated freetype to 2.5.1 (fwiw, this is already the case for debian unstable) from building ff26 out of the box. This is also affecting mozilla developers building on linux with freetype 2.5.1 (and considering this bug hit several people already is indication that there is such a population, although the population of mozilla developers who might need to build ff26 after release is slim and might not intersect, but who knows)
Comment on attachment 8340117 [details] [diff] [review]
Wrap non-prefixed freetype headers from newer freetype versions

since this is a noop on our builds but important for source tarball, we'll take it as it doesn't put our builds at risk.
Attachment #8340117 - Flags: approval-mozilla-beta- → approval-mozilla-beta+
https://hg.mozilla.org/mozilla-central/rev/d6f47a333fe1
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
Whiteboard: [qa-]
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: