Search code examples
scalascala-native

Using Breeze Libraries or Apache Commons with Scala Native


I am trying to use Scala native while performing few linear algebra computations (using Scala version 2.13.4 and Native version 0.4.0). When I try apache commons or Breeze library for linear algebra computations, I get the linking error as below, while running "sbt run".

[error] Found 1 missing definitions while linking [error] Not found Top(org.apache.commons.math3.linear.MatrixUtils$).

Error using Breeze Scala library: Found 3 missing definitions while linking Not found Top(breeze.linalg.DenseMatrix$)

Any help is appreaciated.


Solution

  • Apache Commons is a Java library. I don't think there's a way to use it with Scala native. You'll have to find a native libary. Maybe this one? https://github.com/ekrich/sblas