diff --git a/qb/config.libs.sh b/qb/config.libs.sh index 52f32a37dd..f51fa10368 100644 --- a/qb/config.libs.sh +++ b/qb/config.libs.sh @@ -22,6 +22,7 @@ PTHREADLIB=-lpthread SOCKETLIB=-lc SOCKETHEADER= INCLUDES='usr/include usr/local/include' +SORT=sort if [ "$OS" = 'BSD' ]; then [ -d /usr/local/include ] && add_dirs INCLUDE /usr/local/include @@ -39,6 +40,8 @@ elif [ "$OS" = 'Win32' ]; then DYLIB= elif [ "$OS" = 'Cygwin' ]; then die 1 'Error: Cygwin is not a supported platform. See https://bot.libretro.com/docs/compilation/windows/' +elif [ "$OS" = 'SunOS' ]; then + SORT=gsort fi add_define MAKEFILE DYLIB_LIB "$DYLIB" @@ -514,6 +517,6 @@ while [ $# -gt 0 ]; do var="${tmpvar#HAVE_}" vars="${vars} $var" done -VARS="$(printf %s "$vars" | tr ' ' '\n' | sort)" +VARS="$(printf %s "$vars" | tr ' ' '\n' | $SORT)" create_config_make config.mk $(printf %s "$VARS") create_config_header config.h $(printf %s "$VARS") diff --git a/qb/qb.system.sh b/qb/qb.system.sh index 597ba350c0..22a2fb73a8 100644 --- a/qb/qb.system.sh +++ b/qb/qb.system.sh @@ -36,6 +36,7 @@ if [ -z "$CROSS_COMPILE" ] || [ -z "$OS" ]; then 'CYGWIN'*) OS='Cygwin';; 'Haiku') OS='Haiku';; 'MINGW'*) OS='Win32';; + 'SunOS') OS='SunOS';; *) OS="Win32";; esac fi