From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id AFCE31382C5 for ; Sun, 10 Jan 2021 13:34:24 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 10278E0B1C; Sun, 10 Jan 2021 13:34:20 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 7BE3DE0B18 for ; Sun, 10 Jan 2021 13:34:19 +0000 (UTC) Message-ID: Subject: [gentoo-dev] [RFC] Dealing with global /usr/bin/libtool use vs CC/CXX etc. From: =?UTF-8?Q?Micha=C5=82_G=C3=B3rny?= To: gentoo-dev@lists.gentoo.org Date: Sun, 10 Jan 2021 14:34:13 +0100 Organization: Gentoo Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.38.3 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Archives-Salt: 53af3ac4-b27a-40c6-a2d8-41d97522e628 X-Archives-Hash: abf2e3c467542c9958107fbc4a716ef9 Hi, The vast majority of libtool-based programs use configure script to generate libtool. However, a few non-autoconf packages also use libtool by calling system-installed /usr/bin/libtool. The problem is that this libtool hardcodes the values of CC/CXX at its' build time, so unless it is rebuilt frequently, packages end up using the stale values. The problem is known since 2005 [1] and hasn't been resolved yet. I can think of two ways of solving it: 1. We could patch system-installed libtool to respect environment variables such as CC, CXX, etc. This will probably require carrying a (possibly non-trivial) patch forever. On the bright side, libtool is not exactly a package seeing frequent releases. I mean, the current version is from 2015. 2. We could regenerate libtool and force local instance of libtool in the packages needing it. The main advantage of this is that it's a no-brainer. I could make a quick eclass that does configure a local instance and prepends it into PATH. WDYT? [1] https://bugs.gentoo.org/88596 -- Best regards, Michał Górny