haxpor / aseprite-macos-buildsh

Automated script to create latest release app (either beta, or release whichever is newer) of Aseprite for macOS
MIT License
155 stars 41 forks source link

library not found for -lSKSHAPER_LIBRARY-NOTFOUND #11

Closed Banjerr closed 3 years ago

Banjerr commented 3 years ago

I'm receiving the following after running the script

FAILED: bin/aseprite
: && /Library/Developer/CommandLineTools/usr/bin/c++ -stdlib=libc++ -Wall -Wno-switch -O2 -g -DNDEBUG -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.9 -Wl,-search_paths_first -Wl,-headerpad_max_install_names  src/CMakeFiles/aseprite.dir/main/main.cpp.o -o bin/aseprite  lib/libapp-lib.a  lib/libclip.a  lib/libdio-lib.a  lib/libfilters-lib.a  lib/libflic-lib.a  lib/libtga-lib.a  lib/librender-lib.a  lib/libdoc-lib.a  lib/libfixmath-lib.a  lib/libui-lib.a  lib/liblaf-os.a  lib/liblaf-gfx.a  lib/liblaf-ft.a  /Users/bengineer/Source/aseprite-macos-buildsh/deps/skia/out/Release/libskia.a  -framework  OpenGL  -framework  Cocoa  -framework  Carbon  -lSKSHAPER_LIBRARY-NOTFOUND  lib/libobs.a  lib/libundo.a  lib/libcmark.a  lib/libjpeg.a  lib/libgiflib.a  lib/libwebpdemux.a  lib/libwebpmux.a  lib/libwebp.a  lib/libfreetype.a  lib/libharfbuzz.a  lib/libfreetype.a  lib/libharfbuzz.a  lib/libpng16.a  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/lib/libbz2.tbd  lib/libjson11.a  lib/libarchive.a  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/lib/libiconv.tbd  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/lib/libcharset.tbd  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/lib/libexpat.tbd  lib/libfmt.a  lib/libtinyexpr.a  lib/liblauxlib.a  lib/liblua.a  lib/liblualib.a  lib/libupdater-lib.a  lib/libcfg-lib.a  lib/libver-lib.a  lib/libtinyxml.a  lib/libnet-lib.a  lib/liblaf-base.a  lib/libmodpbase64.a  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/lib/libdl.tbd  lib/libcurl.a  lib/libz.a  -ldl  -lldap && :
ld: library not found for -lSKSHAPER_LIBRARY-NOTFOUND
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Something went wrong
haxpor commented 3 years ago

Hi thank you for reporting the issue. As I'm away from macOS platform for long, there is no time frame for me to fix this unfortunately. But I will try to help as best I can.

I suspect it didn't build modules which includes SkShaper as it reflects on your issue. I checked and our build script is slightly outdated. We could try the following workaround

Option 1: Rebuild skia with updated build script

Option 2: Use pre-built skia library

Banjerr commented 3 years ago

Thanks for the feedback! I will try these steps soon 🙏

Sent from my iPhone

On Jan 10, 2021, at 3:31 AM, Wasin Thonkaew notifications@github.com wrote:

 Hi thank you for reporting the issue. As I'm away from macOS platform for long, there is no time frame for me to fix this unfortunately. But I will try to help as best I can.

I suspect it didn't build modules which includes SkShaper as it reflects on your issue. I checked and our build script is slightly outdated. We could try the following workaround

Validate that you didn't see libskshaper.a inside deps/skia/out/Release/? or (optional) try to see if it located elsewhere outside that path (less likely, but just to be sure) if not found then, there are 2 options we can go with 1:) Rebuild skia with updated build script to include modules 2:) Use pre-built skia library (both see below to continue...) Option 1: Rebuild skia with updated build script

There's updated skia build commands for macOS as seen from https://github.com/aseprite/skia#skia-on-macos. Change these two lines https://github.com/haxpor/aseprite-macos-buildsh/blob/master/aseprite.sh#L129-L130 to last two lines in former link, notice it now includes modules which contains SKSHAPER. Start it over executing build script from this project Option 2: Use pre-built skia library

Download pre-built skia library package for macOS namely Skia-macOS-Release-x64.zip at https://github.com/aseprite/skia/releases/tag/m81-b607b32047 Extract it and copy out/Release-x64/libskshaper.a then paste into your deps/skia/out/Release/ (it's not necessary to copy all files, but if it didn't work, try another time by copying all the files there, then replace at destination path as mentioned) Execute the build script command of this project again — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

axfelix commented 3 years ago

I'm getting this error too, FYI -- I think current master is basically broken under newest macOS.

animator commented 3 years ago

I followed the option 2 and the build executed perfectly.

axfelix commented 3 years ago

I'm now hitting this issue: https://gitlab.kitware.com/cmake/cmake/-/issues/21048

Doesn't seem to be a resolution, oh well... thanks for your help!

haxpor commented 3 years ago

FYI: As I'm away from macOS platform, I'm open to contributors to resolve this issue cleanly. Mainly it would need to test on newer / latest version of macOS (that's the main problem), and adopt building changes from upstream aseprite repo.

animator commented 3 years ago

I can see that @axfelix 's issue is related to the curl library. You can check out the detailed guide (with troubleshooting) I wrote for MacOS installation using this utility to resolve the issue.

Link - Building Aseprite from Source on MacOS Catalina 10.15

haxpor commented 3 years ago

There is a PR to amend this for latest macos version. Maybe affected users might want to test and if so please let me know if it's working fine for you here? Thank you very much.

axfelix commented 3 years ago

I can confirm this worked fine for me! Thank you!

haxpor commented 3 years ago

@abhishek-shaw 's PR has been merged. So this issue can be closed now. Thank you everyone 👍🏽