This commit is contained in:
mtgmonkey 2025-06-27 04:10:26 -04:00
commit a183d55b69
5 changed files with 244 additions and 0 deletions

30
package.nix Normal file
View file

@ -0,0 +1,30 @@
{
lib,
stdenv,
nasm,
...
}:
stdenv.mkDerivation {
name = "asm-test";
src = ./src;
nativeBuildInputs = [
nasm
];
buildInputs = [
];
configurePhase = ''
'';
buildPhase = ''
nasm -f elf main.asm
ld -m elf_i386 main.o -o main
'';
installPhase = ''
mkdir -p $out/bin
cp main $out/bin/main
'';
meta = {
license = lib.licenses.wtfpl;
mainProgram = "main";
};
}