From ea7d4bc02f5b9e90759bde04533c987456514d17 Mon Sep 17 00:00:00 2001 From: Able <75036841+AbleTheAbove@users.noreply.github.com> Date: Thu, 7 Mar 2024 10:05:17 -0600 Subject: [PATCH] Add in nix packaging (#1) * Add in nix packaging * include stdint * Fixes the PRs --- hbas.c | 1 + run.sh | 2 ++ shell.nix | 9 +++++++++ 3 files changed, 12 insertions(+) create mode 100755 run.sh create mode 100644 shell.nix diff --git a/hbas.c b/hbas.c index 2e876d6..88a9750 100644 --- a/hbas.c +++ b/hbas.c @@ -23,6 +23,7 @@ SOFTWARE. #include #include #include +#include void hd(char *data, size_t len) { for (size_t ii = 0; ii < len; ii += 1) { diff --git a/run.sh b/run.sh new file mode 100755 index 0000000..e5e8659 --- /dev/null +++ b/run.sh @@ -0,0 +1,2 @@ +make CC=clang +./hbas < example.S > example.hbf diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000..8655f3b --- /dev/null +++ b/shell.nix @@ -0,0 +1,9 @@ +{ pkgs ? import { } }: +pkgs.mkShell rec { + buildInputs = with pkgs; [ + clang + ]; + shellHook = '' + export CC=clang + ''; +}