nix-build patchedPostgrest.nix
notbrianzach / patchedpostgrest Goto Github PK
View Code? Open in Web Editor NEWpostgrest 0.3.2.0 binary/executable patched for nixos
postgrest 0.3.2.0 binary/executable patched for nixos
nix-build patchedPostgrest.nix
Thank you very much for sharing this bit of code! I'm new to NixOS, but it worked as expected for me.
However I ran into problems when I tried to update the derivation to use PostgREST 0.4.0.0, downloading directly from their GitHub release:
with import <nixpkgs> {};
stdenv.mkDerivation {
name = "patchedPostgrest";
src = fetchurl {
url = "https://github.com/begriffs/postgrest/releases/download/v0.4.0.0/postgrest-0.4.0.0-ubuntu.tar.xz";
sha256 = "aa1756bffa4a81e3d6ce48509b8af7590dc06c2cab8b0e157a24bb6be9861e57";
};
# Work around the "unpacker appears to have produced no directories"
# case that happens when the archive doesn't have a subdirectory.
setSourceRoot = "sourceRoot=`pwd`";
installPhase = ''
mkdir -p $out/bin
cp postgrest $out/bin/
patchelf --set-interpreter \
${stdenv.glibc}/lib/ld-linux-x86-64.so.2 $out/bin/postgrest
patchelf --set-rpath ${zlib}/lib:${postgresql.lib}/lib:${gmp}/lib:${stdenv.glibc}/lib:${stdenv.glibc}/lib $out/bin/postgrest
'';
}
This builds with nix-build patchedPostgrest.nix
, but running the binary fails:
result/bin/postgrest: result/bin/postgrest: no version information available (required by result/bin/postgrest)
result/bin/postgrest: symbol lookup error: result/bin/postgrest: undefined symbol: , version
Now I'm stuck. If you have time to help, I'd really appreciate it. If not, feel free to close this issue. Thanks again!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.