LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 03-13-2004, 01:57 AM   #1
tusher
Member
 
Registered: Aug 2003
Distribution: RedHat
Posts: 36

Rep: Reputation: 15
Wink Newbies really need to know following answers to have a good base on linux.


Yes, i think configuration is something like..change some parameters and some good knowledge on networking...but to have a good base on linux OS..newbies need to know how the compiling works..then..where the files reside with OS. bla..bla..bla....

here goes my problem.............

I need to know some basic information on linux OS .. cuz i am having problem installing and uninstalling software. for example, when i install some tools/software on windows box..i usually get a user interface with wizard. but one guru said me.. "to learn linux u should use command prompt and consol" --- i believe it, and want to operate linux on consol mode.

but i m passing horrible time (cuz i m still newbie) with linux .. i tried to install gaim on Redhat 9 then i come to know .. it need gtk ... when i was compiling gtk.. an error message appears stating that:

Library required (glib , atk and pango) ...

I checked the install log file and got i have already atk installed on the system.. on the other hand i got from gtk documentation that...i need GLib, atk and Pango libraries available at the same location as GTK+

now...plz tell me ,

1. what is the difference between libraries, package, modules etc.

2. atk already installed on my linux box..so how can i point the required library to the configuration path.

3. and most important thing to konw: when i install any program where the system files goes ?? ( as on windows, i can view them from programs files...what about linux??)

4. what resides on /usr/lib/pkgconfig directory? i got some .pc files over that location...what does they do?

5. How really i can understand .. whether any (what should i say..package/library ??? ) already installed on my system or i have to install it to solve dependency problem ? I mean to say...how can i check .. which module/library/package are installed ?

I think all of above question's answer will help all other newbies also...like me. so reply with good explanation will be highly appreciated.

Thanks,
 
Old 03-13-2004, 03:03 AM   #2
zajelo3
Member
 
Registered: Mar 2004
Location: Central Florida
Distribution: Gentoo & Fedora
Posts: 153

Rep: Reputation: 30
Wow, that's alot of questions! But I think the main problem you are having is with "package managment". My personal preference is to use a package manager like RPM or APT-GET. There are others also depending on your distro. On Redhat RPM and apt-get are the main ones. I personally prefer apt-get because it solves dependency issues. That is, if you install a package that needs other packages to work correctly, it will install those also. Another problem that I see you are having is one that I had when I started using Linux, and that is the steep learning curve that most everybody faces when they start using Linux (I can tell by all the questions). All I can say is that Google and mailing lists can be very helpful as can the "man" pages on your system ( type "man apt-get" at the command line).
Also, if you want to find a package on your system try the "locate packagename" command, although you might need to "updatedb" first.
 
Old 03-13-2004, 03:07 AM   #3
zajelo3
Member
 
Registered: Mar 2004
Location: Central Florida
Distribution: Gentoo & Fedora
Posts: 153

Rep: Reputation: 30
Oh, I forgot to mention that if you like GUI's apt-get has a front end called "synaptic", once you install apt-get simply type " apt-get install synaptic" then you can use the GUI.
 
Old 03-13-2004, 03:58 AM   #4
tusher
Member
 
Registered: Aug 2003
Distribution: RedHat
Posts: 36

Original Poster
Rep: Reputation: 15
it would helpful..if i got some to-the-point answers...
 
Old 03-13-2004, 06:24 AM   #5
vasudevadas
Member
 
Registered: Jul 2003
Location: Bedford, UK
Distribution: Slackware 11.0, LFS 6.1
Posts: 519

Rep: Reputation: 30
1. What is a library? It's a piece or pieces of code, that doesn't do anything in its own right - by that I mean it's not an application you can run. The purpose of a library is to provide useful functions that other programmers can use without having to write the code themselves.

A good example is the one you're having trouble with, GTK. GTK is a GUI toolkit library. It contains routines to draw and manage "widgets" for you. A widget is something you see in a GUI - a window, a button, a poplist, a check box. All these things are widgets. If you're writing a GUI application to run on Linux, instead of figuring out how to implement all of these things yourself - lot of hassle - you can simply use this GTK library to do that for you. In the meantime you can concentrate on the important parts of your application: the specific things it must do that people probably won't have written libraries for.

A package is when an application has been wrapped up for easy delivery and installation. The application may consist of many files, which must be installed in specific locations, but the package comprises all of these files wrapped up into one single file plus the information the package manager needs to be able to install them all in the correct places. Example package managers are the Red Hat rpm system and the Debian apt-get system. Since you use Red Hat, you will be concerned with RPMs (Red hat Package Manager). It's dead easy: if you have a package (a .rpm file) you install it like this:

(as root)
rpm -iv whatever_the_rpm_file_is_called.rpm

What is a module? The word "module" is a bit general, referring to a part of any system that is modular as opposed to a system that is centralised, but I expect you've probably seen it in relation to kernel modules. The kernel is the core of the operating system. Early in the development of Linux, Linus was criticised for having built a "monolithic" kernel; that is, it performed all of its functions in one big piece of code. Since then, it has been made possible to separate out functions of the kernel into "modules". These modules can be inserted into and out of the kernel at will. At your stage you probably don't need to worry about this yet.

2. If I were you, I'd go to www.gtk.org, and download and install from scratch Glib, Pango, ATK and GTK, following the instructions given. I had trouble with GTK too; it was supposed to be installed from my Mandrake install discs, but I could not compile anything that used it. In the end I got the sources from gtk.org and installed them by hand and now everything is cool. Just ignore whatever Red Hat have installed on to your system.

