🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

65 lines
1.8 KiB

  1. #!/bin/sh
  2. # Get the canonical path of the folder containing this script
  3. bindir=$(cd -P -- "$(dirname -- "$0")" && printf '%s\n' "$(pwd -P)")
  4. # Calculate the canonical path of the prefix, relative to the folder of this script
  5. prefix=$(cd -P -- "$bindir/@bin_prefix_relpath@" && printf '%s\n' "$(pwd -P)")
  6. exec_prefix=@exec_prefix@
  7. exec_prefix_set=no
  8. libdir=@libdir@
  9. @ENABLE_STATIC_FALSE@usage="\
  10. @ENABLE_STATIC_FALSE@Usage: $0 [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]"
  11. @ENABLE_STATIC_TRUE@usage="\
  12. @ENABLE_STATIC_TRUE@Usage: $0 [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs] [--static-libs]"
  13. if test $# -eq 0; then
  14. echo "${usage}" 1>&2
  15. exit 1
  16. fi
  17. while test $# -gt 0; do
  18. case "$1" in
  19. -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  20. *) optarg= ;;
  21. esac
  22. case $1 in
  23. --prefix=*)
  24. prefix=$optarg
  25. if test $exec_prefix_set = no ; then
  26. exec_prefix=$optarg
  27. fi
  28. ;;
  29. --prefix)
  30. echo $prefix
  31. ;;
  32. --exec-prefix=*)
  33. exec_prefix=$optarg
  34. exec_prefix_set=yes
  35. ;;
  36. --exec-prefix)
  37. echo $exec_prefix
  38. ;;
  39. --version)
  40. echo @SDL_VERSION@
  41. ;;
  42. --cflags)
  43. echo -I@includedir@/SDL2 @SDL_CFLAGS@
  44. ;;
  45. @ENABLE_SHARED_TRUE@ --libs)
  46. @ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@
  47. @ENABLE_SHARED_TRUE@ ;;
  48. @ENABLE_STATIC_TRUE@@ENABLE_SHARED_TRUE@ --static-libs)
  49. @ENABLE_STATIC_TRUE@@ENABLE_SHARED_FALSE@ --libs|--static-libs)
  50. @ENABLE_STATIC_TRUE@ sdl_static_libs=$(echo "@SDL_LIBS@ @SDL_STATIC_LIBS@" | sed -E "s#-lSDL2[ $]#$libdir/libSDL2.a #g")
  51. @ENABLE_STATIC_TRUE@ echo -L@libdir@ $sdl_static_libs
  52. @ENABLE_STATIC_TRUE@ ;;
  53. *)
  54. echo "${usage}" 1>&2
  55. exit 1
  56. ;;
  57. esac
  58. shift
  59. done