[perl #16000] Configure -Dstatic_ext=foo builds foo as both static and dynamic
Yitzchak Scott-Thoennes [Tue, 6 Aug 2002 04:28:15 +0000 (04:28 +0000)]
From: Yitzchak Scott-Thoennes (via RT) <perlbug@perl.org>
Message-id: <rt-16000-32913.8.41582281961522@bugs6.perl.org>

p4raw-id: //depot/perl@17698

Configure

index 5468749..03b4c7d 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -19424,7 +19424,19 @@ Note that DynaLoader is always built and need not be mentioned here.
 
 EOM
        case "$dynamic_ext" in
-       '') dflt="$avail_ext" ;;
+       '')
+               : Exclude those listed in static_ext
+               dflt=''
+               for xxx in $avail_ext; do
+                       case " $static_ext " in
+                       *" $xxx "*) ;;
+                       *) dflt="$dflt $xxx" ;;
+                       esac
+               done
+               set X $dflt
+               shift
+               dflt="$*"
+               ;;
        *)      dflt="$dynamic_ext"
                # Perhaps we are reusing an old out-of-date config.sh.
                case "$hint" in