From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id GNudFyon8l8OGgAA0tVLHw (envelope-from ) for ; Sun, 03 Jan 2021 20:20:58 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id oHoOEyon8l9hYQAAbx9fmQ (envelope-from ) for ; Sun, 03 Jan 2021 20:20:58 +0000 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 B74E794036A for ; Sun, 3 Jan 2021 20:20:57 +0000 (UTC) Received: from localhost ([::1]:49938 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kw9s0-0002CU-CW for larch@yhetil.org; Sun, 03 Jan 2021 15:20:56 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:58656) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kw9Zi-0004r1-1f for bug-guix@gnu.org; Sun, 03 Jan 2021 15:02:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:55357) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kw9Zh-0005Yw-QX for bug-guix@gnu.org; Sun, 03 Jan 2021 15:02:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kw9Zh-0002l4-OK for bug-guix@gnu.org; Sun, 03 Jan 2021 15:02:01 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#41177: Fontconfig issues in Java applications that use fonts References: <1589126137.10294.0@terracrypt.net> In-Reply-To: <1589126137.10294.0@terracrypt.net> Resent-From: Fabien SK Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 03 Jan 2021 20:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41177 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 41177@debbugs.gnu.org Received: via spool by 41177-submit@debbugs.gnu.org id=B41177.160970407010544 (code B ref 41177); Sun, 03 Jan 2021 20:02:01 +0000 Received: (at 41177) by debbugs.gnu.org; 3 Jan 2021 20:01:10 +0000 Received: from localhost ([127.0.0.1]:38670 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kw9Yr-0002jz-NC for submit@debbugs.gnu.org; Sun, 03 Jan 2021 15:01:10 -0500 Received: from smtp6-g21.free.fr ([212.27.42.6]:62486) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kw4g8-0003Gd-1g for 41177@debbugs.gnu.org; Sun, 03 Jan 2021 09:48:20 -0500 Received: from [IPv6:2001:41d0:fe25:200:1921:d260:5e26:684] (unknown [IPv6:2001:41d0:fe25:200:1921:d260:5e26:684]) (Authenticated sender: fabsk) by smtp6-g21.free.fr (Postfix) with ESMTPSA id 96104780372 for <41177@debbugs.gnu.org>; Sun, 3 Jan 2021 15:48:17 +0100 (CET) From: Fabien SK Message-ID: <11250641-ee7a-94e8-d3c4-ebdabc1c5036@free.fr> Date: Sun, 3 Jan 2021 15:48:17 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: fr-FR X-Mailman-Approved-At: Sun, 03 Jan 2021 15:01:08 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Mailman-Approved-At: Sun, 03 Jan 2021 15:20:48 -0500 X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -2.33 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Queue-Id: B74E794036A X-Spam-Score: -2.33 X-Migadu-Scanner: scn0.migadu.com X-TUID: LHtvVsifnUes I faced the issue when running josm (downloaded from josm.openstreetmap.de, not the guix package). Using "strace" showed me that it failed because it cannot load "libfontconfig.so" (it tries in several directories). If I add the directory of libfontconfig.so to LD_LIBRARY_PATH, then it starts. I have limited knowledge about how shared libraries are found. I tried to understand how "geany" manages to load libfontconfig.so. It looks like it depends on libgeany, libgtk3 and libpango which depend on libfontconfig. When I do a "readelf -a" on these libraries, I can see in their "RUNPATH" the path of "libfontconfig.so": 0x000000000000001d (RUNPATH)            Bibliothèque runpath:[/gnu/store/avjxs6qgyginkiq6qpk9280zakkaj35h-graphite2-1.3.13/lib:/gnu/store/xwl0p4m34bcan0v9vkjkyzwi6znsv4dm-pixman-0.38.4/lib:/gnu/store/y9fdy234r6hqiacd7hgwlmbdsngbp8p1-fontconfig-2.13.1/lib:… Regarding Java, I think (but I'm not sure) that it's loaded by "libawt_xawt.so". In fontpath.c [1], there is a dlopen of libfontconfig. But if I do a "ldd" on the shared library itself, it looks like it does not depend on libfontconfig.so. [1] https://github.com/openjdk/jdk16/blob/37043b05576c8b81b43ac41a8f06de0d0bbb3f5b/src/java.desktop/unix/native/common/awt/fontpath.c#L566 Also libfontconfig is not on its RUNPATH: 0x000000000000001d (RUNPATH)            Bibliothèque runpath:[$ORIGIN:/gnu/store/fa6wj5bxkj5ll1d7292a70knmyl7a0cr-glibc-2.31/lib:/gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib/lib:/gnu/store/w09mqfj1yy32r2fr02nndzs34m4f9ipp-libxext-1.3.4/lib:/gnu/store/4ildmh169dixyn05mlgjz07x4d2hcq2g-libx11-1.6.A/lib:/gnu/store/8m6368gv4z10n6i31ppbr8nxziwmlp3f-libxrender-0.9.10/lib:/gnu/store/cgsk20z1gcw78fdm7bwlb2l49xh7bmzk-libxtst-1.2.3/lib:/gnu/store/b4dk2y4vf98dhxnr0p6f5h4d86vqndkc-libxi-1.7.10/lib:/gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib/lib/gcc/x86_64-unknown-linux-gnu/7.5.0/../../..] I'm quite a beginner in term of Guix (I only played with it in a VM), and I hope this information will be useful to somebody. I don't understand how the dependencies between executable and libraries are supposed to be done in Guix. I can see that sometimes in /gnu/store there are symbolic links of shared libraries into other packages. I assume that sometimes this RUNPATH is used.