From 10de3e7239fd1bd2f2e32057ad5a37f1504981ed Mon Sep 17 00:00:00 2001 From: kanjitalk755 Date: Sun, 20 Jan 2019 19:11:43 +0900 Subject: [PATCH] static link (BII/SS Windows) --- BasiliskII/src/Windows/Makefile.in | 2 +- BasiliskII/src/Windows/configure.ac | 20 ++++++++++---------- SheepShaver/src/Windows/Makefile.in | 2 +- SheepShaver/src/Windows/configure.ac | 2 +- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/BasiliskII/src/Windows/Makefile.in b/BasiliskII/src/Windows/Makefile.in index c1ee4838..b3a3a11b 100755 --- a/BasiliskII/src/Windows/Makefile.in +++ b/BasiliskII/src/Windows/Makefile.in @@ -39,7 +39,7 @@ CFLAGS = @CFLAGS@ $(SDL_CFLAGS) CXXFLAGS = @CXXFLAGS@ $(SDL_CFLAGS) CPPFLAGS = @CPPFLAGS@ -I../include -I. -I../CrossPlatform @CPUINCLUDES@ -I../slirp DEFS = @DEFS@ @DEFINES@ -LDFLAGS = @LDFLAGS@ +LDFLAGS = @LDFLAGS@ -Wl,-Bstatic LIBS = @LIBS@ -lws2_32 -lwsock32 -liphlpapi CPUSRCS = @CPUSRCS@ diff --git a/BasiliskII/src/Windows/configure.ac b/BasiliskII/src/Windows/configure.ac index 3a7b5e49..a13a3983 100755 --- a/BasiliskII/src/Windows/configure.ac +++ b/BasiliskII/src/Windows/configure.ac @@ -12,7 +12,7 @@ AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE_NAME", [Define this program name.]) AC_DEFINE_UNQUOTED(VERSION, "$PACKAGE_VERSION", [Define this program version.]) dnl SDL options. -AC_ARG_ENABLE(sdl-static, [ --enable-sdl-static use SDL static libraries for linking [default=no]], [WANT_SDL_STATIC=$enableval], [WANT_SDL_STATIC=no]) +#AC_ARG_ENABLE(sdl-static, [ --enable-sdl-static use SDL static libraries for linking [default=no]], [WANT_SDL_STATIC=$enableval], [WANT_SDL_STATIC=no]) dnl JIT compiler options. AC_ARG_ENABLE(jit-compiler, [ --enable-jit-compiler enable JIT compiler [default=yes]], [WANT_JIT=$enableval], [WANT_JIT=yes]) @@ -527,16 +527,16 @@ dnl We really want SDL for now AC_CHECK_TOOL(sdl_config, sdl2-config, [AC_MSG_ERROR([Sorry, you currently need SDL for this port])]) SDL_CFLAGS=`$sdl_config --cflags` AC_SUBST(SDL_CFLAGS) -if [[ "x$WANT_SDL_STATIC" = "xyes" ]]; then +#if [[ "x$WANT_SDL_STATIC" = "xyes" ]]; then SDL_LIBS=`$sdl_config --static-libs` - sdl_prefix=`$sdl_config --exec-prefix` - if [[ -n "$sdl_prefix" ]]; then - SDL_LIBS=`echo "$SDL_LIBS" | sed -e "s,-l\(SDLmain\|SDL\),$sdl_prefix/lib/lib\1.a,g"` - fi - SDL_LIBS="$SDL_LIBS -lwinmm" -else - SDL_LIBS=`$sdl_config --libs` -fi +# sdl_prefix=`$sdl_config --exec-prefix` +# if [[ -n "$sdl_prefix" ]]; then +# SDL_LIBS=`echo "$SDL_LIBS" | sed -e "s,-l\(SDLmain\|SDL\),$sdl_prefix/lib/lib\1.a,g"` +# fi +# SDL_LIBS="$SDL_LIBS -lwinmm" +#else +# SDL_LIBS=`$sdl_config --libs` +#fi AC_SUBST(SDL_LIBS) AC_DEFINE(USE_SDL, 1, [Define to enble SDL support]) AC_DEFINE(USE_SDL_VIDEO, 1, [Define to enable SDL video graphics support]) diff --git a/SheepShaver/src/Windows/Makefile.in b/SheepShaver/src/Windows/Makefile.in index 539d2b8a..4c34ffac 100755 --- a/SheepShaver/src/Windows/Makefile.in +++ b/SheepShaver/src/Windows/Makefile.in @@ -37,7 +37,7 @@ CFLAGS = @CFLAGS@ $(SDL_CFLAGS) CXXFLAGS = @CXXFLAGS@ $(SDL_CFLAGS) CPPFLAGS = @CPPFLAGS@ -I../include -I. -I../slirp -I../Unix/dyngen_precompiled DEFS = @DEFS@ -LDFLAGS = @LDFLAGS@ -static-libgcc -static-libstdc++ -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic +LDFLAGS = @LDFLAGS@ -Wl,-Bstatic #TODO remove pthread part of that if irrelevant LIBS = @LIBS@ -lws2_32 -lwsock32 -liphlpapi CPUSRCS = @CPUSRCS@ diff --git a/SheepShaver/src/Windows/configure.ac b/SheepShaver/src/Windows/configure.ac index 7d688981..21571618 100644 --- a/SheepShaver/src/Windows/configure.ac +++ b/SheepShaver/src/Windows/configure.ac @@ -241,7 +241,7 @@ dnl We really want SDL for now AC_CHECK_TOOL(sdl_config, sdl2-config, [AC_MSG_ERROR([Sorry, you currently need SDL for this port])]) SDL_CFLAGS=`$sdl_config --cflags` AC_SUBST(SDL_CFLAGS) -SDL_LIBS=`$sdl_config --libs` +SDL_LIBS=`$sdl_config --static-libs` AC_SUBST(SDL_LIBS) AC_DEFINE(USE_SDL, 1, [Define to enble SDL support]) AC_DEFINE(USE_SDL_VIDEO, 1, [Define to enable SDL video graphics support])