3. When you install a program yourself, it probably goes either in /usr/bin or /usr/local/bin. If you installed it from a Red Hat rpm it probably went in /usr/bin, if you install something from source it will most likely go in /usr/local/bin.

But you don't really need to worry about this. You see, your system has an environment variable called the path. You can see what it is set to by typing

echo $PATH

at your console prompt. Whenever you enter a command at the prompt, your shell looks in every directory specified in your path for a file matching the command you entered. When it finds a match, it runs the file. If it finds no match, it says so.

So, if you installed Mozilla from an rpm, say, all you have to do is type mozilla at the console prompt, and it will start up for you. You can set up a desktop icon for it if you like, and how to do that depends on the desktop manager you're using but in most cases it's pretty straightforward.

4. No idea.

5. You don't have to understand. If you're installing an rpm, the rpm manager will complain to you if you are missing some dependency you need. If you're installing from source then you will probably have to run a configure script first; this script will inform you if you are missing a required dependency.
 
Old 03-13-2004, 07:07 AM   #6
estod
LQ Newbie
 
Registered: Mar 2004
Distribution: Slackware9, 10.1
Posts: 9

Rep: Reputation: 0
Quote:
Originally posted by vasudevadas
2. If I were you, I'd go to www.gtk.org, and download and install from scratch Glib, Pango, ATK and GTK, following the instructions given. I had trouble with GTK too; it was supposed to be installed from my Mandrake install discs, but I could not compile anything that used it. In the end I got the sources from gtk.org and installed them by hand and now everything is cool. Just ignore whatever Red Hat have installed on to your system.

I have problems running the Gnome: I installed Gnome from Mandrake disk
but there is nothing of it. May it be a trouble like you had? -- it's supposed
to be installed but nothing is there???

I changed values in /etc/sysconfig/desktop file to GDM, tried to start X by
"startx gmd" but Gnome didn't appered.
 
Old 03-13-2004, 08:05 AM   #7
vasudevadas
Member
 
Registered: Jul 2003
Location: Bedford, UK
Distribution: Slackware 11.0, LFS 6.1
Posts: 519

Rep: Reputation: 30
Quote:
Originally posted by estod
I have problems running the Gnome: I installed Gnome from Mandrake disk
but there is nothing of it. May it be a trouble like you had? -- it's supposed
to be installed but nothing is there???

I changed values in /etc/sysconfig/desktop file to GDM, tried to start X by
"startx gmd" but Gnome didn't appered.
The problem I had was with compiling programs that use the GTK library. I have never had any trouble using the Gnome desktop. I don't know what your problem is, sorry, but it is probably not related the original poster's question; best not to hijack the thread. You should go and start a new thread, maybe in Linux-Software, maybe in the Mandrake forum, and ask your question there.
 
Old 03-13-2004, 10:09 AM   #8
tusher
Member
 
Registered: Aug 2003
Distribution: RedHat
Posts: 36

Original Poster
Rep: Reputation: 15
Question

Hi vasudevadas,

It was very helpful reply to me..but i really like to ask u again that; i installed the glib-2.0 from
source file and compiled it. As your reply .. i even got the (library files ??) glib-2.0.pc , gmodule-2.0.pc from /usr/local/lib/pkgconfig.
but whenever i m trying to compile gtk+-2.0.0 i am keep getting an error message .. and seems like the pkg-config file looking for the library file "glib-2.0.pc" and not getting from its desired location. so..it asking for edit the PKG_CONFIG_PATH environment variable.

the actual message is here:
----------------------
checking for pkg-config... /usr/bin/pkg-config
checking for glib-2.0 >= 2.0.0 atk >= 1.0.0 pango >= 1.0.0... Package glib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found

configure: error: Library requirements (glib-2.0 >= 2.0.0 atk >= 1.0.0 pango >=
1.0.0) 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 used following command to fix the problem :

>"export PKG_CONFIG_PATH=/usr/lib/pkgconfig:/usr/local/lib/pkgconfig/glib-2.0.pc"
>"ldconfig"

But it didn't workd. Although i don't have clear idea..what the above commands do? still i used them for experiment as i got them from same linux forum by searching...


Any Idea ? Please help.

Thnx...
 
Old 03-13-2004, 10:18 AM   #9
vasudevadas
Member
 
Registered: Jul 2003
Location: Bedford, UK
Distribution: Slackware 11.0, LFS 6.1
Posts: 519

Rep: Reputation: 30
When you compiled glibc, you did "make" to do that, yes? Did you do "make install" after that?

When I was having trouble with these things, I followed the advice given to me by fr0zen in this thread:

http://www.linuxquestions.org/questi...&highlight=gtk

I can't really advise better than that, although I can perhaps give a little more detail on fr0zen's instructions, if necessary.

By the way, you were right about the export command, it sets a variable and "exports" it so the whole session can see it. If you want to add a directory to a path, a better way to do it is:

Code:
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:whatever/directory/i/want/to/add
This saves you retyping the current contents of the variable to add what you want to 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
A practical knowledge base - queries / answers on linux knindumathy Linux - Newbie 6 09-01-2005 11:48 AM
More newbies is a good thing, right? Radiolarian LinuxQuestions.org Member Intro 1 01-23-2005 10:34 AM
distro maybe good for newbies fisheromen1031 Linux - Newbie 5 07-26-2004 07:34 PM
My Linux Story: (Good for newbies) hexadevil LinuxQuestions.org Member Success Stories 2 06-05-2004 06:37 PM
Good books for newbies??? DaDdY SnEb Linux - Newbie 14 10-30-2002 07:27 PM


All times are GMT -5. The time now is 04:20 AM.

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