@@ -364,7 +364,7 @@ def get_windows_args():
364
364
cmake args for windows platform.
365
365
"""
366
366
result_args = []
367
- result_args .append ('-G \" Visual Studio 16 2019\" ' )
367
+ result_args .append ('-G Visual Studio 16 2019' )
368
368
result_args .append ('-A x64' ) # TODO flexibily for x32
369
369
result_args .append ("-DFIREBASE_PYTHON_HOST_EXECUTABLE:FILEPATH=%s" % sys .executable )
370
370
return result_args
@@ -537,15 +537,22 @@ def main(argv):
537
537
os .chdir (build_path )
538
538
cmake_setup_args = [
539
539
"cmake" ,
540
- source_path ,
541
- "-DFIREBASE_INCLUDE_UNITY=ON" ,
542
- "-DFIREBASE_UNITY_BUILD_TESTS=ON" ,
543
- "-DFIREBASE_CPP_BUILD_STUB_TESTS=ON" ,
540
+ source_path
544
541
]
545
542
546
543
if FLAGS .verbose :
547
544
cmake_setup_args .append ('-DCMAKE_VERBOSE_MAKEFILE=1' )
548
545
546
+ if is_windows_build ():
547
+ # windows args need to happen right after target path
548
+ cmake_setup_args .extend (get_windows_args ())
549
+
550
+ cmake_setup_args .extend ([
551
+ "-DFIREBASE_INCLUDE_UNITY=ON" ,
552
+ "-DFIREBASE_UNITY_BUILD_TESTS=ON" ,
553
+ "-DFIREBASE_CPP_BUILD_STUB_TESTS=ON" ,
554
+ ])
555
+
549
556
unity_root_args = get_unity_engine_folder_args (FLAGS .unity_root )
550
557
if unity_root_args :
551
558
cmake_setup_args .append (unity_root_args )
@@ -566,8 +573,6 @@ def main(argv):
566
573
cmake_setup_args .extend (get_ios_args (source_path ))
567
574
elif is_android_build ():
568
575
cmake_setup_args .extend (get_android_args ())
569
- elif is_windows_build ():
570
- cmake_setup_args .extend (get_windows_args ())
571
576
elif is_macos_build ():
572
577
cmake_setup_args .extend (get_macos_args ())
573
578
@@ -585,7 +590,11 @@ def main(argv):
585
590
make_macos_multi_arch_build (cmake_setup_args )
586
591
else :
587
592
subprocess .call (cmake_setup_args )
588
- subprocess .call ("make" )
593
+ if is_windows_build ():
594
+ # no make command in windows. TODO make config passable
595
+ subprocess .call ("cmake --build . --config Release" )
596
+ else :
597
+ subprocess .call ("make" )
589
598
590
599
cmake_pack_args = [
591
600
"cpack" ,
0 commit comments