user10381988
user10381988

Reputation:

Create executable OSX file on Windows for .jar file

I have created a java program (in Eclipse). I have successfully compiled it to a .jar file which I can run on windows without any problems. I want to give this program to a friend who has a MacOSX. So my aim is to:

The twist is that I have to configure it on my Windows computer since I don't have access to a Mac. Any advice would be of great help!

Upvotes: 0

Views: 105

Answers (1)

Arun Prasat
Arun Prasat

Reputation: 360

I am not sure what you are referring as "create a file which can be run on macOSX"

If you want to run on any OS you just need a JRE on that particular system without it you cant run. It will provide a runtime environment to run a jar file. Then use below command to run the jar.

java -jar Myjar_file.jar

Upvotes: 1

Related Questions