@@ -13,16 +13,16 @@ stdenv.mkDerivation rec {
1313
1414 nativeBuildInputs = [ premake5 ];
1515
16− # Don’t guess where our makefiles will end up. Just use current
17− # directory.
18− patchPhase = ''
19− substituteInPlace premake5.lua \
20− --replace 'location "build/gmake"' 'location "."'
21− '';
16+ patches = [
17+ ./fix-aarch64.patch
18+ ./move-makefiles.patch
19+ ];
20+
21+ buildFlags = stdenv.lib.optional stdenv.isAarch64 [ "config=release_arm" ];
2222
2323 installPhase = ''
2424 mkdir -p $out/bin
25− cp bin/release-x*/otfcc* $out/bin/
25+ cp bin/release-*/otfcc* $out/bin/
2626 '';
2727
2828 enableParallelBuilding = true;
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
3131 description = "Optimized OpenType builder and inspector";
3232 homepage = "https://github.com/caryll/otfcc";
3333 license = licenses.asl20;
34− platforms = [ "i686-linux" "x86_64-linux" "x86_64-darwin" ];
34+ platforms = [ "aarch64-linux" "i686-linux" "x86_64-linux" "x86_64-darwin" ];
3535 maintainers = with maintainers; [ jfrankenau ttuegel ];
3636 };
3737