X-Git-Url: https://git.tld-linux.org/?p=packages%2Frpm-tld-macros.git;a=blobdiff_plain;f=macros.rust;fp=macros.rust;h=9ad61a05212520a09c04a6282d1e8f32bf48867b;hp=3f61146aad9d1ae17ee44450c5cd5bdea1174e47;hb=a8b462c1f839b0f67d81b5f94047e6e0f50c67d4;hpb=d37e647b8b3e05d3b062c9de9a86b19cdfc60740 diff --git a/macros.rust b/macros.rust index 3f61146..9ad61a0 100644 --- a/macros.rust +++ b/macros.rust @@ -2,7 +2,7 @@ %rpmrustflags %debuginforustflags %rust_arches %{x8664} %{ix86} x32 aarch64 armv6hl armv7hl armv7hnl -%cargo_target \\\ +%rust_target \\\ %ifarch i586\ i586-unknown-linux-gnu\\\ %endif\ @@ -29,8 +29,9 @@ thumbv7neon-unknown-linux-gnueabihf\\\ %endif\ %{nil} +%cargo_target %rust_target %cargo_targetdir target -%cargo_objdir %{?buildsubdir:%{_builddir}/%{buildsubdir}/}%{cargo_targetdir}/%{cargo_target}/%{!?debug:release}%{?debug:debug} +%cargo_objdir %{?buildsubdir:%{_builddir}/%{buildsubdir}/}%{cargo_targetdir}/%{rust_target}/%{!?debug:release}%{?debug:debug} %__cargo /usr/bin/cargo %__cargo_common_opts -v --offline @@ -44,7 +45,7 @@ thumbv7neon-unknown-linux-gnueabihf\\\ RUSTFLAGS="${RUSTFLAGS:-%rpmrustflags}" \\\ %{?__jobs:CARGO_BUILD_JOBS="${CARGO_BUILD_JOBS:-%{__jobs}}"} \\\ %{__cargo} %{__cargo_common_opts} build %{!?debug:--release} \\\ - --target %{cargo_target} \\\ + --target %{rust_target} \\\ --target-dir %{cargo_targetdir} \\\ %{nil} @@ -58,6 +59,6 @@ thumbv7neon-unknown-linux-gnueabihf\\\ RUSTFLAGS="${RUSTFLAGS:-%rpmrustflags}" \\\ %{?__jobs:CARGO_BUILD_JOBS="${CARGO_BUILD_JOBS:-%{__jobs}}"} \\\ %{__cargo} %{__cargo_common_opts} install \\\ - --target %{cargo_target} \\\ + --target %{rust_target} \\\ --target-dir %{cargo_targetdir} \\\ %{nil}