aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.android4
-rw-r--r--Makefile.target4
2 files changed, 6 insertions, 2 deletions
diff --git a/Makefile.android b/Makefile.android
index 7e66bd9..f5c008b 100644
--- a/Makefile.android
+++ b/Makefile.android
@@ -132,6 +132,10 @@ ifneq ($(combo_target)$(TARGET_SIMULATOR),HOST_true)
MY_LDLIBS += -m32
endif
endif
+
+ ifneq ($(BUILD_HOST_static),)
+ MY_LDLIBS += -static
+ endif
endif
# Enable warning, except those related to missing field initializers
diff --git a/Makefile.target b/Makefile.target
index 45c8e69..e8a41f4 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -326,7 +326,7 @@ endif
# Generate a completely static executable if needed.
# Note that this means no sound and graphics on Linux.
#
-ifeq ($(CONFIG_STATIC_EXECUTABLE),true)
+ifneq ($(strip $(CONFIG_STATIC_EXECUTABLE)$(BUILD_HOST_static)),)
LOCAL_SRC_FILES += dynlink-static.c
LOCAL_LDLIBS += -static
endif
@@ -412,7 +412,7 @@ common_LOCAL_SRC_FILES += $(SDLMAIN_SOURCES)
# Generate a completely static executable if needed.
# Note that this means no sound and graphics on Linux.
#
-ifeq ($(CONFIG_STATIC_EXECUTABLE),true)
+ifneq ($(strip $(CONFIG_STATIC_EXECUTABLE)$(BUILD_HOST_static)),)
common_LOCAL_SRC_FILES += dynlink-static.c
common_LOCAL_LDLIBS += -static
endif