From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Zhu Zihao Newsgroups: gmane.lisp.guile.devel Subject: Make the pkgconfig file of Guile relocatable. Date: Mon, 28 Feb 2022 00:04:52 +0800 Message-ID: <86tuckqoge.fsf@163.com> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31580"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.6.10; emacs 27.2 To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Sun Feb 27 17:27:43 2022 Return-path: Envelope-to: guile-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nOMOc-00084Q-1E for guile-devel@m.gmane-mx.org; Sun, 27 Feb 2022 17:27:42 +0100 Original-Received: from localhost ([::1]:57438 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nOMOa-0004gq-Ml for guile-devel@m.gmane-mx.org; Sun, 27 Feb 2022 11:27:40 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:38878) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nOMOP-0004gb-0h for guile-devel@gnu.org; Sun, 27 Feb 2022 11:27:29 -0500 Original-Received: from m12-15.163.com ([220.181.12.15]:33259) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nOMOH-0005HZ-CM for guile-devel@gnu.org; Sun, 27 Feb 2022 11:27:23 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-ID:MIME-Version; bh=kJjv1 3tWF3naifXQ1COlny+2ifusrrvEeNhYtWlexgk=; b=oHsRsCm8BYwOK3yx8EEPk yTRNJ4CJ/AzTp95sLabdaZGNZmH9uhjk8aHXaUmOPr80/OCrEyA+osuRYdaqCUVc CC7HGU/Q0rlzwyPpOHwhDw8RCdK2HPkkhcfe+weBImlOYwPL1kFBELaIr8lt2AVM tXlKMHaMJmIseps94Abqek= Original-Received: from asus-laptop (unknown [14.150.111.161]) by smtp11 (Coremail) with SMTP id D8CowAB3ZpzDohtiiFWTAQ--.16433S2; Mon, 28 Feb 2022 00:11:53 +0800 (CST) X-CM-TRANSID: D8CowAB3ZpzDohtiiFWTAQ--.16433S2 X-Coremail-Antispam: 1Uf129KBjvJXoW7KrWDGFW3JF1DXw43GrWrGrg_yoW8Gr4fpF s2ga4rKr95XFy8Cr1kAr47AF1FkrW3Xr97Kan5uw1xCwnIqrWavr9F9FyfX3WUArWvkF47 X3yv9348Z3W7WaDanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07UnqXLUUUUU= X-Originating-IP: [14.150.111.161] X-CM-SenderInfo: pdoosuxxwbztlvw6il2tof0z/xtbBaxG0r1et3PrJBwAAsz Received-SPF: pass client-ip=220.181.12.15; envelope-from=all_but_last@163.com; helo=m12-15.163.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.io gmane.lisp.guile.devel:21155 Archived-At: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Currently, the guile-3.0.pc.in in 'meta' use the variable substitution directly. prefix=3D@prefix@ exec_prefix=3D@exec_prefix@ bindir=3D@bindir@ libdir=3D@libdir@ includedir=3D@includedir@ datarootdir=3D@datarootdir@ datadir=3D@datadir@ pkgdatadir=3D@datadir@/guile pkgincludedir=3D@includedir@/guile sitedir=3D@sitedir@ extensiondir=3D@libdir@/guile/@GUILE_EFFECTIVE_VERSION@/extensions siteccachedir=3D@libdir@/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache libguileinterface=3D@LIBGUILE_INTERFACE@ sitedir, siteccachedir and extensiondir will be subsituted to the full path of the install path of Guile. But sometimes I want to install guile module in different prefix(e.g. NixOS, Guix, flatpak). I have to adjust these variable manually. My idea is change the definition of sitedir, siteccachedir, extensiondir use the variable substition of pkg-config instead of autotools. For example sitedir=3D${datadir}/guile/site/@GUILE_EFFECTIVE_VERSION@ siteccachedir=3D${libdir}/guile/@GUILE_EFFECTIVE_VERSION@/extensions .... So I can use pkg-config guile-3.0 --define-variable=3Dlibdir=3D$MY_PREFIX --variable=3Ds= iteccachedir to get the correct install directory. Thoughts? =2D-=20 Retrieve my PGP public key: gpg --recv-keys D47A9C8B2AE3905B563D9135BE42B352A9F6821F Zihao --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iIsEARYIADMWIQRefA5qkqvnKdl/GTlmOX+E92aT+QUCYhuisRUcYWxsX2J1dF9s YXN0QDE2My5jb20ACgkQZjl/hPdmk/nY2QEAryveqi0EkhnkAtBRjI3WLQeYPu3b SISAkSSjW9Fe1EMA/0SEflSUpGhjC6VsWd+VcQJLdFd9pZeebW8OTxmyniAH =C7Uu -----END PGP SIGNATURE----- --=-=-=--