From owner-freebsd-hackers@freebsd.org Thu Oct 18 00:25:37 2018 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8D9E510E2ADA for ; Thu, 18 Oct 2018 00:25:37 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 00B4296CA0 for ; Thu, 18 Oct 2018 00:25:36 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 6B0142222C for ; Wed, 17 Oct 2018 20:25:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Wed, 17 Oct 2018 20:25:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yuripv.net; h=to :from:subject:message-id:date:mime-version:content-type; s=fm3; bh=L5CTh8yOwHUz9huACx1hIwRK/ZxMMPOsdalhFhNsiyU=; b=pT/8san77l55 WrcD6c7GuuvkdgZ/1XQKq4dVn0lIcHgQ/2BSLVj/7pRegfLR4lQZNJota2q4LLMx CA3/rflmmqg53N25/c5TStXzJ+NLfkc37VxNVsWWjMOUEMtetTyygvEL2keJBnm+ f1C+yoFdtFVaQeSXf3vB+TdQO1MVkSFESL18DUKr7h91S19dTbwbtoxqN9YHWGHn i5AdC6XCy6mvFAj4AG7GTTmYPDjMBIHNTRo4Y4otqPzTllKR37rYuEFKwN+on9hQ 5ow3XQWqcFiNxOiBM0WQK2yZcxPtCBDgA0k5L/H0tc2J17dgOkH9QkYXZ2vcMsMU 3yKHUE2TjA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:message-id :mime-version:subject:to:x-me-proxy:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; bh=L5CTh8yOwHUz9huACx1hIwRK/ZxMM POsdalhFhNsiyU=; b=P/G015U6u4JO2fsJIXmdc+7meydebXpJutBpFw/OyC5YY yqoYnMoZfV4f0odnY9oyJnTJiPiq+Ngujd3ZbLHCSyS5QefiwWi8CU5g+Cgfs2sB 8DEVnww6UZMdlR8hdLVVj3pZUb96K2SNu8fMg2Y3IxN8auRfT3ArvAFDBckAYy/e 3mLK9CKiEn0GwNjaNH1xvKkF/WK7wisQlIGyENWg8wRzYwBBlVYY7CZ9qAt/fvqr ROiahlMJW1R4VhQXoqoyBz4JGVZQz8K3oyfYF5ZfgeoKEGGW97SX3thkeyFs/Jih qPVnNctHZ+IpbfRb/1WDSrtkSiIXr3BwDaNw2xKXQ== X-ME-Sender: X-ME-Proxy: Received: from [192.168.1.2] (unknown [85.173.27.113]) by mail.messagingengine.com (Postfix) with ESMTPA id D04C4102DE for ; Wed, 17 Oct 2018 20:25:34 -0400 (EDT) To: freebsd-hackers From: Yuri Pankov Subject: embed endian info in locale data files magic (PR231965) Openpgp: preference=signencrypt Autocrypt: addr=yuripv@yuripv.net; keydata= xsBNBFu8u6IBCADB11gP0QwnorrHjqAtKLHKHNHskhy0s7jqJKfx0YqXgVBKGLJ9/mjLAz0F CBNvemHSDDTs0mEZ9cBKKi6cmsav6+UQgr//yai6hvXLBJqKchSFO4MhmdvBtsGFq1yKz5Zi uhjmimKyIpgBgvMdbgGbGq6cnSB2uEPmZuJr419SVRODOkXukU+F5WHgaHzDdHAIu1asCt2B +6msxqIqlFWcXyZyTGicTGGvC/PFIsVRUtD1dIJANTC876g7DTb7LZXWiWwJpSJ4GKMXMHVX Ct9BoQ4i3nhKbOxb6Io1wsy+NFyWsTJ9KYrxKKPJP3oG8BWb/cqlFqnE4eNSsiq2q7krABEB AAHNH1l1cmkgUGFua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nTfUWuQllbzMP0MfhCDMk1Mo8WvDH2/cOEP/yLKf20a+cd6nLs7bidjmGXo9pyuBKAtV6 Kv+VRu54AL+A/UBYu/eB3Dtvzcnut+1Zq6KaP++kUwPwINLIk04OBDwN0zRNTiqMAFYYyz2v ZHBB6E1th/l//ZC5b9Dk0ZpFI1bYdL9ymnrZe1MqbGPnDCToQxu00T/pZCm6Z92YrZQYuNwl Message-ID: Date: Thu, 18 Oct 2018 03:25:26 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="RTL9UyG6YiKgof5xLKUFl5STeAOQNr1v0" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Oct 2018 00:25:37 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --RTL9UyG6YiKgof5xLKUFl5STeAOQNr1v0 Content-Type: multipart/mixed; boundary="5oxIDsZ06G3YJqyqE6v4e2eYEjCaO8uTB"; protected-headers="v1" From: Yuri Pankov To: freebsd-hackers Message-ID: Subject: embed endian info in locale data files magic (PR231965) --5oxIDsZ06G3YJqyqE6v4e2eYEjCaO8uTB Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D231965 ([PowerPC64] Cross compiling powerpc64 from amd64 results in nonfunctional locale installations), describes the issue with locale data built on LE system (amd64) when used on BE system (powerpc). Fix introduced in rS308170 depends on the fact that locale data is built on LE system, and will likely fail when it's built natively on mips (please correct me if I'm wrong). More so, we shouldn't be hardcoding the conversion in libc, and I see 2 options here: 1. fix localedef to output data in target's system endian 2. embed the endian info in locale data files (updating magic signature) and ehhance the previous fix with runtime selection of needed conversion I have put the change for #2 together at https://reviews.freebsd.org/D17603 (more a PoC at the moment than a real review), and wondering if it looks sane enough or if there's anything obvious I'm missing. I have briefly tested the libc and locale files (LC_CTYPE and LC_COLLATE) built on amd64 on a powerpc system, and it seems to work. TIA --5oxIDsZ06G3YJqyqE6v4e2eYEjCaO8uTB-- --RTL9UyG6YiKgof5xLKUFl5STeAOQNr1v0 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEE+Gq3PsPeLT4tL/9wk4vgf7Eq4WwFAlvH0vYACgkQk4vgf7Eq 4Wy+XQf8DvLLWf5bYetZTJiTR7vlNSiZQLxjbF72CDcq60puz7mmCmGLlqUCYsSZ 3uPpU0G90LpQ8hY95Y1RvCX8MXet7YheiOxv550jvCkER9khiGCHILjkGVG+P2ae DJLuB/aKI/+q4WyKRC7IF+y3Yk/WaLymkEIy984buR/0H9fTpbVtlB8TPQQz/qm2 olNXa+SP2xTFJPP0lEd+V92k8kqLk0fS+uLwOUmlEjUoqrr20uQrGtRaPhXGVvmg 5WfVF8JU63vHUL2AC5lpKwmW7CzOKJj2p0dEFkLPtHVyNE6IVYxc/jPRg8GTef0B FgLBI0xLxu2Ui7dLOyRue8MwxFPknA== =sll+ -----END PGP SIGNATURE----- --RTL9UyG6YiKgof5xLKUFl5STeAOQNr1v0--