LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-21-2004, 06:37 AM   #1
domo2505
LQ Newbie
 
Registered: Apr 2004
Posts: 5

Rep: Reputation: 0
Having problems with compiling gtk, nicotine? try this


Ok. Here goes. I am a returning linux user, and although I am still quite newbie at this, I've managed to bypass the problems people here are mentioning when they are trying to compile gtk, nicotine, or other related software on their linux box(es). After an hour of trying various stuff, I managed to get the app to work, so here are some tips that could help you if you have experienced similar problems.

download the following stuff:
atk-1.6.0
glib-2.4.0
gtk+-2.4.0.
pango-1.4.0
psyco-1.2
pygtk-2.0.0
and of course, latest nicotine source file

I did the following under 'root', so if it doesnt work for you under a normal account, try doing this with your su acc.

Steps:
compile glib-2.4.0
% gzip -cd glib-2.4.0.tar.gz | tar xvf - # unpack the sources
% cd glib-2.4.0 # change to the toplevel directory
% ./configure # run the `configure' script
% make # build GLIB
[ Become root if necessary ]
% rm -rf /install-prefix/include/glib.h /install-prefix/include/gmodule.h
% make install
compile atk-1.6.0

compile pango1.4.0
you might start experiencing problems here, like the following:

checking for GLIB - version >= 2.4.0... no
*** Could not run GLIB test program, checking why...
*** The test program failed to compile or link. See the file config.log for the
*** exact error that occured. This usually means GLIB is incorrectly installed.
configure: error:
*** Glib 2.4.0 or better is required. The latest version of


this is due to the fact that the pkgconfig looks for the file glib-2.0.pc in either /usr/lib/pkgconfig dir *OR* /usr/lib/pkgconfig dir. So check where you have that file and check what is in it. You should see headers in there, that tell you what version it is, and just simply select the one with the newer version in it(if both are same, thats ok). Now, most likely, you will only have one .pc file in /usr/lib/pkgconfig (after compiling glib succesfully without --prefix=<dir>). Make sure that the following lines are in the file ~/.profile

export LDFLAGS="-L/usr/local/lib"
export LD_LIBRARY_PATH=/usr/local/lib
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH

logout,login

Ok. Now make sure you got a copy of that above-mentioned .pc file in /usr/local/lib/pkgconfig *AND* in /usr/lib/pkgconfig

Now you should be able to compile gtk+-2.4.0. If the compiling still misbehaves, make a copy of atk.pc (found in /usr/lib/pkgconfig) and put it into /usr/local/lib/pkgconfig (cp /usr/lib/pkgconfig/atk.pc /usr/local/pkgconfig)

---Nicotine users read on---
OK. Now you should have gtk, glib and atk compiled on your box. Nicotine also requires pango-1.4.0 to be installed. Same procedure as above. You also need psyco-1.2 and pygtk-2.0.0

I had no problems compiling psyco, but i did encounter a problem when trying to compile pygtk. To bypass it, use ./configure --prefix=/usr
That should compile it succesfully. Now you can compile Nicotine using python and it works! Well, it did for me. If you encounter any problems regarding this, please email me and I will try to help you or advise you what to do.


p.s.: i did all this on Slackware 9.1 dist.

Last edited by domo2505; 04-21-2004 at 06:41 AM.
 
Old 04-28-2004, 05:53 PM   #2
hobarry
LQ Newbie
 
Registered: Apr 2004
Posts: 6

Rep: Reputation: 0
Can you tell me where is this ~/.profile file is located at. I can't find it on my system. I am also running Slackware 9.1 (downloaded version).
 
Old 04-28-2004, 05:59 PM   #3
Matt Collier
Member
 
Registered: Apr 2004
Distribution: Debian
Posts: 80

Rep: Reputation: 15
~/ is your home directory
and .profile is a hidden file within it

if it's not present, then just create it with any editor
 
Old 04-28-2004, 06:09 PM   #4
hobarry
LQ Newbie
 
Registered: Apr 2004
Posts: 6

Rep: Reputation: 0
How do you change the setting to see the hidden file? I am new to Linux. Thanks!
 
Old 04-29-2004, 08:50 AM   #5
Borje
Member
 
Registered: Apr 2004
Location: Helsingborg, Sweden
Distribution: Debian/Xandros 3.0
Posts: 41

Rep: Reputation: 15
To see all files in your home dir open a console and type ls -a
(check the manual for ls "man ls")
 
Old 04-29-2004, 12:32 PM   #6
hobarry
LQ Newbie
 
Registered: Apr 2004
Posts: 6

Rep: Reputation: 0
Hello,

Thanks for the help! I can see the file now, but how to I open the file in console mode? Is there anyway to the file to show up in the windows mode?
 
Old 04-29-2004, 03:50 PM   #7
Borje
Member
 
Registered: Apr 2004
Location: Helsingborg, Sweden
Distribution: Debian/Xandros 3.0
Posts: 41

Rep: Reputation: 15
To open the file use a text-editor like vi or pico. Type "vi .profile" in your console. I recommend you to google for a howto for using vi, doesn't work quite like notepad or any other windows text-editor.
If your file does not exist vi will create a new one for you.

