We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2461 - Allow compilation of SDL_mixer for Android x86
Summary: Allow compilation of SDL_mixer for Android x86
Status: RESOLVED FIXED
Alias: None
Product: SDL_mixer
Classification: Unclassified
Component: misc (show other bugs)
Version: unspecified
Hardware: x86 Android (All)
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-23 13:28 UTC by Daniel Sobe
Modified: 2014-03-23 16:52 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Sobe 2014-03-23 13:28:55 UTC
Hi,

the following patch enables compilation of SDL_mixer for Android x86. I have checked and there doesn't seem to be a nicer way to change the makefile. The patch disables the _ARM_ASSEM_ #define if the platform is not ARM.

--- SDL_mixer/Android.mk	2014-03-23 14:04:43.045322407 +0100
+++ SDL_mixer_new/Android.mk	2014-03-23 14:21:37.255577268 +0100
@@ -89,7 +89,13 @@
 
 ifeq ($(SUPPORT_OGG),true)
     LOCAL_C_INCLUDES += $(LOCAL_PATH)/$(OGG_LIBRARY_PATH)/include $(LOCAL_PATH)/$(VORBIS_LIBRARY_PATH)
-    LOCAL_CFLAGS += -DOGG_MUSIC -DOGG_USE_TREMOR -D_ARM_ASSEM_
+    LOCAL_CFLAGS += -DOGG_MUSIC -DOGG_USE_TREMOR
+    ifeq ($(TARGET_ARCH_ABI),armeabi)
+	LOCAL_CFLAGS += -D_ARM_ASSEM_
+    endif
+    ifeq ($(TARGET_ARCH_ABI),armeabi-v7a)
+	LOCAL_CFLAGS += -D_ARM_ASSEM_
+    endif
     LOCAL_SRC_FILES += \
         $(VORBIS_LIBRARY_PATH)/mdct.c \
         $(VORBIS_LIBRARY_PATH)/block.c \
Comment 1 Sam Lantinga 2014-03-23 16:52:29 UTC
Fixed, thanks!
https://hg.libsdl.org/SDL_mixer/rev/d9e357c04dfa