GNOME Bugzilla – Bug 336369
Build broken under NetBSD
Last modified: 2006-03-28 23:45:56 UTC
gdm does not build under NetBSD (3.99.16). The daemon/gdmconfig.c and daemon/server.c files use the setpriority(2) function so, according to the manual page, they have to include sys/resource.h. They currently do not include it. The problem is that these files use PRIO_MAX, PRIO_MIN and PRIO_PROCESS definitions, all of which are only defined by the sys/resource.h header file in the NetBSD operating system. The fix is trivial: include this header file in both files. I have checked NetBSD, Solaris and Linux, and all three have sys/resource.h, so including it does not seem to be a portability problem. In case you do not want to include it unconditionally, please DO NOT add a '#if defined(__NetBSD__)' to guard their inclusion. Just tell me and I'll came up with an appropriate configure patch (if it's really needed).
Created attachment 62227 [details] [review] Proposed patch.
Thanks, fixed in CVS head.