| Summary: | Patch to make busybox build on Hurd | ||
|---|---|---|---|
| Product: | Busybox | Reporter: | Michael Schierl <schierlm> |
| Component: | Other | Assignee: | unassigned |
| Status: | VERIFIED FIXED | ||
| Severity: | minor | CC: | busybox-cvs |
| Priority: | P5 | ||
| Version: | 1.32.x | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | Other | ||
| Host: | Target: | ||
| Build: | |||
| Attachments: |
Busybox patch
IP_PKTINFO patch |
||
|
Description
Michael Schierl
2020-07-18 21:26:13 UTC
(In reply to Michael Schierl from comment #0) > RLIMIT_NICE is undefined on Hurd, which is used in shell_common.c. Note that I took the liberty to reorder the limits list so that LIMIT_F_IDX can always stay at 2. This changes the order of "ulimit -a", which was matching bash. I applied most of your fixes. Please try current git. Created attachment 8711 [details]
IP_PKTINFO patch
As of commit cd48f0, compared to 1.32.0: 1) I needed to disable CONFIG_MAKEMIME and CONFIG_REFORMIME due to the not applied hunk to mailutils/mail.c, but I can live with that. 2) I also needed to disable CONFIG_FEATURE_DD_IBS_OBS as it depends on O_DIRECT, and I can also live with that 3) I can confirm that the limits work well and the order matches the order printed by bash (bash also prints -b and -p which are missing from busybox, but I can live wit that as well) 4) The biggest obstacle for me is that I also had to disable CONFIG_TRACEROUTE and CONFIG_TRACEROUTE6 which depend on IP_PKTINFO (even if that option is, if I can see correctly, only needed if CONFIG_FEATURE_TRACEROUTE_VERBOSE is active). I could live with a non-verbose traceroute, but having no traceroute at all is disappointing. This can be worked around by disabling the corresponding setsockopts call if CONFIG_FEATURE_TRACEROUTE_VERBOSE is unset. Patch is attached. The rest builds and (from a quick smoke test) works fine. (In reply to Michael Schierl from comment #3) > I can confirm that the limits work well and the order matches the order printed by bash (bash also prints -b and -p which are missing from busybox, but I can live wit that as well) My bash has no "ulimit -b". What is that? > This can be worked around by disabling the corresponding setsockopts call if CONFIG_FEATURE_TRACEROUTE_VERBOSE is unset. Patch is attached. Actually... we can disable much more for !VERBOSE case. I can confirm that it builds and runs fine as of commit ff4ca1. -b is "socket buffer size" (RLIMIT_SBSIZE). On Linux, my bash (binary) does not have it either. But it is in the source code: https://git.savannah.gnu.org/cgit/bash.git/tree/builtins/ulimit.def#n243 And you can see it live in action on Hurd, FreeBSD and maybe more OSes. |