Project

General

Profile

Bug #1234

[librechroot] `librechroot -A armv7h make` aborts during `locale-gen`

isacdaavid - over 3 years ago - . Updated about 2 years ago.

Status:
fixed
Priority:
broken
Category:
ARM on x86
Assignee:
-
% Done:

100%


Description

$ sudo librechroot -A armv7h -n armv7h make

[...]
:: Running post-transaction hooks...
[...]
Generating locales...
  en_US.UTF-8...localedef: ../sysdeps/unix/sysv/linux/spawni.c:360: __spawnix: Assertion `ec >= 0' failed.
qemu: uncaught target signal 6 (Aborted) - core dumped
/usr/bin/locale-gen: line 41:    27 Aborted                 (core dumped) localedef -i $input -c -f $charset -A /usr/share/locale/locale.alias $locale

The problem isn't specific to librechroot, I have confirmed it in 2 machines by running locale-gen inside a chroot not made by librechroot. However it prevents everything after locale-gen from occurring, with awful consequences for libremakepkg:

$ sudo libremakepkg -n armv7h

[...]
==> Starting to build the package...
 |  /usr/bin/cp: cannot stat '/repo/repo.db': No such file or directory
 |  ==> Checking runtime dependencies...
 |  warning: database file for 'repo' does not exist
 |  ==> Installing missing dependencies...
 |  warning: database file for 'repo' does not exist
 |  error: failed to prepare transaction (could not find database)
 |  ==> ERROR: 'pacman' failed to install missing dependencies.
==> Copying log and package files out of the chroot...

History

#2

Updated by lukeshu about 3 years ago

  • Target version set to Better ARM support
#3

Updated by oaken-source about 3 years ago

A workaround for the failing locale-gen call is running in the chroot:

# gunzip --keep /usr/share/i18n/charmaps/UTF-8.gz

afterwards, locale-gen succeeds:

# locale-gen 
Generating locales...
  en_US.UTF-8... done
  de_DE.UTF-8... done
Generation complete.

Now, is there any way that I can take this to a working chroot? what other steps are required?

#4

Updated by isacdaavid about 3 years ago

oaken-source wrote:

Now, is there any way that I can take this to a working chroot? what other steps are required?

Last time I checked just touching an empty `/repo/repo.db` was able to do the trick.

#5

Updated by oaken-source about 3 years ago

yes, this appears to work. thank you!

#6

Updated by lukeshu over 2 years ago

I wonder if this is "caused" by librechroot not calling setarch before calling mkarchroot; in contrast with Arch's archbuild, which does call setarch on mkarchroot.

#7

Updated by lukeshu over 2 years ago

Upon further reflection, that was a dumb thought. We can't call setarch to ARM from x86; how could not calling it be the issue?

#8

Updated by lukeshu about 2 years ago

  • % Done changed from 0 to 100
  • Status changed from open to fixed

This is fixed in current versions of things. I don't know what was causing it.

Also available in: Atom PDF