Fix Windows builds to correctly build -release tests
authorMike Fenelon <mike.fenelon@microsoft.com>
Thu, 27 Oct 2016 23:30:57 +0000 (16:30 -0700)
committerDave Thaler <dthaler@microsoft.com>
Fri, 4 Nov 2016 18:59:09 +0000 (18:59 +0000)
Change-Id: I80b4a9f09cc3278414b289b0693efb491dc00e89
Signed-off-by: Mike Fenelon <mike.fenelon@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13791
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
run.bat

diff --git a/run.bat b/run.bat
index a320b45..578005b 100644 (file)
--- a/run.bat
+++ b/run.bat
@@ -36,6 +36,7 @@ if "%RELEASE%" == "" (
 set SECURED=1
 set ROUTING=EP
 set WITH_UPSTREAM_LIBCOAP=1
+set BINDIR=debug
 
 set RUN_ARG=%1
 SHIFT
@@ -65,12 +66,16 @@ IF NOT "%1"=="" (
   GOTO :processArgs
 )
 
+IF %RELEASE% == 1 (
+  set BINDIR=release
+)
+
 REM We need to append the "PATH" so the octbstack.dll can be found by executables
 IF "%BUILD_MSYS%" == "" (
-  set BUILD_DIR=out\windows\%TARGET_ARCH%\debug
+  set BUILD_DIR=out\windows\%TARGET_ARCH%\%BINDIR%
   set PATH=!PATH!;!IOTIVITY_DIR!!BUILD_DIR!;
 ) ELSE (
-  set BUILD_DIR=out\msys_nt\x86_64\debug
+  set BUILD_DIR=out\msys_nt\x86_64\%BINDIR%
   set PATH=!PATH!;!BUILD_DIR!;C:\msys64\mingw64\bin
 )