This is the mail archive of the mailing list for the newlib project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Path to fix MIPS build problem

On Thu, 2013-04-18 at 09:24 +0200, Corinna Vinschen wrote:
> On Apr 17 13:34, Steve Ellcey  wrote:

> In theory, yes.  I'm just a bit puzzled.  intptr_t and uintptr_t are
> defined in stdint.h, too.  Wouldn't it make sense to remove their
> definitions now in cfe_api.h as well?
> Thanks,
> Corinna

Yes, it would.  I didn't do that in my first patch because I didn't see
any warnings about them.  I think I didn't get any warning because the
typedefs in cfe_api.h show up before the typedefs in stdint.h and I
believe GCC suppresses warnings in system header files.  I took out the
definitions of intptr_t and uintptr_t and also the includes that were
only there to define the values used for int64_t, uint64_t, intptr_t,
and uintptr_t and everything still builds.

Steve Ellcey

Here is a new ChangeLog and diff:

2013-04-18  Steve Ellcey  <>

	* mips/cfe_api.h (int64_t): Remove define.
	(uint64_t): Remove define.
	(intptr_t): Remove define.
	(uintptr_t): Remove define.
	(sys/types.h): Remove include.
	(_ansi.h): Remove include.

diff --git a/libgloss/mips/cfe_api.h b/libgloss/mips/cfe_api.h
index afe4683..b17f929 100644
--- a/libgloss/mips/cfe_api.h
+++ b/libgloss/mips/cfe_api.h
@@ -59,13 +59,6 @@
  * CFE_API_* can be defined here as desired.
 /* Begin customization. */
-#include <sys/types.h>		/* for __uint64_t and __int64_t. */
-#define int64_t __int64_t
-#define uint64_t __int64_t
-#include <_ansi.h>		/* for _POINTER_INT. */
-typedef _POINTER_INT intptr_t;
-typedef unsigned _POINTER_INT uintptr_t;
 #include <string.h>
 #define cfe_strlen(s)	strlen(s)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]