zdoom-macos-deps/deps/sdl2/bin/sdl2-config

57 lines
1.3 KiB
Text
Raw Normal View History

2020-12-17 10:04:59 +00:00
#!/bin/sh
prefix="$(cd "${0%/*}/.."; pwd)"
2021-09-08 09:10:12 +00:00
exec_prefix="${prefix}"
2020-12-17 10:04:59 +00:00
exec_prefix_set=no
2021-09-08 09:10:12 +00:00
libdir="${exec_prefix}/lib"
2020-12-17 10:04:59 +00:00
#usage="\
#Usage: $0 [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]"
usage="\
Usage: $0 [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs] [--static-libs]"
if test $# -eq 0; then
echo "${usage}" 1>&2
exit 1
fi
while test $# -gt 0; do
case "$1" in
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
*) optarg= ;;
esac
case $1 in
--prefix=*)
prefix=$optarg
if test $exec_prefix_set = no ; then
exec_prefix=$optarg
fi
;;
--prefix)
echo $prefix
;;
--exec-prefix=*)
exec_prefix=$optarg
exec_prefix_set=yes
;;
--exec-prefix)
echo $exec_prefix
;;
--version)
2021-12-04 11:46:55 +00:00
echo 2.0.18
2020-12-17 10:04:59 +00:00
;;
--cflags)
2021-09-08 09:10:12 +00:00
echo -I${prefix}/include/SDL2 -D_THREAD_SAFE
2020-12-17 10:04:59 +00:00
;;
--libs|--static-libs)
2021-12-04 11:46:55 +00:00
echo -L${libdir} -lSDL2 -framework AudioToolbox -framework AVFoundation -framework Carbon -framework Cocoa -framework CoreAudio -framework CoreVideo -framework ForceFeedback -framework Foundation -framework IOKit -framework Metal -framework QuartzCore
2020-12-17 10:04:59 +00:00
;;
*)
echo "${usage}" 1>&2
exit 1
;;
esac
shift
done