xo-unit: nix: fix deps after splitting off xo-flatstring,xo-ratio

This commit is contained in:
Roland Conybeare 2024-05-02 10:13:50 -04:00
commit 7d53a47f50
10 changed files with 107 additions and 31 deletions

View file

@ -50,8 +50,11 @@
inputs.xo-cmake-path = { type = "github"; owner = "Rconybea"; repo = "xo-cmake"; flake = false; };
inputs.xo-indentlog-path = { type = "github"; owner = "Rconybea"; repo = "indentlog"; flake = false; };
inputs.xo-flatstring-path = { type = "github"; owner = "Rconybea"; repo = "xo-flatstring"; flake = false; };
inputs.xo-refcnt-path = { type = "github"; owner = "Rconybea"; repo = "refcnt"; flake = false; };
inputs.xo-subsys-path = { type = "github"; owner = "Rconybea"; repo = "subsys"; flake = false; };
inputs.xo-randomgen-path = { type = "github"; owner = "Rconybea"; repo = "randomgen"; flake = false; };
inputs.xo-ratio-path = { type = "github"; owner = "Rconybea"; repo = "xo-ratio"; flake = false; };
#inputs.xo-pyutil-path = { type = "github"; owner = "Rconybea"; repo = "xo-pyutil"; flake = false; };
inputs.xo-reflect-path = { type = "github"; owner = "Rconybea"; repo = "reflect"; flake = false; };
#inputs.xo-pyreflect-path = { type = "github"; owner = "Rconybea"; repo = "xo-pyreflect"; flake = false; };
@ -64,8 +67,11 @@
flake-utils,
xo-cmake-path,
xo-indentlog-path,
xo-flatstring-path,
xo-refcnt-path,
xo-subsys-path,
xo-randomgen-path,
xo-ratio-path,
xo-reflect-path,
# placeholder-B
} :
@ -97,8 +103,11 @@
packages.xo-cmake = appliedOverlay.xo-cmake;
packages.xo-indentlog = appliedOverlay.xo-indentlog;
packages.xo-flatstring = appliedOverlay.xo-flatstring;
packages.xo-refcnt = appliedOverlay.xo-refcnt;
packages.xo-subsys = appliedOverlay.xo-subsys;
packages.xo-randomgen = appliedOverlay.xo-randomgen;
packages.xo-ratio = appliedOverlay.xo-ratio;
packages.xo-reflect = appliedOverlay.xo-reflect;
packages.xo-unit = appliedOverlay.xo-unit;
# placeholder-C
@ -147,10 +156,32 @@
(prev.callPackage ./pkgs/xo-indentlog.nix { xo-cmake = xo-cmake; }).overrideAttrs
(old: { src = xo-indentlog-path; });
xo-flatstring =
(prev.callPackage ./pkgs/xo-flatstring.nix { xo-cmake = xo-cmake;
xo-indentlog = xo-indentlog;
python = python;
pythonPackages = pythonPackages; }).overrideAttrs
(old: { src = xo-flatstring-path; });
xo-subsys =
(prev.callPackage ./pkgs/xo-subsys.nix { xo-cmake = xo-cmake; }).overrideAttrs
(old: { src = xo-subsys-path; });
xo-randomgen =
(prev.callPackage ./pkgs/xo-randomgen.nix { xo-cmake = xo-cmake;
xo-indentlog = xo-indentlog;
}).overrideAttrs
(old: { src = xo-randomgen-path; });
xo-ratio =
(prev.callPackage ./pkgs/xo-ratio.nix { xo-cmake = xo-cmake;
xo-flatstring = xo-flatstring;
xo-randomgen = xo-randomgen;
python = python;
pythonPackages = pythonPackages;
}).overrideAttrs
(old: { src = xo-ratio-path; });
xo-refcnt =
(prev.callPackage ./pkgs/xo-refcnt.nix { xo-cmake = xo-cmake;
xo-indentlog = xo-indentlog; }).overrideAttrs
@ -164,7 +195,9 @@
xo-unit =
(prev.callPackage ./pkgs/xo-unit.nix { xo-cmake = xo-cmake;
xo-reflect = xo-reflect;
xo-flatstring = xo-flatstring;
xo-randomgen = xo-randomgen;
xo-ratio = xo-ratio;
python = python;
pythonPackages = pythonPackages;
}).overrideAttrs
@ -178,6 +211,8 @@
xo-indentlog = xo-indentlog;
xo-subsys = xo-subsys;
xo-refcnt = xo-refcnt;
xo-randomgen = xo-randomgen;
xo-ratio = xo-ratio;
xo-reflect = xo-reflect;
xo-unit = xo-unit;
}).overrideAttrs(old: {});
@ -192,8 +227,11 @@
{
xo-cmake = xo-cmake;
xo-indentlog = xo-indentlog;
xo-flatstring = xo-flatstring;
xo-subsys = xo-subsys;
xo-refcnt = xo-refcnt;
xo-randomgen = xo-randomgen;
xo-ratio = xo-ratio;
xo-reflect = xo-reflect;
xo-unit = xo-unit;
# placeholder-E

View file

@ -1,8 +1,24 @@
{
# nixpkgs dependencies
# 1. nixpkgs dependencies
# 1.1. python
python, pythonPackages,
# 1.2. particular python packages
sphinx ? pythonPackages.sphinx,
sphinx-rtd-theme ? pythonPackages.sphinx-rtd-theme,
breathe ? pythonPackages.breathe,
# 1.3. document-generation packages
# use of makeFontsConf adapted from nixpkgs/development/libraries/gtkmm/4.x.nix
#
doxygen, graphviz,
##fontconfig,
##makeFontsConf,
# 1.4. c++ build/utest chain
stdenv, cmake, catch2, # ... other deps here
# xo dependencies
# 2. xo dependencies
xo-cmake, xo-indentlog
# args
@ -31,7 +47,29 @@ stdenv.mkDerivation (finalattrs:
});
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
# move HOME so fontconfig can do sensible things
buildPhase = ''
#set -x
echo "FONTCONFIG_FILE=$FONTCONFIG_FILE"
#export FONTCONFIG_FILE=$fontconfig.out/etc/fonts/fonts.conf
export HOME=$TMPDIR
export XDG_CONFIG_HOME=$TMPDIR
mkdir $XDG_CONFIG_HOME/fontconfig
#grep xdg $FONTCONFIG_FILE
#$fontconfig.out/bin/fc-cache -v
make && make docs
#make
'';
doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
nativeBuildInputs = [ cmake catch2
doxygen graphviz sphinx sphinx-rtd-theme breathe ];
propagatedBuildInputs = [ xo-indentlog ];
})

