technically works: Perspective, matrices, other fun stuff

This commit is contained in:
mtgmonkey
2025-12-02 19:35:44 +01:00
parent ed61ff3868
commit d5719e36ba
13 changed files with 226 additions and 112 deletions

View File

@@ -13,7 +13,7 @@
"-Wincomplete-record-updates"
"-Wincomplete-uni-patterns"
"-Wmissing-export-lists"
"-Wmossing-home-modules"
"-Wmissing-home-modules"
"-Wpartial-fields"
"-Wredundant-constraints"
"-threaded"
@@ -23,9 +23,20 @@
"-i./lib/hs-glsl/src"
# src
"-i./src"
"-main-is Haskengl.Main"
];
haddockOptions = lib.concatStringsSep " " haddockFlags;
haddockFlags = [
"--html"
"--odir docs"
"--optghc=-i./src"
"--optghc=-i./lib/hs-glsl/src"
"src/Haskengl/Main.hs"
];
ghcPackages = p: [
p.GLFW-b
p.linear
p.linear-opengl
p.OpenGL
p.relude
];
@@ -42,11 +53,13 @@ in
configurePhase = ''
'';
buildPhase = ''
ghc ${ghcExeOptions} ./src/Main.hs -o ./Main
ghc ${ghcExeOptions} ./src/Haskengl/Main.hs -o ./Main
'';
installPhase = ''
mkdir -p $out/bin
cp ./Main $out/bin/haskengl
#haddock ${haddockOptions}
#cp ./docs $out/docs -r
'';
meta = {