This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: Why does bfd/trad-core.c include <sys/dir.h>?
- To: ac131313 at cygnus dot com
- Subject: Re: Why does bfd/trad-core.c include <sys/dir.h>?
- From: Ian Lance Taylor <ian at zembu dot com>
- Date: 20 Apr 2000 09:52:56 -0700
- CC: binutils at sourceware dot cygnus dot com
- References: <38FEA80D.4629EDDA@cygnus.com>
Date: Thu, 20 Apr 2000 16:47:41 +1000
From: Andrew Cagney <ac131313@cygnus.com>
bfd/trad-core.c includes <sys/dir.h> (unconditionally). My Solaris
2.5.1 machine tells me:
/usr/include/sys/dir.h:41: warning: #warning "The information in this
file should be obtained from <dirent.h>"
/usr/include/sys/dir.h:42: warning: #warning "and is provided solely
(and temporarily) for backward compatibility."
what really puzzles me is that I can't see any obvious <dirent.h>
dependant code in the file.
I believe that on some systems you must include <sys/dir.h> before
including <sys/user.h>. I'm not completly certain about that, though.
In any case, the fix is straightforward. Copy the HAVE_DIRENT_H
handling from hpux-core.c.
Ian