This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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]

[PATCH] sim/mcore/interp.c: Include "unistd.h" standard C header file to avoid compiling warnings.


The related warnings:

  gcc -DHAVE_CONFIG_H     -DPROFILE=1 -DWITH_PROFILE=-1          -DDEFAULT_INLINE=0              -I. -I../../../binutils-gdb/sim/mcore -I../common -I../../../binutils-gdb/sim/mcore/../common -I../../include -I../../../binutils-gdb/sim/mcore/../../include -I../../bfd -I../../../binutils-gdb/sim/mcore/../../bfd -I../../opcodes -I../../../binutils-gdb/sim/mcore/../../opcodes  -g -O2 -c -o interp.o -MT interp.o -MMD -MP -MF .deps/interp.Tpo ../../../binutils-gdb/sim/mcore/interp.c
../../../binutils-gdb/sim/mcore/interp.c: In function âhandle_trap1â:
../../../binutils-gdb/sim/mcore/interp.c:559:22: warning: implicit declaration of function âlinkâ [-Wimplicit-function-declaration]
         cpu.gr[RET1] = link ((char *) a[0], (char *) a[1]);
                        ^
  ../../../binutils-gdb/sim/mcore/interp.c:585:22: warning: implicit declaration of function âaccessâ [-Wimplicit-function-declaration]
         cpu.gr[RET1] = access ((char *) a[0], a[1]);
                        ^

2015-02-07  Chen Gang <gang.chen.5i5j@gmail.com>

	* mcore/interp.c: Include "unistd.h" standard C header file to
	avoid compiling warnings.
---
 sim/ChangeLog      | 5 +++++
 sim/mcore/interp.c | 1 +
 2 files changed, 6 insertions(+)

diff --git a/sim/ChangeLog b/sim/ChangeLog
index a891ce5..8a05ff7 100644
--- a/sim/ChangeLog
+++ b/sim/ChangeLog
@@ -1,3 +1,8 @@
+2015-02-07  Chen Gang <gang.chen.5i5j@gmail.com>
+
+	* mcore/interp.c: Include "unistd.h" standard C header file to
+	avoid compiling warnings.
+
 2015-02-02  Chen Gang <gang.chen.5i5j@gmail.com>
 
 	* microblaze/interp.c (sim_do_command): Call freeargv() before
diff --git a/sim/mcore/interp.c b/sim/mcore/interp.c
index dfaa6aa..7e2be0d 100644
--- a/sim/mcore/interp.c
+++ b/sim/mcore/interp.c
@@ -23,6 +23,7 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 #include <sys/times.h>
 #include <sys/param.h>
 #include <netinet/in.h>	/* for byte ordering macros */
+#include <unistd.h>
 #include "bfd.h"
 #include "gdb/callback.h"
 #include "libiberty.h"
-- 
1.9.3


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