[jvm-packages] Make it easier to release GPU/CPU code artifacts to Maven Central (#6940)

This commit is contained in:
Philip Hyunsu Cho 2021-05-04 14:00:03 -07:00 committed by GitHub
parent 4ddbaeea32
commit ec6ce08cd0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 13 additions and 4 deletions

View File

@ -84,8 +84,9 @@ if __name__ == "__main__":
print("building Java wrapper")
with cd(".."):
maybe_makedirs("build")
with cd("build"):
build_dir = 'build-gpu' if cli_args.use_cuda == 'ON' else 'build'
maybe_makedirs(build_dir)
with cd(build_dir):
if sys.platform == "win32":
# Force x64 build on Windows.
maybe_generator = ' -A x64'
@ -114,6 +115,9 @@ if __name__ == "__main__":
if gpu_arch_flag is not None:
args.append("%s" % gpu_arch_flag)
lib_dir = os.path.join(os.pardir, 'lib')
if os.path.exists(lib_dir):
shutil.rmtree(lib_dir)
run("cmake .. " + " ".join(args) + maybe_generator)
run("cmake --build . --config Release" + maybe_parallel_build)

View File

@ -1 +0,0 @@
../xgboost4j/src/

View File

@ -0,0 +1 @@
../../../xgboost4j/src/main/java/

View File

@ -0,0 +1 @@
../../../../xgboost4j/src/main/resources/xgboost4j-version.properties

View File

@ -0,0 +1 @@
../../../xgboost4j/src/main/scala/

View File

@ -0,0 +1 @@
../../xgboost4j/src/native

View File

@ -0,0 +1 @@
../../xgboost4j/src/test

View File

@ -1 +0,0 @@
../xgboost4j-spark/src/

View File

@ -0,0 +1 @@
../../../xgboost4j-spark/src/main/scala

View File

@ -0,0 +1 @@
../../xgboost4j-spark/src/test