# HG changeset patch # User "Yann E. MORIN" # Date 1251715678 -7200 # Node ID f79fcf38ec21d92dd1068f5364432e6b357bc70e # Parent 7eeeaf4bc78afab529b7734d3f13f5d9b1a347e6 config: add fallback to patch order Add the possibility to fallback to either bundled or local patches if local or bundled are missing. diff -r 7eeeaf4bc78a -r f79fcf38ec21 config/global/paths.in --- a/config/global/paths.in Mon Aug 31 12:51:53 2009 +0200 +++ b/config/global/paths.in Mon Aug 31 12:47:58 2009 +0200 @@ -94,6 +94,24 @@ Apply your local patches, then apply the patches bundled with crosstool-NG. +config PATCH_BUNDLED_FALLBACK_LOCAL + bool + prompt "Bundled only, local if no bundled" + select PATCH_USE_LOCAL + select PATCH_SINGLE + help + Apply the patches bundled with crosstool-NG; + if there's no bundled patches, apply your local patches. + +config PATCH_LOCAL_FALLBACK_BUNDLED + bool + prompt "Local only, bundled if no local" + select PATCH_USE_LOCAL + select PATCH_SINGLE + help + Only apply your local patches; + if there's no local patches, apply patches bundled with crosstool-NG. + endchoice config PATCH_ORDER @@ -103,6 +121,10 @@ default "bundled,local" if PATCH_BUNDLED_LOCAL default "local,bundled" if PATCH_LOCAL_BUNDLED +config PATCH_SINGLE + bool + default n + config PATCH_USE_LOCAL bool default n diff -r 7eeeaf4bc78a -r f79fcf38ec21 scripts/functions --- a/scripts/functions Mon Aug 31 12:51:53 2009 +0200 +++ b/scripts/functions Mon Aug 31 12:47:58 2009 +0200 @@ -630,6 +630,9 @@ CT_DoExecLog ALL patch -g0 -F1 -p1 -f <"${p}" fi done + if [ "${CT_PATCH_SINGLE}" = "y" ]; then + break + fi fi done