Commit 56e59961 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Contribs: add an option to optimize a bit for the size

Notably for libavcodec
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
(cherry picked from commit 55295e3d)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent 9be9a1f9
...@@ -28,6 +28,7 @@ usage() ...@@ -28,6 +28,7 @@ usage()
echo " --enable-FOO configure to build package FOO" echo " --enable-FOO configure to build package FOO"
echo " --disable-disc configure to not build optical discs packages" echo " --disable-disc configure to not build optical discs packages"
echo " --disable-sout configure to not build stream output packages" echo " --disable-sout configure to not build stream output packages"
echo " --enable-small optimize libraries for size with slight speed decrease [DANGEROUS]"
} }
BUILD= BUILD=
...@@ -66,6 +67,9 @@ do ...@@ -66,6 +67,9 @@ do
--disable-sout) --disable-sout)
BUILD_ENCODERS= BUILD_ENCODERS=
;; ;;
--enable-small)
ENABLE_SMALL=1
;;
--disable-*) --disable-*)
PKGS_DISABLE="${PKGS_DISABLE} ${1#--disable-}" PKGS_DISABLE="${PKGS_DISABLE} ${1#--disable-}"
;; ;;
...@@ -161,6 +165,7 @@ check_android_sdk() ...@@ -161,6 +165,7 @@ check_android_sdk()
test -z "$PREFIX" || add_make "PREFIX := $PREFIX" test -z "$PREFIX" || add_make "PREFIX := $PREFIX"
test -z "$BUILD_DISCS" || add_make_enabled "BUILD_DISCS" test -z "$BUILD_DISCS" || add_make_enabled "BUILD_DISCS"
test -z "$BUILD_ENCODERS" || add_make_enabled "BUILD_ENCODERS" test -z "$BUILD_ENCODERS" || add_make_enabled "BUILD_ENCODERS"
test -z "$ENABLE_SMALL" || add_make_enabled "ENABLE_SMALL"
# #
# Checks # Checks
......
...@@ -32,7 +32,10 @@ FFMPEGCONF += --enable-libmp3lame --enable-libvpx ...@@ -32,7 +32,10 @@ FFMPEGCONF += --enable-libmp3lame --enable-libvpx
DEPS_ffmpeg += lame $(DEPS_lame) vpx $(DEPS_vpx) DEPS_ffmpeg += lame $(DEPS_lame) vpx $(DEPS_vpx)
else else
FFMPEGCONF += --disable-encoders --disable-muxers FFMPEGCONF += --disable-encoders --disable-muxers
# XXX: REVISIT --enable-small ? endif
ifdef ENABLE_SMALL
FFMPEGCONF += --enable-small --optflags=-O2
endif endif
# XXX: REVISIT # XXX: REVISIT
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment