RESOLVED WONTFIX 216771
[Win] 32bit AppleWin link error: unresolved external symbol _CTFontTransformGlyphs
https://bugs.webkit.org/show_bug.cgi?id=216771
Summary [Win] 32bit AppleWin link error: unresolved external symbol _CTFontTransformG...
QuellaZhang
Reported 2020-09-21 03:37:44 PDT
Created attachment 409266 [details] webkit.txt Environment: Windows Server 2016 VS2019 unreleased version WebKitRequirements: https://github.com/WebKitForWindows/WebKitRequirements/releases/tag/v2020.05.08 Issue description: We tried to build WebKit using VS2019 on Windows Server 2016. WebKit failed to build due to link error on windows with MSVC. It can be reproduced on master branch latest commit 577b3e6. Could you please help take a look at this? Thanks in advance! Repro steps: 1. git clone https://github.com/WebKit/webkit F:\gitP\WebKit\webkit 2. open a VS 2019 x86 command prompt as admin and browse to F:\gitP\WebKit\webkit 3. extra WebKitAuxiliaryLibrary to F:\gitP\WebKit\webkit\WebKitLibraries\win 4. extra WebKitSupportLibrary to F:\gitP\WebKit\webkit\WebKitLibraries\win 5. mkdir build_x86 && pushd build_x86 6. cmake -G "Visual Studio 16 2019" -A Win32 -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_BUILD_TYPE=Release -DRUBY_LIBRARY=C:\tools\ruby26\lib -DPORT="AppleWin" .. 7. msbuild /p:Platform=Win32 /p:Configuration=Release WebKit.sln /t:Rebuild Actual result: F:\gitP\WebKit\webkit\linkrepro>link @link.rsp Creating library .\WebKit.lib and object .\WebKit.exp WebCore.lib(FontCoreText.obj) : error LNK2019: unresolved external symbol _CTFontTransformGlyphs referenced in function "public: void __thiscall WebCore::Font::applyTransforms(class WebCore::GlyphBuffer &,unsigned int,unsigned int,bool,bool,class WTF::AtomString const &,class WTF::StringView,enum WebCore::TextDirection)const " (?applyTransforms@Font@WebCore@@QBEXAAVGlyphBuffer@2@II_N1ABVAtomString@WTF@@VStringView@5@W4TextDirection@2@@Z) WebCore.lib(FontCoreText.obj) : error LNK2019: unresolved external symbol _CTFontGetGlyphsForCharacterRange referenced in function "public: bool __thiscall WebCore::Font::isProbablyOnlyUsedToRenderIcons(void)const " (?isProbablyOnlyUsedToRenderIcons@Font@WebCore@@QBE_NXZ) WebCore.lib(GlyphPageCoreText.obj) : error LNK2019: unresolved external symbol _CTFontGetVerticalGlyphsForCharacters referenced in function "public: bool __thiscall WebCore::GlyphPage::fill(char16_t *,unsigned int)" (?fill@GlyphPage@WebCore@@QAE_NPA_SI@Z) WebCore.lib(FontCustomPlatformData.obj) : error LNK2019: unresolved external symbol _CTFontManagerCreateFontDescriptorFromData referenced in function "class std::unique_ptr<struct WebCore::FontCustomPlatformData,struct std::default_delete<struct WebCore::FontCustomPlatformData> > __cdecl WebCore::createFontCustomPlatformData(class WebCore::SharedBuffer &,class WTF::String const &)" (?createFontCustomPlatformData@WebCore@@YA?AV?$unique_ptr@UFontCustomPlatformData@WebCore@@U?$default_delete@UFontCustomPlatformData@WebCore@@@std@@@std@@AAVSharedBuffer@1@ABVString@WTF@@@Z) WebCore.lib(FontPlatformDataCoreText.obj) : error LNK2019: unresolved external symbol _CTFontDescriptorIsSystemUIFont referenced in function "public: __thiscall WebCore::FontPlatformData::FontPlatformData(struct __CTFont const *,float,bool,bool,enum WebCore::FontOrientation,enum WebCore::FontWidthVariant,enum WebCore::TextRenderingMode)" (??0FontPlatformData@WebCore@@QAE@PBU__CTFont@@M_N1W4FontOrientation@1@W4FontWidthVariant@1@W4TextRenderingMode@1@@Z) .\WebKit.dll : fatal error LNK1120: 5 unresolved externals
Attachments
webkit.txt (899.40 KB, text/plain)
2020-09-21 03:37 PDT, QuellaZhang
no flags
Fujii Hironori
Comment 1 2020-09-22 21:42:30 PDT
Those functions should be in CoreText.lib of the latest WebKitSupportLibrary.zip. Are you using old WebKitSupportLibrary.zip?
Myles C. Maxfield
Comment 2 2020-09-22 23:05:03 PDT
You can get the latest version of the WebKit support library here: https://developer.apple.com/opensource/internet/webkit_sptlib_agree.html
QuellaZhang
Comment 3 2020-09-23 23:08:56 PDT
Thanks, I tried latest WebKitAuxiliaryLibrary(https://webkit.org/webkit-on-windows/#build-webkit) and WebKitSupportLibrary(https://developer.apple.com/opensource/internet/webkit_sptlib_agree.html), same error.
Fujii Hironori
Comment 4 2020-09-23 23:49:33 PDT
Umm, weird. AFAICT, the latest AppleWin can compile on my PC. > perl .\Tools\Scripts\build-webkit --release --no-ninja You should check your CoreText.lib really has CTFontTransformGlyphs. Here is my result. > PS C:\home\webkit\gc> dumpbin.exe /exports .\WebKitLibraries\win\lib64\CoreText.lib | findstr CTFontTransformGlyphs > CTFontTransformGlyphs
Fujii Hironori
Comment 5 2020-09-23 23:55:35 PDT
Ah, you are building 32bit version of AppleWin. lib32/CoreText.lib is not updated. Try 64bit AppleWin. I'd like to recommend you to use build-webkit script.
QuellaZhang
Comment 6 2020-09-25 03:52:13 PDT
Ha, thanks, 64bit AppleWin compiles, I will add x64 build arch. BTW, do you have a plan to update lib32? :) And thanks for your suggestions, I will try to use build-webkit script
Radar WebKit Bug Importer
Comment 7 2020-09-28 03:38:34 PDT
jasonshan
Comment 8 2020-11-21 21:13:20 PST
Here's the way to get a 32-bit CoreText.lib 1. Download 32-bit Apple Application Support(comes from iTunes or QuickTime) 2. Find CoreText.dll from the install directory of AAS 3. run these commands to get CoreText.lib from dll dumpbin /exports CoreText.dll > CoreText.def lib /def:CoreText.def /machine:i386 /out:CoreText.lib 4. replace CoreText.lib in WebKitLibraries\win\lib32 5. build your project I've tried build 32-bit AppleWin by VS2017, It works!
Fujii Hironori
Comment 9 2023-07-16 13:21:36 PDT
AppleWin port was removed.
Note You need to log in before you can comment on or make changes to this bug.