aboutsummaryrefslogtreecommitdiffhomepage
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md75
1 files changed, 35 insertions, 40 deletions
diff --git a/README.md b/README.md
index f00dd95..2d0b092 100644
--- a/README.md
+++ b/README.md
@@ -71,61 +71,51 @@ directory: sisudoc-spine
NOTE all actions to build sisudoc-spine are taken within the directory
sisudoc-spine
-cd sisudoc-spine
-
-to build directly with dub, either:
-
-for ldc2:
- # on nix (get dependencies by setting your development environment):
- nix develop ".#dsh-nixpkgs-ldc-dub" --print-build-logs -c zsh
-
- # assuming you have ldc2 & dub installed on your system:
- dub run --compiler=ldmd2 --config=ldmd2 --combined --skip-registry=all
- dub --compiler=ldmd2 --config=ldmd2
+NOTE:
+- if dub is used to build, the resulting binary should be located in ./bin:
+- if "nix build" is used the resulting binary should be in ./result/bin
- dub run --compiler=ldc2 --config=ldc2 --combined --skip-registry=all
- dub --compiler=ldc2 --config=ldc2
-
-for dmd:
- # on nix (get dependencies by setting your development environment):
- nix develop ".#dsh-nixpkgs-dmd-dub" --print-build-logs -c zsh
-
- # assuming you have dmd & dub installed on your system:
- dub run --compiler=dmd --config=dmd --combined --skip-registry=all
- dub --compiler=dmd --config=dmd
+cd sisudoc-spine
-to build with make using the provided makefile, (assuming you have the named
-compiler and dub installed on your system) either:
+### build using nix flakes on linux (binary in ./result/bin)
-for ldc2:
+you need to have nix installed on your system, and to have nix flakes enabled,
+on Debian for example, you would do the following:
- make ldc
+sudo apt install nix
-for dmd:
+create the file in the given path & filename: ~/.config/nix/nix.conf
+with the following content: experimental-features = flakes nix-command
- make dmd
+which can be achieved thusly:
-to build using nix flakes on linux / nixos
+mkdir -p ~/.config/nix && echo "experimental-features = flakes nix-command" >> ~/.config/nix/nix.conf
-for ldc2:
+- to use the D compiler ldc2:
nix build ".#spine-nixpkgs-ldc" --print-build-logs
-for dmd:
+- to use the D compiler dmd:
nix build ".#spine-nixpkgs-dmd" --print-build-logs
-The Meson build system was used briefly to build spine, but the spine build
-tooling for Meson has not been updated, maintained or tested in recent years.
+### build using dub directly (binary in ./bin)
+
+- to use the D compiler ldc2:
+ # on nix (get dependencies by setting your development environment):
+ nix develop ".#dsh-nixpkgs-ldc-dub" --print-build-logs -c zsh
- meson
- ninja -C build
- meson setup --wipe build && ninja -v -C build
- make meson
+ # assuming you have ldc2 & dub installed on your system:
+ dub run --compiler=ldmd2 --config=ldmd2 --combined --skip-registry=all
+ or
+ dub run --compiler=ldc2 --config=ldc2 --combined --skip-registry=all
-- https://mesonbuild.com/
+- to use the D compiler dmd:
+ # on nix (get dependencies by setting your development environment):
+ nix develop ".#dsh-nixpkgs-dmd-dub" --print-build-logs -c zsh
-dub --force --compiler=ldc2 && sudo cp -v cgi-bin/spine-search /usr/lib/cgi-bin/.
+ # assuming you have dmd & dub installed on your system:
+ dub run --compiler=dmd --config=dmd --combined --skip-registry=all
# Commands - document processing examples
@@ -134,10 +124,15 @@ dub --force --compiler=ldc2 && sudo cp -v cgi-bin/spine-search /usr/lib/cgi-bin/
For the most basic output you will need to specify:
- the spine binary (executable)
+ - for dub builds ./bin/spine (also used filenames: spine-dmd & spine-ldc)
+ - for nix flake builds ./result/bin/spine
+
- the (recognized) path to a prepared (spine marked up) document or document
collection
-- the (path to) where the output is to be placed
-- the output types you seek
+
+- the output types you seek, e.g. --html --epub
+
+- the (path for) where the generated output is to be placed
export SpineBIN=./result/bin/spine
export SpinePOD=../sisudoc-spine-samples/markup/pod