summary refs log tree commit diff
path: root/pkgs/development/tools/misc/global
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2022-05-31 09:59:33 +0000
committerAlyssa Ross <hi@alyssa.is>2022-05-31 09:59:57 +0000
commit9ff36293d1e428cd7bf03e8d4b03611b6d361c28 (patch)
tree1ab51a42b868c55b83f6ccdb80371b9888739dd9 /pkgs/development/tools/misc/global
parent1c4fcd0d4b0541e674ee56ace1053e23e562cc80 (diff)
parentddc3c396a51918043bb0faa6f676abd9562be62c (diff)
downloadnixpkgs-archive.tar
nixpkgs-archive.tar.gz
nixpkgs-archive.tar.bz2
nixpkgs-archive.tar.lz
nixpkgs-archive.tar.xz
nixpkgs-archive.tar.zst
nixpkgs-archive.zip
Last good Nixpkgs for Weston+nouveau? archive
I came this commit hash to terwiz[m] on IRC, who is trying to figure out
what the last version of Spectrum that worked on their NUC with Nvidia
graphics is.
Diffstat (limited to 'pkgs/development/tools/misc/global')
-rw-r--r--pkgs/development/tools/misc/global/default.nix61
1 files changed, 61 insertions, 0 deletions
diff --git a/pkgs/development/tools/misc/global/default.nix b/pkgs/development/tools/misc/global/default.nix
new file mode 100644
index 00000000000..70ec9278ae1
--- /dev/null
+++ b/pkgs/development/tools/misc/global/default.nix
@@ -0,0 +1,61 @@
+{ fetchurl, lib, stdenv, libtool, makeWrapper
+, coreutils, ctags, ncurses, python3Packages, sqlite, universal-ctags
+}:
+
+let
+  pygments = python3Packages.pygments;
+in stdenv.mkDerivation rec {
+  pname = "global";
+  version = "6.6.7";
+
+  src = fetchurl {
+    url = "mirror://gnu/global/${pname}-${version}.tar.gz";
+    sha256 = "sha256-aaD3f1OCfFVoF2wdOCFm3zYedCY6BH8LMFiqLyrVijw=";
+  };
+
+  nativeBuildInputs = [ libtool makeWrapper ];
+
+  buildInputs = [ ncurses ];
+
+  propagatedBuildInputs = [ pygments ];
+
+  configureFlags = [
+    "--with-ltdl-include=${libtool}/include"
+    "--with-ltdl-lib=${libtool.lib}/lib"
+    "--with-ncurses=${ncurses.dev}"
+    "--with-sqlite3=${sqlite.dev}"
+    "--with-exuberant-ctags=${ctags}/bin/ctags"
+    "--with-universal-ctags=${universal-ctags}/bin/ctags"
+    "--with-posix-sort=${coreutils}/bin/sort"
+  ];
+
+  doCheck = true;
+
+  postInstall = ''
+    mkdir -p "$out/share/emacs/site-lisp"
+    cp -v *.el "$out/share/emacs/site-lisp"
+
+    wrapProgram $out/bin/gtags \
+      --prefix PYTHONPATH : "$(toPythonPath ${pygments})"
+    wrapProgram $out/bin/global \
+      --prefix PYTHONPATH : "$(toPythonPath ${pygments})"
+  '';
+
+  meta = with lib; {
+    description = "Source code tag system";
+    longDescription = ''
+      GNU GLOBAL is a source code tagging system that works the same way
+      across diverse environments (Emacs, vi, less, Bash, web browser, etc).
+      You can locate specified objects in source files and move there easily.
+      It is useful for hacking a large project containing many
+      subdirectories, many #ifdef and many main() functions.  It is similar
+      to ctags or etags but is different from them at the point of
+      independence of any editor.  It runs on a UNIX (POSIX) compatible
+      operating system like GNU and BSD.
+    '';
+    homepage = "https://www.gnu.org/software/global/";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ pSub peterhoeg ];
+    platforms = platforms.unix;
+  };
+}