initial hello world
This commit is contained in:
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
output/
|
||||
11
Makefile
Normal file
11
Makefile
Normal file
@@ -0,0 +1,11 @@
|
||||
CC = cc
|
||||
OUTPUT_FOLDER = output
|
||||
OUTPUT = $(OUTPUT_FOLDER)/wamf
|
||||
|
||||
all: run
|
||||
$(OUTPUT_FOLDER):
|
||||
mkdir $(OUTPUT_FOLDER)
|
||||
build: $(OUTPUT_FOLDER)
|
||||
$(CC) -o $(OUTPUT) src/main.c
|
||||
run: build
|
||||
cd $(OUTPUT_FOLDER) && ./wamf
|
||||
27
flake.lock
generated
Normal file
27
flake.lock
generated
Normal file
@@ -0,0 +1,27 @@
|
||||
{
|
||||
"nodes": {
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1770197578,
|
||||
"narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
||||
17
flake.nix
Normal file
17
flake.nix
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
description = "development shell";
|
||||
|
||||
inputs.nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||
|
||||
outputs = { self, nixpkgs }:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
in {
|
||||
devShells.x86_64-linux.default = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
clang
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
5
src/main.c
Normal file
5
src/main.c
Normal file
@@ -0,0 +1,5 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
printf("hello");
|
||||
}
|
||||
Reference in New Issue
Block a user