Can't compile anything

Discussions Regarding Software

Moderator: Moderators

micia
Sagely Hen
Posts: 2718
Joined: Wed Nov 26, 2008 16:41
Contact:

Re: Can't compile anything

Post by micia » Sat Mar 05, 2011 1:44

I really can't see why it is not seeing those headers, just in case, you did run:

Code: Select all

emerge --sync && layman -S
recently, do you?

knightlain
Baby Hen
Posts: 18
Joined: Mon Feb 07, 2011 16:43

Re: Can't compile anything

Post by knightlain » Sat Mar 05, 2011 16:35

Yes I did, is that the reason of my error? If yes, what should I do then?

micia
Sagely Hen
Posts: 2718
Joined: Wed Nov 26, 2008 16:41
Contact:

Re: Can't compile anything

Post by micia » Sat Mar 05, 2011 22:39

No, it was just in case the reason was obsolete ebuilds or something like that, but it seems that it is not.
Try to check the includes path of your GCC compiler with:

Code: Select all

cpp -v
to see if /usr/include is listed.

Then check which is the output of:

Code: Select all

pkg-config --cflags gtk+-2.0
to see if it produces the correct results.

knightlain
Baby Hen
Posts: 18
Joined: Mon Feb 07, 2011 16:43

Re: Can't compile anything

Post by knightlain » Sun Mar 06, 2011 4:26

cpp output.

Code: Select all

Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.4.4-r2/work/gcc-4.4.4/configure --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.4.4 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.4/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.4 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.4/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.4/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.4/include/g++-v4 --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec --disable-fixed-point --without-ppl --without-cloog --disable-ppl-version-check --enable-nls --without-included-gettext --with-system-zlib --disable-werror --enable-secureplt --enable-multilib --enable-libmudflap --disable-libssp --enable-libgomp --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.4.4/python --enable-checking=release --enable-objc-gc --enable-languages=c,c++,java,objc,obj-c++,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.4.4-r2 p1.3, pie-0.4.5'
Thread model: posix
gcc version 4.4.4 (Gentoo 4.4.4-r2 p1.3, pie-0.4.5) 
COLLECT_GCC_OPTIONS='-E' '-v' '-mtune=generic'
 /usr/libexec/gcc/x86_64-pc-linux-gnu/4.4.4/cc1 -E -quiet -v - -D_FORTIFY_SOURCE=2 -mtune=generic
ignoring nonexistent directory "/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.4/../../../../x86_64-pc-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /usr/lib/gcc/x86_64-pc-linux-gnu/4.4.4/include
 /usr/lib/gcc/x86_64-pc-linux-gnu/4.4.4/include-fixed
 /usr/include
End of search list.
This is what gtk+-2.0 does

Code: Select all

pkg-config --cflags gtk+-2.0
Package dri2proto was not found in the pkg-config search path.
Perhaps you should add the directory containing `dri2proto.pc'
to the PKG_CONFIG_PATH environment variable
Package 'dri2proto', required by 'gl', not found

micia
Sagely Hen
Posts: 2718
Joined: Wed Nov 26, 2008 16:41
Contact:

Re: Can't compile anything

Post by micia » Sun Mar 06, 2011 14:44

knightlain wrote: This is what gtk+-2.0 does

Code: Select all

pkg-config --cflags gtk+-2.0
Package dri2proto was not found in the pkg-config search path.
Perhaps you should add the directory containing `dri2proto.pc'
to the PKG_CONFIG_PATH environment variable
Package 'dri2proto', required by 'gl', not found
That's it!

Code: Select all

emerge -av dri2proto
after that it should be fine,

knightlain
Baby Hen
Posts: 18
Joined: Mon Feb 07, 2011 16:43

Re: Can't compile anything

Post by knightlain » Sun Mar 06, 2011 15:46

Thanks micia, you did my day, in base of that, I found my solution :D

micia
Sagely Hen
Posts: 2718
Joined: Wed Nov 26, 2008 16:41
Contact:

Re: Can't compile anything

Post by micia » Thu Mar 10, 2011 13:03

That's great :mrgreen:

if you solved your problems, it would be nice to add a description of how you solved it, if it is not the exact way I suggested you, so that it can be useful to other users too :wink:

Also, remember to mark this topic as solved, following these instructions:
http://forum.sabayon.org/viewtopic.php?f=59&t=17059

Post Reply