From 219038c445a34c5e506787d5457779c6db8f2b6c Mon Sep 17 00:00:00 2001 From: Roland Conybeare Date: Sat, 10 May 2025 19:16:43 -0500 Subject: [PATCH] + xo-flatstring --- CMakeLists.txt | 2 +- default.nix | 2 +- pkgs/xo-flatstring.nix | 53 ++++++++++++++++++++++++++++++++++++++++++ pkgs/xo-userenv.nix | 4 ++-- 4 files changed, 57 insertions(+), 4 deletions(-) create mode 100644 pkgs/xo-flatstring.nix diff --git a/CMakeLists.txt b/CMakeLists.txt index 125ac956..dc83426d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -70,8 +70,8 @@ add_subdirectory(xo-refcnt) add_subdirectory(xo-subsys) add_subdirectory(xo-randomgen) add_subdirectory(xo-ordinaltree) +add_subdirectory(xo-flatstring) #add_subdirectory(xo-pyutil) -#add_subdirectory(xo-flatstring) #add_subdirectory(xo-reflectutil) #add_subdirectory(xo-reflect) #add_subdirectory(xo-pyreflect) diff --git a/default.nix b/default.nix index fded1338..6e914f3d 100644 --- a/default.nix +++ b/default.nix @@ -43,8 +43,8 @@ let xo-subsys = self.callPackage pkgs/xo-subsys.nix {}; xo-randomgen = self.callPackage pkgs/xo-randomgen.nix {}; xo-ordinaltree = self.callPackage pkgs/xo-ordinaltree.nix {}; + xo-flatstring = self.callPackage pkgs/xo-flatstring.nix {}; # xo-pyutil = self.callPackage pkgs/xo-pyutil.nix {}; -# xo-flatstring = self.callPackage pkgs/xo-flatstring.nix {}; # xo-reflectutil = self.callPackage pkgs/xo-reflectutil.nix {}; # xo-reflect = self.callPackage pkgs/xo-reflect.nix {}; # xo-pyreflect = self.callPackage pkgs/xo-pyreflect.nix {}; diff --git a/pkgs/xo-flatstring.nix b/pkgs/xo-flatstring.nix new file mode 100644 index 00000000..a1b01806 --- /dev/null +++ b/pkgs/xo-flatstring.nix @@ -0,0 +1,53 @@ +{ + # dependencies + lib, stdenv, cmake, catch2, doxygen, + + python3Packages, + + sphinx, + + xo-cmake, xo-indentlog, + + buildDocs ? false, +} : + +stdenv.mkDerivation (finalattrs: + { + name = "xo-flatstring"; + version = "1.0"; + + outputs = [ + "out" + ] +# ++ lib.optionals buildDocs [ +# "doc" + # ] + ; + + src = ../xo-flatstring; + + # guessing may need this for doxygen etc + # env.LC_ALL = "en_US.UTF-8"; + + cmakeFlags = ["-DCMAKE_MODULE_PATH=${xo-cmake}/share/cmake"]; + doCheck = true; + + propagatedBuildInputs = [ ]; + + nativeBuildInputs = [ + cmake + catch2 + doxygen + sphinx + xo-cmake + xo-indentlog + ] +# + lib.optionals buildDocs [ +# doxygen +# sphinx +# python3Packages.sphinx-rtd-theme +# python3Packages.breathe + # ] + ; + + }) diff --git a/pkgs/xo-userenv.nix b/pkgs/xo-userenv.nix index c7d9c23b..74f681ff 100644 --- a/pkgs/xo-userenv.nix +++ b/pkgs/xo-userenv.nix @@ -28,7 +28,7 @@ xo-subsys, xo-randomgen, xo-ordinaltree, -# xo-flatstring, + xo-flatstring, # xo-reflectutil, # xo-ratio, # xo-unit, @@ -63,8 +63,8 @@ buildEnv { xo-subsys xo-randomgen xo-ordinaltree + xo-flatstring # xo-pyutil -# xo-flatstring # xo-reflectutil # xo-reflect # xo-pyreflect