From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1O3v7l-0004N3-8o for garchives@archives.gentoo.org; Mon, 19 Apr 2010 17:51:09 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 50E51E0856; Mon, 19 Apr 2010 17:51:06 +0000 (UTC) Received: from mx1.bouyguestel.com (mx1.bouyguestel.com [62.201.140.9]) by pigeon.gentoo.org (Postfix) with ESMTP id 6A9A2E0817 for ; Mon, 19 Apr 2010 17:51:01 +0000 (UTC) Received: from PNMSSS164 ([10.123.138.11]) by mx1.bouyguestel.com (MTA Server) with ESMTP id <0L14009EETBWHUE0@mx1.bouyguestel.com>; Mon, 19 Apr 2010 18:19:09 +0200 (MEST) Date: Mon, 19 Apr 2010 18:19:02 +0200 From: Alexis Ballier Subject: [gentoo-dev] static builds, static-libs useflag and indirect dependencies To: gentoo-dev@lists.gentoo.org Message-id: <20100419181902.14775ee7@capa-portable> Organization: Gentoo 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 MIME-version: 1.0 X-Mailer: Claws Mail 3.7.2 (GTK+ 2.18.3; x86_64-pc-linux-gnu) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7bit X-Archives-Salt: ae6b10b2-500d-4627-b98c-ec30a7566565 X-Archives-Hash: 394c30634f701b1e4a103d3169f0cbc6 Hi all, We used to install both shared and static libraries when both were available; this was good and working. Now we have the static-libs useflag to control when static libs are built and installed; this is better: we save time & space. The problem I want to raise here is about indirect dependencies with that new approach; let's take a real life example: We have xz-utils and libarchive with the static-libs useflag. I want to build freebsd-rescue statically against libarchive. What should I do? So far we depend on libarchive[static-libs] because we cannot guess the deps of libarchive. Thanks to pkg-config --static this is a non issue, unless xz-utils is built without static-libs and we enabled lzma support in libarchive! In this case, libarchive's static libs are useless if I don't have xz-utils' ones because the former requires the latter. For me, the current way of adding static-libs to packages only for controlling whether static libraries are installed is broken. I'd like to see the following as a guideline/rule for the static-libs useflag: 1) if a package has a static-libs useflag then its deps must be cat/pkg[static-libs?] when applicable. 2) if one wants to add a static-libs useflag to a package then one must check the reverse deps and make them happy with 1). Needless to say I am volunteering to scan & fix the tree to see this implemented quickly. Another option would be to make the package manager automagically handling the propagation of the static-libs useflag but that sounds more a hack than anything else. Alexis.