We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 14f2f7b commit 9fc8788Copy full SHA for 9fc8788
utils/python/codal_utils.py
@@ -1,13 +1,9 @@
1
import os
2
import sys
3
-import optparse
4
import platform
5
import json
6
import shutil
7
import re
8
-
9
-import os, re, json, xml.etree.ElementTree
10
-from optparse import OptionParser
11
import subprocess
12
13
@@ -16,7 +12,10 @@ def system(cmd):
16
sys.exit(1)
17
18
14
def build(clean, verbose = False, parallelism = 10):
19
- if platform.system() == "Windows":
15
+ # Use Ninja on Windows, or if available in any other OS
+ use_ninja = shutil.which("ninja") is not None or platform.system() == "Windows"
+
+ if use_ninja:
20
# configure
21
system("cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo -G \"Ninja\"")
22
0 commit comments