-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build fail on mac mojave #4375
Comments
Did you brew install? |
Package name changed from lua51 to lua@5.1. We need to update the README. I'm going to try to build on my macbook later this night to see if it builds. |
yes, i have brew installed |
@Dollyn: You need to install luarocks too. But if you install it from brew you'll find that is configured to work w/ lua 5.3 instead of 5.1. You can check that with You can change that with
|
I mean did you run the relevant |
I did not do that directly. I only use the comand ./kodev build |
@pazos
I can use luarocs-5.1 from my terminal. But ./kodev build still can not find command 'luarocs-5.1'. Then I modify base/thirdparty/lua-Spore/CMakeLists.txt, change the build command directly: set(BUILD_CMD bash -c "luarocks --lua-dir=/usr/local/opt/lua@5.1 make --tree=${OUTPUT_DIR}/rocks ${LUA_SPORE_ROCKSPEC}") Now a new error appears:
failed find lua lib, but it did't tell which lib it can't find |
You didn't say if you installed all the requirements as per the readme or just Lua? |
Yes, I did execute the commands in the readme:
|
I don't have my laptop near me right now, which version of luarocks is brew installing? Luarocks 3 introduced many changes to help handle // lua installations, but we're probably not handling it correctly (or at all on macOS), as the bots are still using luarocks 2 |
@NiLuJe: 3.0.1 as https://formulae.brew.sh/formula/luarocks. I managed to build luarocks 3.0.4 from source and link against lua@5.1 and it works as long as I modify the base repo:
The rest of the build script worked but, sadly, I needed to use BTW, movaje breaks compatibility with 10.4, so some packages (like luajit) require a newer deployment target (I'm building with |
After building I noticed that running If I run
otool output for libjpeg:
otool output for libmupdf
|
To make the program work we need to type:
This will change otool output to:
The program starts fine and logs:
|
I opened without problems epubs, pdf and djvu from tests folder. Pinging @chrox because he will know better how to fix the rpath stuff on mac. |
@Dollyn: This issue isn't related to mojave (except the mandatory environment MACOSX_DEPLOYMENT_TARGET > 10.4), and should affect any other mac running el capitan/sierra/high sierra with recent brew tools (and with recent I mean |
A fun twist of messing with otool is that we can create a mac app bundle just by loading shared libraries from I followed the guide to build an osx app bundle - the ugly way and copied everything under the emulator (using cp -LR to avoid soft links) to koreader.app/Contents/Resources and place a shell script in koreader.app/Contents/MacOS/koreader with
And funny enough it seems to be ready to rock! tried packaging the emulator with debug info and got an app of 180MB. I guess without debugging symbols I will get about 80MB reduction. (dmg file of about 40MB) |
@pazos I had no issues when I fixed the MuPDF build on Mac earlier this year and that would've been a brand new brew. |
@Frenzie: You're right! It seems that transiction to luarocks3 has happened in August 2018. Homebrew/homebrew-core@799af87 |
Includes: * [build, MacOS] Add support for luarocks3 from brew (koreader/koreader-base#774) @pazos Fixes #4375. * [fix] Android nightmode landscape (koreader/koreader-base#776) @Frenzie Fixes #3945.
Pinging @Dollyn, let us know if you find issues now. Thanks |
Issue
[ 37%] Performing patch step for 'lua-Spore'
[ 50%] No update step for 'lua-Spore'
[ 62%] No configure step for 'lua-Spore'
[ 75%] Performing build step for 'lua-Spore'
sh: luarocks-5.1: command not found
make[4]: *** [lua-Spore-prefix/src/lua-Spore-stamp/lua-Spore-build] Error 127
make[3]: *** [CMakeFiles/lua-Spore.dir/all] Error 2
make[2]: *** [all] Error 2
make[1]: *** [build/x86_64-apple-darwin18.2.0-debug/rocks/lib/luarocks/rocks/lua-spore/0.3.1-1/lua-spore-0.3.1-1.rockspec] Error 2
make: *** [base/build/x86_64-apple-darwin18.2.0-debug/luajit] Error 2
Steps to reproduce
git clone https://github.com/koreader/koreader.git
cd koreader && ./kodev fetch-thirdparty
./kodev build
The text was updated successfully, but these errors were encountered: