Skip to content

Commit

Permalink
Fix DemoApp/pom.xml exec issue which prevented FluidSynthEmbeddedSynt…
Browse files Browse the repository at this point in the history
…h from being used
  • Loading branch information
jjazzboss committed Jun 24, 2024
1 parent 5cfde2f commit 83fd669
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 62 deletions.
2 changes: 1 addition & 1 deletion DemoApp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ This small Maven project demonstrates how to use the JJazzLab Toolkit.
### Run
- For FluidSynth to work you need to download and copy [JJazzLab-SoundFont.sf2](https://musical-artifacts.com/artifacts/1036) to the project root directory (next to `pom.xml`).
- `mvn exec:java`
- `mvn exec:exec`


Sample program output
Expand Down
55 changes: 0 additions & 55 deletions DemoApp/nbactions.xml

This file was deleted.

24 changes: 18 additions & 6 deletions DemoApp/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,21 +23,33 @@
<version>${jjazzlab.maven.compiler.plugin.version}</version>
<configuration>
<release>${jjazzlab.compiler.release}</release>
<enablePreview>true</enablePreview> <!-- needed for fluidsynthembeddedsynth -->
<compilerArgs>
<arg>--add-modules=jdk.incubator.foreign</arg> <!-- needed for fluidsynthembeddedsynth -->
</compilerArgs>
</configuration>
</plugin>


<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.3.0</version>
<version>3.3.0</version>
<configuration>
<mainClass>org.jjazzlab.toolkitdemo.ToolkitDemoApp</mainClass>
<executable>java</executable>
<arguments>
<!-- The 2 lines below automatically create the classpath using all project dependencies, also adding the project build directory -->
<argument>-classpath</argument>
<classpath/>
<argument>--add-modules=jdk.incubator.foreign</argument> <!-- required for FluidSynthEmbeddedSynth -->
<argument>--enable-preview</argument> <!-- required for FluidSynthEmbeddedSynth -->
<argument>--enable-native-access=ALL-UNNAMED</argument>
<argument>--add-opens=java.base/java.net=ALL-UNNAMED</argument>
<argument>--add-opens=java.base/java.lang=ALL-UNNAMED</argument>
<argument>--add-opens=java.desktop/javax.swing=ALL-UNNAMED</argument>
<argument>--add-exports=java.desktop/sun.awt=ALL-UNNAMED</argument>
<argument>--add-opens=java.base/java.util=ALL-UNNAMED</argument>
<argument>org.jjazzlab.toolkitdemo.ToolkitDemoApp</argument> <!-- program entry point -->
</arguments>
</configuration>
</plugin>

</plugins>

</build>
Expand Down

0 comments on commit 83fd669

Please sign in to comment.