Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 474038 - sys-libs/libcxx-0.0_p20130531-r1: build fails with using clang-3.3 on Gentoo/FreeBSD
Summary: sys-libs/libcxx-0.0_p20130531-r1: build fails with using clang-3.3 on Gentoo/...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: FreeBSD (show other bugs)
Hardware: All FreeBSD
: Normal normal
Assignee: Gentoo/BSD Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-21 12:13 UTC by Yuta SATOH
Modified: 2013-08-07 21:16 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
sample patch for libcxx-0.0_p20130531-r1.ebuild (474038.patch,630 bytes, patch)
2013-06-21 12:36 UTC, Yuta SATOH
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yuta SATOH 2013-06-21 12:13:36 UTC
When installing sys-libs/libcxx for the first time, it fails to build.


>>> Emerging (1 of 1) sys-libs/libcxx-0.0_p20130531-r1
 * libcxx-0.0_p20130531.tar.xz SHA256 SHA512 WHIRLPOOL size ;-) ...      [ ok ]
>>> Unpacking source...
>>> Unpacking libcxx-0.0_p20130531.tar.xz to /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work
>>> Source unpacked in /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work
>>> Preparing source in /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531 ...
 * Applying multilib.patch ...                                           [ ok ]
 * Applying cxxrt.patch ...                                              [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531 ...
>>> Working in BUILD_DIR: "/var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared"
cmake --no-warn-unused-cli -C /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/gentoo_common_config.cmake -G Unix Makefiles -DCMAKE_INSTALL_PREFIX=/usr -DLIBCXX_CXX_ABI=libcxxrt -DLIBCXX_LIBCXXRT_INCLUDE_PATHS=/usr/include/libcxxrt/ -DCMAKE_BUILD_TYPE=Gentoo -DCMAKE_INSTALL_DO_STRIP=OFF -DCMAKE_USER_MAKE_RULES_OVERRIDE=/var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/gentoo_rules.cmake  /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531
Not searching for unused variables given on the command line.
loading initial cache file /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/gentoo_common_config.cmake
-- The CXX compiler identification is Clang 3.3.0
-- The C compiler identification is Clang 3.3.0
-- Check for working CXX compiler: /usr/bin/clang++
-- Check for working CXX compiler: /usr/bin/clang++ -- broken
CMake Error at /usr/share/cmake/Modules/CMakeTestCXXCompiler.cmake:54 (message):
  The C++ compiler "/usr/bin/clang++" is not able to compile a simple test
  program.

  It fails with the following output:

   Change Dir: /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/CMakeFiles/CMakeTmp



  Run Build Command:/usr/bin/gmake "cmTryCompileExec3134877955/fast"

  gmake -f CMakeFiles/cmTryCompileExec3134877955.dir/build.make
  CMakeFiles/cmTryCompileExec3134877955.dir/build

  gmake[1]: Entering directory
  `/var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/CMakeFiles/CMakeTmp'


  /usr/bin/cmake -E cmake_progress_report
  /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/CMakeFiles/CMakeTmp/CMakeFiles
  1

  Building CXX object
  CMakeFiles/cmTryCompileExec3134877955.dir/testCXXCompiler.cxx.o

  /usr/bin/clang++ -DNDEBUG -O2 -pipe -o
  CMakeFiles/cmTryCompileExec3134877955.dir/testCXXCompiler.cxx.o -c
  /var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/CMakeFiles/CMakeTmp/testCXXCompiler.cxx


  Linking CXX executable cmTryCompileExec3134877955

  /usr/bin/cmake -E cmake_link_script
  CMakeFiles/cmTryCompileExec3134877955.dir/link.txt --verbose=1

  /usr/bin/clang++ -O2 -pipe
  CMakeFiles/cmTryCompileExec3134877955.dir/testCXXCompiler.cxx.o -o
  cmTryCompileExec3134877955

  /usr/bin/x86_64-gentoo-freebsd9.0-ld: cannot find -lstdc++

  clang: error: linker command failed with exit code 1 (use -v to see
  invocation)

  gmake[1]: *** [cmTryCompileExec3134877955] Error 1

  gmake[1]: Leaving directory
  `/var/tmp/portage/sys-libs/libcxx-0.0_p20130531-r1/work/libcxx-0.0_p20130531_shared/CMakeFiles/CMakeTmp'


  gmake: *** [cmTryCompileExec3134877955/fast] Error 2





  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:7 (project)


-- Configuring incomplete, errors occurred!
 * ERROR: sys-libs/libcxx-0.0_p20130531-r1 failed (configure phase):
 *   cmake failed


Reproducible: Always

Steps to Reproduce:
1. emerge -C libcxx (if it is installed already)
2. emerge libcxx
3.
Comment 1 Yuta SATOH 2013-06-21 12:36:21 UTC
Created attachment 351554 [details, diff]
sample patch for libcxx-0.0_p20130531-r1.ebuild
Comment 2 Yuta SATOH 2013-06-21 12:43:17 UTC
(In reply to Yuta SATOH from comment #1)
> Created attachment 351554 [details, diff] [details, diff]
> sample patch for libcxx-0.0_p20130531-r1.ebuild

Note)
This patch is not required if you've fixes Bug 474042.
Comment 3 Alexis Ballier gentoo-dev 2013-06-21 15:10:51 UTC
better fix clang since you provided the patches

note: _gcc-install-dir is supposed to be an internal function.
Comment 4 Alexis Ballier gentoo-dev 2013-08-07 21:16:05 UTC
should be fixed in recent libcxx versions