Opened 17 months ago

Closed 17 months ago

Last modified 17 months ago

#5304 closed defect (fixed)

chapter6: Add --build for all cross compiled packages

Reported by: Xi Ruoyao Owned by: Bruce Dubbs
Priority: normal Milestone: 12.0
Component: Book Version: git
Severity: normal Keywords:
Cc:

Description

In autoconf, --host=$LFS_TGT alone is not enough for cross compiling. We need the combination of --host=$LFS_TGT --build=$(./config.guess) (path to config.guess may vary for different packages).

With diffutils-3.10 (the first chapter 6 package without --build) the configure script says:

checking whether we are cross compiling... no

This is not what we want. And the issue is likely causing a build failure in chapter 6 sed with glibc-2.38 (not sure why it only starts to blow up with the glibc update though).

Change History (6)

comment:1 by Xi Ruoyao, 17 months ago

The chapter 6 packages lacking --build:

  • diffutils
  • findutils
  • grep
  • sed

comment:2 by Xi Ruoyao, 17 months ago

I (and Thomas, and r1c0n3r0 from #lfs-support) can confirm with Glibc-2.38 sed FTBFS with:

help2man: can't get `--help' info from sed/sed
Try `--no-discard-stderr' if option outputs to stderr

because the building system does not know we are cross compiling, and attempts to run sed --help.

The reason it suddenly starts to blow up with Glibc-2.38: Glibc-2.38 redirects strtol to __isoc23_strtol if C2X or _GNU_SOURCE is enabled, and __isoc23_strtol did not exist in previous Glibc versions.

comment:3 by Xi Ruoyao, 17 months ago

With --build=$(./build-aux/config.guess) added sed builds and installs fine in chapter 6.

Last edited 17 months ago by Xi Ruoyao (previous) (diff)

comment:4 by Bruce Dubbs, 17 months ago

Owner: changed from lfs-book to Bruce Dubbs
Status: newassigned

comment:5 by Bruce Dubbs, 17 months ago

Resolution: fixed
Status: assignedclosed

comment:6 by Bruce Dubbs, 17 months ago

Milestone: 11.412.0

Milestone renamed

Note: See TracTickets for help on using tickets.