Open mtvgn opened 1 year ago
Could you explain why the installer needs Maven?
The installer doesn't need maven, but it takes the content of the /target directory as input for the msi-file, so when I do 'mvn clean install' (when the dependency is on javacv-platform) without further arguments, the target directory is 908 MegaByte. When I add the -Djavacpp.platform.windows-x86_64 option I get the "Could not resolve" errors from above.
When I add the -Djavacpp.platform.windows-x86_64 option when the dependency is on javacv I get a way smaller /target directory (28 MB), but that installed program doesn't work because it misses one or more dependencies. Which makes sense as the target directory became 32 times smaller in size, I would have expected it to become 5-10 times smaller.
It sounds like you have a buggy version of Maven. Since you only need the binaries for a single platform anyway, use "-Djavacpp.platform=windows-x86_64" instead. That triggers a simpler profile.
That does the trick, thank you very much! Installer is now 170 MB, that seems logical
I'm programming this JavaFX application in Java 19 for which I also create a MSI file as installer. This works (packaging the Liberica SDK), but both the jar file as the installer (and also installed application) is very big then: around 1 GB.
I found the need to use the -Djavacpp.platform.windows-x86_64 option with mvn elsewhere on these javacv github pages to get only the platform-specific OpenCV and FFMPEG libraries packaged in the jar instead of all of them. This works when I use javacv 1.5.8 as dependency, but then when I run the installed program it gives the error mentioned at https://github.com/bytedeco/javacv/issues/1402
When I switch to javacv-platform 1.5.8 as dependency mvn will only compile my application successfully without the -Djavacpp.platform.windows-x86_64 option. With it I get a lot of missing dependencies:
Especially the :true part seems weird to me and googling that (accompanied with one of these bytedeco jars) doesn't give me much either, so hopefully someone here can help me with my use case of needing to combine the javacv-platform dependency and the -Djavacpp.platform.windows-x86_64 option