changeset 31782:971b1ce234cd

Make the sys/cdio.h header test work by explictly including sys/types.h before. Broken headers are a Solaris and BSD tradition, hoping for them to get their act together is hopeless, so we work around it (for now at least).
author reimar
date Thu, 29 Jul 2010 08:44:44 +0000
parents 036d59b53de2
children 1d5af4fbd107
files configure
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Wed Jul 28 10:43:02 2010 +0000
+++ b/configure	Thu Jul 29 08:44:44 2010 +0000
@@ -3763,7 +3763,14 @@
 
 echocheck "sys/cdio.h"
 _cdio=no
-header_check sys/cdio.h && _cdio=yes
+cat > $TMPC << EOF
+// types.h needed to workaround broken headers
+// on e.g. OpenSolaris
+#include <sys/types.h>
+#include <sys/cdio.h>
+int main(void) { return 0; }
+EOF
+compile_check $TMPC && _cdio=yes
 if test "$_cdio" = yes ; then
   def_cdio='#define DVD_STRUCT_IN_SYS_CDIO_H 1'
 else