LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 07-27-2004, 02:01 AM   #1
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Rep: Reputation: 15
first linux, first post, how do you install tar.bz2 ??


first i would like to state that i have never used linux. got tired of windows and decided to try it. so then i download a few distros (overnight) and burn them. i tried them and decided to learn on Xandros. i dont know how to use the command console at all. im used to dos.

so to get to the question. i read the install page in this tar.bz2 it said:

1. `cd' to the directory containing the package's source code and type
`./configure' to configure the package for your system. If you're
using `csh' on an old version of System V, you might need to type
`sh ./configure' instead to prevent `csh' from trying to execute
`configure' itself.

Running `configure' takes awhile. While running, it prints some
messages telling which features it is checking for.

2. Type `make' to compile the package.

3. Optionally, type `make check' to run any self-tests that come with
the package.

4. Type `make install' to install the programs and any data files and
documentation.

i didnt get past #1. how exactly do i change directories? and after that what do i do? i would apreciate help very much



a little more information in case its needed. xandros open source version. and im trying to instal the new digikam program.
 
Old 07-27-2004, 02:30 AM   #2
jax8
Member
 
Registered: Feb 2004
Location: Australia
Distribution: Ubuntu, Fedora 10
Posts: 632

Rep: Reputation: 31
to change directories use cd

cd / ---changes to the root (the bottom of the filesystem, it is like "cd C:" in windows)
cd --- will change to your home directory, so if your home directory is /home/john it will place you there

cd .. -----will go down one directory
cd ./somefilename -----will execute the file somefilename (./ is the current directory ../ is the parent directory)

cd /usr/lib --- will take you to /usr/lib




to list files and direcories us ls (list, like dir in DOS), so type ls in a terminal

type man ls for more information (to exit man pages press q)



so to run the program you just downloaded you need to go to that directory.

if you downloaded into /home/john/downloads do this

cd /home/john/downloads

then type ls

you should see somefile.tar.bz2 (bz2 is a compression format and tar is like a .CAB file in windows)

use

tar -jxf somefile.tar.bz2


this will unzip (j) and extract (x)


type ls

and you should see a "somefile" directory.

cd somefile

then type ls and you will see a heap of files.

run this command to compile and install

./configure && make && make install


done, if there were no errors the package will be installed.






SOME TIPS

linux is case sensitive so John is not the same as JOhn

pressing the <TAB> key will finish a command as best as possible so tar -zxf som (then press the tab key will output) somefile.tar.bz2 . THIS WILL SAVE YOU A LOT OF TIME. pressing <TAB> twice will show lots of possible commands that have "som" at the start

Last edited by jax8; 07-27-2004 at 02:31 AM.
 
Old 07-27-2004, 02:31 AM   #3
SBing
Member
 
Registered: Mar 2004
Posts: 519

Rep: Reputation: 35
Edit: lol, beat me to it Jax mate :( - scary we said exactly the same stuff :D

Hiya, welcome to LQ!

At the prompt ($), type in:

$ tar -jxvf filename.tar.bz2 (the 'j' is used when you have a bz2 file, this is replaced with a 'z' when you are dealing with a gz file)
$ cd filename (it will extract to a directory, probably called filename, type in 'ls' to list the files in the directory, don't forget TAB auto completion helps!)

Now you are in the directory where you can run configure :) - I'm off to work, if you have any more help, I'm sure someone else will post a reply before I get back (typical 9-5 work...fun!)

Last edited by SBing; 07-27-2004 at 02:32 AM.
 
Old 07-27-2004, 02:38 AM   #4
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 376Reputation: 376Reputation: 376Reputation: 376
also, you might wanna consider starting with binary packages instead of compiling source code... at least while you're still getting the feel of linux... of course if you wanna compile everything there's nothing wrong with that... both methods have their advantages...

the three main types of binaries for linux are RPM (red hat linux), DEB (debian* linux), and TGZ (slackware linux)...

with binaries, everything is pre-compiled and pre-packaged for you...

installing a binary package is usually as easy as one of these:

rpm -i example.rpm

dpkg -i example.deb

installpkg example.tgz



*i believe xandros is based on debian...


Last edited by win32sux; 07-27-2004 at 02:41 AM.
 
Old 07-27-2004, 03:14 AM   #5
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 69
Re: first linux, first post, how do you install tar.bz2 ??

Quote:
Originally posted by blackdragon

i didnt get past #1. how exactly do i change directories? and after that what do i do? i would apreciate help very much



a little more information in case its needed. xandros open source version. and im trying to instal the new digikam program.
To change to a directory you would use cd /path/to/directory/you/want then the ENTER key in a console window.
Code:
[12:05 AM Tue Jul 27: stephen @ ~]
>$ cd archives/tar/
[12:06 AM Tue Jul 27: stephen @ ~/archives/tar]
>$

Have you actually extracted the .tar.bz2 yet to have a directory to enter into? If not you need to use in the directory you downloaded the source too tar -xjvf some.tar.bz2 which will extract the files in the tarball to most likely some-1.2.3 directory you will see the real directory name in the output of the extraction process like this.

Code:
>$ tar -xjvf skype_ver-0_90_0_14.tar.bz2
skype_ver-0_90_0_14/
skype_ver-0_90_0_14/skype
skype_ver-0_90_0_14/icons/
skype_ver-0_90_0_14/icons/skype_16_32.png
skype_ver-0_90_0_14/icons/skype_24_32.png
skype_ver-0_90_0_14/icons/skype_32_32.png
skype_ver-0_90_0_14/icons/skype_48_32.png
skype_ver-0_90_0_14/call_in.wav
skype_ver-0_90_0_14/LICENSE
skype_ver-0_90_0_14/skype.desktop
skype_ver-0_90_0_14/skype.desktop.old
Now in this case there is not much sense in me changing into the directory to do anything but run the pre-compiled binary that is there but for you use the cd command and type in the first few letters you seen in the directory name then the TAB key and bash should try to auto complete the directory name if you hear a beep then hit the TAB key again and see the list of choices you have.

Code:
[12:08 AM Tue Jul 27: stephen @ ~/archives/tar]
>$ cd skype_ver-0_90_0_
skype_ver-0_90_0_14  skype_ver-0_90_0_4
skype_ver-0_90_0_3   skype_ver-0_90_0_6
[12:09 AM Tue Jul 27: stephen @ ~/archives/tar]
>$ cd skype_ver-0_90_0_
Enter the letter/number that will complete the directory you are looking for and TAB then ENTER key to change into the directory.

Code:
>$ cd skype_ver-0_90_0_14/
[12:09 AM Tue Jul 27: stephen @ ~/archives/tar/skype_ver-0_90_0_14]
>$
Now that you would be in the directory you want to compile the source you would use the ./configure command again type the first few letters of the command and TAB to complete then ENTER and you will see the configure script checking for the libraries/compiler it needs to to build the source. Then you need to run make to actually compile the program/libraries needed for the install process. If all goes well then it will exit without errors and you can use su -c 'make install' then ENTER key you will then be asked for the root password if you type it in and enter again then the program will be installed. Or if you want in place of the last step you can install the checkinstall package before hand and make/install yourself a .deb package with the command:

Code:
>$ su -c 'checkinstall -D  --pkgname=some --pkgversion=1.2.3'
Then you can remove the package later with apt/dpkg if you every decide to upgrade to a different version without hoping the uninstall script (if there is one) works properly and you do not have to start tracking down where everything went to prevent conflicts.
 
Old 07-27-2004, 12:29 PM   #6
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Original Poster
Rep: Reputation: 15
wow that was a lot of help. i just woke up and had lots of advice. thanx for the quick response. there was no rpm of the file i wanted to instal. or at least i couldnt find one. lemme try this stuff and see where it me. i will post a followup later. thanx again
 
Old 07-27-2004, 01:23 PM   #7
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Original Poster
Rep: Reputation: 15
ok.... i got to the right directory... several times. i ran the config file. it was working then it said

configure: error:
***
*** gPhoto2 is required. Available from gPhoto's Sourceforge CVS.
*** Check http://www.gphoto.org/download.html for details
***

so. i went to the site to download. and it also only comes in tar.bz2.
downloaded, extracted, read the install file. tried to config and i get this

config search path.
Perhaps you should add the directory containing `libgphoto2.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libgphoto2' found

