Installing Oprofile

Submitted by RamCharanTej
on February 12, 2008 - 3:21am

While installing Oprofile-0.9.3 through ./configure --with-kernel-support, the following error is shown.
From the error its apparent that it is liberty package which needs to be installed but I am not able to resolve this as I found it difficult to get this package which includes liberty.

Or else can we play around with Yum to install all the dependency packages required to install Oprofile?

Following is the error.

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for ranlib... ranlib
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ld... ld
checking for kernel OProfile support... yes
checking whether malloc attribute is understood... no
checking whether __builtin_expect is understood... yes
checking for sched_setaffinity... yes
checking for perfmonctl... no
checking for poptGetContext in -lpopt... yes
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking libiberty.h usability... no
checking libiberty.h presence... no
checking for libiberty.h... no
checking for cplus_demangle in -liberty... no
configure: error: liberty library not found

Any help will be appreciated.

Thanks,
Ram

It's actually not looking

on
February 12, 2008 - 12:32pm

It's actually not looking for a liberty package... it is looking for the header file 'libiberty.h' or the library 'iberty'. These are generally part of binutil-dev, or libbinutil-dev packages. These are fairly common packages which you shouldn't have much trouble finding.

Search your distor for a package containing the 'libiberty.h' file and install that package. That will likely resolve your problem.

Memphis, Thanks for your

on
February 13, 2008 - 12:22am

Memphis,

Thanks for your reply.
Are binutil-dev and libbinutil-dev part of binutils and libbinutils packages respectively?
I couldn't find binutil-dev or the latter one.
Its a fedora core 6 workstation.
Any pointer to these packages would be a great help.

Ram

Usually these are split into

on
February 13, 2008 - 2:12pm

Usually these are split into separate packages. Binutils typically has executables useful for development, whereas binutils-dev has headers and libraries. It looks like for fedora, you'll want to install the 'binutils-devel' package.

If that fails, you might try searching with yum. Something like:
yum provides libiberty.h

That command should search for packages containing the libiberty.h file.

I found that gcc will have

on
February 15, 2008 - 12:23am

I found that gcc will have libiberty.h file but there was already a gcc installed but through RPM. I downloaded gcc source code and built it from source and that successfully eliminated the error.

Thanks,
Ram

how to solve the problem "liberty.h laibrary not found"

Anonymous (not verified)
on
March 18, 2008 - 2:39am

[root@server1 oprofile-0.9.3]# ./configure --with-kernel-support
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for ranlib... ranlib
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ld... ld
checking for kernel OProfile support... yes
checking whether malloc attribute is understood... no
checking whether __builtin_expect is understood... yes
checking for sched_setaffinity... yes
checking for perfmonctl... no
checking for poptGetContext in -lpopt... yes
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking libiberty.h usability... no
checking libiberty.h presence... no
checking for libiberty.h... no
checking for cplus_demangle in -liberty... no
configure: error: liberty library not found

I am having this problem when i tried to install oprofile. I told in this form u solved the problem. I updated my gcc. Still i have this problem. Any RPM is needed to solve this problem..
Please give me the steps to slove this issue

Error while configure oprofile

Surya (not verified)
on
December 30, 2008 - 1:43am

Hi I am also getting similar error as what u posted here. But in my case I have the libiberty.a, please find the dump below.
Any body can help me out......

If a cross compiler is detected then cross compile mode will be used.
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for mips-linux-strip... mips-linux-strip
checking for mips-linux-ranlib... mips-linux-ranlib
checking for mips-linux-gcc... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for mips-linux-g++... no
checking for mips-linux-c++... no
checking for mips-linux-gpp... no
checking for mips-linux-aCC... no
checking for mips-linux-CC... no
checking for mips-linux-cxx... no
checking for mips-linux-cc++... no
checking for mips-linux-cl... no
checking for mips-linux-FCC... no
checking for mips-linux-KCC... no
checking for mips-linux-RCC... no
checking for mips-linux-xlC_r... no
checking for mips-linux-xlC... no
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ld... /data/PROFILING_TAR/oprofile/utils/packages/binutils-2.17/ld
checking for kernel OProfile support... yes
checking whether malloc attribute is understood... yes
checking whether __builtin_expect is understood... yes
checking for sched_setaffinity... yes
checking for perfmonctl... no
checking for poptGetContext in -lpopt... yes
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking libiberty.h usability... yes
checking libiberty.h presence... no
configure: WARNING: libiberty.h: accepted by the compiler, rejected by the preprocessor!
configure: WARNING: libiberty.h: proceeding with the compiler's result
checking for libiberty.h... yes
checking for cplus_demangle in -liberty... no
configure: error: liberty library not found

I am trying to compile it for mips.

--Surya

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.