Hi Travis,
Thanks for the revised diffs.
unibilium now looks fine.
libvterm:
On Mon, Nov 04, 2019 at 08:40:19PM -0800, Travis Cole wrote:
> > SHARED_LIBS += vterm 1.0 # 0.0
>
> I've bumped the version
Cool. I suppose we should probably add a comment warning other porters
that they don't properly version their shared libs.
Something like:
---8<---
# Note: Upstream doesn't bump the library version properly.
# Diff the headers and check for bump-worthy cnahges."
--->8---
> I did also notice some minor compiler
> warnings in libvterm. I'm not sure if we want to address them?
The warnings looks harmless, so I wouldn't waste your time on fixing
them.
Neovim itself fails to link for me:
---8<---
/usr/local/pobj/neovim-0.4.2/bin/cc -O2 -pipe ... -o bin/nvim ...
ld: error: undefined symbol: lua_tointegerx
>>> referenced by luv.c
>>> luv.c.o:(luv_stack_dump) in archive .deps/usr/lib/libluv.a
ld: error: undefined symbol: lua_rotate
>>> referenced by luv.c
>>> luv.c.o:(luv_cfpcall) in archive .deps/usr/lib/libluv.a
ld: error: undefined symbol: lua_pcallk
>>> referenced by luv.c
>>> luv.c.o:(luv_cfpcall) in archive .deps/usr/lib/libluv.a
ld: error: undefined symbol: lua_rotate
>>> referenced by luv.c
>>> luv.c.o:(luv_cfpcall) in archive .deps/usr/lib/libluv.a
...
--->8---
I reckon our default Lua version (currently 5.1) is too old. `lua_rotate` is
one of the symbols needed for linkage:
---8<---
$ nm liblua5.1.so.5.1 | grep lua_rotate
$ nm liblua5.2.so.5.2 | grep lua_rotate
$ nm liblua5.3.so.5.3 | grep lua_rotate
00011580 T lua_rotate
--->8---
This shows that some part of the build expects a symbol non-existent in
versions of lua older than 5.3, So we could add:
---8<---
MODLUA_VERSION = 5.3
--->8---
And then change the FLAVORS of all of the Lua RUN/BUILD dependencies, e.g.:
---8<---
devel/libmpack/lua,${MODLUA_FLAVOR}
--->8---
(We should do that *anyway*, even if we stick with the default Lua
version)
Except we can't use Lua-5.3 for lua-bitop! It only supports Lua5.1 and
Lua5.2!
Further, the fact that they build lua53-compat suggests that neovim requires an
earlier version than 5.3 itself.
third-party/CMakelists seems to use Lua-5.1.
Confused? I was too. But here's what I think the problem is. When building luv:
---8<---
...
-- Found LIBUV: /usr/local/lib/libuv.so.2.1
-- Found Lua: /usr/local/lib/liblua5.3.so.5.3;/usr/lib/libm.so.10.1 (found
version "5.3.5")
--->8---
luv is picking up Lua-5.3. I guess you don't see the symbol errors as you only
have Lua-5.1 installed? You need to patch the build to pick up the
MODLUA_VERSION one. Hopefully that will fix it.
I also notice:
---8<---
-- downloading...
src='https://github.com/keplerproject/lua-compat-5.3/archive/v0.7.tar.gz'
--->8---
We can't have the build download stuff. I think you can have a play with
MASTER_SITES1 and a DISTFILE with a :1 suffix to fetch that tarball, then use a
post-fetch target to put it wherever it needs to go. I'm hand-waving a bit, but
you get the gist of it. Grep the tree for examples.
I'd fix the symbol problems first.
Isn't porting FUN!
--
Best Regards
Edd Barrett
http://www.theunixzoo.co.uk