Build JAR and got NoClassDefFoundError
已回答
I have tried to build JAR by the "jar -cfm" command with the same contents and same manifest file, and it works, but not by Build Artifacts in Intellij. No idea is it my mistakes or bug in Intellij. Anyone can help me?
Pls refer to the project file I uploaded.
Upload id: 2022_10_22_juKLQEKfr4cvC54Zrbm1LZ (file: hello-test.zip)
I have set classpath in the manifest.

I think I have put all the stuff in the right place.

请先登录再写评论。
Thank you for the provided information!
Please, try to make an artifact without adding the HelloUtil.jar file:
File|Project Structure...window select the Artifacts tab+|JAR|From modules with dependencies...com.hello.Helloand DIrectory for META-INF/MANIFEST.MF:After adding an artifact this way, building and running it we observe no errors.