[Bug 13711] New: Android API 21+ missing definitions for wait3 and issetugid

bugzilla at busybox.net bugzilla at busybox.net
Thu Apr 1 00:15:52 UTC 2021


https://bugs.busybox.net/show_bug.cgi?id=13711

            Bug ID: 13711
           Summary: Android API 21+ missing definitions for wait3 and
                    issetugid
           Product: Busybox
           Version: unspecified
          Hardware: Other
                OS: Other
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
          Assignee: unassigned at busybox.net
          Reporter: osm0sis at outlook.com
                CC: busybox-cvs at busybox.net
  Target Milestone: ---

Created attachment 8871
  --> https://bugs.busybox.net/attachment.cgi?id=8871&action=edit
platform.h patch (1) for the reported issue

Linker error only occurs on arm64, x86_64 + mips64 with Android NDK building
with API 21+

miscutils/lib.a(time.o): In function `.L13':
time.c:(.text+0xe4): undefined reference to `wait3'
miscutils/lib.a(time.o): In function `.L19':
time.c:(.text+0x104): undefined reference to `wait3'
collect2.exe: error: ld returned 1 exit status
make: *** [Makefile:719: busybox_unstripped] Error 1

I've got a patch for this to wrap wait3 to wait4, and add the stub definition
for issetugid on Android API 21+ which helps with adding glob for hush support.

Then supporting both the unified and deprecated Android NDK headers needs a
further tweak to avoid this error:

  CC      libbb/platform.o
libbb/platform.c:218:5: error: conflicting types for 'issetugid'
 int issetugid(void)
     ^
In file included from include/libbb.h:13:0,
                 from libbb/platform.c:9:
include/platform.h:624:12: note: previous declaration of 'issetugid' was here
 extern int issetugid(void) FAST_FUNC;
            ^
make[1]: *** [scripts/Makefile.build:198: libbb/platform.o] Error 1

John Wu, aka. topjohnwu, the Magisk/Android root dev submitted another patch to
resolve this, so I've included it as well so hopefully both can be included to
retain his authorship.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the busybox-cvs mailing list