Skip to content

Commit

Permalink
softioc: init at 4.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Synthetica9 committed Nov 29, 2024
1 parent 46e0ac8 commit b878529
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkgs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ in
pvxslibs = final.callPackage ./epnix/python-modules/pvxslibs {};
aioca = final.callPackage ./epnix/python-modules/aioca/default.nix {};
epicsdbbuilder = final.callPackage ./epnix/python-modules/epicsdbbuilder {};
softioc = final.callPackage ./epnix/python-modules/softioc {};

# epicscorelibs needs at least 2.11.
# TODO: remove for NixOS 24.11
Expand Down Expand Up @@ -93,7 +94,7 @@ in

channel-finder-service = callPackage ./epnix/tools/channel-finder/service {};

inherit (final.python3Packages) lewis pyepics aioca;
inherit (final.python3Packages) lewis pyepics aioca softioc;
inherit (callPackage ./epnix/tools/lewis/lib.nix {}) mkLewisSimulator;

pcas = callPackage ./epnix/tools/pcas {};
Expand Down
38 changes: 38 additions & 0 deletions pkgs/epnix/python-modules/softioc/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
lib,
buildPythonPackage,
fetchgit,
setuptools,
epicscorelibs,
pvxslibs,
epicsdbbuilder,
epnixLib,
}:
buildPythonPackage rec {
pname = "softioc";
version = "4.5.0";

pyproject = true;

src = fetchgit {
url = "https://github.com/DiamondLightSource/pythonSoftIOC.git";
rev = version;
fetchSubmodules = true;
hash = "sha256-JXfFkA3MzipqUw0riMTZmgCP9qe4Tfj8vZaFBwqoO+c=";
};

# Set correct version instead of automatically detected version:
postPatch = ''
awk -i inplace "/__version__/ && !x {print; print \"__version__ = '${version}'\"; x=1; next} 1" setup.py
'';

build-system = [setuptools];
dependencies = [setuptools epicscorelibs epicsdbbuilder pvxslibs];

meta = {
description = "Embed an EPICS IOC in a Python process";
homepage = "https://DiamondLightSource.github.io/pythonSoftIOC";
license = lib.licenses.asl20;
maintainers = with epnixLib.maintainers; [synthetica];
};
}

0 comments on commit b878529

Please sign in to comment.