summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-02-17 23:34:54 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2016-02-18 16:28:30 +0100
commit8fdee3ee8fb50877c526b79f78a754b70bf7c426 (patch)
tree5913b19c0bc2e5d20b49c9e2b3ef75a2d9a483ec /configure
parent6eaad752c1c6d854af881f813ae5a414d4d336f1 (diff)
Revert 4 commits to configure which broke dependency handling
Revert "configure: Don't enable examples when --disable-everything is used" reverted as the problematic commit will be reverted too This reverts commit 02dfa64c088c87367c298a3f648454204656734f. Revert "Merge commit 'a2bb771a3cded8a05137c0effb34f61a2bc78e22'" This reverts commit e8ebcb0034c5d4e5df8ff407a5c28d8c53823236, reversing changes made to 3bff005be8ea213c23160ee0ac286634a80a10e1. Revert "Merge commit '21c750f240b9d0c41a258d1adee2d9f75ff378b6'" This reverts commit 470bfab470893d45328f4e6e25d60b89c9af1abe, reversing changes made to f97ee815cf25580cbb9d6bed304d9c22895f7074. Revert "Revert "configure: Revert recent changes to disable-everything"" This reverts commit f97ee815cf25580cbb9d6bed304d9c22895f7074. Reviewed-by: Hendrik Leppkes <h.leppkes@gmail.com> Immediate commit suggested by BBB
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure80
1 files changed, 15 insertions, 65 deletions
diff --git a/configure b/configure
index fb81a19d61..287896f8ce 100755
--- a/configure
+++ b/configure
@@ -579,15 +579,8 @@ enable(){
set_all yes $*
}
-check_requested() {
- for var; do
- eval test "x\$${var#!}_requested" = "xyes" && die "${var%%_*} cannot be enabled"
- done
-}
-
disable(){
set_all no $*
- check_requested $*
}
enable_weak(){
@@ -638,32 +631,6 @@ enable_deep_weak(){
done
}
-do_enable_deep_force(){
- for var; do
- enabled $var && continue
- eval sel="\$${var}_deps\ \$${var}_deps_any\ \$${var}_select\ \$${var}_suggest\ \$${var}_select_any"
- pushvar var
- enable_deep_force $sel
- popvar var
- done
-}
-
-enable_deep_force(){
- do_enable_deep_force $*
- for var; do
- is_in $var $ALL_COMPONENTS $COMPONENT_LIST $LIBRARY_LIST && enable $var
- done
-}
-
-request(){
- disable $* # force the refresh of the dependencies
- for var; do
- enable ${var}_requested
- done
- enable_deep_force $*
- enable $*
-}
-
enabled(){
test "${1#!}" = "$1" && op='=' || op=!=
eval test "x\$${1#!}" $op "xyes"
@@ -723,7 +690,7 @@ do_check_deps(){
append allopts $cfg
eval dep_all="\$${cfg}_deps"
- eval dep_any="\$${cfg}_deps_any\ \$${cfg}_select_any"
+ eval dep_any="\$${cfg}_deps_any"
eval dep_sel="\$${cfg}_select"
eval dep_sgs="\$${cfg}_suggest"
eval dep_ifa="\$${cfg}_if"
@@ -2860,7 +2827,7 @@ tls_schannel_protocol_deps="schannel"
tls_schannel_protocol_select="tcp_protocol"
tls_securetransport_protocol_deps="securetransport"
tls_securetransport_protocol_select="tcp_protocol"
-tls_protocol_select_any="tls_schannel_protocol tls_securetransport_protocol tls_gnutls_protocol tls_openssl_protocol"
+tls_protocol_deps_any="tls_schannel_protocol tls_securetransport_protocol tls_gnutls_protocol tls_openssl_protocol"
udp_protocol_select="network"
udplite_protocol_select="network"
unix_protocol_deps="sys_un_h"
@@ -3047,7 +3014,10 @@ cpu="generic"
intrinsics="none"
# configurable options
+enable $PROGRAM_LIST
enable $DOCUMENT_LIST
+enable $EXAMPLE_LIST
+enable $(filter_out avresample $LIBRARY_LIST)
enable stripping
enable asm
@@ -3168,6 +3138,12 @@ ALL_COMPONENTS="
$PROTOCOL_LIST
"
+for n in $COMPONENT_LIST; do
+ v=$(toupper ${n%s})_LIST
+ eval enable \$$v
+ eval ${n}_if_any="\$$v"
+done
+
enable $ARCH_EXT_LIST
die_unknown(){
@@ -3234,11 +3210,10 @@ for opt do
disable $PROGRAM_LIST
;;
--disable-everything)
- map 'eval disable \${$(toupper ${v%s})_LIST}' $COMPONENT_LIST
- enable_deep_force $(filter_out avresample $LIBRARY_LIST) $PROGRAM_LIST
+ map 'eval unset \${$(toupper ${v%s})_LIST}' $COMPONENT_LIST
;;
--disable-all)
- map 'eval disable \${$(toupper ${v%s})_LIST}' $COMPONENT_LIST
+ map 'eval unset \${$(toupper ${v%s})_LIST}' $COMPONENT_LIST
disable $LIBRARY_LIST $PROGRAM_LIST doc
enable avutil
;;
@@ -3255,7 +3230,6 @@ for opt do
is_in "${thing}s" $COMPONENT_LIST || die_unknown "$opt"
eval list=\$$(toupper $thing)_LIST
name=$(echo "${optval}" | sed "s/,/_${thing}|/g")_${thing}
- test $action = enable && action="request"
list=$(filter "$name" $list)
[ "$list" = "" ] && warn "Option $opt did not match anything"
$action $list
@@ -3263,10 +3237,9 @@ for opt do
--enable-?*|--disable-?*)
eval $(echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g')
if is_in $option $COMPONENT_LIST; then
- test $action = enable && action="enable_deep_force"
+ test $action = disable && action=unset
eval $action \$$(toupper ${option%s})_LIST
elif is_in $option $CMDLINE_SELECT; then
- test $action = enable && action="request"
$action $option
else
die_unknown $opt
@@ -3303,15 +3276,11 @@ done
disabled logging && logfile=/dev/null
-# Enable the default components if not disabled explicitly
-
-enable_weak $(filter_out avresample $LIBRARY_LIST) $PROGRAM_LIST
-
# Disable all the library-specific components if the library itself
# is disabled, see AVCODEC_LIST and following _LIST variables.
disable_components(){
- disabled ${1} && disable_weak $(
+ disabled ${1} && disable $(
eval components="\$$(toupper ${1})_COMPONENTS"
map 'eval echo \${$(toupper ${v%s})_LIST}' $components
)
@@ -3320,25 +3289,6 @@ disable_components(){
map 'disable_components $v' $LIBRARY_LIST
echo "# $0 $FFMPEG_CONFIGURATION" > $logfile
-
-# Mark components that had not been enabled/disabled explicitly
-# as enabled
-
-for n in $COMPONENT_LIST; do
- v=$(toupper ${n%s})_LIST
- eval enable_weak \$$v
- eval ${n}_if_any="\$$v"
-done
-
-# Make so that disabled libraries are enabled if a component
-# of them is requested
-
-for n in $LIBRARY_LIST; do
- v=$(toupper ${n})_COMPONENTS
- eval ${n}_if_any="\$$v"
-done
-
-echo "# $0 $FFMPEG_CONFIGURATION" > $logfile
set >> $logfile
test -n "$valgrind" && toolchain="valgrind-memcheck"