Bug 711

Summary: Build error with musl C library
Product: Sudo Reporter: Jörg Krause <joerg.krause>
Component: PackagingAssignee: Todd C. Miller <Todd.Miller>
Status: RESOLVED FIXED    
Severity: normal    
Priority: low    
Version: 1.8.14   
Hardware: PC   
OS: Linux   

Description Jörg Krause 2015-08-01 01:34:21 MDT
The musl C library is very strict with header includes. In sudo_util.h id_t is used so <sys/types.h> has to be included.

This is the error message if <sys/types.h> is NOT included in sudo_util.h:

In file included from ./sudo.h:39:0,
                 from ./preserve_fds.c:32:
../include/sudo_util.h:220:14: error: unknown type name 'id_t'
 __dso_public id_t sudo_strtoid_v1(const char *str, const char *sep, char **endp, const char **errstr);
              ^
Makefile:329: recipe for target 'preserve_fds.o' failed
Comment 1 Todd C. Miller 2015-08-02 20:00:40 MDT
Fixed in http://www.sudo.ws/repos/sudo/rev/fda95d9ca1e9
Comment 2 Todd C. Miller 2015-08-03 09:43:20 MDT
Verified working on Alpine Linux with musl libc.
Comment 3 Todd C. Miller 2015-11-01 15:27:05 MST
Fixed in sudo 1.8.15