This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug libgomp/36469] New: bootstrap broken on HPUX PA


The build of libgomp fails due to the use of strtoull in env.c

HPUX-PA does not know about this function, officially. On 32-bit the function
is available but not headerwise. On 64-bit this function is not available at
all.

The following snippet added to env.c cures the issue:

Index: env.c
===================================================================
--- env.c       (revision 136534)
+++ env.c       (working copy)
@@ -47,6 +47,11 @@
 #include <limits.h>
 #include <errno.h>

+#if (defined(__hpux__) && defined(__LP64__))
+#define strtoull strtoul
+#elif (defined(__hpux__) && !defined(__LP64__))
+#define strtoull __strtoull
+#endif

 struct gomp_task_icv gomp_global_icv = {
   .nthreads_var = 1,


But I do not know if this is the right(tm) way to handle such cases or if you
prefer a configure magic part. Other libs as libstdc++ use special includes.
And I do not have a configure magic at hand.

Tests with the above in progress, on 32 and 64-bit.

Comments?


-- 
           Summary: bootstrap broken on HPUX PA
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgomp
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: andreast at gcc dot gnu dot org
 GCC build triplet: hppa*-hp-hpux11.11
  GCC host triplet: hppa*-hp-hpux11.11
GCC target triplet: hppa*-hp-hpux11.11


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36469


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