Well, clearly we need to address this somehow.
That said, I cannot fathom why glibc is taking it upon themselves to deprecate a standard function. The documented justification:
It is expected that a future version of POSIX.1 will make readdir_r() obsolete, and require that readdir() be thread-safe when concurrently employed on different directory streams.
seems twisted, since the key point is that the current standard does no such thing. It strikes me as odd that a libc implementation would intentionally break their previous compatibility with the actual existing standard, in the hope that their vision for a different standard will become reality and provide absolution.
Anyway, on to what this would mean for the guacamole-server source:
In cases where multiple threads must read from the same directory stream, using readdir(3) with external synchronization is still preferable to the use of readdir_r(), for the reasons given in the points above.
Using readdir() instead of readdir_r() will require adding additional synchronization to prevent client threads trampling each other during concurrent directory reads.