[Top][All Lists]

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

Errors compiling fwriting.c on OSF/1

From: Albert Chin
Subject: Errors compiling fwriting.c on OSF/1
Date: Mon, 3 Jun 2013 20:44:19 -0500
User-agent: Mutt/1.5.20 (2009-06-14)

With latest gnulib:
  $ uname -a
  OSF1 gen V5.1 732 alpha
  $ ./gnulib-tool --test --with-tests fwriting
  source='../../gllib/freading.c' object='freading.o' libtool=no DEPDIR=.deps 
depmode=tru64 /bin/ksh ../../build-aux/depcomp  cc -DHAVE_CONFIG_H -I. 
-I../../gllib -I..  -DGNULIB_STRICT_CHECKING=1 -g -c ../../gllib/freading.c
  cc: Error: ../../gllib/freading.c, line 48: In this statement, "_IOREAD" is 
not declared. (undeclared)
    return (fp->_flag & _IOREAD) != 0;

The problem is that _OSF_SOURCE is required to expose _IOREAD. From
  #ifdef _OSF_SOURCE
  #define _IOREAD         0001
  #define _IOWRT          0002
  #define _IOMYBUF        0010
  #define _IOSTRG         0100
  #define _IONOFD         _IOSTRG         /* strange or no file descriptor */
  #define _IORW           0400
  #define _IOUNGETC       01000
  #define _IOINUSE        02000           /* new flag for _THREAD_SAFE */
  #define _IONONSTD       04000
  #define _IOCLOSE        010000
  #define _IOWINIT        020000
  #define _IOWSET         040000

What's the best way to fix this?

albert chin (address@hidden)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]