diff --git a/Makefile b/Makefile
index 742fe7fa4841..5f1433916595 100644
--- a/Makefile
+++ b/Makefile
@@ -18,8 +18,6 @@
ROOTDIR = $(CURDIR)
TPARTYDIR = $(ROOTDIR)/3rdparty
-SCALA_VERSION_PROFILE := scala-2.11
-
ifeq ($(OS),Windows_NT)
UNAME_S := Windows
else
@@ -408,18 +406,13 @@ PLUGIN_OBJ =
PLUGIN_CUOBJ =
include $(MXNET_PLUGINS)
-ifeq ($(UNAME_S), Windows)
- # TODO(yizhi) currently scala package does not support windows
- SCALA_PKG_PROFILE := windows
-else
+ifneq ($(UNAME_S), Windows)
ifeq ($(UNAME_S), Darwin)
WHOLE_ARCH= -all_load
NO_WHOLE_ARCH= -noall_load
- SCALA_PKG_PROFILE := osx-x86_64
else
WHOLE_ARCH= --whole-archive
NO_WHOLE_ARCH= --no-whole-archive
- SCALA_PKG_PROFILE := linux-x86_64
endif
endif
@@ -438,7 +431,6 @@ ifeq ($(USE_CUDA), 1)
# Make sure to add stubs as fallback in order to be able to build
# without full CUDA install (especially if run without nvidia-docker)
LDFLAGS += -L/usr/local/cuda/lib64/stubs
- SCALA_PKG_PROFILE := $(SCALA_PKG_PROFILE)-gpu
ifeq ($(USE_NCCL), 1)
ifneq ($(USE_NCCL_PATH), NONE)
CFLAGS += -I$(USE_NCCL_PATH)/include
@@ -450,7 +442,6 @@ ifeq ($(USE_CUDA), 1)
CFLAGS += -DMXNET_USE_NCCL=0
endif
else
- SCALA_PKG_PROFILE := $(SCALA_PKG_PROFILE)-cpu
CFLAGS += -DMXNET_USE_NCCL=0
endif
@@ -620,18 +611,10 @@ rpkgtest:
Rscript -e 'res<-covr:::package_coverage("R-package");fileConn<-file(paste("r-package_coverage_",toString(runif(1)),".json"));writeLines(covr:::to_codecov(res), fileConn);close(fileConn)'
scalaclean:
- (cd $(ROOTDIR)/scala-package && \
- mvn clean -P$(SCALA_PKG_PROFILE),$(SCALA_VERSION_PROFILE))
-
-scalatestcompile:
- (cd $(ROOTDIR)/scala-package && \
- mvn test-compile -P$(SCALA_PKG_PROFILE),$(SCALA_VERSION_PROFILE) -Dcxx="$(CXX)" \
- -Dbuild.platform="$(SCALA_PKG_PROFILE)" \
- -Dcflags="$(CFLAGS)" -Dldflags="$(LDFLAGS)" \
- -Dcurrent_libdir="$(ROOTDIR)/lib" \
- -Dlddeps="$(LIB_DEP) $(ROOTDIR)/lib/libmxnet.a")
+ (cd $(ROOTDIR)/scala-package && mvn clean)
scalapkg:
+<<<<<<< HEAD
(cd $(ROOTDIR)/scala-package && \
mvn package $(MAVEN_ARGS) -P$(SCALA_PKG_PROFILE),$(SCALA_VERSION_PROFILE) -Dcxx="$(CXX)" \
-Dbuild.platform="$(SCALA_PKG_PROFILE)" \
@@ -691,6 +674,18 @@ scaladeploylocal:
-Dbuild.platform="$(SCALA_PKG_PROFILE)" \
-Dcflags="$(CFLAGS)" -Dldflags="$(LDFLAGS)" \
-Dlddeps="$(LIB_DEP) $(ROOTDIR)/lib/libmxnet.a")
+=======
+ (cd $(ROOTDIR)/scala-package && mvn install -DskipTests)
+
+scalainstall:
+ (cd $(ROOTDIR)/scala-package && mvn install)
+
+scalaunittest:
+ (cd $(ROOTDIR)/scala-package && mvn package)
+
+scalaintegrationtest:
+ (cd $(ROOTDIR)/scala-package && mvn integration-test)
+>>>>>>> Redo maven deploy related tasks.
jnilint:
3rdparty/dmlc-core/scripts/lint.py mxnet-jnicpp cpp scala-package/native/src --exclude_path scala-package/native/src/main/native/org_apache_mxnet_native_c_api.h
diff --git a/contrib/clojure-package/project.clj b/contrib/clojure-package/project.clj
index 7a259a0fdd7f..c4428ce6eff4 100644
--- a/contrib/clojure-package/project.clj
+++ b/contrib/clojure-package/project.clj
@@ -29,7 +29,7 @@
;[org.apache.mxnet/mxnet-full_2.11-linux-x86_64-gpu "1.2.1"]
;;; CI
- [org.apache.mxnet/mxnet-full_2.11 "1.5.0-SNAPSHOT"]
+ [org.apache.mxnet/mxnet-full_2.11 "INTERNAL"]
[org.clojure/tools.logging "0.4.0"]
[org.apache.logging.log4j/log4j-core "2.8.1"]
diff --git a/docs/mxdoc.py b/docs/mxdoc.py
index d4f379b3e849..58e603ed017a 100644
--- a/docs/mxdoc.py
+++ b/docs/mxdoc.py
@@ -113,9 +113,9 @@ def build_scala_docs(app):
scala_doc_sources = 'find . -type f -name "*.scala" | egrep \"\.\/core|\.\/infer\" | egrep -v \"\/javaapi\" | egrep -v \"Suite\"'
scala_doc_classpath = ':'.join([
'`find native -name "*.jar" | grep "target/lib/" | tr "\\n" ":" `',
- '`find macros -name "*-SNAPSHOT.jar" | tr "\\n" ":" `',
- '`find core -name "*-SNAPSHOT.jar" | tr "\\n" ":" `',
- '`find infer -name "*-SNAPSHOT.jar" | tr "\\n" ":" `'
+ '`find macros -name "*-INTERNAL.jar" | tr "\\n" ":" `',
+ '`find core -name "*-INTERNAL.jar" | tr "\\n" ":" `',
+ '`find infer -name "*-INTERNAL.jar" | tr "\\n" ":" `'
])
# There are unresolvable errors on mxnet 1.2.x. We are ignoring those errors while aborting the ci on newer versions
scala_ignore_errors = '; exit 0' if '1.2.' in _BUILD_VER else ''
@@ -135,9 +135,9 @@ def build_java_docs(app):
java_doc_sources = 'find . -type f -name "*.scala" | egrep \"\.\/core|\.\/infer\" | egrep \"\/javaapi\" | egrep -v \"Suite\"'
java_doc_classpath = ':'.join([
'`find native -name "*.jar" | grep "target/lib/" | tr "\\n" ":" `',
- '`find macros -name "*-SNAPSHOT.jar" | tr "\\n" ":" `',
- '`find core -name "*-SNAPSHOT.jar" | tr "\\n" ":" `',
- '`find infer -name "*-SNAPSHOT.jar" | tr "\\n" ":" `'
+ '`find macros -name "*-INTERNAL.jar" | tr "\\n" ":" `',
+ '`find core -name "*-INTERNAL.jar" | tr "\\n" ":" `',
+ '`find infer -name "*-INTERNAL.jar" | tr "\\n" ":" `'
])
_run_cmd('cd {}; scaladoc `{}` -classpath {} -feature -deprecation'
.format(java_path, java_doc_sources, java_doc_classpath))
diff --git a/scala-package/.gitignore b/scala-package/.gitignore
index f75826b29281..bf60e7bef0c5 100644
--- a/scala-package/.gitignore
+++ b/scala-package/.gitignore
@@ -1,10 +1,10 @@
.flattened-pom.xml
core/src/main/scala/org/apache/mxnet/NDArrayAPIBase.scala
core/src/main/scala/org/apache/mxnet/NDArrayBase.scala
+core/src/main/scala/org/apache/mxnet/NDArrayRandomAPIBase.scala
core/src/main/scala/org/apache/mxnet/javaapi/NDArrayBase.scala
core/src/main/scala/org/apache/mxnet/SymbolAPIBase.scala
core/src/main/scala/org/apache/mxnet/SymbolBase.scala
-core/src/main/scala/org/apache/mxnet/NDArrayRandomAPIBase.scala
core/src/main/scala/org/apache/mxnet/SymbolRandomAPIBase.scala
examples/scripts/infer/images/
examples/scripts/infer/models/
diff --git a/scala-package/README.md b/scala-package/README.md
index f103c47b0e4e..16d612b902a4 100644
--- a/scala-package/README.md
+++ b/scala-package/README.md
@@ -128,7 +128,7 @@ You can also run the unit tests and integration tests on the Scala Package by :
```bash
cd scala-package
-mvn integration-test
+mvn integration-test -DskipTests=false
```
Or run a subset of unit tests, for e.g.,
@@ -141,6 +141,25 @@ mvn -DSCALA_TEST_ARGS=-Dsuites=org.apache.mxnet.NDArraySuite integration-test
If everything goes well, you will find jars for `assembly`, `core` and `example` modules.
Also it produces the native library in `native/target`, which you can use to cooperate with the `core` module.
+Deploy to repository
+--------------------
+
+By default, `maven deploy` will deploy artifacts to local file system, you can file then in: ``scala-package/deploy/target/repo`` folder.
+
+For nightly build in CI, a snapshot build will be uploaded to apache repository with follow command:
+
+```bash
+cd scala-package
+mvn deploy -Pnightly
+```
+
+Use following command to deploy release build (push artifacts to apache staging repository):
+
+```bash
+cd scala-package
+mvn deploy -Pstaging
+```
+
Examples & Usage
-------
- To set up the Scala Project using IntelliJ IDE on macOS follow the instructions [here](https://mxnet.incubator.apache.org/tutorials/scala/mxnet_scala_on_intellij.html).
diff --git a/scala-package/assembly/pom.xml b/scala-package/assembly/pom.xml
index 27e843a6650a..00aa8682f8fa 100644
--- a/scala-package/assembly/pom.xml
+++ b/scala-package/assembly/pom.xml
@@ -6,101 +6,56 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
mxnet-full_2.11
- MXNet Scala Package - Full ${platform}-only
+ Assembly Scala Package
pom
- ${parent.basedir}/..
+ ${project.parent.basedir}/..
org.apache.mxnet
mxnet-core
- 1.5.0-SNAPSHOT
+ INTERNAL
org.apache.mxnet
libmxnet-scala
- 1.5.0-SNAPSHOT
+ INTERNAL
${libtype}
org.apache.mxnet
mxnet-infer
- 1.5.0-SNAPSHOT
+ INTERNAL
- release
+ staging
-
- org.apache.maven.plugins
- maven-source-plugin
-
-
- package
-
- jar-no-fork
-
-
- true
-
-
-
-
-
- org.apache.maven.plugins
- maven-javadoc-plugin
-
-
- package
-
- jar
-
-
- true
-
- commons-codec:*
- org.scala-lang:*
- log4j:*
- org.slf4j:*
-
-
-
-
-
org.apache.maven.plugins
maven-gpg-plugin
+ 1.6
sign-artifacts
- verify
+ deploy
sign
-
- org.sonatype.plugins
- nexus-staging-maven-plugin
- true
-
- ossrh
- https://oss.sonatype.org/
- true
-
-
@@ -108,38 +63,6 @@
-
- org.codehaus.mojo
- flatten-maven-plugin
- 1.0.1
-
-
- remove
-
-
-
-
-
- flatten
- process-resources
-
- flatten
-
-
-
-
- flatten.clean
- clean
-
- clean
-
-
-
-
-
- org.apache.maven.plugins
- maven-install-plugin
-
org.apache.maven.plugins
maven-assembly-plugin
@@ -151,7 +74,6 @@
single
- ${project.artifactId}-${platform}-${flavor}-${project.version}
false
src/main/assembly/assembly.xml
@@ -167,7 +89,7 @@
true
- src/source.xml
+ src/main/assembly/source.xml
@@ -180,7 +102,7 @@
true
- src/javadoc.xml
+ src/main/assembly/javadoc.xml
@@ -188,5 +110,4 @@
-
diff --git a/scala-package/assembly/src/javadoc.xml b/scala-package/assembly/src/javadoc.xml
deleted file mode 100644
index e4b35c99d865..000000000000
--- a/scala-package/assembly/src/javadoc.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-
- bundle
-
- jar
-
- false
-
-
-
-
-
-
- org.apache.mxnet:mxnet-core
-
- true
-
- false
- javadoc
- /
- true
-
-
-
-
\ No newline at end of file
diff --git a/scala-package/assembly/src/main/assembly/assembly.xml b/scala-package/assembly/src/main/assembly/assembly.xml
index c93efa77c9a8..5f02fda79c80 100644
--- a/scala-package/assembly/src/main/assembly/assembly.xml
+++ b/scala-package/assembly/src/main/assembly/assembly.xml
@@ -29,10 +29,15 @@
-
-
-
+
+
+ ${MXNET_DIR}/lib
+
+ libmxnet.so
+ libgfortran.so.3
+ libquadmath.so.0
+
lib/native
-
-
+
+
diff --git a/scala-package/assembly/src/main/assembly/javadoc.xml b/scala-package/assembly/src/main/assembly/javadoc.xml
new file mode 100644
index 000000000000..8f30a261811c
--- /dev/null
+++ b/scala-package/assembly/src/main/assembly/javadoc.xml
@@ -0,0 +1,15 @@
+
+ bundle
+
+ jar
+
+ false
+
+
+ ${rootdir}/core/target/site/scaladocs
+ /
+
+
+
diff --git a/scala-package/assembly/src/main/assembly/source.xml b/scala-package/assembly/src/main/assembly/source.xml
new file mode 100644
index 000000000000..87fcde360c48
--- /dev/null
+++ b/scala-package/assembly/src/main/assembly/source.xml
@@ -0,0 +1,19 @@
+
+ src
+
+
+ jar
+
+ false
+
+
+ ${rootdir}/core/src/main/scala
+
+ **\/*.scala
+
+ /
+
+
+
diff --git a/scala-package/assembly/src/source.xml b/scala-package/assembly/src/source.xml
deleted file mode 100644
index 594cc6a86f23..000000000000
--- a/scala-package/assembly/src/source.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-
- src
-
-
- jar
-
- false
-
-
- true
-
-
- org.apache.mxnet:mxnet-core
-
-
- false
-
-
-
- src/main/scala
-
- **\/*.scala
-
- /
-
-
-
-
-
-
\ No newline at end of file
diff --git a/scala-package/core/pom.xml b/scala-package/core/pom.xml
index d48b36774f63..8a54890ac946 100644
--- a/scala-package/core/pom.xml
+++ b/scala-package/core/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -50,7 +50,6 @@
exec
- 0
diff
${project.build.directory}/custom-javah/org_apache_mxnet_native_c_api.h ${project.parent.basedir}/native/src/main/native/org_apache_mxnet_native_c_api.h
@@ -96,9 +95,10 @@
NDArrayAPIBase.scala
NDArrayBase.scala
+ NDArrayRandomAPIBase.scala
javaapi/NDArrayBase.scala
SymbolAPIBase.scala
- SymbolBase.scala
+ SymbolRandomAPIBase.scala
false
@@ -135,13 +135,13 @@
org.apache.mxnet
mxnet-macros
- 1.5.0-SNAPSHOT
+ INTERNAL
provided
org.apache.mxnet
mxnet-scala-init
- 1.5.0-SNAPSHOT
+ INTERNAL
provided
diff --git a/scala-package/core/src/main/scala/org/apache/mxnet/Base.scala b/scala-package/core/src/main/scala/org/apache/mxnet/Base.scala
index 5737b47365b0..ed7aff602f63 100644
--- a/scala-package/core/src/main/scala/org/apache/mxnet/Base.scala
+++ b/scala-package/core/src/main/scala/org/apache/mxnet/Base.scala
@@ -89,35 +89,8 @@ private[mxnet] object Base {
@throws(classOf[UnsatisfiedLinkError])
private def tryLoadLibraryOS(libname: String): Unit = {
- try {
- logger.info(s"Try loading $libname from native path.")
- System.loadLibrary(libname)
- } catch {
- case e: UnsatisfiedLinkError =>
- val os = System.getProperty("os.name")
- // ref: http://lopica.sourceforge.net/os.html
- if (os.startsWith("Linux")) {
- tryLoadLibraryXPU(libname, "linux-x86_64")
- } else if (os.startsWith("Mac")) {
- tryLoadLibraryXPU(libname, "osx-x86_64")
- } else {
- // TODO(yizhi) support windows later
- throw new UnsatisfiedLinkError()
- }
- }
- }
-
- @throws(classOf[UnsatisfiedLinkError])
- private def tryLoadLibraryXPU(libname: String, arch: String): Unit = {
- try {
- // try gpu first
- logger.info(s"Try loading $libname-$arch-gpu from native path.")
- System.loadLibrary(s"$libname-$arch-gpu")
- } catch {
- case e: UnsatisfiedLinkError =>
- logger.info(s"Try loading $libname-$arch-cpu from native path.")
- System.loadLibrary(s"$libname-$arch-cpu")
- }
+ logger.info(s"Try loading $libname from native path.")
+ System.loadLibrary(libname)
}
// helper function definitions
diff --git a/scala-package/core/src/main/scala/org/apache/mxnet/util/NativeLibraryLoader.scala b/scala-package/core/src/main/scala/org/apache/mxnet/util/NativeLibraryLoader.scala
index 2ce893b478ed..1a940d98a92a 100644
--- a/scala-package/core/src/main/scala/org/apache/mxnet/util/NativeLibraryLoader.scala
+++ b/scala-package/core/src/main/scala/org/apache/mxnet/util/NativeLibraryLoader.scala
@@ -85,8 +85,10 @@ private[mxnet] object NativeLibraryLoader {
}
logger.debug(s"Attempting to load $loadLibname")
val libFileInJar = libPathInJar + loadLibname
- saveLibraryToTemp("libmxnet.so", "/lib/native/libmxnet.so")
- val tempfile: File = saveLibraryToTemp(libname, libFileInJar)
+ saveLibraryToTemp("libmxnet.so", "/lib/native/libmxnet.so", true)
+ saveLibraryToTemp("libgfortran.so.3", "/lib/native/libgfortran.so.3", false)
+ saveLibraryToTemp("libquadmath.so.0", "/lib/native/libquadmath.so.0", false)
+ val tempfile: File = saveLibraryToTemp(libname, libFileInJar, true)
loadLibraryFromFile(libname, tempfile)
}
@@ -134,29 +136,34 @@ private[mxnet] object NativeLibraryLoader {
*
* @param libname name of the library (just used in constructing the library name)
* @param resource String resource path in the jar file
+ * @param required true if library is required
*/
- private def saveLibraryToTemp(libname: String, resource: String): File = {
+ private def saveLibraryToTemp(libname: String, resource: String, required: Boolean): File = {
try {
val is: InputStream = getClass.getResourceAsStream(resource)
if (is == null) {
- throw new UnsatisfiedLinkError(s"Couldn't find the resource $resource")
- }
-
- val tempfile: File = new File(_tempDir, libname)
- val os: OutputStream = new FileOutputStream(tempfile)
- logger.debug("tempfile.getPath() = {}", tempfile.getPath)
- val savedTime: Long = System.currentTimeMillis
- val buf: Array[Byte] = new Array[Byte](8192)
- var len: Int = is.read(buf)
- while (len > 0) {
- os.write(buf, 0, len)
- len = is.read(buf)
+ if (required) {
+ throw new UnsatisfiedLinkError(s"Couldn't find the resource $resource")
+ } else {
+ null
+ }
+ } else {
+ val tempfile: File = new File(_tempDir, libname)
+ val os: OutputStream = new FileOutputStream(tempfile)
+ logger.debug("tempfile.getPath() = {}", tempfile.getPath)
+ val savedTime: Long = System.currentTimeMillis
+ val buf: Array[Byte] = new Array[Byte](8192)
+ var len: Int = is.read(buf)
+ while (len > 0) {
+ os.write(buf, 0, len)
+ len = is.read(buf)
+ }
+ os.close()
+ is.close()
+ val seconds: Double = (System.currentTimeMillis - savedTime).toDouble / 1e3
+ logger.debug(s"Copying $libname took $seconds seconds.")
+ tempfile
}
- os.close()
- is.close()
- val seconds: Double = (System.currentTimeMillis - savedTime).toDouble / 1e3
- logger.debug(s"Copying $libname took $seconds seconds.")
- tempfile
} catch {
case io: IOException =>
throw new UnsatisfiedLinkError(s"Could not create temp file for $libname")
diff --git a/scala-package/deploy/pom.xml b/scala-package/deploy/pom.xml
new file mode 100644
index 000000000000..c51aa9a92090
--- /dev/null
+++ b/scala-package/deploy/pom.xml
@@ -0,0 +1,140 @@
+
+
+ 4.0.0
+
+ org.apache.mxnet
+ mxnet-parent
+ INTERNAL
+ ../pom.xml
+
+
+ mxnet-deployment
+ ${revision}
+ MXNet Scala Package - Full ${platform}-only
+ pom
+
+ Scala Package for Apache MXNet (Incubating) - flexible and efficient library for deep learning.
+
+
+
+ mxnet-full_2.11-${platform}-${flavor}
+ 1.5.0-SNAPSHOT
+ apache.snapshots.https
+ file://${project.build.directory}/repo
+
+
+
+
+
+
+
+ org.apache.mxnet
+ mxnet-full_2.11
+ INTERNAL
+
+
+
+
+
+ staging
+
+ 1.5.0
+ apache.releases.https
+ https://repository.apache.org/content/repositories/staging
+ jar.asc,asc,asc
+ ,sources.jar,javadoc.jar
+
+ ../assembly/target/mxnet-full_2.11-INTERNAL.jar.asc,../assembly/target/mxnet-full_2.11-INTERNAL-src.jar.asc,../assembly/target/mxnet-full_2.11-INTERNAL-bundle.jar.asc
+
+
+
+
+ nightly
+
+ apache.snapshots.https
+ https://repository.apache.org/content/repositories/snapshots
+
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-assembly-plugin
+
+ false
+
+
+
+
+ com.google.code.maven-replacer-plugin
+ replacer
+ 1.5.3
+
+
+ deploy
+
+ replace
+
+
+
+
+ ${basedir}/src/main/deploy/deploy.xml
+ ${project.build.directory}/deploy.xml
+
+
+ DESCRIPTION
+ ${project.description}
+
+
+ ARTIFACT_ID
+ ${ARTIFACT_ID}
+
+
+ PROJECT_VERSION
+ ${project.version}
+
+
+ SCALA_VERSION
+ ${scala.version}
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-deploy-plugin
+
+
+ deploy-file
+ deploy
+
+ deploy-file
+
+
+ ${project.description}
+ ${repositoryId}
+ ${repo_url}
+ ${project.groupId}
+ ${ARTIFACT_ID}
+ ${project.version}
+ jar
+ ${project.build.directory}/deploy.xml
+ ${rootdir}/assembly/target/mxnet-full_2.11-INTERNAL.jar
+ ${rootdir}/assembly/target/mxnet-full_2.11-INTERNAL-src.jar
+ ${rootdir}/assembly/target/mxnet-full_2.11-INTERNAL-bundle.jar
+ ${deploy_asc_types}
+ ${deploy_asc_classifers}
+ ${deploy_asc_files}
+
+
+
+
+
+
+
+
diff --git a/scala-package/deploy/src/main/deploy/deploy.xml b/scala-package/deploy/src/main/deploy/deploy.xml
new file mode 100644
index 000000000000..97ba5f0ceb49
--- /dev/null
+++ b/scala-package/deploy/src/main/deploy/deploy.xml
@@ -0,0 +1,37 @@
+
+
+ 4.0.0
+ org.apache.mxnet
+ ARTIFACT_ID
+ PROJECT_VERSION
+ DESCRIPTION
+
+
+ org.scala-lang
+ scala-library
+ SCALA_VERSION
+ runtime
+
+
+ org.scala-lang
+ scala-reflect
+ SCALA_VERSION
+ runtime
+
+
+ org.scala-lang.modules
+ scala-parser-combinators_2.11
+ 1.0.4
+ runtime
+
+
+ org.scala-lang
+ scala-compiler
+ SCALA_VERSION
+ runtime
+
+
+
diff --git a/scala-package/examples/pom.xml b/scala-package/examples/pom.xml
index 07cc280917ce..564102a9f696 100644
--- a/scala-package/examples/pom.xml
+++ b/scala-package/examples/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -17,37 +17,6 @@
true
-
-
- release
-
-
-
- org.apache.maven.plugins
- maven-source-plugin
-
- true
-
-
-
- org.apache.maven.plugins
- maven-gpg-plugin
-
- true
-
-
-
- org.sonatype.plugins
- nexus-staging-maven-plugin
-
- true
-
-
-
-
-
-
-
@@ -125,13 +94,13 @@
org.apache.mxnet
mxnet-core
- 1.5.0-SNAPSHOT
+ INTERNAL
provided
org.apache.mxnet
mxnet-infer
- 1.5.0-SNAPSHOT
+ INTERNAL
provided
diff --git a/scala-package/infer/pom.xml b/scala-package/infer/pom.xml
index 3e3a677c2ff1..68b76c8b65ad 100644
--- a/scala-package/infer/pom.xml
+++ b/scala-package/infer/pom.xml
@@ -2,63 +2,63 @@
- 4.0.0
-
- mxnet-parent
- org.apache.mxnet
- 1.5.0-SNAPSHOT
- ../pom.xml
-
+ 4.0.0
+
+ mxnet-parent
+ org.apache.mxnet
+ INTERNAL
+ ../pom.xml
+
- mxnet-infer
- MXNet Scala Package - Inference
+ mxnet-infer
+ MXNet Scala Package - Inference
-
-
-
- org.apache.maven.plugins
- maven-jar-plugin
-
-
- META-INF/*.SF
- META-INF/*.DSA
- META-INF/*.RSA
-
-
-
-
- org.apache.maven.plugins
- maven-compiler-plugin
-
-
- org.scalatest
- scalatest-maven-plugin
-
-
- -Djava.library.path=${project.parent.basedir}/native/target \
- -Dlog4j.configuration=file://${project.basedir}/src/test/resources/log4j.properties
-
-
-
-
- org.scalastyle
- scalastyle-maven-plugin
-
-
-
-
-
- org.apache.mxnet
- mxnet-core
- 1.5.0-SNAPSHOT
- provided
-
-
-
- org.mockito
- mockito-all
- 1.10.19
- test
-
-
+
+
+
+ org.apache.maven.plugins
+ maven-jar-plugin
+
+
+ META-INF/*.SF
+ META-INF/*.DSA
+ META-INF/*.RSA
+
+
+
+
+ org.apache.maven.plugins
+ maven-compiler-plugin
+
+
+ org.scalatest
+ scalatest-maven-plugin
+
+
+ -Djava.library.path=${project.parent.basedir}/native/target \
+ -Dlog4j.configuration=file://${project.basedir}/src/test/resources/log4j.properties
+
+
+
+
+ org.scalastyle
+ scalastyle-maven-plugin
+
+
+
+
+
+ org.apache.mxnet
+ mxnet-core
+ INTERNAL
+ provided
+
+
+
+ org.mockito
+ mockito-all
+ 1.10.19
+ test
+
+
diff --git a/scala-package/init-native/pom.xml b/scala-package/init-native/pom.xml
index 4da6d8b89638..caf095c32a6d 100644
--- a/scala-package/init-native/pom.xml
+++ b/scala-package/init-native/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -144,25 +144,6 @@
-
-
- org.codehaus.mojo
- exec-maven-plugin
- 1.6.0
-
-
- link-native-lib
- generate-resources
-
- exec
-
-
- ln
- -sf ${MXNET_DIR}/lib/libmxnet.so ${project.build.directory}/libmxnet.so
-
-
-
-
@@ -182,8 +163,8 @@
exec
- ln
- -sf ${MXNET_DIR}/lib/libmxnet.so ${project.build.directory}/libmxnet.so
+ bash
+ -c 'ln -sf ${MXNET_DIR}/lib/libmxnet.so ${project.build.directory}/libmxnet.so; ln -sf ${MXNET_DIR}/lib/libgfortran.so.3 ${project.build.directory}/libgfortran.so.3; ln -sf ${MXNET_DIR}/lib/libquadmath.so.0 ${project.build.directory}/libquadmath.so.0'
diff --git a/scala-package/init/pom.xml b/scala-package/init/pom.xml
index eeeb711ba3be..a0bb6be384b5 100644
--- a/scala-package/init/pom.xml
+++ b/scala-package/init/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -51,9 +51,11 @@
exec
- 0
diff
- ${project.build.directory}/custom-javah/org_apache_mxnet_init_native_c_api.h ${project.parent.basedir}/init-native/src/main/native/org_apache_mxnet_init_native_c_api.h
+
+ ${project.build.directory}/custom-javah/org_apache_mxnet_init_native_c_api.h
+ ${project.parent.basedir}/init-native/src/main/native/org_apache_mxnet_init_native_c_api.h
+
diff --git a/scala-package/macros/pom.xml b/scala-package/macros/pom.xml
index 53c8a36f4527..52dfde181d72 100644
--- a/scala-package/macros/pom.xml
+++ b/scala-package/macros/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -17,7 +17,7 @@
org.apache.mxnet
mxnet-scala-init
- 1.5.0-SNAPSHOT
+ INTERNAL
provided
diff --git a/scala-package/native/pom.xml b/scala-package/native/pom.xml
index b44c498c2353..46da75c9b01b 100644
--- a/scala-package/native/pom.xml
+++ b/scala-package/native/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -158,8 +158,8 @@
exec
- ln
- -sf ${MXNET_DIR}/lib/libmxnet.so ${project.build.directory}/libmxnet.so
+ bash
+ -c 'ln -sf ${MXNET_DIR}/lib/libmxnet.so ${project.build.directory}/libmxnet.so; ln -sf ${MXNET_DIR}/lib/libgfortran.so.3 ${project.build.directory}/libgfortran.so.3; ln -sf ${MXNET_DIR}/lib/libquadmath.so.0 ${project.build.directory}/libquadmath.so.0'
diff --git a/scala-package/pom.xml b/scala-package/pom.xml
index ec1e303c69b5..1ea898013951 100644
--- a/scala-package/pom.xml
+++ b/scala-package/pom.xml
@@ -11,7 +11,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
MXNet Scala Package - Parent
https://github.com/apache/incubator-mxnet/tree/master/scala-package
@@ -38,7 +38,7 @@
2.11.8
-
+
g++
$
${project.basedir}/..
@@ -55,34 +55,10 @@
examples
spark
assembly
+ deploy
-
- release
-
-
-
- org.codehaus.mojo
- build-helper-maven-plugin
-
-
- generate-sources
-
- add-source
-
-
-
-
-
-
-
-
-
-
-
-
-
scala-2.11
@@ -116,7 +92,9 @@
osx-x86_64
- mac
+
+ mac
+
osx-x86_64
@@ -152,7 +130,7 @@
bash
- -c 'if [[ $(ldd ${MXNET_DIR}/lib/libmxnet.so | grep libcuda.so | wc -l) == "0" ]]; then echo flavor=cpu > /tmp/flavor.properties; else echo flavor=gpu > /tmp/flavor.properties; fi'
+ -c 'mkdir -p ${project.build.directory}; if [[ $(ldd ${MXNET_DIR}/lib/libmxnet.so | grep libcuda.so | wc -l) == "0" ]]; then echo flavor=cpu > ${project.build.directory}/flavor.properties; else echo flavor=gpu > ${project.build.directory}/flavor.properties; fi'
@@ -170,7 +148,7 @@
- /tmp/flavor.properties
+ ${project.build.directory}/flavor.properties
@@ -204,14 +182,6 @@
-
- org.apache.maven.plugins
- maven-release-plugin
-
- true
- false
-
-
org.apache.maven.plugins
maven-source-plugin
@@ -357,6 +327,14 @@
+
+
+ org.apache.maven.plugins
+ maven-deploy-plugin
+
+ true
+
+
@@ -400,7 +378,7 @@
test
-
+
org.scala-lang
scala-library
diff --git a/scala-package/spark/pom.xml b/scala-package/spark/pom.xml
index 074f30cc92aa..f2737e9334f4 100644
--- a/scala-package/spark/pom.xml
+++ b/scala-package/spark/pom.xml
@@ -6,7 +6,7 @@
org.apache.mxnet
mxnet-parent
- 1.5.0-SNAPSHOT
+ INTERNAL
../pom.xml
@@ -21,7 +21,7 @@
org.apache.mxnet
mxnet-core
- 1.5.0-SNAPSHOT
+ INTERNAL
provided