Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. make jar file

make jar file

Scheduled Pinned Locked Moved C / C++ / MFC
c++question
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    cqwangdonghua
    wrote on last edited by
    #1

    I want to write a c++ program to convert a j2me source folder to a jar file. How should i do?is jar file is same as a zip file? Thanks for any answer!

    A 1 Reply Last reply
    0
    • C cqwangdonghua

      I want to write a c++ program to convert a j2me source folder to a jar file. How should i do?is jar file is same as a zip file? Thanks for any answer!

      A Offline
      A Offline
      Anonymuos
      wrote on last edited by
      #2

      cqwangdonghua wrote:

      I want to write a c++ program to convert a j2me source folder to a jar file. How should i do?

      jar is not only a file format but also a tool that produces jar files: http://java.sun.com/j2se/1.3/docs/tooldocs/win32/jar.html[^]

      cqwangdonghua wrote:

      is jar file is same as a zip file?

      Basically, yes.

      C 1 Reply Last reply
      0
      • A Anonymuos

        cqwangdonghua wrote:

        I want to write a c++ program to convert a j2me source folder to a jar file. How should i do?

        jar is not only a file format but also a tool that produces jar files: http://java.sun.com/j2se/1.3/docs/tooldocs/win32/jar.html[^]

        cqwangdonghua wrote:

        is jar file is same as a zip file?

        Basically, yes.

        C Offline
        C Offline
        cqwangdonghua
        wrote on last edited by
        #3

        Thanks!:) I know the jar is a tool to create jar format file.But I don't want use it.Since jar file is same as zip format file,so I can zip a src folder and change the filename to create a jar file.But when use I winzip and winrar to do this work today,it do not work. Is jar file not same as zip?what's wrong with it?

        K S 2 Replies Last reply
        0
        • C cqwangdonghua

          Thanks!:) I know the jar is a tool to create jar format file.But I don't want use it.Since jar file is same as zip format file,so I can zip a src folder and change the filename to create a jar file.But when use I winzip and winrar to do this work today,it do not work. Is jar file not same as zip?what's wrong with it?

          K Offline
          K Offline
          kakan
          wrote on last edited by
          #4

          It should work. A classic mistake, when it doesn't, is that the jar file was FTP:d using TEXT/ASCII mode instead of binary. Do you think that's a possibility here?

          Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson

          1 Reply Last reply
          0
          • C cqwangdonghua

            Thanks!:) I know the jar is a tool to create jar format file.But I don't want use it.Since jar file is same as zip format file,so I can zip a src folder and change the filename to create a jar file.But when use I winzip and winrar to do this work today,it do not work. Is jar file not same as zip?what's wrong with it?

            S Offline
            S Offline
            S Douglas
            wrote on last edited by
            #5

            cqwangdonghua wrote:

            Since jar file is same as zip format file,so I can zip a src folder and change the filename to create a jar file

            No, JAR is a compression format, which is indeed similar in that Zip is a compression format; JAR uses a different algorithm for compressing the files. You will either need to implement the JAR compression algorithm in your application or locate a library to do so. Check Suns website, as memory serves they have a lib you can use from C++. I believe the original respondent to your question provided you a link to Suns website. Good luck


            I'd love to help, but unfortunatley I have prior commitments monitoring the length of my grass. :Andrew Bleakley:

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups