Commit d6d98ddc authored by Sam Lantinga's avatar Sam Lantinga

EXTRA_LDFLAGS are the linker flags and libraries needed to build SDL.

SDL_LIBS are the linker flags and libraries needed to build SDL applications.
SDL_STATIC_LIBS is set to SDL_LIBS by default.

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401552
parent dbce258f
......@@ -2306,8 +2306,6 @@ case "$target" in
fi
have_timers=yes
fi
# Now set libraries needed in sdl-config
SYSTEM_LIBS="$EXTRA_LDFLAGS"
;;
*-riscos)
ARCH=riscos
......@@ -2401,31 +2399,16 @@ else
fi
case "$ARCH" in
openbsd | netbsd | bsdi)
SHARED_SYSTEM_LIBS="$SYSTEM_LIBS"
;;
qnx)
SHARED_SYSTEM_LIBS="$SYSTEM_LIBS"
;;
macosx)
SHARED_SYSTEM_LIBS=""
if test x$enable_video = xyes -a x$enable_video_cocoa = xyes; then
SHARED_SYSTEM_LIBS="$SHARED_SYSTEM_LIBS -framework Cocoa"
SDL_LIBS="$SDL_LIBS -framework Cocoa"
fi
if test x$enable_video = xyes -a x$enable_video_carbon = xyes; then
SHARED_SYSTEM_LIBS="$SHARED_SYSTEM_LIBS -framework Carbon"
SDL_LIBS="$SDL_LIBS -framework Carbon"
fi
if test x$enable_video = xyes -a x$enable_video_opengl = xyes; then
SHARED_SYSTEM_LIBS="$SHARED_SYSTEM_LIBS -framework OpenGL"
SDL_LIBS="$SDL_LIBS -framework OpenGL"
fi
;;
*)
SHARED_SYSTEM_LIBS=""
;;
esac
case "$ARCH" in
macosx)
# Evil hack to allow static linking on Mac OS X
SDL_STATIC_LIBS="\${exec_prefix}/lib/libSDLmain.a \${exec_prefix}/lib/libSDL.a"
;;
......@@ -2434,8 +2417,6 @@ case "$ARCH" in
;;
esac
STATIC_SYSTEM_LIBS="$SYSTEM_LIBS"
dnl Expand the cflags and libraries needed by apps using SDL
AC_SUBST(SDL_CFLAGS)
AC_SUBST(SDL_LIBS)
......@@ -2460,11 +2441,6 @@ AC_SUBST(ENABLE_SHARED_FALSE)
AC_SUBST(ENABLE_STATIC_TRUE)
AC_SUBST(ENABLE_STATIC_FALSE)
dnl Expand the libraries needed for static and dynamic linking
AC_SUBST(STATIC_SYSTEM_LIBS)
AC_SUBST(SHARED_SYSTEM_LIBS)
AC_SUBST(SYSTEM_LIBS)
dnl Expand the sources and objects needed to build the library
AC_SUBST(ac_aux_dir)
AC_SUBST(INCLUDE)
......
......@@ -42,13 +42,11 @@ while test $# -gt 0; do
echo -I@includedir@/SDL @SDL_CFLAGS@
;;
@ENABLE_SHARED_TRUE@ --libs)
@ENABLE_SHARED_TRUE@ libdirs="-L@libdir@ @SDL_RLD_FLAGS@"
@ENABLE_SHARED_TRUE@ echo $libdirs @SDL_LIBS@ @SHARED_SYSTEM_LIBS@
@ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@
@ENABLE_SHARED_TRUE@ ;;
@ENABLE_STATIC_TRUE@@ENABLE_SHARED_TRUE@ --static-libs)
@ENABLE_STATIC_TRUE@@ENABLE_SHARED_FALSE@ --libs|--static-libs)
@ENABLE_STATIC_TRUE@ libdirs="-L@libdir@ @SDL_RLD_FLAGS@"
@ENABLE_STATIC_TRUE@ echo $libdirs @SDL_STATIC_LIBS@ @STATIC_SYSTEM_LIBS@
@ENABLE_STATIC_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_STATIC_LIBS@
@ENABLE_STATIC_TRUE@ ;;
*)
echo "${usage}" 1>&2
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment