Questions tagged [module-path]

Starting from Java 9 module path is used by JVM to look up modules during different phases (compile-time, runtime, etc.) by specifying `--module-path` or `-p` options. Its value is a semicolon-separated (;) list of directories each of which is a directory of modules.

66 questions
3
votes
0 answers

Gradle and Java 11: Partial module path

I want to modularize my Gradle project with Java 11. Unfortunately, many of my dependencies are not modular yet. As a consequence, my module-info.java contains a lot of automatic modules, derived from the dependency names. Also, I followed this…
3
votes
1 answer

Different behaviour between Maven & Eclipse to launch a JavaFX 11 app

I'm starting to dig into Java 11 migration for a large app (includes Java FX parts) and I need your help to understand the difference between Maven (3.5.4) on the command-line and Eclipse (2018-09 with Java11 upgrade). I have a simple Java 11…
Francois Marot
  • 1,145
  • 11
  • 18
3
votes
1 answer

Mix --class-path and --module-path in javac (JDK 9)

I tried to follow this question but it does`t work for me. I want to compile 1 module (which does not requires any other module or jar) together with other classes which use this module and will be in unnamed module. javac -cp lib\* --module-path…
3
votes
2 answers

How to use --hash-modules and --module-path options of JDK 9 jar tool?

I would like to compute and record the hash of module matched by the given pattern that depend upon directly on a modular JAR file being updated. For this a use --hash-modules and --module-path options. There are my tries: jar --hash-modules…
3
votes
1 answer

How do I add modules to the Eclipse Oxygen module path for a project?

I have a project that today has several jars as "Referenced Libraries". I'd instead like to add these as automatic modules on the module path so I can require them in my module-info.java. How do you add jars to the module path in Eclipse Oxygen?
tibbe
  • 8,809
  • 7
  • 36
  • 64
3
votes
1 answer

Unrecognized option: -modulepath

Is anyone else having this issue when they run the module it complains about this in java 9 mac version? Below is the issue! Unrecognized option: -modulepath Error: Could not create the Java Virtual Machine. How to reproduce ? I am doing this…
JLP
  • 311
  • 2
  • 3
  • 12
2
votes
2 answers

Customizing --module-path for Java

I created a javafx application via the IDE IntelliJ IDEA on ArchLinux. Now, I want to start this program without any IDE, so I created a .jar file. When trying to start the program with java -jar myprogram.jar, then I get the error message that…
cwellm
  • 64
  • 7
2
votes
1 answer

Java modules and the JAR MANIFEST Class-Path attribute

I have a Java 8 application I am working on converting to Java 11 and of course with this I am working with the module system for the first time. I have my application Maven assembly configuration set such that all the JAR files are put in a /lib…
Michael Remijan
  • 687
  • 7
  • 22
2
votes
0 answers

Java failed to bootstrap path, eclipse, jdk-13

I’m trying to update my JavaFX project to be compatible with JRE 13 (until now it was set up to use JRE 1.8). I’m developing with Eclipse 2020-03, using a Mac. The first big issue I’ve had to deal with is the migration from the included JavaFX…
owengall
  • 455
  • 4
  • 11
2
votes
2 answers

module Directory or module file inside name should be same or not

Directory Structure . ├── out │   └── calc-module │   ├── com │   │   └── ngsharma │   │   └── ocp │   │   └── Calculator.class │   └── module-info.class └── src └── calculator ├── com │   └──…
Ng Sharma
  • 2,072
  • 8
  • 27
  • 49
2
votes
1 answer

How to specify multiple jar files on the modulepath for java on the command line?

For the java command line tool, there is now the --module-path option as a replacement for the --class-path (or -cp) option. With the classpath option, you can specify wildcards to include all jars in a given directory. E.g.: java -cp…
Wim Deblauwe
  • 25,113
  • 20
  • 133
  • 211
2
votes
1 answer

How to let a java class on classpath access a class belonging to a module on module-path

I am trying out the various access rules about who can access and what and I saw this statement in The State of the module system document, The unnamed module reads every other module. Code in any type loaded from the class path will thus be able…
Priyshrm
  • 662
  • 8
  • 20
2
votes
1 answer

intellij java-9 build path- module path settings

i know intellij supports java9,and i know how to set classpath on intellij by adding libraries to build path. but how does it works in java 9, is there a section for module path in intellij? i think java 9 uses classpath if it cannot find classes…
darcula
  • 33
  • 4
1
vote
0 answers

How to invoke module-path in a portable manner across Windows and *nix platforms?

Oracle's documentation states that: module-path is the path to either a directory of modules or to a modular JAR file. The path can be absolute or relative to the current directory. For more than one path, separate the paths with a colon (:) on…
Gili
  • 86,244
  • 97
  • 390
  • 689
1
vote
0 answers

Removing Class Path and Module Path from an Eclipse Project

I am trying to import some files into a java project that I created in eclipse. Other students in my class have indicated that when they go into their project properties, they do not have "classpath" and "modulepath", allowing them to add the files…