summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjgraciahlrs <gracia@hlrs.de>2024-08-05 15:47:38 +0200
committerGitHub <noreply@github.com>2024-08-05 08:47:38 -0500
commit0257b2db4bb2539c103fe324435bb9e14eaa0644 (patch)
tree064c969d34e602c8ad56ba1c96f77533020bd724
parentd3bf1e04fca844abb7c1eeac38dda4e126c81b67 (diff)
downloadspack-0257b2db4bb2539c103fe324435bb9e14eaa0644.tar.gz
spack-0257b2db4bb2539c103fe324435bb9e14eaa0644.tar.bz2
spack-0257b2db4bb2539c103fe324435bb9e14eaa0644.tar.xz
spack-0257b2db4bb2539c103fe324435bb9e14eaa0644.zip
libxcb: Set well-known locale for build (#45502)
* libxcb: Set well-known locale for build Builds might fail if no valid locale is set. See https://www.linuxfromscratch.org/blfs/view/git/x/libxcb.html * libxcb: fix style * libxcb: change locale from en_US.UTF-8 to C.UTF-8 * libxcb: fix style * Update var/spack/repos/builtin/packages/libxcb/package.py Co-authored-by: Wouter Deconinck <wdconinc@gmail.com> * [@spackbot] updating style on behalf of jgraciahlrs --------- Co-authored-by: Wouter Deconinck <wdconinc@gmail.com> Co-authored-by: jgraciahlrs <jgraciahlrs@users.noreply.github.com>
-rw-r--r--var/spack/repos/builtin/packages/libxcb/package.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/libxcb/package.py b/var/spack/repos/builtin/packages/libxcb/package.py
index fefdebd20c..2d5959cc8c 100644
--- a/var/spack/repos/builtin/packages/libxcb/package.py
+++ b/var/spack/repos/builtin/packages/libxcb/package.py
@@ -60,3 +60,13 @@ class Libxcb(AutotoolsPackage, XorgPackage):
def patch(self):
filter_file("typedef struct xcb_auth_info_t {", "typedef struct {", "src/xcb.h")
+
+ # libxcb fails to build with non-UTF-8 locales, see:
+ # https://www.linuxfromscratch.org/blfs/view/git/x/libxcb.html
+ # https://gitlab.freedesktop.org/xorg/lib/libxcb/-/merge_requests/53 (merged in 1.17.0)
+ # https://gitlab.freedesktop.org/xorg/lib/libxcb/-/merge_requests/60
+ # If a newer release can be verified to build with LC_ALL=en_US.ISO-8859-1,
+ # then we can limit the following function, e.g.
+ # when("@:1.17")
+ def setup_build_environment(self, env):
+ env.set("LC_ALL", "C.UTF-8")