public inbox for bfd@sourceware.org
 help / color / mirror / Atom feed
From: manfred@s-direktnet.de
To: gas2@cygnus.com, bfd@cygnus.com
Subject: Patch for gas-980119 on m68k-motorola-sysv
Date: Wed, 21 Jan 1998 09:36:00 -0000	[thread overview]
Message-ID: <9801211709.AA08498@lts.sel.alcatel.de> (raw)

The   include files on  this system  aren't protected against multiple
inclusion; especially  <sys/stat.h> causes much grief. Another problem
is that gcc's fixed <stdlib.h> doesn't define  the `size_t' type where
-  at least - dwarf2.c  expects it to  be defined; anyway, IMHO and as
far  as I understood the  ANSI-C definition, it   should be defined in
<stddef.h> or, as a last resort, in <sys/types.h>.

This patch fixes these problems:

in bfd/:
Tue Jan 20 17:13:50 1998  Manfred Hollstein  <manfred@s-direktnet.de>

	* dwarf2.c: Include config.h to get the proper HAVE_..._H macros
	defined; then include stddef.h or sys/types.h to get size_t defined.

in ld/:
Wed Jan 21 17:49:29 1998  Manfred Hollstein  <manfred@s-direktnet.de>

	* emultempl/sunos.em: Don't include sys/types.h and sys/stat.h here;
	they are included already via sysdep.h.

diff --context --recursive --show-c-function -x *.o -x *.info* -x *.html* -x *.elc -x *.dvi -x *.orig -x *~ -x version.el gas-980119.orig/bfd/dwarf2.c gas-980119/bfd/dwarf2.c
*** gas-980119.orig/bfd/dwarf2.c	Mon Jan 19 10:12:36 1998
--- gas-980119/bfd/dwarf2.c	Tue Jan 20 16:21:06 1998
*************** You should have received a copy of the G
*** 28,35 ****
  along with this program; if not, write to the Free Software
  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
  
  #include <stdlib.h>
! 
  #include <stdio.h>
  #include "bfd.h"
  #include "libbfd.h"
--- 28,42 ----
  along with this program; if not, write to the Free Software
  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
  
+ #include "config.h"
+ #ifdef HAVE_STDDEF_H
+ #include <stddef.h>
+ #else
+ #include <sys/types.h>
+ #endif
+ #ifdef HAVE_STDLIB_H
  #include <stdlib.h>
! #endif
  #include <stdio.h>
  #include "bfd.h"
  #include "libbfd.h"
diff --context --recursive --show-c-function -x *.o -x *.info* -x *.html* -x *.elc -x *.dvi -x *.orig -x *~ -x version.el gas-980119.orig/ld/emultempl/sunos.em gas-980119/ld/emultempl/sunos.em
*** gas-980119.orig/ld/emultempl/sunos.em	Mon Jan 19 10:15:07 1998
--- gas-980119/ld/emultempl/sunos.em	Wed Jan 21 08:18:24 1998
*************** Foundation, Inc., 59 Temple Place - Suit
*** 27,34 ****
  #define TARGET_IS_${EMULATION_NAME}
  
  #include <ctype.h>
- #include <sys/types.h>
- #include <sys/stat.h>
  
  #include "bfd.h"
  #include "sysdep.h"
--- 27,32 ----

                 reply	other threads:[~1998-01-21  9:36 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9801211709.AA08498@lts.sel.alcatel.de \
    --to=manfred@s-direktnet.de \
    --cc=bfd@cygnus.com \
    --cc=gas2@cygnus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).