2020-04-04 12:07:50 -04:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
CUR="$PWD"
|
|
|
|
|
2020-05-20 10:36:27 -04:00
|
|
|
LIBFUSE_DIR=$CUR/LIBFUSE
|
2020-04-04 12:07:50 -04:00
|
|
|
|
|
|
|
if uname -a | egrep -q 'x86_64|amd64'; then
|
|
|
|
name=vtoy_fuse_iso_64
|
|
|
|
else
|
|
|
|
name=vtoy_fuse_iso_32
|
|
|
|
opt=-lrt
|
|
|
|
fi
|
|
|
|
|
2020-12-11 18:56:52 -05:00
|
|
|
#
|
2021-01-16 10:30:12 -05:00
|
|
|
# use musl-c to build for x86_64
|
2020-12-11 18:56:52 -05:00
|
|
|
#
|
|
|
|
|
2020-04-04 12:07:50 -04:00
|
|
|
export C_INCLUDE_PATH=$LIBFUSE_DIR/include
|
|
|
|
|
|
|
|
rm -f $name
|
2021-01-16 10:30:12 -05:00
|
|
|
gcc -specs "/usr/local/musl/lib/musl-gcc.specs" -static -O2 -D_FILE_OFFSET_BITS=64 vtoy_fuse_iso.c $LIBFUSE_DIR/lib/libfuse.a -o $name
|
|
|
|
|
|
|
|
strip --strip-all $name
|
2020-04-04 12:07:50 -04:00
|
|
|
|
|
|
|
if [ -e $name ]; then
|
|
|
|
echo -e "\n############### SUCCESS $name ##################\n"
|
|
|
|
else
|
|
|
|
echo -e "\n############### FAILED $name ##################\n"
|
|
|
|
fi
|
|
|
|
|
|
|
|
strip --strip-all $name
|
|
|
|
|