I'll explain another way too.
To see what's in a textfile (every file that's not a binary file) type "cat filename" ("more filename" if the file is large and you want to be able to see the top of the file)
To write over an existing file with a sting of text type: echo "here is some text" (was supposed to write a single rightarrow here but that button doesn't work for me in X (kde) have to figure out why) filename
To append some text last in a file type: echo "some text" (two rightarrows) filename

Last edited by Borje; 04-29-2004 at 03:52 PM.
 
Old 04-30-2004, 05:12 PM   #8
domo2505
LQ Newbie
 
Registered: Apr 2004
Posts: 5

Original Poster
Rep: Reputation: 0
editing/viewing files

hey man... yeah, where the .profile is was already explained, but I am wondering, why you recommend to him to use vi... I mean cmon man, vi is not for newbie users, it's so weird I never learned it. So hobarry, try doing the following:

type: joe .profile

then you just type in what you want to be in the file, and to save u press ctrl-k-x

joe is a very simple and useful file editing program, and Im surprised people dont use/mention it more often. To get help when in joe, press ctrl-k-h
feel free to contact me if you want any more info.

p.s. Sorry for the late reply, was offline some days.
 
Old 04-30-2004, 05:31 PM   #9
hobarry
LQ Newbie
 
Registered: Apr 2004
Posts: 6

Rep: Reputation: 0
My system crashed yesterday. So, I reloaded Slackware 9.1 and follow the instruction to load gtk+-2.4.0. Everything went OK, even the compilation of gtk. But, when I ran the make file, the program ended up with some sort or recursion errors. So, I loaded the pkgconfig-0.15.0 (because gtk site mention that is one of the dependencies). When I tried to compile gtk again, I encounter the following error:

...
checking for freetype-config... /usr/bin/freetype-config
checking For sufficiently new FreeType (at leasst 2.0.1)...yes
configuration: error: Xft version 2 is required for x11 target


Can anyone tell me what's going on? Help!!
 
Old 04-30-2004, 06:28 PM   #10
Matt Collier
Member
 
Registered: Apr 2004
Distribution: Debian
Posts: 80

Rep: Reputation: 15
Xft2 is a FreeType-based font drawing library for X, it appears that you need the development files to compile your package. No idea what it's called for slack, but the Debian pkg is libxft2-dev
 
Old 05-01-2004, 07:14 PM   #11
Borje
Member
 
Registered: Apr 2004
Location: Helsingborg, Sweden
Distribution: Debian/Xandros 3.0
Posts: 41

Rep: Reputation: 15
Re: editing/viewing files

Quote:
Originally posted by domo2505
hey man... yeah, where the .profile is was already explained, but I am wondering, why you recommend to him to use vi... I mean cmon man, vi is not for newbie users, it's so weird I never learned it. So hobarry, try doing the following:
I recommended him to use vi since that's the editor I know comes with all distros, don't know what other editors that comes with slackware.
I thought typing: echo "text to be inserted" >> filename
was a pretty easy way to do it though, without learning vi.

Last edited by Borje; 05-01-2004 at 07:16 PM.
 
Old 05-16-2004, 12:56 AM   #12
phiz
LQ Newbie
 
Registered: May 2004
Distribution: Fedora C3
Posts: 11

Rep: Reputation: 0
Hi all, another newbie joins the fray. I'm having troubles that I think are kinda the same as other peoples in this thread. I'm trying to install a file manager (more as an exercise to learn linux than anything) and when I run ./configure it prints an error:

*** The gtk-config script installed by GTK could not be found
*** If GTK was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the GTK_CONFIG environment variable to the
*** full path to gtk-config.
configure: error: Bad GTK+ version

So, I figure I'll install the newest version of GTK, and I run off to do that but see that I need glib which I go and install, and also atk and pango. Whew.. so I installed the newest version of glib just fine so i think, then i run the ./configure in atk and low and behold:

*** 'pkg-config --modversion glib-2.0' returned 2.2.3, but GLIB (2.4.1)
*** was found! If pkg-config was correct, then it is best
*** to remove the old version of GLib. You may also be able to fix the error
*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing
*** /etc/ld.so.conf. Make sure you have run ldconfig if that is
*** required on your system.
*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH
*** to point to the correct configuration files
no
configure: error:
*** GLIB 2.0.0 or better is required. The latest version of
*** GLIB is always available from ftp://ftp.gtk.org/. If GLIB is installed
*** but not in the same location as pkg-config add the location of the file
*** glib-2.0.pc to the environment variable PKG_CONFIG_PATH.

Well I didn't understand any of that so I came here to look for help and tried creating a ~/.profile text file with the 3 lines suggested at the top of this thread, but I get the same errors. I think I'm not understanding something fundamental about libraries and dependencies and programs... Anyone care to enlighten me?
 
Old 05-16-2004, 02:17 PM   #13
hobarry
LQ Newbie
 
Registered: Apr 2004
Posts: 6

Rep: Reputation: 0
Are you also running Slackware 9.1?
 
Old 05-16-2004, 02:24 PM   #14
phiz
LQ Newbie
 
Registered: May 2004
Distribution: Fedora C3
Posts: 11

Rep: Reputation: 0


<----------Mandrake10CE
 
  


Reply



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
Adding Gtk-2 themes (for Nicotine --soulseek client) flamesrock Linux - Software 3 10-07-2006 01:27 PM
Problems with GTK and libXML when compiling HELP! britishnemesis Linux - Software 2 02-18-2005 01:27 PM
compiling gaim/ gtk error (two versions of gtk) webazoid Linux - Software 0 07-06-2004 06:05 PM
Problems Compiling GTK C++ Source Code drdroid Programming 17 04-10-2004 07:08 PM
Problems installing Nicotine drxsmurf Linux - Software 3 10-20-2003 04:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 01:39 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
Open Source Consulting | Domain Registration