Results 1 to 6 of 6
  1. #1
    funnygames is offline Member
    Join Date
    Sep 2010
    Posts
    3
    Rep Power
    0

    Default Creating an EXE help

    Hello,

    I'm started using Java about one week ago. I see that there is no a compiler for EXE.
    My friend said I have to make an emulator or something for that.

    Can somebody tell me what I have to do after finishing my program? How to create an EXE or emulator for it, all I know is how to create *.jar or *.dist files.

    And do I have to know another language for that? Like C++/C# (programs which have exe compilers).

    Thanks in advance.

    Found the program. Solved.
    Last edited by funnygames; 09-27-2010 at 11:18 PM. Reason: Solved

  2. #2
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default

    The Java philosophy is to not create EXE's since that would tie the application to one OS (Windows and its variants). Instead create a Jar and distribute that. And yes, there are apps out there that will compile java apps to exe's, but it still begs the question (usually) of why one would want to do this. Sometimes there are valid reasons for this, but most often a Jar would be better.

  3. #3
    funnygames is offline Member
    Join Date
    Sep 2010
    Posts
    3
    Rep Power
    0

    Default

    Ok, I do understand the idea behind this. But how will my friends play the game without installing additional programs? I know that to run a jar file, you need to have JRE installed and other program (which I don't remember its name).

    Anyway, after compiling it to JAR file, what program will you recommend me to use, so I'll can create an exe, and without installing any additional programs.

    I once again asked my friend, and he says that I have to create an emulator for my program, if that true, then does somebody knows how to create it, and/or maybe tutorial for it?

    I'll be grateful for help. Thanks.

  4. #4
    dinosoep is offline Senior Member
    Join Date
    Nov 2009
    Posts
    150
    Rep Power
    5

    Default

    an emulator? does your friend know what he is talking about? :p

    there are two kinds of exe creating apps:
    -and exe wrapper (you will still need the jvm then)
    -compile to native code. there is one for free on linux (gcj) and also something for windows (jet or something like that)

    but first, why would you want to do that? every modern computer has java installed on it, use it :)

  5. #5
    funnygames is offline Member
    Join Date
    Sep 2010
    Posts
    3
    Rep Power
    0

    Default

    I don't know what my friend is talking about, so that's why I'm asking.

    Anyway, after creating a JAR file, I can't open it. Probably because the imports I'm using...

    About the program you recommend me, you said that for the exe wrapper I need to intall a jvm? In that case, it's not exactly what I want.

    About the second program, jet, as you mention, does it supports everything? I mean, all the libraries, and will NOT create an program errors? (ex. if I run using Java, there are not errors, but after using the exe compiler I will get errors).

    Thanks for replying.

  6. #6
    dinosoep is offline Senior Member
    Join Date
    Nov 2009
    Posts
    150
    Rep Power
    5

Similar Threads

  1. Creating jar
    By nitinverma in forum AWT / Swing
    Replies: 1
    Last Post: 07-12-2010, 11:07 AM
  2. Need help for creating executable xml
    By patilsubh in forum XML
    Replies: 3
    Last Post: 10-01-2009, 10:54 AM
  3. creating archives
    By almaz__ in forum Java Applets
    Replies: 2
    Last Post: 09-27-2009, 04:30 PM
  4. Creating files stopped creating...
    By Dieter in forum Advanced Java
    Replies: 3
    Last Post: 09-25-2009, 11:45 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •