Change winrt build to be less dependent on ANGLE
Now it does not try to build if the solution is not found. This way it's possible to provide a minimal package with includes and libs and make it build correctly. Also remove messages from detect.py since it is ran for every platform target.
This commit is contained in:
parent
1c50dfdf6c
commit
5c21d49caf
2 changed files with 8 additions and 7 deletions
|
@ -13,7 +13,10 @@ files = [
|
||||||
'os_winrt.cpp',
|
'os_winrt.cpp',
|
||||||
]
|
]
|
||||||
|
|
||||||
|
if "build_angle" in env and env["build_angle"]:
|
||||||
cmd = env.AlwaysBuild(env.ANGLE('libANGLE.lib', None))
|
cmd = env.AlwaysBuild(env.ANGLE('libANGLE.lib', None))
|
||||||
|
|
||||||
prog = env.Program('#bin/godot', files)
|
prog = env.Program('#bin/godot', files)
|
||||||
|
|
||||||
|
if "build_angle" in env and env["build_angle"]:
|
||||||
env.Depends(prog, [cmd])
|
env.Depends(prog, [cmd])
|
||||||
|
|
|
@ -17,11 +17,6 @@ def can_build():
|
||||||
if (os.getenv("VSINSTALLDIR")):
|
if (os.getenv("VSINSTALLDIR")):
|
||||||
|
|
||||||
if (os.getenv("ANGLE_SRC_PATH") == None):
|
if (os.getenv("ANGLE_SRC_PATH") == None):
|
||||||
print("You need to define ANGLE_SRC_PATH to the path of ANGLE source root.")
|
|
||||||
return False
|
|
||||||
|
|
||||||
if not os.path.isfile(str(os.getenv("ANGLE_SRC_PATH")) + "/winrt/10/src/angle.sln"):
|
|
||||||
print ("Couldn't find the ANGLE solution. Is ANGLE_SRC_PATH configured to the right path?")
|
|
||||||
return False
|
return False
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
@ -56,6 +51,9 @@ def configure(env):
|
||||||
jobs = str(env.GetOption("num_jobs"))
|
jobs = str(env.GetOption("num_jobs"))
|
||||||
angle_build_cmd = "msbuild.exe " + angle_root + "/winrt/10/src/angle.sln /nologo /v:m /m:" + jobs + " /p:Configuration=Release /p:Platform="
|
angle_build_cmd = "msbuild.exe " + angle_root + "/winrt/10/src/angle.sln /nologo /v:m /m:" + jobs + " /p:Configuration=Release /p:Platform="
|
||||||
|
|
||||||
|
if os.path.isfile(str(os.getenv("ANGLE_SRC_PATH")) + "/winrt/10/src/angle.sln"):
|
||||||
|
env["build_angle"] = True
|
||||||
|
|
||||||
if os.getenv('Platform') == "ARM":
|
if os.getenv('Platform') == "ARM":
|
||||||
|
|
||||||
print "Compiled program architecture will be an ARM executable. (forcing bits=32)."
|
print "Compiled program architecture will be an ARM executable. (forcing bits=32)."
|
||||||
|
|
Loading…
Reference in a new issue