From c4f6c86999ec8fe3b610ac269a121c9fa424daf5 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sat, 23 Oct 2021 19:49:43 -0400 Subject: dlang dub & nix build related, includes dep update - nix-shell --pure - nix-build - dub build --compiler=ldc2 --build=release --force --- org/config_dub.org | 35 +++++++++++++++++++++-------------- org/config_nix.org | 44 ++++++++++++++++++++++++++------------------ 2 files changed, 47 insertions(+), 32 deletions(-) (limited to 'org') diff --git a/org/config_dub.org b/org/config_dub.org index bb0091f..da65bfc 100644 --- a/org/config_dub.org +++ b/org/config_dub.org @@ -86,7 +86,8 @@ "authors": [ "Nicolas Sicard", "Other contributors: see Github repo" ], "copyright": "Copyright 2011-18 Nicolas Sicard", "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends/d2sqlite3/source" ], + "sourcePaths": [ "./src/ext_depends/d2sqlite3/source" ], + "importPaths": [ "./src/ext_depends/d2sqlite3/source" ], "configurations": [ { "name": "d2sqlite3", @@ -103,7 +104,8 @@ "description": "Decoders for PNG, TGA, BMP, JPEG and encoders for PNG, TGA, BMP.", "authors": [ "Tero Hänninen" ], "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends/imageformats/imageformats" ] + "sourcePaths": [ "./src/ext_depends/imageformats" ], + "importPaths": [ "./src/ext_depends/imageformats" ] }, { "name": "dyaml", @@ -115,12 +117,12 @@ "license": "BSL-1.0", "homepage": "https://github.com/dlang-community/D-YAML", "copyright": "Copyright © 2011-2018, Ferdinand Majerech", - "sourcePaths": [ - "./src/ext_depends/D-YAML/source/dyaml", + "sourcePaths": [ + "./src/ext_depends/D-YAML/source", "./src/ext_depends/tinyendian/source" ], - "importPaths": [ - "./src/ext_depends/D-YAML/source/dyaml", + "importPaths": [ + "./src/ext_depends/D-YAML/source", "./src/ext_depends/tinyendian/source" ], "preGenerateCommands": [ @@ -190,7 +192,8 @@ "authors": [ "Nicolas Sicard", "Other contributors: see Github repo" ], "copyright": "Copyright 2011-18 Nicolas Sicard", "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends/d2sqlite3/source" ], + "sourcePaths": [ "./src/ext_depends/d2sqlite3/source" ], + "importPaths": [ "./src/ext_depends/d2sqlite3/source" ], "configurations": [ { "name": "with-lib", @@ -206,7 +209,8 @@ "description": "Decoders for PNG, TGA, BMP, JPEG and encoders for PNG, TGA, BMP.", "authors": [ "Tero Hänninen" ], "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends/imageformats/imageformats" ] + "sourcePaths": [ "./src/ext_depends/imageformats" ], + "importPaths": [ "./src/ext_depends/imageformats" ] }, { "name": "dyaml", @@ -218,9 +222,9 @@ "license": "BSL-1.0", "homepage": "https://github.com/dlang-community/D-YAML", "copyright": "Copyright © 2011-2018, Ferdinand Majerech", - "sourcePaths": [ "./src/ext_depends/D-YAML/source/dyaml" ], - "importPaths": [ - "./src/ext_depends/D-YAML/source/dyaml", + "sourcePaths": [ "./src/ext_depends/D-YAML/source" ], + "importPaths": [ + "./src/ext_depends/D-YAML/source", "./src/ext_depends/tinyendian/source" ], "dependencies": { @@ -238,7 +242,8 @@ "license": "Boost 1.0", "copyright": "Copyright © 2014, Ferdinand Majerech", "homepage": "https://github.com/kiith-sa/tinyendian", - "importPaths": [ "./src/ext_depends/tinyendian/source" ] + "sourcePaths": [ "./src/ext_depends/tinyendian/source" ], + "importPaths": [ "./src/ext_depends/tinyendian/source" ] } ], "configurations": [ @@ -569,7 +574,8 @@ configuration "build" { "authors": [ "Adam Ruppee" ], "copyright": "Copyright 2011-18 Adam Ruppee", "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends_cgi/arsd" ], + "sourcePaths": [ "./src/ext_depends_cgi/arsd" ], + "importPaths": [ "./src/ext_depends_cgi/arsd" ], "configurations": [ { "name": "cgi", @@ -586,7 +592,8 @@ configuration "build" { "authors": [ "Nicolas Sicard", "Other contributors: see Github repo" ], "copyright": "Copyright 2011-18 Nicolas Sicard", "license": "BSL-1.0", - "sourcePaths": [ "./src/ext_depends_cgi/d2sqlite3/source" ], + "sourcePaths": [ "./src/ext_depends_cgi/d2sqlite3/source" ], + "importPaths": [ "./src/ext_depends_cgi/d2sqlite3/source" ], "configurations": [ { "name": "d2sqlite3", diff --git a/org/config_nix.org b/org/config_nix.org index c5bd8dd..9763c57 100644 --- a/org/config_nix.org +++ b/org/config_nix.org @@ -555,14 +555,15 @@ nix flake update #+HEADER: :shebang "#!/usr/bin/env -S nix-shell --pure" #+BEGIN_SRC nix { pkgs ? import {} }: -pkgs.mkShell { - buildInputs = with pkgs; [ +with pkgs; +mkShell { + buildInputs = [ <> <> - <> - # <> + <> # <> # <> + <> ]; shellHook = '' if [[ -e ".envrc" ]]; then @@ -609,7 +610,6 @@ starship #+NAME: shell_packages_search_related_sqlite #+BEGIN_SRC nix -# search_sqlite_related # search related sqlite #+END_SRC @@ -688,6 +688,15 @@ nix build -f spine.nix #+HEADER: :tangle-mode (identity #o755) #+HEADER: :shebang "#!/usr/bin/env -S nix-build" #+BEGIN_SRC nix +{ pkgs ? import {} }: +pkgs.callPackage ./derivation.nix {} +#+END_SRC + +*** derivation.nix :default: + +#+HEADER: :tangle ../derivation.nix +#+HEADER: :tangle-mode (identity #o644) +#+BEGIN_SRC nix { pkgs ? import {}, stdenv ? pkgs.stdenv, lib ? pkgs.lib, @@ -779,11 +788,6 @@ mkDubDerivation rec { ldc sqlite ]; - # buildPhase = [ ]; - installPhase = '' - install -m755 -D spine $out/bin/spine - echo "built $out/bin/spine" - ''; <> } #+END_SRC @@ -1109,8 +1113,9 @@ nix flake update #+HEADER: :shebang "#!/usr/bin/env -S nix-shell --pure" #+BEGIN_SRC nix { pkgs ? import {} }: -pkgs.mkShell { - buildInputs = with pkgs; [ +with pkgs; +mkShell { + buildInputs = [ <> <> <> @@ -1131,6 +1136,15 @@ pkgs.mkShell { #+HEADER: :tangle-mode (identity #o755) #+HEADER: :shebang "#!/usr/bin/env -S nix-build" #+BEGIN_SRC nix +{ pkgs ? import {} }: +pkgs.callPackage ./derivation.nix {} +#+END_SRC + +*** derivation.nix :derivation: + +#+HEADER: :tangle "../sundry/spine_search_cgi/derivation.nix" +#+HEADER: :tangle-mode (identity #o644) +#+BEGIN_SRC nix { pkgs ? import {}, stdenv ? pkgs.stdenv, lib ? pkgs.lib, @@ -1231,11 +1245,6 @@ mkDubDerivation rec { ] ) ]; - # # buildPhase = [ ]; - # installPhase = '' - # install -m755 -D spine_search $out/bin/spine-search - # echo "built $out/bin/spine-search" - # ''; meta = with pkgs.lib; { homepage = https://sisudoc.org; description = "a sisu like document parser"; @@ -1429,4 +1438,3 @@ fc-query DejaVuSans.ttf | grep '^\s\+family:' | cut -d'"' -f2 $XDG_DATA_HOME/fonts ~/.local/share/fonts #+END_SRC - -- cgit v1.2.3