diff -r cb59d6afeb61 -r 0cd2ee160ef5 openpkg/rpm.patch.porting --- a/openpkg/rpm.patch.porting Tue Jan 06 23:40:39 2009 +0100 +++ b/openpkg/rpm.patch.porting Tue Jan 06 23:42:49 2009 +0100 @@ -1482,3 +1482,52 @@ #include /* The code at the top of get_date which figures out the offset of the + ++--------------------------------------------------------------------------- +| The following patch works around a general failure of RPM to +| adhere to the ISO C standard, for which newer GCC releases claim +| compile errors and fail. ++--------------------------------------------------------------------------- +Index: misc/err.h +--- misc/err.h 2009-01-06 22:48:16.104430941 +0100 ++++ misc/err.h 2009-01-06 22:47:55.944312482 +0100 +@@ -29,31 +29,4 @@ + # define __gnuc_va_list __ptr_t + #endif + +-__BEGIN_DECLS +- +-/* Print "program: ", FORMAT, ": ", the standard error string for errno, +- and a newline, on stderr. */ +-extern void warn __P ((__const char *__format, ...)) +- __attribute__ ((__format__ (__printf__, 1, 2))); +-extern void vwarn __P ((__const char *__format, __gnuc_va_list)) +- __attribute__ ((__format__ (__printf__, 1, 0))); +- +-/* Likewise, but without ": " and the standard error string. */ +-extern void warnx __P ((__const char *__format, ...)) +- __attribute__ ((__format__ (__printf__, 1, 2))); +-extern void vwarnx __P ((__const char *__format, __gnuc_va_list)) +- __attribute__ ((__format__ (__printf__, 1, 0))); +- +-/* Likewise, and then exit with STATUS. */ +-extern void err __P ((int __status, __const char *__format, ...)) +- __attribute__ ((__noreturn__, __format__ (__printf__, 2, 3))); +-extern void verr __P ((int __status, __const char *__format, __gnuc_va_list)) +- __attribute__ ((__noreturn__, __format__ (__printf__, 2, 0))); +-extern void errx __P ((int __status, __const char *__format, ...)) +- __attribute__ ((__noreturn__, __format__ (__printf__, 2, 3))); +-extern void verrx __P ((int __status, __const char *, __gnuc_va_list)) +- __attribute__ ((__noreturn__, __format__ (__printf__, 2, 0))); +- +-__END_DECLS +- + #endif /* err.h */ + ++--------------------------------------------------------------------------- +| Due to either GCC enforcing ISO C or faulty references in the +| rpmio component, Solaris 11 fails to build while compiling fts.c. +| Hack a custom 'dirent.h' as found in /usr/include, remove the +| line 104 'extern int dirfd(DIR *);' from the header file, and +| place in directory openpkg-`date +%Y%m%d`/rpm-/rpmio/. ++---------------------------------------------------------------------------