Skip to content

Instantly share code, notes, and snippets.

@rgoulter
Created May 10, 2024 05:23
Show Gist options
  • Save rgoulter/3f9f69839650e968fd3b9696111b0c2b to your computer and use it in GitHub Desktop.
Save rgoulter/3f9f69839650e968fd3b9696111b0c2b to your computer and use it in GitHub Desktop.
{ pkgs ? import <nixpkgs> {} }:
pkgs.stdenv.mkDerivation {
pname = "stdenv-maketargets-demo";
version = "0.0.0";
src = ./.;
makeTargets = ["foo" "bar"];
installPhase = ''
mkdir -p $out
'';
}
.PHONY: all foo bar
all:
echo "true"
foo:
echo "foo"
bar:
exit 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment