Bug 14801 - buildsys: "File name too long" errors when creating `.dep` files
Summary: buildsys: "File name too long" errors when creating `.dep` files
Status: NEW
Alias: None
Product: uClibc++
Classification: Unclassified
Component: Other (show other bugs)
Version: 0.2.5
Hardware: All Linux
: P5 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-17 15:46 UTC by Alois Klink
Modified: 2022-05-17 15:46 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alois Klink 2022-05-17 15:46:55 UTC
It looks like this error has already been fixed in the `master` branch: https://git.uclibc.org/uClibc++/commit/?id=6687fc9276fa52defaf8592f2001c19b826aec93

Still, I thought I'd document it since it took me quite a while of debugging to find the cause of this error (and maybe to gently nudge for a v0.2.6 release)

Building uClibc++ encodes the path to libsup and libgcc as a filename.
On most systems, the maximum filepath is longer than the maximum filename.

Linux defaults to 4096 for the max filepath length and 255 for the max filename length.

Using cross-compiling SDKs can easily create a filepath over 255 chars, and thus cause uClibc++ to fail to build due to maximum filepath errors.

This error has reached a few people using the OpenWRT SDK:
  - https://forum.openwrt.org/t/buid-package-uclibc-failed-by-using-openwrt-sdk/64377
  - https://lists.openwrt.org/pipermail/openwrt-devel/2021-May/035321.html
  - https://github.com/trojan-gfw/trojan/issues/588