NativeImageModule

mill.scalalib.NativeImageModule
@Scaladoc(value = "/**\n * Provides a [[NativeImageModule.nativeImage task]] to build a native executable using [[https://www.graalvm.org/ Graal VM]].\n *\n * It is recommended to specify a custom JDK that includes the `native-image` Tool.\n * {{{\n * trait AppModule extends NativeImageModule {\n * def jvmWorker = ModuleRef(JvmWorkerGraalvm)\n *\n * object JvmWorkerGraalvm extends JvmWorkerModule {\n * def jvmId = \"graalvm-community:23.0.1\"\n * }\n * }\n * }}}\n */")

Provides a task to build a native executable using Graal VM.

It is recommended to specify a custom JDK that includes the native-image Tool.

trait AppModule extends NativeImageModule {
 def jvmWorker = ModuleRef(JvmWorkerGraalvm)

 object JvmWorkerGraalvm extends JvmWorkerModule {
   def jvmId = "graalvm-community:23.0.1"
 }
}

Attributes

Source
NativeImageModule.scala
Graph
Supertypes
trait Module
trait ModuleApi
trait Wrapper
class BaseClass
trait Cacher
trait Cacher
class Object
trait Matchable
class Any
Show all

Members list

Type members

Inherited classlikes

@Scaladoc(value = "/**\n * Miscellaneous machinery around traversing & querying the build hierarchy,\n * that should not be needed by normal users of Mill\n */")
object moduleInternal extends Internal

Miscellaneous machinery around traversing & querying the build hierarchy, that should not be needed by normal users of Mill

Miscellaneous machinery around traversing & querying the build hierarchy, that should not be needed by normal users of Mill

Attributes

Inherited from:
Module
Source
Module.scala
Supertypes
class Internal
class Object
trait Matchable
class Any

Value members

Abstract methods

def finalMainClass: Target[String]

Attributes

Source
NativeImageModule.scala

Attributes

Source
NativeImageModule.scala

Concrete methods

@Scaladoc(value = "/**\n * [[https://www.graalvm.org/latest/reference-manual/native-image/#from-a-class Builds a native executable]] for this\n * module with [[finalMainClass]] as the application entry point.\n */")

Builds a native executable for this module with finalMainClass as the application entry point.

Builds a native executable for this module with finalMainClass as the application entry point.

Attributes

Source
NativeImageModule.scala
@Scaladoc(value = "/**\n * The classpath to use to generate the native image. Defaults to [[runClasspath]].\n */")

The classpath to use to generate the native image. Defaults to runClasspath.

The classpath to use to generate the native image. Defaults to runClasspath.

Attributes

Source
NativeImageModule.scala
@Scaladoc(value = "/**\n * Additional options for the `native-image` Tool.\n */")
def nativeImageOptions: Target[Seq[String]]

Additional options for the native-image Tool.

Additional options for the native-image Tool.

Attributes

Source
NativeImageModule.scala
@Scaladoc(value = "/**\n * Path to the [[https://www.graalvm.org/latest/reference-manual/native-image/ `native-image` Tool]].\n * Defaults to a path relative to\n * - [[JvmWorkerModule.javaHome]], if defined\n * - environment variable `GRAALVM_HOME`, if defined\n *\n * @note The task fails if the `native-image` Tool is not found.\n */")

Path to the `native-image` Tool. Defaults to a path relative to

Path to the `native-image` Tool. Defaults to a path relative to

Attributes

Note

The task fails if the native-image Tool is not found.

Source
NativeImageModule.scala

Inherited methods

Attributes

Inherited from:
WithJvmWorker
Source
WithZincWorker.scala

Attributes

Inherited from:
BaseClass
Source
Module.scala
def moduleDir: Path

Attributes

Inherited from:
Module
Source
Module.scala
def moduleDirJava: Path

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Module -> Any
Inherited from:
Module
Source
Module.scala

Implicits

Inherited implicits

implicit def moduleNestedCtx: Nested

Attributes

Inherited from:
Module
Source
Module.scala