Skip to content
This repository was archived by the owner on Mar 5, 2023. It is now read-only.

Commit aeac14b

Browse files
committed
Reverted to more stable gradle plugin (+added retrolambda because lambdas aren't supported on stable yet);
Rebuilt cmake libs in release; Fixed launcher losing some vcmi config options;
1 parent b5d3d6e commit aeac14b

39 files changed

+24
-9
lines changed

build.py

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
PARAM_FIXES = 0
1212
PARAM_BUILD_EXT = 1
1313
PARAM_BUILD_CMAKE = 2
14+
PARAM_BUILD_APP = 3
1415

1516
def copyLibs():
1617
vcmiutil.copytree("./libs/", conf["extOutput"])
@@ -69,7 +70,13 @@ def buildFFMPEG():
6970
def buildCMakeExternals():
7071
os.chdir("project")
7172
os.environ["JAVA_HOME"] = conf["javaRoot"]
72-
cmd = "gradlew -a :vcmi-app:compileLibsOnlyDebugSources"
73+
cmd = "gradlew -a :vcmi-app:compileLibsOnly{}Sources".format(conf["cmakeBuildMode"])
74+
assertZero(os.system(cmd), cmd)
75+
76+
def buildApp():
77+
os.chdir("project")
78+
os.environ["JAVA_HOME"] = conf["javaRoot"]
79+
cmd = "gradlew -a :vcmi-app:assembleVcmiOnly{}".format(conf["cmakeBuildMode"])
7380
assertZero(os.system(cmd), cmd)
7481

7582
def buildAllOptional():
@@ -91,17 +98,18 @@ def inputError():
9198

9299
args = len(sys.argv)
93100
if args < 2:
94-
print("run with any of these: all, build, fixpaths")
95-
sys.exit(1)
101+
inputError()
96102

97-
parsedParams = [False, False, False]
103+
parsedParams = [False, False, False, False]
98104
for arg in sys.argv[1:]:
99105
if arg == "all" or arg == "build-optional":
100106
parsedParams[PARAM_BUILD_EXT] = True
101107
if arg == "all" or arg == "build-cmake":
102108
parsedParams[PARAM_BUILD_CMAKE] = True
103109
if arg == "all" or arg == "fixpaths":
104110
parsedParams[PARAM_FIXES] = True
111+
if arg == "all" or arg == "build-app":
112+
parsedParams[PARAM_BUILD_APP] = True
105113

106114
executedAnything = False
107115
if parsedParams[PARAM_FIXES]:
@@ -113,6 +121,9 @@ def inputError():
113121
if parsedParams[PARAM_BUILD_CMAKE]:
114122
buildAllCmake()
115123
executedAnything = True
124+
if parsedParams[PARAM_BUILD_APP]:
125+
timed(buildApp, "app")
126+
executedAnything = True
116127

117128
if executedAnything == False:
118129
inputError()
-280 KB
Binary file not shown.
66.3 KB
Binary file not shown.
-212 KB
Binary file not shown.
-368 KB
Binary file not shown.
-1.06 KB
Binary file not shown.
-333 KB
Binary file not shown.

ext-output/arm64-v8a/libminizip.so

43.3 KB
Binary file not shown.
8 Bytes
Binary file not shown.
-215 KB
Binary file not shown.

0 commit comments

Comments
 (0)