Bug 15235 - libgfortran doesn't build on Solaris 10
Summary: libgfortran doesn't build on Solaris 10
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: libfortran (show other bugs)
Version: tree-ssa
: P2 normal
Target Milestone: 4.0.1
Assignee: Not yet assigned to anyone
URL:
Keywords: build
: 15465 (view as bug list)
Depends on: 15234 21315
Blocks: 15930 16991 19292
  Show dependency treegraph
 
Reported: 2004-04-30 20:04 UTC by Rainer Orth
Modified: 2005-05-31 16:43 UTC (History)
3 users (show)

See Also:
Host:
Target: *-*-solaris2.10
Build:
Known to work:
Known to fail:
Last reconfirmed: 2005-04-02 00:19:05


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Orth 2004-04-30 20:04:45 UTC
Bootstrapping current tree-ssa branch with gmp 4.1.3 on i386-pc-solaris2.10
fails compiling libgfortran/runtime/environ.c:

In file included from /vol/gnu/src/gcc/gcc-tree-ssa-dist/libgfortran/runtime/environ.c:26:
/vol/gnu/src/gcc/gcc-tree-ssa-dist/libgfortran/libgfortran.h:53: error: conflicting types for 'offset_t'
/vol/gcc/obj/gcc-3.5-tree-ssa-20040429/10-gcc/gcc/include/sys/types.h:233: error: previous declaration of 'offset_t' was here

