Hi all,
I am working on issue #5420, “Reimplement POSIX passwd and group Entry APIs” (link: Reimplement POSIX passwd and group Entry APIs (#5420) · Issues · RTEMS / RTOS / RTEMS · GitLab).
I have been studying the current RTEMS files and comparing them with the FreeBSD implementation. At the moment, I have a working getgrent.c replacement and a getgrnam.c replacement that still keep the current RTEMS file split, and the psxpasswd01 test passes with these changes.
While reading the FreeBSD source, I noticed that the group-related non-_r interfaces such as getgrnam() and getgrgid() are implemented within getgrent.c, rather than being kept in separate source files.
Before I continue, I would like to ask about the preferred direction for RTEMS:
- Should I keep the current RTEMS file layout and continue with separate files such as
getgrent.candgetgrnam.c, while only reusing/adapting FreeBSD logic internally? - Or would it be preferable to also reorganize the RTEMS source layout to more closely follow the current FreeBSD structure, for example by merging the group-related non-
_rwrappers intogetgrent.c?
My current inclination is to keep the existing RTEMS file split unless there is a preference to change it, since that seems like the smaller structural change. If so, I would likely follow the same layout approach for the passwd-related files as well for consistency.
However, I wanted to confirm before moving further.
Thanks.