I've been working to get a successful build of neovim on the Odroid 2 and finally had some success, but it took some tweaks to get it working.
In my conversation with the project maintainers, they suggested I reach out and inquire as to how we can get neovim, python-neovim, and python3-neovim as supported packages using DietPi's package management system.
neovim is already supported with apt in Debian and Ubuntu as documented here:
https://github.com/neovim/neovim/wiki/Installing-Neovim
Is there a way I can help get neovim supported as a supported package for DietPi? My thanks in advance.
Is there a way I can help get neovim supported as a supported package for DietPi? My thanks in advance.
Yep, i'll take a look and see whats involved.
Should be two options for install method:
Source build is to ensure latest version, but can fail if libraries/compile steps change.
Deb packages preferred, with testing ensures working, stable installations. But they will need to be re-built to match latest versions.
Either way, i'll know more once I've done some tests based on your notes. Leave it with me.
Quick compile C2 notes (based on @joshuamcginnis original notes):
apt-get install -y git build-essential checkinstall libtool libtool-bin autoconf automake cmake g++ pkg-config unzip
apt-get install -y lua5.1 luarocks libuv1-dev
---
#lua stuff
luarocks install lpeg
luarocks install mpack
luarocks install luabitop
---
#Build msgpack-c
cd "$HOME"
git clone --depth=1 https://github.com/msgpack/msgpack-c.git
cd msgpack*
cmake .
make -j $(nproc --all)
make install
# - Create .deb
#checkinstall
---
#Build neovim
cd "$HOME"
git clone --depth=1 https://github.com/neovim/neovim.git
cd neovim
make deps DEPS_CMAKE_FLAGS="-DUSE_BUNDLED_LIBUV=OFF -DUSE_BUNDLED_MSGPACK=OFF -DUSE_BUNDLED_LUAROCKS=OFF -DUSE_BUNDLED_LUAJIT=OFF"
mkdir -p build
cd build
cmake -DCMAKE_INSTALL_PREFIX=$HOME/neovim ..
make -j $(nproc --all)
make install
# - Create .deb
#checkinstall
@joshuamcginnis
Looks like its failing on LuaJIT 2.0.4, dep required by NeoVim, ARM64 (v8) not supported:
==== Building LuaJIT 2.0.4 ====
make[5]: Entering directory '/root/neovim/.deps/build/src/luajit/src'
Creating directories for 'msgpack'
lj_arch.h:55:2: error: #error "No support for this architecture (yet)"
#
---
#LUA jit
cd "$HOME"
git clone --depth=1 https://github.com/LuaJIT/LuaJIT.git
cd Lua*
make -j $(nproc --all)
#make install
#Same errors
Did you receive the same issues during compile? And, have you been successful in compiling and installing NeoVim on ARM64?
Looks like its failing on LuaJIT 2.0.4, dep required by NeoVim, ARM64 (v8) not supported:
@Fourdee That's correct. This issue has a discussion from another Odroid user regarding this failure. It's a little unclear, but I believe the user was able to get a successful build of luajit with a patch.
However, I opted to configure the build to NOT compile luajit (and others) since the neovim maintainers claimed it was only needed for running tests.
This comment has my exact build steps for getting a successful build:
https://github.com/neovim/neovim/issues/5861#issuecomment-270216617
@joshuamcginnis
Ok, tested again, using your steps located here,fails to build: https://github.com/neovim/neovim/issues/5861#issuecomment-270216617
I cant seem to get past make deps DEPS_CMAKE_FLAGS="-DUSE_BUNDLED_LIBUV=OFF -DUSE_BUNDLED_MSGPACK=OFF -DUSE_BUNDLED_LUAROCKS=OFF -DUSE_BUNDLED_LUAJIT=OFF":
In file included from /root/neovim/.deps/build/src/luv/src/luv.c:18:0:
/root/neovim/.deps/build/src/luv/src/luv.h:19:17: fatal error: lua.h: No such file or directory
#include <lua.h>
^
compilation terminated.
CMakeFiles/luv.dir/build.make:54: recipe for target 'CMakeFiles/luv.dir/src/luv.c.o' failed
make[6]: *** [CMakeFiles/luv.dir/src/luv.c.o] Error 1
make[6]: Leaving directory '/root/neovim/.deps/build/src/luv-static-build'
CMakeFiles/Makefile2:60: recipe for target 'CMakeFiles/luv.dir/all' failed
make[5]: *** [CMakeFiles/luv.dir/all] Error 2
make[5]: Leaving directory '/root/neovim/.deps/build/src/luv-static-build'
Makefile:117: recipe for target 'all' failed
make[4]: *** [all] Error 2
make[4]: Leaving directory '/root/neovim/.deps/build/src/luv-static-build'
CMakeFiles/luv-static.dir/build.make:107: recipe for target 'build/src/luv-static-stamp/luv-static-build' failed
make[3]: *** [build/src/luv-static-stamp/luv-static-build] Error 2
make[3]: Leaving directory '/root/neovim/.deps'
CMakeFiles/Makefile2:235: recipe for target 'CMakeFiles/luv-static.dir/all' failed
make[2]: *** [CMakeFiles/luv-static.dir/all] Error 2
make[2]: Leaving directory '/root/neovim/.deps'
Makefile:76: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/root/neovim/.deps'
Makefile:75: recipe for target 'deps' failed
make: *** [deps] Error 2
The dependency target "libuv" of target "luv-static" does not exist.
Call Stack (most recent call first):
CMakeLists.txt:160 (include)
This warning is for project developers. Use -Wno-dev to suppress it.
So as suggested here (make, not make deps: https://github.com/neovim/neovim/issues/4692#issuecomment-216345030
Tried:
make distclean
make -j $(nproc --all) DEPS_CMAKE_FLAGS="-DUSE_BUNDLED_LIBUV=OFF -DUSE_BUNDLED_MSGPACK=OFF -DUSE_BUNDLED_LUAROCKS=OFF -DUSE_BUNDLED_LUAJIT=OFF"
Which results in:
make[4]: Leaving directory '/root/neovim/.deps/build/src/unibilium'
[ 77%] Completed 'unibilium'
make[3]: Leaving directory '/root/neovim/.deps'
[ 77%] Built target unibilium
/usr/bin/install -c -m 755 lib/libjemalloc.a /root/neovim/.deps/usr/lib
/usr/bin/install -c -m 755 lib/libjemalloc_pic.a /root/neovim/.deps/usr/lib
make[4]: Leaving directory '/root/neovim/.deps/build/src/jemalloc'
[ 79%] Completed 'jemalloc'
make[3]: Leaving directory '/root/neovim/.deps'
[ 79%] Built target jemalloc
make[2]: Leaving directory '/root/neovim/.deps'
Makefile:76: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/root/neovim/.deps'
Makefile:75: recipe for target 'deps' failed
make: *** [deps] Error 2
Those errors seem to hint at either lua not being installed or the wrong version (which I did the first time around).
sudo apt-get install lua5.1 luarocks libuv1-dev
Are you sure you have lua5.1 and libuv1-dev installed?
@joshuamcginnis
Are you sure you have lua5.1 and libuv1-dev installed?
Yes. Followed your instructions exactly: https://github.com/neovim/neovim/issues/5861#issuecomment-270216617
Also tried with libuv0.10-dev, same result.
root@DietPi:~/neovim# apt-cache search libuv
libuv0.10 - asynchronous event notification library - runtime library
libuv0.10-dbg - asynchronous event notification library - debugging symbols
libuv0.10-dev - asynchronous event notification library - development files
libuv1 - asynchronous event notification library - runtime library
libuv1-dbg - asynchronous event notification library - debugging symbols
libuv1-dev - asynchronous event notification library - development files
r-cran-httpuv - GNU R package of HTTP and WebSocket Server Library
So, either something has changed on NeoVim git, that breaks your original compile notes. Or, possibly we are lacking some additional packages and/or steps?
Are you on slack or freenode? Perhaps I can blow away my installation and we can go through it together.
@joshuamcginnis
Are you on slack or freenode?
Nope, i'd never get anything done lol 馃槂
Perhaps I can blow away my installation and we can go through it together.
Sounds good, may take a bit longer, but we should be able to achieve this here.
Here are my install notes (based on yours), includes all the commands required: https://github.com/Fourdee/DietPi/issues/692#issuecomment-270419916
I'm testing Dietpi Stretch, and I just noticed that neovim package is already included in the repo:
It looks like Debian 9 Stretch will go full freeze on 2-Feb-2017. Though, I don't know how much longer after DietPi Stretch will be released. That said, it might be the path of least resistance for this issue.
As an aside, if I were to begin testing DietPi Stretch, will I need to reimage once it released or will the normal update process take care of it?
As an aside, if I were to begin testing DietPi Stretch, will I need to reimage once it released or will the normal update process take care of it?
If i'am honest, unknown at the moment. It really depends how much Stretch changes. We'll patch if we can, however, do expect a new image required for Alpha > Beta? > Release
@joshuamcginnis @007lva (thanks!)
NeoVim, straightforward apt install on Stretch:
https://github.com/Fourdee/DietPi/issues/475#issuecomment-273755851
Although a simple apt-get install, i've added to dietpi-software aswell, under additional linux software.
Will mark this as closed. This installation is available for Stretch only.
@joshuamcginnis
If you get any further success with compiling for Jessie, please reopen as needed. However, from my end, I simply don't have the time available to put more into this, and, i'am a nano user 馃槈 lol.
Most helpful comment
I'm testing Dietpi Stretch, and I just noticed that neovim package is already included in the repo:
https://packages.debian.org/stretch/neovim