~vonfry/omnetpp-nix

1343f5e616834d0535c557618cc549784ae15be9 — Vonfry 11 months ago e9e618f
dev/nix: add flake
1 files changed, 28 insertions(+), 0 deletions(-)

A flake.nix
A flake.nix => flake.nix +28 -0
@@ 0,0 1,28 @@
{
  inputs.nixpkgs = "github:nixos/nixpkgs";
  outputs = { self, nixpkgs }:
    let
      system = "x86_64-linux";
      pkgs = nixpkgs.legacyPackages.${system};

      defaultScope = with pkgs; {
        inherit (qt5) qtbase wrapQtAppsHook;
        inherit (xorg) libX11 libXrender libXtst;
        gtk = gtk3;
      } ;

      nixPkgs =  rec {
        callPackage = pkgs.newScope (defaultScope // nixPkgs);
        omnetpp = callPackage ./. { };
        keetchi = callPackage ./keetchi.nix { };
        inet = callPackage ./inet.nix { };
        ops = callPackage ./ops.nix { };
        osgearth = callPackage ./osgearth.nix { gdal = pkgs.gdal_2; };
      };
    in {
      packages.${system} = nixPkgs;
      defaultPackage.${system} = nixPkgs.omnetpp;
      defaultApp.${system} = nixPkgs.omnetpp;
      legacyPackages.${system} = nixPkgs;
    };
}