[Android] [PATCH 4/7] contrib: Allow live555 build on Android x86

Rafaël Carré funman at videolan.org
Mon Jul 23 16:22:35 CEST 2012


Le 2012-07-23 05:54, Edward Wang a écrit :
> This package demands exceptions, but if it is enabled globally, it conflicts with other packages.
> ---
>  contrib/src/live555/rules.mak |    7 ++++++-
>  1 files changed, 6 insertions(+), 1 deletions(-)
> 
> diff --git a/contrib/src/live555/rules.mak b/contrib/src/live555/rules.mak
> index 71d1ad6..ba1ac13 100644
> --- a/contrib/src/live555/rules.mak
> +++ b/contrib/src/live555/rules.mak
> @@ -40,8 +40,13 @@ endif
>  	cd live && sed -i.orig -e s/"libtool -s -o"/"ar cr"/g config.macosx*
>  	cd live && sed -i.orig \
>  		-e 's%$(CXX)%$(CXX)\ $(EXTRA_LDFLAGS)%' config.macosx
> +ifdef HAVE_ANDROID
> +	EXTRA_CFLAGS_LIVE="$(EXTRA_CFLAGS) -fexceptions"
> +else
> +	EXTRA_CFLAGS_LIVE=$(EXTRA_CFLAGS)
> +endif
>  	cd live && sed -i.orig \
> -		-e 's%^\(COMPILE_OPTS.*\)$$%\1 '"$(EXTRA_CFLAGS)%" config.*
> +		-e 's%^\(COMPILE_OPTS.*\)$$%\1 '"$(EXTRA_CFLAGS_LIVE)%" config.*
>  	cd live && sed -e 's%-D_FILE_OFFSET_BITS=64%-D_FILE_OFFSET_BITS=64\ -fPIC\ -DPIC%' -i.orig config.linux
>  ifdef HAVE_ANDROID
>  	cd live && sed -e 's%-DPIC%-DPIC -DNO_SSTREAM=1 -DLOCALE_NOT_USED -I$(ANDROID_NDK)/platforms/android-9/arch-$(PLATFORM_SHORT_ARCH)/usr/include%' -i.orig config.linux

Please use Makefile's += like:

EXTRA_CFLAGS_LIVE = $(EXTRA_CFLAGS)
ifdef HAVE_ANDROID
EXTRA_CFLAGS_LIVE += -fexceptions
endif


More information about the Android mailing list