better build script
This commit is contained in:
parent
4bad5494a4
commit
edae70d313
13
build.sh
13
build.sh
@ -18,7 +18,18 @@
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see https://www.gnu.org/licenses/.
|
||||
|
||||
if ! test -n "$1"; then
|
||||
printf "Usage: %s [target]\n" "$0" 1>&2
|
||||
printf "For a list of targets, type 'rustc --print target-list'\n" 1>&2
|
||||
exit 64 # sysexits(3) EX_USAGE
|
||||
fi
|
||||
|
||||
if ! command -v cargo; then
|
||||
printf "%s: Missing depenency: cargo(1)\n" "$0" 1>&2
|
||||
exit 69 # syexits(3) EX_UNAVAILABLE
|
||||
fi
|
||||
|
||||
cargo build --release \
|
||||
-Z build-std=std,panic_abort \
|
||||
-Z build-std-features=panic_immediate_abort \
|
||||
--target x86_64-unknown-linux-gnu
|
||||
--target "$1"
|
||||
|
Reference in New Issue
Block a user