Keep previous cmake arguments when using buildstandalonegc (dotnet/coreclr#12108)
authorOmair Majid <omair.majid@gmail.com>
Wed, 14 Jun 2017 05:39:08 +0000 (01:39 -0400)
committerDan Moseley <danmose@microsoft.com>
Wed, 14 Jun 2017 05:39:08 +0000 (22:39 -0700)
Currently, using buildstandalonegc makes ./build.sh discard any
previous values of __cmakearg set explicitly or implicitly. Preserve
those arguments.

Without this fix, the following invocations behave differently:

    $ ./build.sh ignorewarnings buildstandalonegc verbose

    $ ./build.sh buildstandalonegc ignorewarnings verbose

Commit migrated from https://github.com/dotnet/coreclr/commit/d2f9e21c69e70f1d0edac2392ff95d4670edff6e

src/coreclr/build.sh

index f337ae2..3412663 100755 (executable)
@@ -812,7 +812,7 @@ while :; do
             fi
             ;;
         buildstandalonegc)
-            __cmakeargs="-DFEATURE_STANDALONE_GC=1 -DFEATURE_STANDALONE_GC_ONLY=1"
+            __cmakeargs="$__cmakeargs -DFEATURE_STANDALONE_GC=1 -DFEATURE_STANDALONE_GC_ONLY=1"
             ;;
         msbuildonunsupportedplatform)
             __msbuildonunsupportedplatform=1