From owner-freebsd-toolchain@FreeBSD.ORG Tue May 14 00:35:56 2013 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id AF426190 for ; Tue, 14 May 2013 00:35:56 +0000 (UTC) (envelope-from alex@154cm.com) Received: from nm7-vm0.access.bullet.mail.sp2.yahoo.com (nm7-vm0.access.bullet.mail.sp2.yahoo.com [98.139.44.116]) by mx1.freebsd.org (Postfix) with ESMTP id 7E79D2FF for ; Tue, 14 May 2013 00:35:56 +0000 (UTC) Received: from [98.139.44.100] by nm7.access.bullet.mail.sp2.yahoo.com with NNFMP; 14 May 2013 00:35:50 -0000 Received: from [67.195.14.111] by tm5.access.bullet.mail.sp2.yahoo.com with NNFMP; 14 May 2013 00:35:50 -0000 Received: from [127.0.0.1] by smtp108.sbc.mail.gq1.yahoo.com with NNFMP; 14 May 2013 00:35:50 -0000 X-Yahoo-Newman-Id: 37795.26276.bm@smtp108.sbc.mail.gq1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: PcfK.0IVM1l61EbqoZxgPVkUm47SL8VhcfD2661sF3xqwJn RHBD6W_X40zESidLNcyfsUT.qieh.fT8q0xwspsAjYStW8uCD.e1zuDJrxEP B.oQLuVR3FngK3O2p_Y64dRpuwjH8kaSwd8iw3PI10NYpDphmRvD0I0b6a_. HaCHR7GrZBs6WG6xQiOLprFNkpsSPbq2mqkW3lAyFT8qSLa7PlWXJ7L4VZ0t UE1iM5oX7PMyzPjlZt_ZKgSWHszBtnOfFCbRBnkKrbloozDBbK2AW5ow8CNM UBI0CLQvZb5yPhC8FlaqzBiYTnNy3v3Rk1moqK78pyqgAX3JJevwkR_b_Cbc 6XHPPzRRIlQcrFpzHTlWnEVawl6E8nVDlLWA6thiO_ooV2UB7SRmsjusbuJ2 gPi7s4OrRMPHwPHmU.9bXO93mQ7azaPrFptlfoOTqKyrwhlSisfdEaNflwFx HyIqaEuZkXAieS5fCG3ZV4PyaSzfpREMK X-Yahoo-SMTP: 5Gpe5lSswBBjxDLzXR4T6WeX4oSzvbvEC6CXOr15Kd9FvJA- X-Rocket-Received: from Antikythera (alex@99.189.173.81 with login) by smtp108.sbc.mail.gq1.yahoo.com with SMTP; 13 May 2013 17:35:49 -0700 PDT From: "Alexander K. Beros" To: Subject: missing some c++11 support for clang in FreeBSD Date: Mon, 13 May 2013 17:35:40 -0700 Message-ID: <000301ce503a$fb8e8630$f2ab9290$@154cm.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 14.0 Thread-Index: Ac5QOpjtudyw1K42R8a0dbGbzPwbsg== Content-Language: en-us X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 00:35:56 -0000 I have just started using clang (on FreeBSD 9.1 AMD64) and encountered a couple problems. I have worked around these points, but in case they represent something unintentional (as opposed to some error on my part while building from the port) I would like to mention them. I am using FreeBSD clang version 3.1 (branches/release_31 156863) 20120523 Target: x86_64-unknown-freebsd9.0 Thread model: posix A key element in solving both problems was the installation of gcc47. That was unexpected since I initially installed clang under the assumption that FBSD is moving from gcc to clang and since gcc42 doesn't support c++11. 1.. Symptom: %> clang++ -std=c++11 -stdlib=libstdc++ refparms.c++ initListTest.cpp:43:10: fatal error: 'initializer_list' file not found #include I had included initializer_list. Temporary Solution: I built gcc47 from the port and then added the following to my .cshrc file alias clang11 'clang++ -std=c++11 -I/usr/local/lib/gcc47/include/c++ -I/usr/local/lib/gcc47/include/c++/x86_64-portbld- freebsd9.1' Alternate solution, compile using g++47. 2.. Symptom: /usr/lib/libstdc++.so.6: version GLIBCXX_3.4.14 required by /usr/home/../binaries/a.out not found Solution: I added the following line to /etc/libmap.conf libstdc++.so.6 gcc47/libstdc++.so.6 again compiling with g++47 had no such problem. Best regards, Alexander