uclibc++: fix compilation with long file paths
authorAlois Klink <alois@aloisklink.com>
Sat, 9 Jul 2022 19:16:00 +0000 (20:16 +0100)
committerPetr Štetiar <ynezz@true.cz>
Sun, 28 Aug 2022 05:53:56 +0000 (07:53 +0200)
commitf5db80a3ab387cc840f5602cc81d3c2028cb7401
tree9b665587481decf72c490af53ce080f5391d9bed
parentb93327c4692e605649ff1afade98899a9c4aa1ca
uclibc++: fix compilation with long file paths

Currently, uClic++ 0.2.5 fails to compile when using a long filepath.

For example, if the openwrt directory is in the path:
/tmp/this_directory_name_is_very_long/more_long_paths/.../openwrt,
then uclibc++ will cause a very obtuse error.

Although the uclibc++ makefiles do print a "File name too long" error,
it's not the final error that's printed, so it's a bit confusing:

> /bin/sh: 1:
> cannot create src/abi/libsupc/<SNIP>_libsupc++.a.dep: File name too long
> <SNIP: some other makefile output here>
> array_type_info.o: No such file or directory

Although OpenWRT 22.03 and current master branch have removed uClib++,
I thought I'd make a PR for OpenWRT 21.02, since I encountered it
and there seems to be quite a few other people experiencing the same issue.
It especially happens when using the SDK, (or when using an encrypted fs)
since the pre-packaged SDKs have very long filenames.

This patch is already in upstream [1], but has not yet been released.

[1]: https://git.busybox.net/uClibc++/commit/?id=6687fc9276fa52defaf8592f2001c19b826aec93

Signed-off-by: Alois Klink <alois@aloisklink.com>
package/libs/uclibc++/patches/006-buildsys-shorten-abi-deb-file-names.patch [new file with mode: 0644]