View file

@ -30,7 +30,7 @@ stdenv.mkDerivation (finalattrs:
#rev = "c0472c9d7e4d2c53bfb977d3182380832fe96645";
});
cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"];
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
})

View file

@ -3,7 +3,7 @@
stdenv, cmake, catch2, # ... other deps here
# xo dependencies
xo-cmake,
xo-cmake, xo-indentlog
# args
@ -33,4 +33,5 @@ stdenv.mkDerivation (finalattrs:
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
propagatedBuildInputs = [ xo-indentlog ];
})

View file

@ -1,17 +1,17 @@
{
# 1. nixpkgs dependencies
# 1.1. python
#python, pythonPackages,
python, pythonPackages,
# 1.2. particular python packages
#sphinx ? pythonPackages.sphinx,
#sphinx-rtd-theme ? pythonPackages.sphinx-rtd-theme,
#breathe ? pythonPackages.breathe,
sphinx ? pythonPackages.sphinx,
sphinx-rtd-theme ? pythonPackages.sphinx-rtd-theme,
breathe ? pythonPackages.breathe,
# 1.3. document-generation packages
# use of makeFontsConf adapted from nixpkgs/development/libraries/gtkmm/4.x.nix
#
#doxygen, graphviz,
doxygen, graphviz,
##fontconfig,
##makeFontsConf,
@ -22,7 +22,7 @@
stdenv, cmake, catch2, # ... other deps here
# 2. xo dependencies
xo-cmake,
xo-cmake, xo-flatstring, xo-randomgen,
# args
@ -40,7 +40,7 @@
stdenv.mkDerivation (finalattrs:
{
name = "xo-unit";
name = "xo-ratio";
src = (fetchGit {
url = "https://github.com/rconybea/xo-ratio";
@ -70,14 +70,14 @@ stdenv.mkDerivation (finalattrs:
#$fontconfig.out/bin/fc-cache -v
#make && make docs
make && make install
make && make docs
#make
'';
doCheck = true;
nativeBuildInputs = [ cmake catch2
#doxygen graphviz sphinx sphinx-rtd-theme breathe
doxygen graphviz sphinx sphinx-rtd-theme breathe
xo-randomgen
];
propagatedBuildInputs = [ ];
propagatedBuildInputs = [ xo-flatstring ];
})

View file

@ -30,7 +30,7 @@ stdenv.mkDerivation (finalattrs:
#rev = "c0472c9d7e4d2c53bfb977d3182380832fe96645";
});
cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"];
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
propagatedBuildInputs = [ xo-indentlog ];

View file

@ -30,7 +30,7 @@ stdenv.mkDerivation (finalattrs:
#rev = "c0472c9d7e4d2c53bfb977d3182380832fe96645";
});
cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"];
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
propagatedBuildInputs = [ xo-subsys xo-refcnt ];

View file

@ -30,7 +30,7 @@ stdenv.mkDerivation (finalattrs:
#rev = "c0472c9d7e4d2c53bfb977d3182380832fe96645";
});
cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"];
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
#doCheck = true;
nativeBuildInputs = [ cmake catch2 ];
})

