pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/46410: devel/glib2 2.32.2 fails to compile on Solaris



>Number:         46410
>Category:       pkg
>Synopsis:       devel/glib2 2.32.2 fails to compile on Solaris
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May 04 12:10:00 +0000 2012
>Originator:     Jörn Clausen
>Release:        
>Organization:
University of Bielefeld
>Environment:
>Description:
I can't compile devel/glib2 on Solaris any longer. See pkg/41601 for reference.

  CC     unix.o
  CCLD   unix
  CCLD   unix-nothreads
  CC     include.o
In file included from 
/software/local/gcc/sunos5.10-x64/gcc-4.7.0/bin/../lib/gcc/i386-pc-solaris2.10/4.7.0/include-fixed/pthread.h:20:0,
                 from include.c:6:
/software/local/gcc/sunos5.10-x64/gcc-4.7.0/bin/../lib/gcc/i386-pc-solaris2.10/4.7.0/include-fixed/sys/feature_tests.h:341:2:
 error: #error "Compiler or options invalid for pre-UNIX 03 X/Open applications 
   and pre-2001 POSIX applications"
gmake[4]: *** [include.o] Error 1
gmake[4]: Leaving directory 
`/pkgsrc/source/pkgsrc/devel/glib2/work.pkgsrc-i86/glib-2.32.2/glib/tests'

After adding

CFLAGS.SunOS+= -D_XPG6

to Makefile, compilation breaks at

  CC     libgio_2_0_la-gsocket.lo
gsocket.c: In function 'g_socket_get_available_bytes':
gsocket.c:2391:32: error: 'FIONREAD' undeclared (first use in this function)
gsocket.c:2391:32: note: each undeclared identifier is reported only once for 
each function it appears in
gmake[4]: *** [libgio_2_0_la-gsocket.lo] Error 1

This is fixed by

#ifdef __sun__
#include <sys/filio.h>
#endif

in gio/gsocket.c. After that, compilation succeeds.
>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index