* [patch] Build failure sim/rx on OSX.
@ 2010-01-30 2:23 Masaki Muranaka
2010-02-01 7:19 ` Joel Brobecker
2010-02-02 1:43 ` DJ Delorie
0 siblings, 2 replies; 8+ messages in thread
From: Masaki Muranaka @ 2010-01-30 2:23 UTC (permalink / raw)
To: gdb-patches
[-- Attachment #1: Type: text/plain, Size: 688 bytes --]
Hello maintainers,
There are three issues on sim/rx.
1. A committer have forgot run autoheader.
2. There doesn't use config.h in main.c.
3. We should check if the host has getopt.h
The attached patch is enough to build on OSX host.
It's possible there are another issues around portability there.
Thanks,
sim/rx/ChangeLog
2010-01-30 Masaki Muranaka <monaka@monami-software.com>
* configure.in: Check if the host has getopt.h.
* configure.in: Regenerate.
* config.in: Regenerate.
* main.c: Include config.h
Use HAVE_STDLIB_H, HAVE_UNISTD_H, HAVE_GETOPT_H.
Include getopt.h in case HAVE_GETOPT_H is defined.
--
Masaki Muranaka
Monami software
[-- Attachment #2: rx-sim-host-osx.diff --]
[-- Type: application/octet-stream, Size: 4576 bytes --]
diff --git a/sim/rx/config.in b/sim/rx/config.in
index e69de29..f71c45f 100644
--- a/sim/rx/config.in
+++ b/sim/rx/config.in
@@ -0,0 +1,107 @@
+/* config.in. Generated from configure.in by autoheader. */
+
+/* Define to 1 if translation of program messages to the user's native
+ language is requested. */
+#undef ENABLE_NLS
+
+/* Define to 1 if you have the <dlfcn.h> header file. */
+#undef HAVE_DLFCN_H
+
+/* Define to 1 if you have the <errno.h> header file. */
+#undef HAVE_ERRNO_H
+
+/* Define to 1 if you have the <fcntl.h> header file. */
+#undef HAVE_FCNTL_H
+
+/* Define to 1 if you have the <fpu_control.h> header file. */
+#undef HAVE_FPU_CONTROL_H
+
+/* Define to 1 if you have the <getopt.h> header file. */
+#undef HAVE_GETOPT_H
+
+/* Define to 1 if you have the `getrusage' function. */
+#undef HAVE_GETRUSAGE
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#undef HAVE_INTTYPES_H
+
+/* Define to 1 if you have the `nsl' library (-lnsl). */
+#undef HAVE_LIBNSL
+
+/* Define to 1 if you have the `socket' library (-lsocket). */
+#undef HAVE_LIBSOCKET
+
+/* Define to 1 if you have the <memory.h> header file. */
+#undef HAVE_MEMORY_H
+
+/* Define to 1 if you have the `sigaction' function. */
+#undef HAVE_SIGACTION
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#undef HAVE_STDINT_H
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#undef HAVE_STDLIB_H
+
+/* Define to 1 if you have the <strings.h> header file. */
+#undef HAVE_STRINGS_H
+
+/* Define to 1 if you have the <string.h> header file. */
+#undef HAVE_STRING_H
+
+/* Define to 1 if you have the <sys/resource.h> header file. */
+#undef HAVE_SYS_RESOURCE_H
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#undef HAVE_SYS_STAT_H
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#undef HAVE_SYS_TIME_H
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#undef HAVE_SYS_TYPES_H
+
+/* Define to 1 if you have the `time' function. */
+#undef HAVE_TIME
+
+/* Define to 1 if you have the <time.h> header file. */
+#undef HAVE_TIME_H
+
+/* Define to 1 if you have the <unistd.h> header file. */
+#undef HAVE_UNISTD_H
+
+/* Define to 1 if you have the <zlib.h> header file. */
+#undef HAVE_ZLIB_H
+
+/* Define to 1 if you have the `__setfpucw' function. */
+#undef HAVE___SETFPUCW
+
+/* Define to the address where bug reports for this package should be sent. */
+#undef PACKAGE_BUGREPORT
+
+/* Define to the full name of this package. */
+#undef PACKAGE_NAME
+
+/* Define to the full name and version of this package. */
+#undef PACKAGE_STRING
+
+/* Define to the one symbol short name of this package. */
+#undef PACKAGE_TARNAME
+
+/* Define to the home page for this package. */
+#undef PACKAGE_URL
+
+/* Define to the version of this package. */
+#undef PACKAGE_VERSION
+
+/* Additional package description */
+#undef PKGVERSION
+
+/* Bug reporting address */
+#undef REPORT_BUGS_TO
+
+/* Define as the return type of signal handlers (`int' or `void'). */
+#undef RETSIGTYPE
+
+/* Define to 1 if you have the ANSI C header files. */
+#undef STDC_HEADERS
diff --git a/sim/rx/configure b/sim/rx/configure
index 58e42de..56d03ac 100755
--- a/sim/rx/configure
+++ b/sim/rx/configure
@@ -4517,6 +4517,19 @@ sim_link_files="${sim_link_files} ${TARG_VALS_DEF}"
sim_link_links="${sim_link_links} targ-vals.def"
+for ac_header in getopt.h
+do :
+ ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
+if test "x$ac_cv_header_getopt_h" = x""yes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_GETOPT_H 1
+_ACEOF
+
+fi
+
+done
+
+
ac_sources="$sim_link_files"
ac_dests="$sim_link_links"
diff --git a/sim/rx/configure.in b/sim/rx/configure.in
index c97270a..7c51815 100644
--- a/sim/rx/configure.in
+++ b/sim/rx/configure.in
@@ -21,6 +21,7 @@ dnl
AC_PREREQ(2.5)dnl
AC_INIT(Makefile.in)
AC_CONFIG_HEADER(config.h:config.in)
+AC_CHECK_HEADERS(getopt.h)
sinclude(../common/aclocal.m4)
diff --git a/sim/rx/main.c b/sim/rx/main.c
index 350c7ae..a83794e 100644
--- a/sim/rx/main.c
+++ b/sim/rx/main.c
@@ -19,13 +19,21 @@ You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+#include "config.h"
#include <stdio.h>
#include <string.h>
+#ifdef HAVE_STDLIB_H
#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
#include <assert.h>
#include <setjmp.h>
#include <signal.h>
+#ifdef HAVE_GETOPT_H
+#include <getopt.h>
+#endif
#include "bfd.h"
^ permalink raw reply [flat|nested] 8+ messages in thread* Re: [patch] Build failure sim/rx on OSX.
2010-01-30 2:23 [patch] Build failure sim/rx on OSX Masaki Muranaka
@ 2010-02-01 7:19 ` Joel Brobecker
2010-02-01 7:29 ` Masaki Muranaka
2010-02-14 7:40 ` Masaki Muranaka
2010-02-02 1:43 ` DJ Delorie
1 sibling, 2 replies; 8+ messages in thread
From: Joel Brobecker @ 2010-02-01 7:19 UTC (permalink / raw)
To: Masaki Muranaka; +Cc: gdb-patches
> sim/rx/ChangeLog
> 2010-01-30 Masaki Muranaka <monaka@monami-software.com>
>
> * configure.in: Check if the host has getopt.h.
> * configure.in: Regenerate.
> * config.in: Regenerate.
> * main.c: Include config.h
> Use HAVE_STDLIB_H, HAVE_UNISTD_H, HAVE_GETOPT_H.
> Include getopt.h in case HAVE_GETOPT_H is defined.
This looks fine to me. Still no news from the assignment office
at the FSF?
--
Joel
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-02-01 7:19 ` Joel Brobecker
@ 2010-02-01 7:29 ` Masaki Muranaka
2010-02-01 7:58 ` Joel Brobecker
2010-02-14 7:40 ` Masaki Muranaka
1 sibling, 1 reply; 8+ messages in thread
From: Masaki Muranaka @ 2010-02-01 7:29 UTC (permalink / raw)
To: Joel Brobecker; +Cc: gdb-patches
Hello Joel,
Thanks for your review.
I received assignment forms (cgen/binutils/gdb/gcc) last weekend.
And I sent back them today.
My name will be registered within this month.
Thanks,
On 2010/02/01, at 16:18, Joel Brobecker wrote:
>> sim/rx/ChangeLog
>> 2010-01-30 Masaki Muranaka <monaka@monami-software.com>
>>
>> * configure.in: Check if the host has getopt.h.
>> * configure.in: Regenerate.
>> * config.in: Regenerate.
>> * main.c: Include config.h
>> Use HAVE_STDLIB_H, HAVE_UNISTD_H, HAVE_GETOPT_H.
>> Include getopt.h in case HAVE_GETOPT_H is defined.
>
> This looks fine to me. Still no news from the assignment office
> at the FSF?
>
> --
> Joel
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-02-01 7:29 ` Masaki Muranaka
@ 2010-02-01 7:58 ` Joel Brobecker
2010-02-14 6:53 ` Masaki Muranaka
0 siblings, 1 reply; 8+ messages in thread
From: Joel Brobecker @ 2010-02-01 7:58 UTC (permalink / raw)
To: Masaki Muranaka; +Cc: gdb-patches
> I received assignment forms (cgen/binutils/gdb/gcc) last weekend.
> And I sent back them today.
> My name will be registered within this month.
Great. Depending on snail mail, I'd say that you're about a week away
from being done. When the FSF sends you a confirmation, please go to
http://www.sourceware.org/cgi-bin/pdw/ps_form.cgi to request an accout,
so that you can start committing changes yourself. You may list me as
your sponsor. Once this is done, we'll test your new access by having
you commit a change to gdb/MAINTAINERS, by adding yourself to the
WRITE AFTER APPROVAL list (this change is pre-approved/obvious, but
please remember to send the usual email to gdb-patches with the diff
and ChangeLog entry to gdb-patches, just like we do for all GDB patches).
If this all goes well, then you may commit all approved patches - just
remember again to send confirmation on this list for each patch
committed, especially since it may have been a while since we approved
them.
--
Joel
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-02-01 7:58 ` Joel Brobecker
@ 2010-02-14 6:53 ` Masaki Muranaka
0 siblings, 0 replies; 8+ messages in thread
From: Masaki Muranaka @ 2010-02-14 6:53 UTC (permalink / raw)
To: Joel Brobecker; +Cc: gdb-patches
Hello Joel and maintainers,
I added myself to MAINTAINERS with a help from Joel Brobecker.
I'll apply some patches that were already approved soon.
Thanks,
- - - -
2010-02-14 Masaki Muranaka <monaka@monami-software.com>
* MAINTAINERS: Add myself for write after approval privileges.
- - - -
Index: MAINTAINERS
===================================================================
RCS file: /cvs/src/src/gdb/MAINTAINERS,v
retrieving revision 1.433
diff -u -p -r1.433 MAINTAINERS
--- MAINTAINERS 21 Dec 2009 10:27:21 -0000 1.433
+++ MAINTAINERS 14 Feb 2010 06:40:12 -0000
@@ -622,6 +622,7 @@ Wu Zhou woodzltc@cn.ibm.com
Yoshinori Sato ysato@users.sourceforge.jp
Hui Zhu teawater@gmail.com
Sergio Durigan Junior sergiodj@linux.vnet.ibm.com
+Masaki Muranaka monaka@monami-software.com
Past Maintainers
- - - -
On 2010/02/01, at 16:57, Joel Brobecker wrote:
>> I received assignment forms (cgen/binutils/gdb/gcc) last weekend.
>> And I sent back them today.
>> My name will be registered within this month.
>
> Great. Depending on snail mail, I'd say that you're about a week away
> from being done. When the FSF sends you a confirmation, please go to
> http://www.sourceware.org/cgi-bin/pdw/ps_form.cgi to request an accout,
> so that you can start committing changes yourself. You may list me as
> your sponsor. Once this is done, we'll test your new access by having
> you commit a change to gdb/MAINTAINERS, by adding yourself to the
> WRITE AFTER APPROVAL list (this change is pre-approved/obvious, but
> please remember to send the usual email to gdb-patches with the diff
> and ChangeLog entry to gdb-patches, just like we do for all GDB patches).
> If this all goes well, then you may commit all approved patches - just
> remember again to send confirmation on this list for each patch
> committed, especially since it may have been a while since we approved
> them.
>
> --
> Joel
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-02-01 7:19 ` Joel Brobecker
2010-02-01 7:29 ` Masaki Muranaka
@ 2010-02-14 7:40 ` Masaki Muranaka
1 sibling, 0 replies; 8+ messages in thread
From: Masaki Muranaka @ 2010-02-14 7:40 UTC (permalink / raw)
To: Joel Brobecker; +Cc: gdb-patches
Hello joel and DJ,
This patch was commited.
Thanks for your approval.
On 2010/02/01, at 16:18, Joel Brobecker wrote:
>> sim/rx/ChangeLog
>> 2010-01-30 Masaki Muranaka <monaka@monami-software.com>
>>
>> * configure.in: Check if the host has getopt.h.
>> * configure.in: Regenerate.
>> * config.in: Regenerate.
>> * main.c: Include config.h
>> Use HAVE_STDLIB_H, HAVE_UNISTD_H, HAVE_GETOPT_H.
>> Include getopt.h in case HAVE_GETOPT_H is defined.
>
> This looks fine to me. Still no news from the assignment office
> at the FSF?
>
> --
> Joel
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-01-30 2:23 [patch] Build failure sim/rx on OSX Masaki Muranaka
2010-02-01 7:19 ` Joel Brobecker
@ 2010-02-02 1:43 ` DJ Delorie
2010-02-02 2:57 ` Masaki Muranaka
1 sibling, 1 reply; 8+ messages in thread
From: DJ Delorie @ 2010-02-02 1:43 UTC (permalink / raw)
To: Masaki Muranaka; +Cc: gdb-patches
As the original author, I'm OK with this patch, but I have to ask... a
system without <stdlib.h>?
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [patch] Build failure sim/rx on OSX.
2010-02-02 1:43 ` DJ Delorie
@ 2010-02-02 2:57 ` Masaki Muranaka
0 siblings, 0 replies; 8+ messages in thread
From: Masaki Muranaka @ 2010-02-02 2:57 UTC (permalink / raw)
To: DJ Delorie; +Cc: gdb-patches
Hello DJ,
I've also never met a system without <stdlib.h> excepts freestanding environments.
But stdlib.h is checked in configure script. This is the reason why I added #ifdef.
Thanks,
On 2010/02/02, at 10:42, DJ Delorie wrote:
>
> As the original author, I'm OK with this patch, but I have to ask... a
> system without <stdlib.h>?
>
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2010-02-14 7:40 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-30 2:23 [patch] Build failure sim/rx on OSX Masaki Muranaka
2010-02-01 7:19 ` Joel Brobecker
2010-02-01 7:29 ` Masaki Muranaka
2010-02-01 7:58 ` Joel Brobecker
2010-02-14 6:53 ` Masaki Muranaka
2010-02-14 7:40 ` Masaki Muranaka
2010-02-02 1:43 ` DJ Delorie
2010-02-02 2:57 ` Masaki Muranaka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox