< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index Next in Thread >

Re: [reSIProcate-users] Large shared object files for Android build?


If I remember correctly, configure will still insert the default "-g -O2" when the the flag is in CPPFLAGS. Putting it in CXXFLAGS will cause configure to not insert its default.

On Tue Jun  3 01:06:01 2014, Daniel Pocock wrote:


On 03/06/14 01:01, Brien Colwell wrote:
I'm still deep in trying to get this figured out, but I noticed the
default compiler flags (-g -O2) are not optimized for size, and adding
this to the top of the android-custom-ndk script makes a significant
reduction in size:

export CXXFLAGS="-Os”


Maybe it should go in CPPFLAGS - are you happy with the change below?
If so, I will commit it.  Thanks for the feedback.

--- a/build/android-custom-ndk
+++ b/build/android-custom-ndk
@@ -84,7 +84,7 @@ do
    export LD=${TOOLCHAIN_PREFIX}-ld
    export RANLIB=${TOOLCHAIN_PREFIX}-ranlib

-  export CPPFLAGS="${CPPFLAGS} -I${OPENSSL_HOME}/include"
+  export CPPFLAGS="${CPPFLAGS} -I${OPENSSL_HOME}/include -Os"
    export LDFLAGS="${LDFLAGS} -L${OPENSSL_HOME}/libs/${MOD_NAME}"

    autoreconf -fi
_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/