configure: error: Library requirements (libgphoto2 >= 2.1.2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.

i tried typing in PKG_CONFIG_PATH but it got me nowhere.

did i mention that now im on my second day of linux, and this was my first real task. please be patient. and thanx again
 
Old 07-27-2004, 01:31 PM   #8
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 69
Quote:
Originally posted by blackdragon
ok.... i got to the right directory... several times. i ran the config file. it was working then it said

configure: error:
***
*** gPhoto2 is required. Available from gPhoto's Sourceforge CVS.
*** Check http://www.gphoto.org/download.html for details
***

so. i went to the site to download. and it also only comes in tar.bz2.
downloaded, extracted, read the install file. tried to config and i get this

config search path.
Perhaps you should add the directory containing `libgphoto2.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libgphoto2' found

configure: error: Library requirements (libgphoto2 >= 2.1.2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.

i tried typing in PKG_CONFIG_PATH but it got me nowhere.

did i mention that now im on my second day of linux, and this was my first real task. please be patient. and thanx again

Looks like you need to install the package libgphoto2-2-dev now.

Code:
[02:26 PM Tue Jul 27: stephen @ ~]
>$ apt-cache search  libgphoto2
libgphoto2-2 - The gphoto2 digital camera library
libgphoto2-2-dev - The gphoto2 digital camera library (development files)
libgphoto2-port0 - The gphoto2 digital camera port library
[02:26 PM Tue Jul 27: stephen @ ~]
>$ acp libgphoto2-2-dev
libgphoto2-2-dev:
  Installed: (none)
  Candidate: 2.1.4-5
  Version Table:
     2.1.4-6 0
        600 http://ftp.de.debian.org unstable/main Packages
     2.1.4-5 0
        990 http://ftp.de.debian.org testing/main Packages
 
Old 07-27-2004, 11:22 PM   #9
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Original Poster
Rep: Reputation: 15
>$ apt-cache search libgphoto2

this line did nothing. is there a variation i might use? is it intended to find the libgphoto2 folder?

if so what am i looking for in the folder?



btw, thanx some more for the help

Last edited by blackdragon; 07-27-2004 at 11:23 PM.
 
Old 07-28-2004, 12:07 AM   #10
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 69
Quote:
Originally posted by blackdragon
>$ apt-cache search libgphoto2

this line did nothing. is there a variation i might use? is it intended to find the libgphoto2 folder?

if so what am i looking for in the folder?



btw, thanx some more for the help
You are not looking for a folder when you use the command you would be the searching the apt database on your machine to see if anything has that in their package description so you could install the package or similar package if it exists and from the looks of it there is not a line in your sources.list that will allow you to do that. The database comes from the lines that are in the /etc/apt/sources.list file and gets updated/rebuilt when you use apt-get update as root. Can you post the sources.list file so we can see what Xandros is using for them. You may want to have a look at the Apt How-to it gives you an overview of the commands you can use and a few other things.

BTW: Looking at your first post again is it Digikam that you are trying to install? If so you can get a pre-compiled program/binary package and save all this trouble for yourself with the proper line in your sources.list. Then it should be simply a matter of apt-get install digikam and apt should install it and all other packages needed.

Code:
>$ apt-cache policy digikam
digikam:
  Installed: (none)
  Candidate: 0.6.0-4
  Version Table:
     0.6.2-2 0
        600 http://ftp.de.debian.org unstable/main Packages
     0.6.0-4 0
        990 http://ftp.de.debian.org testing/main Packages
 
Old 07-28-2004, 01:12 PM   #11
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Original Poster
Rep: Reputation: 15
thanx again. i will try it later, if it doesnt work this time im gonna give up on this prog for now
 
Old 07-28-2004, 01:34 PM   #12
scuzzman
Senior Member
 
Registered: May 2004
Location: Hilliard, Ohio, USA
Distribution: Slackware, Kubuntu
Posts: 1,851

Rep: Reputation: 47
Honestly: don't do that (give up I mean). You are VERY close.
You're installing Dependencies: ie: this program needs stdio.h to compile, you would need to install the gcc libraries.
get all the deps, and your all set. Dont give up, I did once and I've regretted it since.
have Fun!!

Last edited by scuzzman; 07-28-2004 at 01:35 PM.
 
Old 07-28-2004, 02:16 PM   #13
blackdragon
LQ Newbie
 
Registered: Jul 2004
Posts: 26

Original Poster
Rep: Reputation: 15
sweet..... it worked. thanx for the help.

apt-get install digikam

was the line that did it.

now maybe i should try another program to make sure i got it.
 
  


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 you install file with TAR.BZ2 extension?.. thanks suse2166 Linux - Software 14 01-03-2005 05:55 PM
can not install the tar(gz,bz2) packages tuzhiyong Linux - General 2 11-23-2004 06:23 PM
how do you install tar.bz2 files? Pbguru Linux - Newbie 1 07-25-2004 05:45 PM
how to install tar.bz2? Fear58 Linux - Software 1 06-20-2004 08:20 PM
How to install .tar.bz2? daYz Slackware 10 11-14-2003 02:58 AM


All times are GMT -5. The time now is 10:30 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