@@ -144,9 +144,7 @@ command_exists() {
144144}
145145
146146library_exists () {
147- local result=0
148- local output=$( pkg-config --exists --print-errors " $1 " 2>&1 > /dev/null) || result=$?
149- if [ ! " $result " = " 0" ]; then
147+ if ! [[ -x $( pkg-config --exists --print-errors " $1 " 2>&1 > /dev/null) ]]; then
150148 return 1
151149 fi
152150
@@ -158,7 +156,7 @@ build_done() {
158156}
159157
160158verify_binary_type () {
161- BINARY_TYPE=$( file $WORKSPACE /bin/ffmpeg | sed -n ' s/^.*\:\ \(.*$\)/\1/p' )
159+ BINARY_TYPE=$( file " $WORKSPACE /bin/ffmpeg" | sed -n ' s/^.*\:\ \(.*$\)/\1/p' )
162160 echo " "
163161 case $BINARY_TYPE in
164162 " Mach-O 64-bit executable arm64" )
@@ -298,7 +296,7 @@ if command_exists "python"; then
298296
299297 if build " serd" ; then
300298 download " https://gitlab.com/drobilla/serd/-/archive/v0.30.6/serd-v0.30.6.tar.gz" " serd-v0.30.6.tar.gz"
301- execute cp -r ${PACKAGES} /autowaf/* " ${PACKAGES} /serd-v0.30.6/waflib/"
299+ execute cp -r " ${PACKAGES} " /autowaf/* " ${PACKAGES} /serd-v0.30.6/waflib/"
302300 execute ./waf configure --prefix=" ${WORKSPACE} " --static --no-shared --no-posix
303301 execute ./waf
304302 execute ./waf install
@@ -316,17 +314,17 @@ if command_exists "python"; then
316314
317315 if build " sord" ; then
318316 download " https://gitlab.com/drobilla/sord/-/archive/v0.16.6/sord-v0.16.6.tar.gz" " sord-v0.16.6.tar.gz"
319- execute cp -r ${PACKAGES} /autowaf/* " ${PACKAGES} /sord-v0.16.6/waflib/"
320- execute ./waf configure --prefix=" ${WORKSPACE} " CFLAGS=${CFLAGS} --static --no-shared --no-utils
321- execute ./waf CFLAGS=${CFLAGS}
317+ execute cp -r " ${PACKAGES} " /autowaf/* " ${PACKAGES} /sord-v0.16.6/waflib/"
318+ execute ./waf configure --prefix=" ${WORKSPACE} " CFLAGS=" ${CFLAGS} " --static --no-shared --no-utils
319+ execute ./waf CFLAGS=" ${CFLAGS} "
322320 execute ./waf install
323321
324322 build_done " sord"
325323 fi
326324
327325 if build " sratom" ; then
328326 download " https://gitlab.com/lv2/sratom/-/archive/v0.6.6/sratom-v0.6.6.tar.gz" " sratom-v0.6.6.tar.gz"
329- execute cp -r ${PACKAGES} /autowaf/* " ${PACKAGES} /sratom-v0.6.6/waflib/"
327+ execute cp -r " ${PACKAGES} " /autowaf/* " ${PACKAGES} /sratom-v0.6.6/waflib/"
330328 execute ./waf configure --prefix=" ${WORKSPACE} " --static --no-shared
331329 execute ./waf
332330 execute ./waf install
@@ -336,7 +334,7 @@ if command_exists "python"; then
336334
337335 if build " lilv" ; then
338336 download " https://gitlab.com/lv2/lilv/-/archive/v0.24.10/lilv-v0.24.10.tar.gz" " lilv-v0.24.10.tar.gz"
339- execute cp -r ${PACKAGES} /autowaf/* " ${PACKAGES} /lilv-v0.24.10/waflib/"
337+ execute cp -r " ${PACKAGES} " /autowaf/* " ${PACKAGES} /lilv-v0.24.10/waflib/"
340338 execute ./waf configure --prefix=" ${WORKSPACE} " --static --no-shared --no-utils
341339 execute ./waf
342340 execute ./waf install
@@ -411,7 +409,7 @@ CONFIGURE_OPTIONS+=("--enable-libsvtav1")
411409
412410if build " x264" ; then
413411 download " https://code.videolan.org/videolan/x264/-/archive/0d754ec36013fee82978496cd56fbd48824910b3/x264-0d754ec36013fee82978496cd56fbd48824910b3.tar.gz" " x264-0d754ec.tar.gz"
414- cd " ${PACKAGES} " /x264-0d754ec
412+ cd " ${PACKAGES} " /x264-0d754ec || exit
415413
416414 if [[ " $OSTYPE " == " linux-gnu" ]]; then
417415 execute ./configure --prefix=" ${WORKSPACE} " --enable-static --enable-pic CXXFLAGS=" -fPIC"
0 commit comments