correct libfesvr script

This commit is contained in:
alonamid 2019-07-18 03:28:22 +00:00
parent 171923d3b6
commit eba7b4ec16
1 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
#!/bin/bash
# This ungodly script surreptitiously builds an archive from existing fesvr objects
# Invoke from riscv-fesvr/build
if [ "x$RISCV" = "x" ]
then
echo "Please set the RISCV environment variable to your preferred install path."
exit 1
fi
set -e
objs=$(head -n 1 <(make -f <( echo -e 'include Makefile\n$(info $(value fesvr_objs))') -n))
ar rcs -o libfesvr.a $objs
cp -f libfesvr.a $RISCV/lib