cargo: Copy target with properties, find filename automatically

This commit is contained in:
Dorota Czaplejewicz
2019-11-19 09:35:03 +00:00
parent 3c0b142c4f
commit f834f174d8

View File

@ -20,5 +20,6 @@ shift
cargo "$@"
if [ -n "${OUT_PATH}" ]; then
cp "${CARGO_TARGET_DIR}"/debug/librs.a "${OUT_PATH}"
FILENAME="$(basename "${OUT_PATH}")"
cp -a "${CARGO_TARGET_DIR}"/debug/"${FILENAME}" "${OUT_PATH}"
fi