Skip to content
This repository was archived by the owner on Jan 22, 2025. It is now read-only.

solana-install-init fails to locate shared libraries on Nixos #20667

Closed
gokumoto-fuckgithub opened this issue Oct 13, 2021 · 4 comments
Closed
Labels
good first issue Good for newcomers stale [bot only] Added to stale content; results in auto-close after a week.

Comments

@gokumoto-fuckgithub
Copy link

gokumoto-fuckgithub commented Oct 13, 2021

Problem

This occurs on a Nixos host.

[root@sol:~/sol]# sh -c "$(curl -sSfL https://release.solana.com/v1.8.0/install)"
downloading v1.8.0 installer
environment: line 155: /tmp/tmp.Yd1lTpmSRK/solana-install-init: No such file or directory

If we run with sh -x:

...
+ command -v curl
+ program=curl
+ '[' http://release.solana.com/v1.8.0/solana-install-init-x86_64-unknown-linux-gnu = --check ']'
+ '[' curl = curl ']'
+ curl -sSfL http://release.solana.com/v1.8.0/solana-install-init-x86_64-unknown-linux-gnu -o /tmp/tmp.7cCb8oUfTG/solana-install-init
+ ensure chmod u+x /tmp/tmp.7cCb8oUfTG/solana-install-init
+ chmod u+x /tmp/tmp.7cCb8oUfTG/solana-install-init
+ '[' '!' -x /tmp/tmp.7cCb8oUfTG/solana-install-init ']'
+ '[' -z '' ']'
+ ignore /tmp/tmp.7cCb8oUfTG/solana-install-init v1.8.0
+ /tmp/tmp.7cCb8oUfTG/solana-install-init v1.8.0
environment: line 155: /tmp/tmp.7cCb8oUfTG/solana-install-init: No such file or directory

If we run ldd on that:

[root@sol:~/sol]# ldd /tmp/tmp.7cCb8oUfTG/solana-install-init
	linux-vdso.so.1 (0x00007ffd82cd6000)
	libdl.so.2 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/libdl.so.2 (0x00007f08f3a6d000)
	libssl.so.1.1 => not found
	libcrypto.so.1.1 => not found
	libudev.so.1 => not found
	libc.so.6 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/libc.so.6 (0x00007f08f38ae000)
	/lib64/ld-linux-x86-64.so.2 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib64/ld-linux-x86-64.so.2 (0x00007f08f4490000)
	libgcc_s.so.1 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/libgcc_s.so.1 (0x00007f08f3894000)
	librt.so.1 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/librt.so.1 (0x00007f08f3888000)
	libpthread.so.0 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/libpthread.so.0 (0x00007f08f3867000)
	libm.so.6 => /nix/store/0c7c96gikmzv87i7lv3vq5s1cmfjd6zf-glibc-2.31-74/lib/libm.so.6 (0x00007f08f3726000)

This is after installing both the openssl and openssl.dev nixos packages.

@t-nelson
Copy link
Contributor

Hi! NixOS isn't an officially supported platform. We'd be happy to entertain external contributions that bring it in line though

@t-nelson t-nelson added the good first issue Good for newcomers label Oct 13, 2021
@ruuda
Copy link
Contributor

ruuda commented Oct 18, 2021

I once made a start with packaging Solana for Nix, but I hit a roadblock with the custom BPF toolchain and the way it’s glued together with scripts that download binaries from the internet. It’s going to be a bit of a challenge to build the BPF SDK with Nix. The pull request is here: NixOS/nixpkgs#121009

@archseer
Copy link
Contributor

Agreed, packaging the BPF tools is a nightmare. This attempt seems to have gotten the furthest: saber-hq/saber-overlay#3

I've also been eyeing https://github.com/drozdziak1/nix-solana-sdk/blob/master/solana-bpf-tools-bin.nix

@rollschild
Copy link

Hi,

I'm seeing the same issue on my NixOS machine. Has there been any progress on this issue?

@github-actions github-actions bot added the stale [bot only] Added to stale content; results in auto-close after a week. label Apr 7, 2023
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Apr 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers stale [bot only] Added to stale content; results in auto-close after a week.
Projects
None yet
Development

No branches or pull requests

5 participants