This error is similar to one reported as PR libfortran/15234 on Tru64 UNIX.
Obviously it is a recipe for disaster to use *_t type names on POSIX.1/Unix
systems ;-(

Environment:
System: SunOS erebus 5.10 s10_54 i86pc i386 i86pc
Architecture: i86pc

	
host: i386-pc-solaris2.10
build: i386-pc-solaris2.10
target: i386-pc-solaris2.10
configured with: /vol/gnu/src/gcc/gcc-tree-ssa-dist/configure --prefix=/vol/gcc --with-local-prefix=/vol/gcc --disable-nls --with-as=/vol/gcc/lib/as-7.0 --disable-libmudflap --with-gmp-dir=/vol/gnu/obj/gmp-4.1.3

How-To-Repeat:
Bootstrap the tree-ssa branch on Solaris 10 as described above.
Comment 1 Andrew Pinski 2004-04-30 20:10:44 UTC
Confirmed, the definition for offset_t is wrong:
#if HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
typedef off_t offset_t;
Comment 2 Tobias Schlüter 2004-05-14 15:54:45 UTC
Is offset_t a macro on Solaris? Then we could maybe replace the typedef by
#ifndef offset_t
#define offset_t off_t
#endif
? 

Does Solaris have off_t? Maybe it would be the smartest to just use off_t
instead of offset_t.

libstdc++ handles this by defining __off_t in system-dependent headers and then
using this. We could also copy this.

Maybe an autoconf test is in place here?
Comment 3 Rainer Orth 2004-05-14 16:16:48 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on Solaris 10/x86

tobi at gcc dot gnu dot org writes:

> Is offset_t a macro on Solaris? Then we could maybe replace the typedef by
> #ifndef offset_t
> #define offset_t off_t
> #endif
> ? 

No, it's a typedef in <sys/types.h>, which clashes with the libgfortran.h
definition:

typedef longlong_t      offset_t;

vs.

typedef off_t offset_t;

> Does Solaris have off_t? Maybe it would be the smartest to just use off_t
> instead of offset_t.

Certainly: off_t is in POSIX.1, and I currently see no reason to invent
anything g95 specific.  If there is, the type should be called gfc_offset_t
or something like this to avoid the clashes.

> libstdc++ handles this by defining __off_t in system-dependent headers and then
> using this. We could also copy this.
> 
> Maybe an autoconf test is in place here?

Depends on what is desired here.

	Rainer
Comment 4 Tobias Schlüter 2004-05-14 17:13:40 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on
 Solaris 10/x86

ro at techfak dot uni-bielefeld dot de wrote:
> 
> Certainly: off_t is in POSIX.1, and I currently see no reason to invent
> anything g95 specific.  If there is, the type should be called gfc_offset_t
> or something like this to avoid the clashes.
> 
> 
Yeah, seems like this is the right thing to do. I will prepare a patch 
to this effect later today. I.e. use off_t in all places.

Besides, I'm curious, is offset_t different from off_t on Solaris?

- Tobi

Comment 5 Rainer Orth 2004-05-14 17:17:38 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on Solaris 10/x86

Tobias dot Schlueter at physik dot uni-muenchen dot de writes:

> Yeah, seems like this is the right thing to do. I will prepare a patch 
> to this effect later today. I.e. use off_t in all places.

Fine, thanks.

> Besides, I'm curious, is offset_t different from off_t on Solaris?

Yes, off_t can be 32 bit or 64 bit: always 64 bit for 64-bit compilations,
either one for 32-bit compilations, depending on large file support, while
offset_t is always 64 bit:

/*
 * The size of off_t and related types depends on the setting of
 * _FILE_OFFSET_BITS.  (Note that other system headers define other types
 * related to those defined here.)
[...]

#if defined(_LP64) || _FILE_OFFSET_BITS == 32
typedef long            off_t;          /* offsets within files */
#elif _FILE_OFFSET_BITS == 64
typedef longlong_t      off_t;          /* offsets within files */
#endif

	Rainer
Comment 6 Tobias Schlüter 2004-05-14 17:24:59 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on
 Solaris 10/x86

ro at techfak dot uni-bielefeld dot de wrote:
> 
>>Besides, I'm curious, is offset_t different from off_t on Solaris?
> 
> 
> Yes, off_t can be 32 bit or 64 bit: always 64 bit for 64-bit compilations,
> either one for 32-bit compilations, depending on large file support, while
> offset_t is always 64 bit:
> 

Hm, isn't offset offset_t actually preferable in that case? I'll prepare 
my patch but we should think about this.

- Tobi
Comment 7 Rainer Orth 2004-05-14 17:29:45 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on Solaris 10/x86

Tobias dot Schlueter at physik dot uni-muenchen dot de writes:

> Hm, isn't offset offset_t actually preferable in that case? I'll prepare 
> my patch but we should think about this.

no way!  What libgfortran actually should do is detect if the target
platform has largefile support and use that if available.  But this isn't
an interface change, just define the appropriate macros.  There's actually
an autoconf macro for this: AC_SYS_LARGEFILE.  See its documentation for
details.

	Rainer
Comment 8 Tobias Schlüter 2004-05-14 18:06:37 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on
 Solaris 10/x86

ro at techfak dot uni-bielefeld dot de wrote:
> no way!  What libgfortran actually should do is detect if the target
> platform has largefile support and use that if available.  But this isn't
> an interface change, just define the appropriate macros.  There's actually
> an autoconf macro for this: AC_SYS_LARGEFILE.  See its documentation for
> details.

Ah, ok.

I attached a cvs diff made in libgfortran/ with the change offset_t -> 
off_t, compiled on i686-pc-linux-gnu. If you could confirm that it works 
I will post this to the lists.

- Tobi


? libdiff
? io/sedtUhMSE
Index: libgfortran.h
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/libgfortran.h,v
retrieving revision 1.2
diff -u -p -r1.2 libgfortran.h
--- libgfortran.h	13 May 2004 06:40:59 -0000	1.2
+++ libgfortran.h	14 May 2004 18:01:49 -0000
@@ -50,7 +50,6 @@ Boston, MA 02111-1307, USA.  */
 #if HAVE_SYS_TYPES_H
 #include <sys/types.h>
 #endif
-typedef off_t offset_t;
 
 #ifndef NULL
 #define NULL (void *) 0
Index: io/backspace.c
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/io/backspace.c,v
retrieving revision 1.2
diff -u -p -r1.2 backspace.c
--- io/backspace.c	13 May 2004 06:41:02 -0000	1.2
+++ io/backspace.c	14 May 2004 18:01:49 -0000
@@ -34,7 +34,7 @@ Boston, MA 02111-1307, USA.  */
 static void
 formatted_backspace (void)
 {
-  offset_t base;
+  off_t base;
   char *p;
   int n;
 
@@ -92,12 +92,12 @@ io_error:
 static void
 unformatted_backspace (void)
 {
-  offset_t *p, new;
+  off_t *p, new;
   int length;
 
-  length = sizeof (offset_t);
+  length = sizeof (off_t);
 
-  p = (offset_t *) salloc_r_at (current_unit->s, &length,
+  p = (off_t *) salloc_r_at (current_unit->s, &length,
 				file_position (current_unit->s) - length);
   if (p == NULL)
     goto io_error;
Index: io/io.h
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/io/io.h,v
retrieving revision 1.2
diff -u -p -r1.2 io.h
--- io/io.h	13 May 2004 06:41:02 -0000	1.2
+++ io/io.h	14 May 2004 18:01:50 -0000
@@ -42,11 +42,11 @@ try;
 
 typedef struct stream
 {
-  char *(*alloc_w_at) (struct stream *, int *, offset_t);
-  char *(*alloc_r_at) (struct stream *, int *, offset_t);
+  char *(*alloc_w_at) (struct stream *, int *, off_t);
+  char *(*alloc_r_at) (struct stream *, int *, off_t);
     try (*sfree) (struct stream *);
     try (*close) (struct stream *);
-    try (*seek) (struct stream *, offset_t);
+    try (*seek) (struct stream *, off_t);
     try (*truncate) (struct stream *);
 }
 stream;
@@ -269,7 +269,7 @@ typedef struct unit_t
   endfile;
 
   unit_flags flags;
-  offset_t recl, last_record, maxrec, bytes_left;
+  off_t recl, last_record, maxrec, bytes_left;
 
   /* recl           -- Record length of the file.
      last_record    -- Last record number read or written
@@ -288,7 +288,7 @@ typedef struct
 {
   int in_library;       /* Nonzero if a library call is being processed.  */
   int size;	/* Bytes processed by the current data-transfer statement.  */
-  offset_t max_offset;	/* Maximum file offset.  */
+  off_t max_offset;	/* Maximum file offset.  */
   int item_count;	/* Item number in a formatted data transfer.  */
   int reversion_flag;	/* Format reversion has occurred.  */
   int first_item;
@@ -445,10 +445,10 @@ const char *inquire_write (const char *,
 const char *inquire_readwrite (const char *, int);
 
 #define file_length prefix(file_length)
-offset_t file_length (stream *);
+off_t file_length (stream *);
 
 #define file_position prefix(file_position)
-offset_t file_position (stream *);
+off_t file_position (stream *);
 
 #define is_seekable prefix(is_seekable)
 int is_seekable (stream *);
Index: io/transfer.c
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/io/transfer.c,v
retrieving revision 1.2
diff -u -p -r1.2 transfer.c
--- io/transfer.c	13 May 2004 06:41:02 -0000	1.2
+++ io/transfer.c	14 May 2004 18:01:53 -0000
@@ -792,13 +792,13 @@ transfer_complex (void *p, int kind)
 static void
 us_read (void)
 {
-  offset_t *p;
+  off_t *p;
   int n;
 
-  n = sizeof (offset_t);
-  p = (offset_t *) salloc_r (current_unit->s, &n);
+  n = sizeof (off_t);
+  p = (off_t *) salloc_r (current_unit->s, &n);
 
-  if (p == NULL || n != sizeof (offset_t))
+  if (p == NULL || n != sizeof (off_t))
     {
       generate_error (ERROR_BAD_US, NULL);
       return;
@@ -815,11 +815,11 @@ us_read (void)
 static void
 us_write (void)
 {
-  offset_t *p;
+  off_t *p;
   int length;
 
-  length = sizeof (offset_t);
-  p = (offset_t *) salloc_w (current_unit->s, &length);
+  length = sizeof (off_t);
+  p = (off_t *) salloc_w (current_unit->s, &length);
 
   if (p == NULL)
     {
@@ -1111,13 +1111,13 @@ static void
 next_record_r (int done)
 {
   int rlength, length;
-  offset_t new;
+  off_t new;
   char *p;
 
   switch (current_mode ())
     {
     case UNFORMATTED_SEQUENTIAL:
-      current_unit->bytes_left += sizeof (offset_t);	/* Skip over tail */
+      current_unit->bytes_left += sizeof (off_t);	/* Skip over tail */
 
       /* Fall through */
 
@@ -1198,7 +1198,7 @@ next_record_r (int done)
 static void
 next_record_w (int done)
 {
-  offset_t c, m;
+  off_t c, m;
   int length;
   char *p;
 
@@ -1225,7 +1225,7 @@ next_record_w (int done)
       m = current_unit->recl - current_unit->bytes_left; /* Bytes written */
       c = file_position (current_unit->s);
 
-      length = sizeof (offset_t);
+      length = sizeof (off_t);
 
       /* Write the length tail */
 
@@ -1233,7 +1233,7 @@ next_record_w (int done)
       if (p == NULL)
 	goto io_error;
 
-      *((offset_t *) p) = m;
+      *((off_t *) p) = m;
       if (sfree (current_unit->s) == FAILURE)
 	goto io_error;
 
@@ -1243,13 +1243,13 @@ next_record_w (int done)
       if (p == NULL)
 	generate_error (ERROR_OS, NULL);
 
-      *((offset_t *) p) = m;
+      *((off_t *) p) = m;
       if (sfree (current_unit->s) == FAILURE)
 	goto io_error;
 
       /* Seek past the end of the current record */
 
-      if (sseek (current_unit->s, c + sizeof (offset_t)) == FAILURE)
+      if (sseek (current_unit->s, c + sizeof (off_t)) == FAILURE)
 	goto io_error;
 
       break;
Index: io/unit.c
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/io/unit.c,v
retrieving revision 1.2
diff -u -p -r1.2 unit.c
--- io/unit.c	13 May 2004 06:41:02 -0000	1.2
+++ io/unit.c	14 May 2004 18:01:53 -0000
@@ -289,7 +289,7 @@ is_internal_unit ()
 void
 init_units (void)
 {
-  offset_t m, n;
+  off_t m, n;
   unit_t *u;
   int i;
 
@@ -336,13 +336,13 @@ init_units (void)
     }
 
   /* Calculate the maximum file offset in a portable manner.
-   * max will be the largest signed number for the type offset_t.
+   * max will be the largest signed number for the type off_t.
    *
    * set a 1 in the LSB and keep a running sum, stopping at MSB-1 bit. */
 
   g.max_offset = 0;
   for (i=0; i < sizeof(g.max_offset) * 8 - 1; i++)
-    g.max_offset = g.max_offset + ((offset_t) 1 << i);
+    g.max_offset = g.max_offset + ((off_t) 1 << i);
 
 }
 
Index: io/unix.c
===================================================================
RCS file: /cvs/gcc/gcc/libgfortran/io/unix.c,v
retrieving revision 1.2
diff -u -p -r1.2 unix.c
--- io/unix.c	13 May 2004 06:41:02 -0000	1.2
+++ io/unix.c	14 May 2004 18:01:53 -0000
@@ -86,11 +86,11 @@ typedef struct
   stream st;
 
   int fd;
-  offset_t buffer_offset;	/* File offset of the start of the buffer */
-  offset_t physical_offset;	/* Current physical file offset */
-  offset_t logical_offset;	/* Current logical file offset */
-  offset_t dirty_offset;	/* Start of modified bytes in buffer */
-  offset_t file_length;		/* Length of the file, -1 if not seekable. */
+  off_t buffer_offset;	/* File offset of the start of the buffer */
+  off_t physical_offset;	/* Current physical file offset */
+  off_t logical_offset;	/* Current logical file offset */
+  off_t dirty_offset;	/* Start of modified bytes in buffer */
+  off_t file_length;		/* Length of the file, -1 if not seekable. */
 
   char *buffer;
   int len;			/* Physical length of the current buffer */
@@ -293,7 +293,7 @@ fd_flush (unix_stream * s)
  * to come next. */
 
 static void
-fd_alloc (unix_stream * s, offset_t where, int *len)
+fd_alloc (unix_stream * s, off_t where, int *len)
 {
   char *new_buffer;
   int n, read_len;
@@ -344,9 +344,9 @@ fd_alloc (unix_stream * s, offset_t wher
  * NULL on I/O error. */
 
 static char *
-fd_alloc_r_at (unix_stream * s, int *len, offset_t where)
+fd_alloc_r_at (unix_stream * s, int *len, off_t where)
 {
-  offset_t m;
+  off_t m;
   int n;
 
   if (where == -1)
@@ -389,9 +389,9 @@ fd_alloc_r_at (unix_stream * s, int *len
  * we've already buffered the data or we need to load it. */
 
 static char *
-fd_alloc_w_at (unix_stream * s, int *len, offset_t where)
+fd_alloc_w_at (unix_stream * s, int *len, off_t where)
 {
-  offset_t n;
+  off_t n;
 
   if (where == -1)
     where = s->logical_offset;
@@ -444,7 +444,7 @@ fd_sfree (unix_stream * s)
 
 
 static int
-fd_seek (unix_stream * s, offset_t offset)
+fd_seek (unix_stream * s, off_t offset)
 {
 
   s->physical_offset = s->logical_offset = offset;
@@ -551,9 +551,9 @@ mmap_flush (unix_stream * s)
  * guaranteed to be mappable. */
 
 static try
-mmap_alloc (unix_stream * s, offset_t where, int *len)
+mmap_alloc (unix_stream * s, off_t where, int *len)
 {
-  offset_t offset;
+  off_t offset;
   int length;
   char *p;
 
@@ -578,9 +578,9 @@ mmap_alloc (unix_stream * s, offset_t wh
 
 
 static char *
-mmap_alloc_r_at (unix_stream * s, int *len, offset_t where)
+mmap_alloc_r_at (unix_stream * s, int *len, off_t where)
 {
-  offset_t m;
+  off_t m;
 
   if (where == -1)
     where = s->logical_offset;
@@ -605,7 +605,7 @@ mmap_alloc_r_at (unix_stream * s, int *l
 
 
 static char *
-mmap_alloc_w_at (unix_stream * s, int *len, offset_t where)
+mmap_alloc_w_at (unix_stream * s, int *len, off_t where)
 {
   if (where == -1)
     where = s->logical_offset;
@@ -632,7 +632,7 @@ mmap_alloc_w_at (unix_stream * s, int *l
 
 
 static int
-mmap_seek (unix_stream * s, offset_t offset)
+mmap_seek (unix_stream * s, off_t offset)
 {
 
   s->logical_offset = offset;
@@ -719,9 +719,9 @@ mmap_open (unix_stream * s)
 
 
 static char *
-mem_alloc_r_at (unix_stream * s, int *len, offset_t where)
+mem_alloc_r_at (unix_stream * s, int *len, off_t where)
 {
-  offset_t n;
+  off_t n;
 
   if (where == -1)
     where = s->logical_offset;
@@ -743,9 +743,9 @@ mem_alloc_r_at (unix_stream * s, int *le
 
 
 static char *
-mem_alloc_w_at (unix_stream * s, int *len, offset_t where)
+mem_alloc_w_at (unix_stream * s, int *len, off_t where)
 {
-  offset_t m;
+  off_t m;
 
   if (where == -1)
     where = s->logical_offset;
@@ -762,7 +762,7 @@ mem_alloc_w_at (unix_stream * s, int *le
 
 
 static int
-mem_seek (unix_stream * s, offset_t offset)
+mem_seek (unix_stream * s, off_t offset)
 {
 
   if (offset > s->file_length)
@@ -1366,7 +1366,7 @@ inquire_readwrite (const char *string, i
 
 /* file_length()-- Return the file length in bytes, -1 if unknown */
 
-offset_t
+off_t
 file_length (stream * s)
 {
 
@@ -1376,7 +1376,7 @@ file_length (stream * s)
 
 /* file_position()-- Return the current position of the file */
 
-offset_t
+off_t
 file_position (stream * s)
 {
 
Comment 9 Tobias Schlüter 2004-05-14 18:08:10 UTC
I'm sorry, I thought attachments to e-mails would end up as attachments to a bug.
Comment 10 Andrew Pinski 2004-05-15 16:20:55 UTC
*** Bug 15465 has been marked as a duplicate of this bug. ***
Comment 11 Rainer Orth 2004-05-17 13:40:16 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on Solaris 10/x86

Tobias dot Schlueter at physik dot uni-muenchen dot de writes:

> I attached a cvs diff made in libgfortran/ with the change offset_t -> 
> off_t, compiled on i686-pc-linux-gnu. If you could confirm that it works 
> I will post this to the lists.

The patch applied cleanly (except for an obvious conflict in io/unit.c),
and allowed libgfortran to build on i386-pc-solaris2.10.

Bootstrap is still running, so I'll have testsuite results later.

Thanks.
	Rainer
Comment 12 GCC Commits 2004-05-18 16:06:24 UTC
Subject: Bug 15235

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	tobi@gcc.gnu.org	2004-05-18 16:06:11

Modified files:
	libgfortran    : ChangeLog libgfortran.h 
	libgfortran/io : backspace.c io.h transfer.c unit.c unix.c 

Log message:
	PR fortran/15235
	* gfortran.h (offset_t): Rename to ...
	(gfc_offset): ... this.
	* io/backspace.c (formatted_backspace, unformatted_backspace),
	io/io.h (stream, gfc_unit, global_t, file_length, file_position),
	transfer.c (us_read, us_write, next_record_r, next_record_w),
	io/unit.c (init_units), unix.c (unix_stream, fd_alloc,
	fd_alloc_r_at, fd_alloc_w_at, fd_seek, mmap_alloc,
	mmap_alloc_r_at, mmap_alloc_w_at, mmap_seek, mem_alloc_r_at,
	mem_alloc_w_at, mem_seek, file_length, file_position): Replace all
	occurences of offset_t by gfc_offset.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/ChangeLog.diff?cvsroot=gcc&r1=1.12&r2=1.13
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/libgfortran.h.diff?cvsroot=gcc&r1=1.3&r2=1.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/backspace.c.diff?cvsroot=gcc&r1=1.3&r2=1.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/io.h.diff?cvsroot=gcc&r1=1.4&r2=1.5
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/transfer.c.diff?cvsroot=gcc&r1=1.4&r2=1.5
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/unit.c.diff?cvsroot=gcc&r1=1.3&r2=1.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/unix.c.diff?cvsroot=gcc&r1=1.4&r2=1.5

Comment 13 Tobias Schlüter 2004-05-18 16:28:06 UTC
Just for the record: it remains the issue of isinf() not being present on
Solaris, patch here: http://gcc.gnu.org/ml/fortran/2004-05/msg00234.html
Comment 14 Rainer Orth 2004-05-18 16:42:24 UTC
Subject: Re:  [gfortran] libgfortran doesn't build on Solaris

tobi at gcc dot gnu dot org writes:

> Just for the record: it remains the issue of isinf() not being present on
> Solaris, patch here: http://gcc.gnu.org/ml/fortran/2004-05/msg00234.html

Unfortunately, this patch doesn't help on Solaris 10, but due to an
unrelated problem: <iso/math_c99.h> (included by <math.h>) unconditionally
defines

#undef  isnan
#define isnan(x)        __builtin_isnan(x)

but GCC doesn't provide __builtin_isnan, so we again get link failures.

This is obviously a problem with the Sun headers which don't accomodate
non-Sun C99 compilers.  I may file a bug report for this, but apart from
that, this is fixincludes material.

I'm running another bootstrap on sparc-sun-solaris2.8 which doesn't have
this issue.

	Rainer
Comment 15 Tobias Schlüter 2004-09-20 16:12:13 UTC
(In reply to comment #14)
> I'm running another bootstrap on sparc-sun-solaris2.8 which doesn't have
> this issue.
> 
> 	Rainer
> 

I don't know if I missed this. Any news here?
Comment 16 Tobias Schlüter 2004-09-27 14:29:08 UTC
GCC does have __builtin_isnan (from builtins.def):

DEF_C99_C90RES_BUILTIN (BUILT_IN_ISNAN, "isnan", BT_FN_INT_VAR,
ATTR_CONST_NOTHROW_LIST)
DEF_EXT_LIB_BUILTIN    (BUILT_IN_ISNANF, "isnanf", BT_FN_INT_FLOAT,
ATTR_CONST_NOTHROW_LIST)
DEF_EXT_LIB_BUILTIN    (BUILT_IN_ISNANL, "isnanl", BT_FN_INT_LONGDOUBLE,
ATTR_CONST_NOTHROW_LIST)

I'm not sure if this is a recent addition. Can you verify if the problem is
still present?
Comment 17 Andrew Pinski 2004-12-27 14:46:28 UTC
What is the current status about this one aka what is the current error or is it fixed?
Comment 18 Eric Botcazou 2005-01-01 12:14:03 UTC
Libgfortran builds on SPARC/Solaris 2.5.1, 2.6, 7, 8 and 9 as of today.  I have
no info for Solaris 10 yet.
Comment 19 Eric Botcazou 2005-05-31 16:43:59 UTC
Libgfortran now builds and runs on Solaris 10 (last problem was PR target/21315).