Automatically remove -m32 cflag from koreader-base makefile

This commit is contained in:
Cosmin Gorgovan 2015-02-10 21:39:21 +00:00
parent abab91b16c
commit 4f72bdbb62
2 changed files with 24 additions and 4 deletions

View File

@ -106,12 +106,21 @@ compile_firmware_okreader() {
compile_koreader() {
cd src/koreader
rm *.tar.gz
rm *.zip
# Remove previous builds
rm *.tar.gz *.zip
make fetchthirdparty
# Remove -m32 cflag
patch -p1 < ../koreader_base_arm.patch
make TARGET=kobo koboupdate
cd ..
cd koreader-pkg
# Reverse the patch so that koreader-base can be cleanly updated in the future
patch -R -p1 < ../koreader_base_arm.patch
cd ../koreader-pkg
rm -R opt
mkdir opt
cd opt

View File

@ -0,0 +1,11 @@
--- a/base/Makefile
+++ b/base/Makefile
@@ -196,7 +196,7 @@ else
# Build its HOST/TARGET_CFLAGS based on CFLAGS, so we need
# a neutral CFLAGS without arch
$(MAKE) -j$(PROCESSORS) -C $(LUA_DIR) \
- CC="$(HOSTCC)" HOST_CC="$(HOSTCC) -m32" \
+ CC="$(HOSTCC)" HOST_CC="$(HOSTCC)" \
CFLAGS="$(BASE_CFLAGS)" HOST_CFLAGS="$(HOSTCFLAGS)" \
$(if $(WIN32),LDFLAGS="$(LDFLAGS)",) \
$(if $(WIN32),TARGET_SYS=Windows,) \