From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18729 invoked by alias); 24 Jun 2015 19:10:14 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 18716 invoked by uid 89); 24 Jun 2015 19:10:13 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-ig0-f178.google.com Received: from mail-ig0-f178.google.com (HELO mail-ig0-f178.google.com) (209.85.213.178) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 24 Jun 2015 19:10:12 +0000 Received: by igbiq7 with SMTP id iq7so103964787igb.1 for ; Wed, 24 Jun 2015 12:10:10 -0700 (PDT) X-Received: by 10.42.214.144 with SMTP id ha16mr11360369icb.70.1435173010173; Wed, 24 Jun 2015 12:10:10 -0700 (PDT) MIME-Version: 1.0 Received: by 10.36.3.2 with HTTP; Wed, 24 Jun 2015 12:09:50 -0700 (PDT) In-Reply-To: References: From: Siddhartha Jain Date: Wed, 24 Jun 2015 19:10:00 -0000 Message-ID: Subject: Re: Custom gcc installation include files To: Jonathan Wakely Cc: gcc-help Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-SW-Source: 2015-06/txt/msg00167.txt.bz2 The command is below. C_INCLUDE_PATH and CXX are empty. I have a symlink to the gcc exec in my home dir bin which is what's running. When I set the CXX and CC to the system g++ and gcc, the problem goes away so it seems like my gcc custom installation is messed up? I have compiled other things in the past with it though. g++ -c -o project.o -pipe -DQMAKE_OPENSOURCE_EDITION -g -I. -Igenerators -Igenerators/unix -Igenerators/win32 -Igenerators/mac -Igenerators/symbian -Igenerators/integrity -I/home/sj1/Software/qt/4.8.7/build/include -I/home/sj1/Software/qt/4.8.7/build/include/QtCore -I/home/sj1/Software/qt/4.8.7/build/src/corelib/global -I/home/sj1/Software/qt/4.8.7/build/src/corelib/xml -I/home/sj1/Software/qt/4.8.7/qt-everywhere-opensource-src-4.8.7/tools/shar= ed -DQT_NO_PCRE -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DQLIBRARYINFO_EPOCROOT -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_STL -DQT_NO_COMPRESS -I/home/sj1/Software/qt/4.8.7/qt-everywhere-opensource-src-4.8.7/mkspecs/li= nux-g++ -DHAVE_QCONFIG_CPP -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DEPRECATED project.cpp On Wed, Jun 24, 2015 at 2:56 PM, Jonathan Wakely wr= ote: > On 24 June 2015 at 19:38, Siddhartha Jain wrote: >> /usr/include/string.h:548:5: error: =E2=80=98__locale_t=E2=80=99 has not= been declared >> __locale_t __loc) > > This indicates you are either doing something wrong or your C library > is severely messed up. > > /usr/include/string.h is part of the C library, and the type > __locale_t should be defined by another header in the C library, > /usr/include/xlocale.h > > >> there are a couple of other similar errors but this is the first one >> and I thought it might be because the system gcc is 4.4.7 and it's >> using the executable for gcc 4.8.1 > > No, that should work fine (and it does, I use such a setup frequently). > > I suggest you stop adding anything to C_INCLUDE_PATH. If you just > invoke gcc 4.8.1 it should know how to find all the standard C and C++ > headers it needs, without your help. > > If that still doesn't work and you want further help you will need to > show the exact gcc or g++ command that causes the error, as well as > any environment variables such as C_INCLUDE_PATH and CXX that you > might have set that would confuse things. We can't guess what the > problem is if you don't tell us exactly what you're doing.