diff --git a/common/build-style/cmake.sh b/common/build-style/cmake.sh index 5760f73dbc8..124ed354eff 100644 --- a/common/build-style/cmake.sh +++ b/common/build-style/cmake.sh @@ -40,6 +40,7 @@ SET(CMAKE_SYSTEM_VERSION 1) SET(CMAKE_C_COMPILER ${CC}) SET(CMAKE_CXX_COMPILER ${CXX}) +SET(Rust_CARGO_TARGET ${XBPS_CROSS_RUST_TARGET}) SET(CMAKE_CROSSCOMPILING TRUE) SET(CMAKE_SYSTEM_PROCESSOR ${_CMAKE_SYSTEM_PROCESSOR}) diff --git a/srcpkgs/corrosion/template b/srcpkgs/corrosion/template new file mode 100644 index 00000000000..0d5663beec5 --- /dev/null +++ b/srcpkgs/corrosion/template @@ -0,0 +1,22 @@ +# Template file for 'corrosion' +pkgname=corrosion +version=0.4.4 +revision=1 +build_style=cmake +hostmakedepends="cargo" +short_desc="Tool for integrating Rust into an existing CMake project" +maintainer="John " +license="MIT" +homepage="https://github.com/corrosion-rs/corrosion" +distfiles="https://github.com/corrosion-rs/corrosion/archive/refs/tags/v${version}.tar.gz" +checksum=bf3981d0e066f2c877949ec59d9ed6cb193ae4ff615b73f20c64a5de68fc06ab + +do_check() { + cd build + # Require and uses rustup + ctest -E '(rustup_proxy_build|parse_target_triple_build)' +} + +post_install() { + vlicense LICENSE +}