[英]Can I have more than one executable file with JavaFX native building tool?
這是可能的,因為底層的javapackager
支持這一點。
由於我理解你是正確的,你有一個項目,你有多個入口點,現在你想為每個入口點創建本機啟動器/二進制文件。 這在gradle插件中稱為“輔助啟動器”,甚至在javapackager
內部。
要使用相同的包創建多個可執行文件,只需在構建文件中添加:
jfx {
// ... normal configuration ...
// your secondary entry points, each will create a native executable (and one .cfg-file for each)
secondaryLaunchers = [
// second executable
[
appName: 'somethingDifferent'
// will create the same executable, just with a different name (so this is demo-purpose only)
],
// third executable
[
appName: 'somethingDifferent2',
// specify your different entry-point
mainClass: 'your.different.entrypoint.MainApp'
// other possible entries: "jfxMainAppJarName", "jvmProperties", "jvmArgs", "userJvmArgs", "nativeReleaseVersion", "needShortcut", "needMenu", "vendor", "identifier"
]
]
}
免責聲明:我是JavaFX Gradle插件的創建者;)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.