logo       

Re: problems building GNULIB allocsa.c on HP/UX 11.0: msg#00001

Subject: Re: problems building GNULIB allocsa.c on HP/UX 11.0
Mark D. Baushke wrote:
> Attempts to build allocsa.c on HP-UX 11.0 using the native compiler
>
> "/u/scjones/cvs-nightly/lib/allocsa.h", line 96: error 1509: Enumeration 
> value must be constant.

GNU gettext already contained a workaround against this. I've put it into
gnulib now. Hope it works for you.

Bruno



        2004-09-11  Bruno Haible  <bruno@xxxxxxxxx>
                * allocsa.valgrind: New file.
        2004-02-06  Bruno Haible  <bruno@xxxxxxxxx>
                * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
                avoid a bug of this cc on HP-UX 10.20 dealing with enums.
                Reported by Christopher Seip <chris.seip@xxxxxx>.

*** lib/allocsa.h       20 Jan 2004 14:03:28 -0000      1.1
--- lib/allocsa.h       4 Nov 2004 13:32:03 -0000       1.2
***************
*** 1,5 ****
  /* Safe automatic memory allocation.
!    Copyright (C) 2003 Free Software Foundation, Inc.
     Written by Bruno Haible <bruno@xxxxxxxxx>, 2003.
  
     This program is free software; you can redistribute it and/or modify
--- 1,5 ----
  /* Safe automatic memory allocation.
!    Copyright (C) 2003-2004 Free Software Foundation, Inc.
     Written by Bruno Haible <bruno@xxxxxxxxx>, 2003.
  
     This program is free software; you can redistribute it and/or modify
***************
*** 77,82 ****
--- 77,86 ----
  #elif defined __cplusplus
    template <class type> struct sa_alignof_helper { char __slot1; type 
__slot2; };
  # define sa_alignof(type) offsetof (sa_alignof_helper<type>, __slot2)
+ #elif defined __hpux
+   /* Work around a HP-UX 10.20 cc bug with enums constants defined as offsetof
+      values.  */
+ # define sa_alignof(type) (sizeof (type) <= 4 ? 4 : 8)
  #else
  # define sa_alignof(type) offsetof (struct { char __slot1; type __slot2; }, 
__slot2)
  #endif


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
web.pylons.gene...    hurd.l4/2002-10...    kernel.commits....    user-groups.lin...    yellowdog.gener...    java.drools.use...    security.openva...    package-managem...    linux.debian.us...    qnx.openqnx.dev...    genealogy.gramp...    file-systems.if...    voip.wengophone...    tex.context/200...    ietf.smime/2003...    audio.csound.de...    culture.region....    xfree86.devel/2...    mobile.kannel.u...    distributed.con...    education.engli...    org.user-groups...    bug-tracking.gn...    recreation.bicy...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe