Closed mcepl closed 5 years ago
Think cargo install can be replaced with simple copy of executable. Not remember why i use cargo install here.
%install
mkdir -p %{buildroot}%{_datadir}/%{binname}/
cp -p -r runtime %{buildroot}%{_datadir}/%{binname}/
install -p -m 0644 -D desktop/org.daa.NeovimGtk.desktop \
%{buildroot}%{_datadir}/applications/org.daa.NeovimGtk.desktop
install -p -m 0644 -D desktop/org.daa.NeovimGtk_128.png \
%{buildroot}%{icondir}/hicolor/128x128/apps/org.daa.NeovimGtk.png
install -p -m 0644 -D desktop/org.daa.NeovimGtk_48.png \
%{buildroot}%{icondir}/hicolor/48x48/apps/org.daa.NeovimGtk.png
install -p -m 0644 -D desktop/org.daa.NeovimGtk.svg \
%{buildroot}%{icondir}/hicolor/scalable/apps/org.daa.NeovimGtk.svg
install -p -m 0644 -D desktop/org.daa.NeovimGtk-symbolic.svg \
%{buildroot}%{icondir}/hicolor/symbolic/apps/org.daa.NeovimGtk-symbolic.svg
install -p -m 0755 -D target/release/nvim-gtk \
%{buildroot}%{_bindir}/nvim-gtk
rm -vf %%{buildroot}%%{_prefix}/.crates.toml
Seems to work just fine. I understand that cargo install
is expected to be used for Rust projects, but it just doesn't work for me, and this does.
don't see any problems with replace cargo install
with cp
Works with the current version of build scripts on https://build.opensuse.org/package/show/home:mcepl:neovim/neovim-gtk
Describe the bug When building in the network isolated environment (e.g., build systems for all Linux distributions) it is necessary (due to the unfortunate lack of dynamic linking for rust) to provide a tarball with the third party dependencies. Therefore, outside of the build environment I first create vendor tarball like this:
and then use tarball in the build process:
Build works without problems, but then when I run
cargo install --force --root %{buildroot}%{_prefix} --path .
I get failed command and the end of the log:Why suddenly cargo requires the network connection? It didn't for a long time.
Technical information (please complete the following information):
Full build log.