LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 869|回复: 4

[求助]emerge python 总是报错[已解决]

[复制链接]
发表于 2005-7-25 22:05:00 | 显示全部楼层 |阅读模式
  1. localhost ~ # emerge dev-lang/python
  2. ...
  3. ./configure --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --build=i686-pc-linux-gnu --with-fpectl --enable-shared --disable-ipv6 --infodir=${prefix}/share/info --mandir=${prefix}/share/man --with-threads --with-libc= --enable-unicode=ucs4
  4. checking MACHDEP... linux2
  5. checking EXTRAPLATDIR...
  6. checking for --without-gcc... no
  7. checking for --with-cxx=<compiler>... no
  8. checking for c++... c++
  9. checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables
  10. See `config.log' for more details.
复制代码

emerge其他软件都没问题,只有python始终出错,怎么办?谢谢!
  1. localhost ~ #  emerge info
  2. Portage 2.0.51.22-r2 (default-linux/x86/2005.0, gcc-3.3.5-20050130, glibc-2.3.5-r0, 2.6.12-gentoo-r6 i686)
  3. =================================================================
  4. System uname: 2.6.12-gentoo-r6 i686 Celeron (Coppermine)
  5. Gentoo Base System version 1.6.13
  6. ccache version 2.3 [enabled]
  7. dev-lang/python:     2.3.5
  8. sys-apps/sandbox:    1.2.11
  9. sys-devel/autoconf:  2.13, 2.59-r6
  10. sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5
  11. sys-devel/binutils:  2.15.92.0.2-r10
  12. sys-devel/libtool:   1.5.18-r1
  13. virtual/os-headers:  2.6.11-r2
  14. ACCEPT_KEYWORDS="x86"
  15. CBUILD="i686-pc-linux-gnu"
  16. CFLAGS="-O2 -march=pentium3 -pipe -mmmx -msse -fomit-frame-pointer -mfpmath=sse"CHOST="i686-pc-linux-gnu"
  17. CXXFLAGS="-O2 -march=pentium3 -pipe -mmmx -msse -fomit-frame-pointer -mfpmath=sse -fvisibility-inlines-hidden"
  18. FEATURES="autoconfig ccache distlocks sandbox sfperms strict"
  19. LANG="zh_CN.UTF-8"
  20. LDFLAGS="-Wl,-O1"
  21. LINGUAS="zh_CN"
  22. USE="X aac acpi alsa apache2 avi bash-completion berkdb bitmap-fonts cjk crypt curl divx4linux emboss encode fam foomaticdb fortran gd gd-external gdbm gif gnome gstreamer gtk gtk2 imagemagick imlib jpeg libg++ libwww live mad mikmod mmx motif mp3 mpeg msn mysql ncurses nls nocardbus nptl nptlonly nvidia ogg oggvorbis opengl pam perl php png python quicktime readline real sdl slang spell sse ssl tcpd tiff truetype truetype-fonts type1-fonts unicode usb vcd vim-with-x vorbis win32codecs x86 xine xml xml2 xv xvid zlib linguas_zh_CN userland_GNU kernel_linux elibc_glibc"
复制代码
发表于 2005-7-25 23:44:16 | 显示全部楼层
"C++ compiler cannot create executables"

常见错误,gentoo的官方论坛上有置顶
回复 支持 反对

使用道具 举报

发表于 2005-7-26 00:53:35 | 显示全部楼层
忘了怎么解决的了我……反正看见这个错误,条件反射的调整一下,就好了……
回复 支持 反对

使用道具 举报

发表于 2005-7-26 00:59:07 | 显示全部楼层
A: The first thing to check when you get this error is the spelling of your CFLAGS. You should also check whether they're supported by your version of gcc (man gcc will help you here). If you still can't see anything wrong, remove them all and add them back one-by-one until you find the problematic flag.

You may also be experiencing toolchain problems. Make sure that when you run gcc-config -l or binutils-config -l they point to valid profiles, and set them appropriately if necessary (for instance, type gcc-config 1 to select the first gcc version in the list).


You may also find some more solutions in this topic: "C compiler cannot create executables" !??!http://forums.gentoo.org/viewtopic.php?t=27486
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-7-26 09:33:37 | 显示全部楼层
谢谢提醒,我把CXXFLAGS中的-fvisibility-inlines-hidden去掉后编译就可以进行下去了。
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表