Skip to content

lxc: fix meson.build on esoteric host systems#28042

Merged
hnyman merged 1 commit intoopenwrt:masterfrom
kazikcz:lxc-fix-build-on-nixos
Jan 25, 2026
Merged

lxc: fix meson.build on esoteric host systems#28042
hnyman merged 1 commit intoopenwrt:masterfrom
kazikcz:lxc-fix-build-on-nixos

Conversation

@kazikcz
Copy link
Contributor

@kazikcz kazikcz commented Dec 9, 2025

When building lxc's meson.build tries to infer
something for the target system out of the host
build OS. This isn't reproducible and can actually fail on some OS' like NixOS.

The failure looked like this, early in the
building stage of lxc:

../../../../build_dir/target-aarch64_cortex-a53_musl/lxc-6.0.5/meson.build:166:8: ERROR: Problem encountered: "distrosysconfdir" is not set

The /etc/default seems to be something that is
derived on most host systems, so use that as the
explicit config.

This fixes building lxc on NixOS and similar.

This also makes the build more pure and
reproducible. Before this commit building the same set of checkouts, same config would yield
different lxc artifacts on RedHat and Ubuntu.
It was probably harmless though.


📦 Package Details

Maintainer: @ratkaj

Description: LXC is the userspace control package for Linux Containers(...)


🧪 Run Testing Details

  • OpenWrt Version: d11b77db5eca3e20c5c238c55d80059229a188b3
  • OpenWrt Target/Subtarget: x86/64
  • OpenWrt Device: QEMU

✅ Formalities

  • I have reviewed the CONTRIBUTING.md file for detailed contributing guidelines.

@BKPepe BKPepe force-pushed the lxc-fix-build-on-nixos branch from 0826929 to 6bca90e Compare December 13, 2025 10:05
@hnyman
Copy link
Contributor

hnyman commented Dec 31, 2025

Please also bump the PKG_RELEASE in Makefile.
You could also remove the long absent ratkaj from the MAINTAINER field in Makefile.

When building lxc's meson.build tries to infer
something for the target system out of the host
build OS. This isn't reproducible and can actually
fail on some OS' like NixOS.

The failure looked like this, early in the
building stage of lxc:

> ../../../../build_dir/target-aarch64_cortex-a53_musl/lxc-6.0.5/meson.build:166:8: ERROR: Problem encountered: "distrosysconfdir" is not set

The /etc/default seems to be something that is
derived on most host systems, so use that as the
explicit config.

This fixes building lxc on NixOS and similar.

This also makes the build more pure and
reproducible. Before this commit building the same
set of checkouts, same config would yield
different lxc artifacts on RedHat and Ubuntu.
It was probably harmless though.

This also removes inactive maintainer from the
Makefile.

Signed-off-by: Michal Kazior <michal@plume.com>
@kazikcz kazikcz force-pushed the lxc-fix-build-on-nixos branch from 6bca90e to 0e27696 Compare January 7, 2026 12:15
@kazikcz
Copy link
Contributor Author

kazikcz commented Jan 7, 2026

@hnyman force-pushed:

  • bumped release from 1 to 2
  • removed @ratkaj from the Makefile
  • rebased to latest master

@hnyman hnyman merged commit ee74cd5 into openwrt:master Jan 25, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants