diff --git a/recipes/hematite/recipe.sh b/recipes/hematite/recipe.sh deleted file mode 100644 index 14014f56f5fd035edd8ae4f8a6864cc75b74dc35..0000000000000000000000000000000000000000 --- a/recipes/hematite/recipe.sh +++ /dev/null @@ -1,16 +0,0 @@ -GIT=https://gitlab.redox-os.org/redox-os/hematite.git -GIT_UPSTREAM=https://github.com/PistonDevelopers/hematite.git -BUILD_DEPENDS=(llvm mesa zlib) -BRANCH=redox - -function recipe_build { - sysroot="$(realpath ../sysroot)" - cp -p "$ROOT/Xargo.toml" "Xargo.toml" - set -x - xargo rustc --target "$TARGET" --release ${CARGOFLAGS} \ - -- \ - -L "${sysroot}/lib" \ - -C link-args="$("${PKG_CONFIG}" --libs osmesa) -lglapi -lz -lstdc++ -lc -lgcc" - set +x - skip=1 -} diff --git a/recipes/hematite/recipe.toml b/recipes/hematite/recipe.toml new file mode 100644 index 0000000000000000000000000000000000000000..e7cbb89242ff8a62a0ea2842ed837096c2657df9 --- /dev/null +++ b/recipes/hematite/recipe.toml @@ -0,0 +1,23 @@ +[source] +git = "https://gitlab.redox-os.org/redox-os/hematite.git" +branch = "redox" +upstream = "https://github.com/PistonDevelopers/hematite.git" + +[build] +template = "custom" +dependencies = [ + "llvm", + "mesa", + "zlib" +] +script = """ +cargo rustc \ + --target "$TARGET" \ + --release \ + --manifest-path "${COOKBOOK_SOURCE}/Cargo.toml" \ + -- \ + -L "${COOKBOK_SYSROOT}/lib" \ + -C link-args="-Wl,-Bstatic $("${TARGET}-pkg-config" --libs osmesa) -lz -lstdc++ -lc -lgcc" +mkdir -pv "${COOKBOOK_STAGE}/bin" +cp -v "target/${TARGET}/release/hematite" "${COOKBOOK_STAGE}/bin/hematite" +"""