Patchwork [VMS/committed] : Add -mpointer-size switch

login
register
mail settings
Submitter Tristan Gingold
Date March 13, 2012, 2:44 p.m.
Message ID <754EA2AF-96BF-420F-BB0D-18F611E03872@adacore.com>
Download mbox | patch
Permalink /patch/146417/
State New
Headers show

Comments

Tristan Gingold - March 13, 2012, 2:44 p.m.
On Mar 13, 2012, at 2:57 PM, Andreas Schwab wrote:

> Tristan Gingold <gingold@adacore.com> writes:
> 
>> For which target ?
> 
> ia64-*-* or alpha-*-*
> 
>> On non-VMS targets, flag_vms_malloc64 is declared in gigi.h as:
>> 
>> /* Let code know whether we are targetting VMS without need of
>>   intrusive preprocessor directives.  */
>> #ifndef TARGET_ABI_OPEN_VMS
> 
> TARGET_ABI_OPEN_VMS is always defined.

I am committing this patch to fix the build failure.

Tested by (cross) building ia64-linux and ia64-hp-openvms.

Tristan.

gcc/ada/
2012-03-13  Tristan Gingold  <gingold@adacore.com>

	* gcc-interface/gigi.h (flag_vms_malloc64): Refine condition.

Patch

Index: gcc-interface/gigi.h
===================================================================
--- gcc-interface/gigi.h	(revision 185334)
+++ gcc-interface/gigi.h	(working copy)
@@ -995,10 +995,12 @@ 
    intrusive preprocessor directives.  */
 #ifndef TARGET_ABI_OPEN_VMS
 #define TARGET_ABI_OPEN_VMS 0
+#endif
 
 /* VMS option set by default, when clear forces 32bit mallocs and 32bit
-   Descriptors. Always used in combination with TARGET_ABI_OPEN_VMS
+   Descriptors.  Always used in combination with TARGET_ABI_OPEN_VMS
    so no effect on non-VMS systems.  */
+#if TARGET_ABI_OPEN_VMS == 0
 #define flag_vms_malloc64 0
 #endif