about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libexecinfo
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2019-01-07 02:18:36 +0000
committerAlyssa Ross <hi@alyssa.is>2019-01-07 02:18:47 +0000
commit36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2 (patch)
treeb3faaf573407b32aa645237a4d16b82778a39a92 /nixpkgs/pkgs/development/libraries/libexecinfo
parent4e31070265257dc67d120c27e0f75c2344fdfa9a (diff)
parentabf060725d7614bd3b9f96764262dfbc2f9c2199 (diff)
downloadnixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.gz
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.bz2
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.lz
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.xz
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.zst
nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.zip
Add 'nixpkgs/' from commit 'abf060725d7614bd3b9f96764262dfbc2f9c2199'
git-subtree-dir: nixpkgs
git-subtree-mainline: 4e31070265257dc67d120c27e0f75c2344fdfa9a
git-subtree-split: abf060725d7614bd3b9f96764262dfbc2f9c2199
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/libexecinfo')
-rw-r--r--nixpkgs/pkgs/development/libraries/libexecinfo/default.nix46
1 files changed, 46 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/libexecinfo/default.nix b/nixpkgs/pkgs/development/libraries/libexecinfo/default.nix
new file mode 100644
index 000000000000..a61d51aa6b72
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/libexecinfo/default.nix
@@ -0,0 +1,46 @@
+{ stdenv, fetchurl, fetchpatch }:
+
+stdenv.mkDerivation rec {
+  name = "libexecinfo-${version}";
+  version = "1.1";
+
+  src = fetchurl {
+    url = "http://distcache.freebsd.org/local-distfiles/itetcu/${name}.tar.bz2";
+    sha256 = "07wvlpc1jk1sj4k5w53ml6wagh0zm9kv2l1jngv8xb7xww9ik8n9";
+  };
+
+  patches = [
+    (fetchpatch {
+      name = "10-execinfo.patch";
+      url = https://git.alpinelinux.org/cgit/aports/plain/main/libexecinfo/10-execinfo.patch?id=730cdcef6901750f4029d4c3b8639ce02ee3ead1;
+      sha256 = "0lnphrad4vspyljnvmm62dyxj98vgp3wabj4w3vfzfph7j8piw7g";
+    })
+    (fetchpatch {
+      name = "20-define-gnu-source.patch";
+      url = https://git.alpinelinux.org/cgit/aports/plain/main/libexecinfo/20-define-gnu-source.patch?id=730cdcef6901750f4029d4c3b8639ce02ee3ead1;
+      sha256 = "1mp8mc639b0h2s69m5z6s2h3q3n1zl298j9j0plzj7f979j76302";
+    })
+    (fetchpatch {
+      name = "30-linux-makefile.patch";
+      url = https://git.alpinelinux.org/cgit/aports/plain/main/libexecinfo/30-linux-makefile.patch?id=730cdcef6901750f4029d4c3b8639ce02ee3ead1;
+      sha256 = "1jwjz22z5cjy5h2bfghn62yl9ar8jiqhdvbwrcfavv17ihbhwcaf";
+    })
+  ];
+
+  makeFlags = [ "CC:=$(CC)" "AR:=$(AR)" ];
+
+  patchFlags = "-p0";
+
+  installPhase = ''
+    install -Dm644 execinfo.h stacktraverse.h -t $out/include
+    install -Dm755 libexecinfo.{a,so.1} -t $out/lib
+    ln -s $out/lib/libexecinfo.so{.1,}
+  '';
+
+  meta = with stdenv.lib; {
+    description = "Quick-n-dirty BSD licensed clone of the GNU libc backtrace facility";
+    license = licenses.bsd2;
+    homepage = https://www.freshports.org/devel/libexecinfo;
+    maintainers = with maintainers; [ dtzWill ];
+  };
+}