LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-07-2009, 12:45 AM   #1
mavuduru_ravi
LQ Newbie
 
Registered: Feb 2009
Posts: 1

Rep: Reputation: 0
how to create .jar .war .ear files


Hi all,

Iam trying to generate .jar , .war files but iam getting errors like

jar command not found
jarcf command not found.

I have tried with this command

tarcf myclasses.tar file1.txt file2.txt

please help me

Regards
Ravi
 
Old 02-07-2009, 02:19 AM   #2
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,464

Rep: Reputation: Disabled
Quote:
Originally Posted by mavuduru_ravi View Post
Hi all,

Iam trying to generate .jar , .war files but iam getting errors like

jar command not found
jarcf command not found.

I have tried with this command

tarcf myclasses.tar file1.txt file2.txt

please help me

Regards
Ravi
Hi Ravi,
Have you installed the JRE? Is the "jar" executable in your path?
cheers,
jdk

Last edited by jdkaye; 02-07-2009 at 05:30 AM.
 
Old 02-07-2009, 04:03 AM   #3
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154
Welcome to LQ.

1) Install java > sun-java-'jre' or similar with
your package manager ( which Linux ? ? ? )

2) Make jar
http://www.javacoffeebreak.com/faq/faq0028.html

....

Last edited by knudfl; 06-30-2010 at 04:29 AM.
 
Old 02-07-2009, 07:38 AM   #4
shyamkumar1986
LQ Newbie
 
Registered: Feb 2009
Posts: 19

Rep: Reputation: 1
Jar -> An Archive of your Java files alone
War -> An Archive of your Java + Web files
Ear -> An Archive of your Enterprise Java Bean application related files


For Jar and War - all you need to do is zip the files/folder using winzip and then rename the extension to .jar and .war respectively.

For Ear - the process is a bit more complex. Checking out the following links should help you understand it better:

http://www.eclipse.org/webtools/jst/..._tutorial.html

http://www.coderanch.com/t/68306/BEA...oy-application

Last edited by shyamkumar1986; 02-09-2009 at 09:43 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to create a desktop shortcut to a JAR file? jdruin Linux - Newbie 4 01-04-2009 04:55 PM
how to create jar files with symbolic links alps963 Linux - General 1 05-03-2008 07:30 AM
How to create a war file chnlinux Linux - Newbie 1 04-22-2008 02:25 AM
Fedora Core 1 Associating .jar files with java -jar command pymehta Fedora 0 01-13-2005 06:26 AM
jar files mlynch147 Programming 2 10-24-2001 08:11 AM


All times are GMT -5. The time now is 02:36 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration