From 930399112ae91cd4a301450b81b20d48da2a8252 Mon Sep 17 00:00:00 2001 From: Dave Woodfall Date: Fri, 7 Apr 2023 02:25:42 +0100 Subject: system/wine: Make tests for lowercase options. No BUILD bump. Signed-off-by: bedlam Signed-off-by: Willy Sudiarto Raharjo --- system/wine/wine.SlackBuild | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'system/wine/wine.SlackBuild') diff --git a/system/wine/wine.SlackBuild b/system/wine/wine.SlackBuild index be2f2950b713..7444cd108910 100644 --- a/system/wine/wine.SlackBuild +++ b/system/wine/wine.SlackBuild @@ -53,19 +53,27 @@ fi # If your video card does not support hardware accelerated OpenGL, # then run the script like: OPENGL=NO ./wine.SlackBuild -if [ "${OPENGL:-YES}" = "YES" ]; then + +# Make lowercase +OPENGL=${OPENGL@L} + +if [ "${OPENGL:-yes}" = "yes" ]; then do_opengl="with" else do_opengl="without" fi +# Find which ARCHs to build for +# Make lowercase +WINE32=${WINE32@L} +WINE64=${WINE64@L} WINETMP="$( mktemp -d $TMP/wine-test-XXXXXX )" echo "int main(void) {; return(0); }" > "$WINETMP/test.c" -gcc -m32 "$WINETMP/test.c" -o /dev/null >/dev/null 2>&1 && WINE32=${WINE32:-YES} -gcc -m64 "$WINETMP/test.c" -o /dev/null >/dev/null 2>&1 && WINE64=${WINE64:-YES} +gcc -m32 "$WINETMP/test.c" -o /dev/null >/dev/null 2>&1 && WINE32=${WINE32:-yes} +gcc -m64 "$WINETMP/test.c" -o /dev/null >/dev/null 2>&1 && WINE64=${WINE64:-yes} rm -rf "$WINETMP" -if [ "${WINE32:-NO}${WINE64:-NO}" = "NONO" ]; then +if [ "$WINE32$WINE64" = "nono" ]; then echo "Both 64 and 32 bit builds disabled. Nothing to do." exit 1 fi @@ -109,7 +117,7 @@ find -L . \ # Fix for flex patch -p1 --verbose < $CWD/0001-winhlp32-Workaround-a-bug-in-Flex.patch -if [ "${WINE64:-NO}" = "YES" ]; then +if [ "$WINE64" = "yes" ]; then wine64="--with-wine64=../wine64" mkdir wine64 cd wine64 @@ -138,7 +146,7 @@ if [ "${WINE64:-NO}" = "YES" ]; then cd .. fi -if [ "${WINE32:-NO}" = "YES" ]; then +if [ "$WINE32" = "yes" ]; then mkdir wine32 cd wine32 export PKG_CONFIG_PATH="/usr/lib/pkgconfig:$PKG_CONFIG_PATH" -- cgit v1.2.3