Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 03-02-2005, 12:49 PM   #1
LQ Newbie
Registered: Feb 2005
Distribution: SuSE 9.2 64bit
Posts: 8

Rep: Reputation: 0
Exclamation ./configure cant find libXext

whenever i go to compile some source i have to change the location of the Xincludes and Xlibraries. that overcame my problem of gcc not being able to find those. now it says that it can't find a working libXext file. i am running suse 9.2 pro 64 bit edition, and was able to locate the libXext file (don't remember exactly where right now, will be able to update once i get home tonight).

what command will allow me to change where ./configure looks for my libXext file?
this is keeping me from compiling pretty much everything from source.

Old 03-02-2005, 03:01 PM   #2
Registered: Feb 2005
Distribution: Gentoo
Posts: 57

Rep: Reputation: 15
./configure CPPFLAGS=-I/path/to/header/files
That is to set where it searches for header files

./configure LDFLAGS=-L/path/to/library/files
That tells it where to look for library files, which I think is what you need.
Old 03-02-2005, 03:16 PM   #3
Registered: Jan 2005
Distribution: Solaris, Linux Fedora Core 6
Posts: 170

Rep: Reputation: 30
First choice:

./configure --help | less
Look through the configure options. Many products provide a parameter to do exactly what you need.

Second choice:

If there is no special configure parameter, configure will try to find its needed include (and other) files. If you installed into a location configure does not expect, it will need a little help finding it. Most products create a file with a ".pc" extension and leave it in "<path>/lib/pkgconfig", where "<path>" is the --prefix= path you specified when you built libXext. Locate it. Then set up the environment variable $PKG_CONFIG_PATH with the path to that file. Example:
export PKG_CONFIG_PATH=some_path/lib/pkgconfig
If the product you are building needs several of these non-standard locations, the syntax of the environment variable is the same as your $PATH variable -- separate fields with a colon ":".

Hopefully, this gets you past the "configure" step ind into the "make" step. If you have a dumb ./configure script, it may be necessary to use additional compiler directives to instruct the compiler where to search. This is done through environment variables.

Use one or more of these environment variables:
 Some influential environment variables:
  CC          C compiler command
  CFLAGS      C compiler flags
  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
              nonstandard directory <lib dir>
  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
              headers in a nonstandard directory <include dir>
  CPP         C preprocessor
  CXX         C++ compiler command
  CXXFLAGS    C++ compiler flags
  CXXCPP      C++ preprocessor
  F77         Fortran 77 compiler command
  FFLAGS      Fortran 77 compiler flags
From your question, LDFLAGS and CPPFLAGS are applicable.

One final environment variable might be helpful:
export LD_LIBRARY_PATH=some_path/lib
Again syntax is the same as $PATH. This will probably only be needed if the make process runs a utility which needs the library.

Hope this helps...
Old 03-15-2005, 02:56 PM   #4
LQ Newbie
Registered: Feb 2005
Distribution: SuSE 9.2 64bit
Posts: 8

Original Poster
Rep: Reputation: 0
I guess I don't understand what you said here. I made libXext? I thought it was just a library file that was already there.

You said:
"Most products create a file with a ".pc" extension and leave it in "<path>/lib/pkgconfig", where "<path>" is the --prefix= path you specified when you built libXext."

Also, I was not able to find the pkgconfig.pc file that you said would probably be generated by whatever package I'm trying to install. I set the install directory (prefix right?) to /opt/kde3 Its not in /opt/kde3/bin
Old 03-15-2005, 03:10 PM   #5
Senior Member
Registered: Dec 2004
Distribution: Slackware, ROCK
Posts: 1,973

Rep: Reputation: 46
kde does not use pkg-config. mostly pkg-config is used by gnome ( but some other libs and programs use it too).

look in /usr/X11R6/lib for*, make sure you have /usr/X11R6/lib in /etc/ and have run ldconfig to update the cache.

if you still have problems, either use the LDFLAGS or LD_LIBRARY_PATH variables above. ( though you shouldn't need to do these if you have the path in /etc/ and have run ldconfig).


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
libXext error when running ./configure gepesz Linux - Software 2 05-26-2011 07:08 AM
Problems with arts-1.4.2 and libXext-6.4.3 configure Fluxxdog Linux - Software 3 09-02-2005 05:04 PM
configure cannot find libXext vivian Linux - Software 2 05-17-2005 05:57 AM
configure can't find libXext in rh9.0 locodog Linux - Software 0 10-24-2003 10:30 AM
configure can't find libXext in rh9.0 locodog Linux - Software 0 10-10-2003 02:42 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:24 AM.

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