mirror of
https://github.com/radareorg/radare2.git
synced 2024-10-07 02:23:58 +00:00
Fix all shellcheck errors
This commit is contained in:
parent
7ff53f8ae0
commit
3b26388769
@ -8,5 +8,5 @@
|
||||
acr -p
|
||||
if [ -n "$1" ]; then
|
||||
echo "./configure $@"
|
||||
./configure $@
|
||||
./configure "$@"
|
||||
fi
|
||||
|
@ -9,9 +9,9 @@ RF="-s"
|
||||
compile() {
|
||||
spp -h >/dev/null 2>&1
|
||||
if [ $? = 0 ]; then
|
||||
spp -Darch=${ARCH} $@ | rarc2 $RF -a${ARCH} > .a.S || exit $?
|
||||
spp -Darch=${ARCH} "$@" | rarc2 $RF -a${ARCH} > .a.S || exit $?
|
||||
else
|
||||
rarc2 $RF -a${ARCH} $@ > .a.S || exit $?
|
||||
rarc2 $RF -a${ARCH} "$@" > .a.S || exit $?
|
||||
fi
|
||||
}
|
||||
|
||||
@ -40,7 +40,7 @@ done
|
||||
|
||||
shift $((${OPTIND}-1))
|
||||
|
||||
if [ -n "`echo $@`" ]; then
|
||||
if [ -n "`echo "$@"`" ]; then
|
||||
if [ -n "$r" ]; then
|
||||
RF=""
|
||||
ARCH=x86
|
||||
@ -48,7 +48,7 @@ if [ -n "`echo $@`" ]; then
|
||||
elif [ -n "$n" ]; then
|
||||
RF=""
|
||||
fi
|
||||
compile $@
|
||||
compile "$@"
|
||||
if [ -n "$c" ]; then
|
||||
# rasm2 and rabin2
|
||||
rasm2 -a x86.olly -f .a.S > .a.x
|
||||
|
4
configure
vendored
4
configure
vendored
@ -397,7 +397,7 @@ USE_LIB_MAGIC="0"
|
||||
LIBMAGIC="-lr_magic"; fi
|
||||
printf 'checking pkg-config flags for capstone... '
|
||||
tmp=`pkg-config --cflags capstone 2>/dev/null`
|
||||
if [ '!' $? = 0 ]; then echo no ; HAVE_PKGCFG_CAPSTONE=0;
|
||||
if [ $? = 0 ]; then echo no ; HAVE_PKGCFG_CAPSTONE=0;
|
||||
else
|
||||
CAPSTONE_CFLAGS=$tmp;
|
||||
tmp=`pkg-config --libs capstone 2>/dev/null`
|
||||
@ -427,7 +427,7 @@ HAVE_GMP="0"
|
||||
check_library HAVE_LIB_SSL ssl 0
|
||||
printf 'checking pkg-config flags for openssl... '
|
||||
tmp=`pkg-config --cflags openssl 2>/dev/null`
|
||||
if [ '!' $? = 0 ]; then echo no ; HAVE_PKGCFG_OPENSSL=0;
|
||||
if [ $? = 0 ]; then echo no ; HAVE_PKGCFG_OPENSSL=0;
|
||||
else
|
||||
SSL_CFLAGS=$tmp;
|
||||
tmp=`pkg-config --libs openssl 2>/dev/null`
|
||||
|
@ -5,6 +5,6 @@ case "$1" in
|
||||
;;
|
||||
*)
|
||||
[ plugins.def.cfg -nt ./plugins.cfg ] && rm -f plugins.cfg
|
||||
./configure-plugins $@
|
||||
./configure-plugins "$@"
|
||||
;;
|
||||
esac
|
||||
|
2
doc/repo
2
doc/repo
@ -5,4 +5,4 @@ EXTRAS=https://github.com/radare/radare2-extras
|
||||
CAPSTONE=https://github.com/radare/radare2-capstone
|
||||
BINDINGS=https://github.com/radare/radare2-bindings
|
||||
REGRESSIONS=https://github.com/radare/radare2-regressions
|
||||
[ -z "$1" ] && grep =h $0 | grep -v grep || eval echo \$$1
|
||||
[ -z "$1" ] && grep -h $0 | grep -v grep || eval echo \$$1
|
||||
|
@ -12,4 +12,4 @@ if [ $RET != 0 ]; then
|
||||
echo "Your compiler doesn't supports AFL"
|
||||
exit 1
|
||||
fi
|
||||
exec sys/install.sh $@
|
||||
exec sys/install.sh "$@"
|
||||
|
@ -10,4 +10,4 @@ if [ $RET != 0 ]; then
|
||||
echo "Your compiler doesn't supports ASAN."
|
||||
exit 1
|
||||
fi
|
||||
exec sys/install.sh $@
|
||||
exec sys/install.sh "$@"
|
||||
|
@ -7,7 +7,7 @@ RR=$1
|
||||
RB=$2
|
||||
N=$3
|
||||
|
||||
git diff --exit-code 2>&1 >/dev/null
|
||||
git diff --exit-code >/dev/null 2>&1
|
||||
if [ $? != 0 ]; then
|
||||
echo "ERROR: There are local changes that must be committed or reseted"
|
||||
echo "ERROR: Cherrypulling process stopped to avoid data loss."
|
||||
|
@ -33,7 +33,7 @@ testcc() {
|
||||
}
|
||||
|
||||
log() {
|
||||
echo $@ ; echo $@ >> ${LOGFILE}
|
||||
echo "$@" ; echo "$@" >> ${LOGFILE}
|
||||
}
|
||||
|
||||
logchk() {
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
D=`dirname $PWD/$0`
|
||||
uncrustify -c ${D}/uncrustify.cfg $@
|
||||
uncrustify -c ${D}/uncrustify.cfg "$@"
|
||||
diff -ru $1 $1.uncrustify
|
||||
|
@ -24,7 +24,7 @@ fi
|
||||
[ -n "${NOSUDO}" ] && SUDO=
|
||||
|
||||
if [ "${HARDEN}" = 1 ]; then
|
||||
./sys/build-harden.sh $@ && ${SUDO} ${MAKE} symstall
|
||||
./sys/build-harden.sh "$@" && ${SUDO} ${MAKE} symstall
|
||||
else
|
||||
./sys/build.sh $@ && ${SUDO} ${MAKE} symstall
|
||||
./sys/build.sh "$@" && ${SUDO} ${MAKE} symstall
|
||||
fi
|
||||
|
@ -60,4 +60,4 @@ LDFLAGS="-L ${IOSROOT}/usr/lib/ ${LDFLAGS}"
|
||||
#fi
|
||||
|
||||
# arm64
|
||||
${CC} ${CFLAGS} ${LDFLAGS} $@
|
||||
${CC} ${CFLAGS} ${LDFLAGS} "$@"
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh
|
||||
#A=`hg diff $@ | grep -v '+++' | grep ^+ |wc -l`
|
||||
#B=`hg diff $@ | grep -v -- '---' | grep ^- |wc -l`
|
||||
A=`git diff $@ | grep -v '+++' | grep ^+ |wc -l`
|
||||
B=`git diff $@ | grep -v -- '---' | grep ^- |wc -l`
|
||||
A=`git diff "$@" | grep -v '+++' | grep ^+ |wc -l`
|
||||
B=`git diff "$@" | grep -v -- '---' | grep ^- |wc -l`
|
||||
echo $((A-B))
|
||||
|
@ -6,9 +6,9 @@ cd `dirname $PWD/$0`
|
||||
cd ..
|
||||
|
||||
. ./sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
cat sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
|
||||
[ -z "${PREFIX}" ] && PREFIX=/usr
|
||||
ID=`id -u`
|
||||
|
@ -91,7 +91,7 @@ esac
|
||||
#LDFLAGS="${LDFLAGS} -Wl,-dynamic-linker=/system/bin/linker"
|
||||
|
||||
LDFLAGS="${LDFLAGS} --sysroot=${PLATFORM_ROOT}"
|
||||
#if [ -z "`echo $@ | grep shared`" ]; then
|
||||
#if [ -z "`echo "$@"" | grep shared`" ]; then
|
||||
#LDFLAGS="${LDFLAGS} ${PLATFORM_PATH}/lib/crtbegin_dynamic.o"
|
||||
#fi
|
||||
CC=${NDKPFX}-gcc
|
||||
@ -100,5 +100,5 @@ EXT_SO=so
|
||||
|
||||
export PATH=${NDK_BINS}:$PATH
|
||||
export EXT_SO AR CC CFLAGS LDFLAGS PATH
|
||||
# echo ${CC} ${CFLAGS} ${LDFLAGS} $@
|
||||
${CC} ${CFLAGS} ${LDFLAGS} $@
|
||||
# echo ${CC} ${CFLAGS} ${LDFLAGS} "$@""
|
||||
${CC} ${CFLAGS} ${LDFLAGS} "$@"
|
||||
|
@ -5,9 +5,9 @@ cd `dirname $PWD/$0`
|
||||
cd ..
|
||||
|
||||
. ./sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
cat sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
cd radare2-bindings
|
||||
cd r2pipe/python
|
||||
${SUDO} make install
|
||||
|
@ -6,9 +6,9 @@ cd `dirname $PWD/$0`
|
||||
cd ..
|
||||
|
||||
. ./sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
cat sys/CONFIG
|
||||
echo =============
|
||||
echo "============="
|
||||
|
||||
export PYTHON
|
||||
export DESTDIR
|
||||
|
@ -8,7 +8,7 @@ if [ -d .git ]; then
|
||||
git pull
|
||||
fi
|
||||
|
||||
ccache --help 2>&1 > /dev/null
|
||||
ccache --help > /dev/null 2>&1
|
||||
if [ $? = 0 ]; then
|
||||
[ -z "${CC}" ] && CC=gcc
|
||||
CC="ccache ${CC}"
|
||||
|
@ -9,14 +9,14 @@ cd `dirname $PWD/$0`
|
||||
mkdir -p _work
|
||||
cd _work
|
||||
|
||||
ccache --help 2>&1 > /dev/null
|
||||
ccache --help > /dev/null 2>&1
|
||||
if [ $? = 0 ]; then
|
||||
[ -z "${CC}" ] && CC=gcc
|
||||
CC="ccache ${CC}"
|
||||
export CC
|
||||
fi
|
||||
|
||||
valac --help 2>&1 >/dev/null
|
||||
valac --help > /dev/null 2>&1
|
||||
if [ ! $? = 0 ]; then
|
||||
# must install from tarball
|
||||
VV=0.13.4
|
||||
|
Loading…
Reference in New Issue
Block a user