View file

@ -16,13 +16,13 @@
makeFontsConf,
# used for graphviz (dot) see docs/Doxyfile.in
helvetica-neue-lt-std,
#helvetica-neue-lt-std,
# 1.4. c++ build/utest chain
stdenv, cmake, catch2, # ... other deps here
# 2. xo dependencies
xo-cmake, xo-reflect,
xo-cmake, xo-flatstring, xo-ratio, xo-randomgen,
# args
@ -49,9 +49,10 @@ stdenv.mkDerivation (finalattrs:
#rev = "c0472c9d7e4d2c53bfb977d3182380832fe96645";
});
cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"];
cmakeFlags = ["-DXO_CMAKE_CONFIG_EXECUTABLE=${xo-cmake}/bin/xo-cmake-config"];
FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ helvetica-neue-lt-std ]; };
# NOTE: helvetic-neue-lt-std has unfree license
#FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ helvetica-neue-lt-std ]; };
# move HOME so fontconfig can do sensible things
buildPhase = ''
@ -72,10 +73,7 @@ stdenv.mkDerivation (finalattrs:
make && make docs
'';
# NOTE: helvetic-neue-lt-std has unfree license
#FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ helvetica-neue-lt-std ]; };
doCheck = true;
nativeBuildInputs = [ cmake catch2 doxygen graphviz sphinx sphinx-rtd-theme breathe ];
propagatedBuildInputs = [ xo-reflect ];
nativeBuildInputs = [ cmake catch2 doxygen graphviz sphinx sphinx-rtd-theme breathe xo-randomgen ];
propagatedBuildInputs = [ xo-flatstring xo-ratio ];
})

View file

@ -3,7 +3,7 @@
buildFHSUserEnv, # ... other deps here
# xo dependencies
xo-cmake, xo-indentlog, xo-subsys, xo-refcnt, xo-reflect, xo-unit,
xo-cmake, xo-indentlog, xo-subsys, xo-refcnt, xo-ratio, xo-reflect, xo-unit,
# other args
@ -16,6 +16,7 @@ buildFHSUserEnv {
xo-indentlog
xo-subsys
xo-refcnt
xo-ratio
xo-reflect
xo-unit
];