From owner-freebsd-toolchain@FreeBSD.ORG Fri Jul 6 20:45:03 2012 Return-Path: Delivered-To: toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61B6B1065673 for ; Fri, 6 Jul 2012 20:45:03 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id F37538FC0A for ; Fri, 6 Jul 2012 20:45:02 +0000 (UTC) Received: by yhfs35 with SMTP id s35so4221632yhf.13 for ; Fri, 06 Jul 2012 13:45:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer :x-gm-message-state; bh=Bm2+b8uN+IIZw17wFhGHQamSJAlL5gyZHXtEJANBZL4=; b=WvLzdHs+WbImrG2DMP4jFmElsdwrf0V7jMLNEv/HyU2bGS8K6UqCi6o5Ca2imuls/f xuvg4CMYA7xf8R7sCI5FUXQfFkqqPXAPeWUZDSM1sC6CtUfSZmBVB9Oj8Gug1sZuimaE jYo7F4URWFaYHQai6p9vUDpMugb4pTihzqPJCVrr8OtXuTptchUXVqGZpafqb18Z+aXS 2XQrMDm5UXtbsc0gVJRB4blRIUXPhM5u25DG9Kriq3Hwb7tzKNzcL6cxL7uiORH/u2Sj KG+n5c/wuDnt2zM7jmQsAAJRZat5rifzbw/ERvPBKRXeE+UFETZPLJnsMXec40IjH20x 9unw== Received: by 10.60.172.236 with SMTP id bf12mr28462868oec.23.1341607502480; Fri, 06 Jul 2012 13:45:02 -0700 (PDT) Received: from [10.30.101.53] ([209.117.142.2]) by mx.google.com with ESMTPS id bd4sm24170194obb.12.2012.07.06.13.45.01 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 06 Jul 2012 13:45:01 -0700 (PDT) Sender: Warner Losh Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Warner Losh In-Reply-To: <714BF622-A1B3-4A4A-A8BC-DCA82B4434A2@FreeBSD.org> Date: Fri, 6 Jul 2012 14:44:59 -0600 Content-Transfer-Encoding: quoted-printable Message-Id: References: <4FF60A9E.5070503@FreeBSD.org> <4FF6DB51.40904@FreeBSD.org> <508B8B4E-DF5E-412B-BD2B-86F21EBF4C8C@bsdimp.com> <4FF700CF.2000206@FreeBSD.org> <1DED79CC-CACD-4D22-9F1F-E3EB17938EB6@bsdimp.com> <4FF7182A.9070803@FreeBSD.org> <714BF622-A1B3-4A4A-A8BC-DCA82B4434A2@FreeBSD.org> To: David Chisnall X-Mailer: Apple Mail (2.1084) X-Gm-Message-State: ALoCoQkkDmUGjmiSblUG4y/rIXJVYV5ezx4ULQzntRcUkrrp7vc6++2OzlFsU1fIksU41jas2H+R Cc: toolchain@FreeBSD.org, Andriy Gapon Subject: Re: gcc46 header search path X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Jul 2012 20:45:03 -0000 On Jul 6, 2012, at 1:11 PM, David Chisnall wrote: > On 6 Jul 2012, at 17:54, Andriy Gapon wrote: >=20 >> Yeah. Honestly speaking I myself was not aware of what is written in = that link >> and I thought that our gcc ports (from ports) added = /usr/local/include to the >> default search path by some mistake. And if somebody asked me what I = thought >> about the idea of adding /usr/local/include to the default path, I'd = say that it >> was a stupid idea. >=20 > Why? The number one question I get from developers new FreeBSD is 'I = wanted to use libfoo from ports, I stalled it, and now [gcc,clang] = doesn't find the headers, why not?' No one has yet provided me with a = sane reason why our system compiler would not look in the standard = locations where we install headers and libraries. Because they aren't standard locations. Or at least didn't used to be = standard locations. At this point, I'd say it is likely better to = include the new path than not, since it has become standard since = FreeBSD started tracking gcc. > Running configure scripts on FreeBSD is a colossal pain because of = this - you often need to explicitly say = -with-foo-include=3D/usr/local/include -with-foo-lib=3D/usr/local/lib = for an arbitrary number of values of foo, depending on the library. >=20 > Please, please, please, can we put our standard library and header = paths in the compiler standard header or library paths, or can someone = give me a good reason other than 'it's a stupid idea' why we should = force every single program that anyone compiles on FreeBSD to do = CFLAGS=3D-I/usr/local/include LDFLAGS=3D-L/usr/local/lib? The reasons are that /usr/local/include superceds anything in = /usr/include. This is dangerous. Users should get just the system = default libraries and headers when they compile unless they ask for = more. That's what makes it stupid. However, regardless of my opinion, I think this may be a case where the = avalanche has started, and it is too late for the snow flakes to vote. Warner