diff options
author | Esther Flashner <esther@flashner.co.il> | 2022-06-23 21:10:13 +0300 |
---|---|---|
committer | Efraim Flashner <efraim@flashner.co.il> | 2022-06-26 14:42:58 +0300 |
commit | 93901d406617fce1641c1a5baeb07c34bcab5127 (patch) | |
tree | d56a2d256545fb5da5d55ed619aee2e7dc5c98e5 | |
parent | 181fdbe319b47de8ea042c90f019306a927c9d73 (diff) | |
download | guix-93901d406617fce1641c1a5baeb07c34bcab5127.tar.gz |
gnu: Add gdmd.
* gnu/packages/dlang.scm (gdmd): New variable. Co-authored-by: Efraim Flashner <efraim@flashner.co.il>
-rw-r--r-- | gnu/packages/dlang.scm | 44 |
1 files changed, 43 insertions, 1 deletions
diff --git a/gnu/packages/dlang.scm b/gnu/packages/dlang.scm index d20b16cd3d..42e5023b19 100644 --- a/gnu/packages/dlang.scm +++ b/gnu/packages/dlang.scm @@ -5,9 +5,10 @@ ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017, 2019, 2022 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020 Guy Fleury Iteriteka <gfleury@disroot.org> -;;; Copyright © 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 ( <paren@disroot.org> +;;; Copyright © 2022 Esther Flashner <esther@flashner.co.il> ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,15 +35,18 @@ #:use-module ((guix build utils) #:hide (delete which)) #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) + #:use-module (guix build-system copy) #:use-module (gnu packages) #:use-module (gnu packages base) #:use-module (gnu packages check) #:use-module (gnu packages compression) #:use-module (gnu packages curl) + #:use-module (gnu packages gcc) #:use-module (gnu packages gdb) #:use-module (gnu packages libedit) #:use-module (gnu packages llvm) #:use-module (gnu packages ninja) + #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) @@ -102,6 +106,44 @@ which runs D source files as scripts, and @code{dustmite}, which reduces D code to a minimal test case.") (license license:boost1.0))) +(define-public gdmd + (let ((commit "ff2c97a47408fb71c18a2d453294d18808a97cc5") + (revision "1")) + (package + (name "gdmd") + (version (git-version "0.1.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/D-Programming-GDC/gdmd") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0pd70clk70069xcjysaas7zszzmigrcw1zl2xxv8kzdg7y7xrzvm")))) + (build-system copy-build-system) + (arguments + (list + #:install-plan + #~'(("dmd-script" "bin/gdmd") + ("dmd-script.1" "share/man/man1/gdmd.1")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'adjust-gdc-location + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "dmd-script" + (("my \\$gdc_dir.*") + (string-append "my $gdc_dir = \"" + (dirname (search-input-file inputs "/bin/gdc")) + "\";\n")))))))) + (inputs + (list gdc-10 perl)) + (home-page "https://github.com/D-Programming-GDC/gdmd") + (synopsis "DMD-like wrapper for GDC") + (description "This package provides a DMD-like wrapper for the +@acronym{GNU D Compiler,GDC}.") + (license license:gpl3+)))) + ;;; The 0.17.6 version is the last release to support being bootstrapped ;;; without a D compiler (requiring only a C++ compiler). ;;; TODO: Bootstrap ldc from GDC (the D frontend for GCC). |