From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id aGRlCilq6mZGAgAAe85BDQ:P1 (envelope-from ) for ; Wed, 18 Sep 2024 05:50:33 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id aGRlCilq6mZGAgAAe85BDQ (envelope-from ) for ; Wed, 18 Sep 2024 07:50:33 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=disroot.org header.s=mail header.b=PTkW2zy5; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=disroot.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1726638632; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=UABo5x+GaGjj0tYDG6Mmc0R8lpu+TWGxFg0uviEf/aw=; b=nkKlKxBa1HhgGViOpPpgFFcnqg1xfqzAcnh926r7XuAAUZcjJSkBmDuV1RYbCU/m6NkYNB NIOGuRk3ywI9W37noVlCR8/ohbKFdXw1JE14qZulxygSHVQcFf35Ak6xEIjrTZstbD1BII 1r4H1D/7iDAqoim+VUpEZTX5tJ4AVxdyKJGzoRL6inPa5Yz4wBnVBTsI4EPzpyTYQrwB4c nJuehJR/BurWuEFlzBuDCzRaTzFJToU4IlbnlAMux6kf54cdixNivtb1s0dQ3fYVQzJE2i XqV75P2r+3LJgK8Qns3dZfn6C3kNmgD6TDljGqCADuHacLKgkQT0iRx7DU6WMg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=disroot.org header.s=mail header.b=PTkW2zy5; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=disroot.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1726638632; a=rsa-sha256; cv=none; b=iRGmI43FdVc7Ifp5bCPca/DkBzKsPCEJz7mGuE3lns/aE6tXOZGgBvVtHMR1KEr2qaiiiQ 0ee3PGMH17Bgtd7YrpDgtwYnZ65ysHt5/RYUsHXDx9dMXmI4XeEZGZr8KGKIUtoeswHdBy 9IBLIFqsIQYEJ9RzTPZEB0IycJqIi6YXspqBQDjLHKJc9/pFyYDbNU2auRINorm5tR0key 9rfQcrB/HFH2+dYfWqLZSemnsAfGRKV9hq6nr2xbIm5X01gpSDd2jcpt1P8DAymZ4uu8nw pdcWVvJ94KatX7RMzxZoUTpEquC+nh6ooBnoK6FWQA8Qd2y8DoRbgBrOdz7t4w== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 8BFA76FDF for ; Wed, 18 Sep 2024 07:50:32 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sqnZY-00017P-Hj; Wed, 18 Sep 2024 01:49:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sqnZV-000178-1A for help-guix@gnu.org; Wed, 18 Sep 2024 01:49:49 -0400 Received: from layka.disroot.org ([178.21.23.139]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sqnZT-0006xD-1z for help-guix@gnu.org; Wed, 18 Sep 2024 01:49:48 -0400 Received: from mail01.disroot.lan (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id C960723D29; Wed, 18 Sep 2024 07:49:43 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from layka.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id xr-FXt5DaL9v; Wed, 18 Sep 2024 07:49:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1726638583; bh=2S2n77zBERJz01Rc7QKD3PbP+tAis45saQ/pTLHPHJc=; h=Date:To:Cc:From:Subject; b=PTkW2zy5xbORun7tP9MGxSrZw/zi+97bmDGOgl8mNxp9iDdLghgKWBGZEUOctnFt3 hJ3j9eN5kOF3nkQqr4Zo9mTGJUmAmZBXH5kkI/JqKHSLz1S8rbO63tcbFEwlWwUL2t WbmEVxjQoRrOPdcbPQh6ErFssBIUg+xBgMKzARLrzr5o+9EhM4CpMQXFvEtFuyqV7O PZaYOVNlqEWGc6DH+dqKCmBj+OIS/TVSf99BysWBjFERTJTT983mCbyL1UnvHCq7l2 rGQJyKRjvKPY5JmNxTJtGcbgegdIxWRlAAnklDUJk6p9gtaNYmDLrzxoV8wVvW7BkE APag3yZ05ba8A== Message-ID: Date: Wed, 18 Sep 2024 13:49:31 +0800 MIME-Version: 1.0 To: amano.kenji@proton.me Content-Language: en-US Cc: help-guix@gnu.org From: Adam Faiz Subject: Re: Direct symlink farm for transitive dependencies vs search paths Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=178.21.23.139; envelope-from=adam.faiz@disroot.org; helo=layka.disroot.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Queue-Id: 8BFA76FDF X-Migadu-Scanner: mx11.migadu.com X-Spam-Score: -7.30 X-Migadu-Spam-Score: -7.30 X-TUID: pCyRQvHlaj3M > Let's say that A depends on B, and B depends on C. > > With search paths, A doesn't have symlinks to B, and B doesn't have symlinks to > C. Thus, disk space is saved. > > However, adding search path patches to existing softwares is cumbersome, and a > long list of search paths results in inefficient searches. > > Let's assume that B has symlinks to C, and A has symlinks to everything in B. > This means A has symlinks to symlinks in B. Transitive symlink is probably more > efficient than search path. If A just copies symlinks from B and has symlinks > to plain files in B, then A ends up with only direct symlinks. Direct symlinks > are more efficient than transitive symlinks. > > It seems that search paths are preferred over symlinks to transitive > dependencies in gnu guix. Why? Search paths are preferred because their purpose is to provide a list of places to look for extensions/plugins/mods of a package. Essentially, search paths are a way to provide runtime dependencies that are optional. Packages usually link directly to their dependencies at compile time, except for scripting programming languages(which aren't expected to have linking functionality). Propagated inputs are used for the transitive dependencies you mention, but they should only be used for required dependencies that have to be installed with the package for it to detect them. Packages shouldn't need to have symlinks in their output to another package when it could just directly reference it instead. More information on how native-inputs, inputs and propagated-inputs are different is explained in the Guix manual: https://guix.gnu.org/manual/devel/en/html_node/package-Reference.html#index-inputs_002c-of-packages