[patch] fix VXWORKSAE_TARGET_DIR not to designate a hardcoded /home subdir

Olivier Hainque hainque@adacore.com
Mon Sep 1 12:34:00 GMT 2014


VxWorks environments all provide a few environment variables
that help locate components such as header files or libraries.

WIND_BASE typically designates an installation root and the
regular VxWorks ports leverage this with:


 #define VXWORKS_ADDITIONAL_CPP_SPEC             \
  "%{!nostdinc:                                  \
     %{isystem*} -idirafter                      \
     %{mrtp: %:getenv(WIND_USR /h)               \
       ;:    %:getenv(WIND_BASE /target/h)}}"

The VxWorksAE configuration (vxworksae.h) currently uses a hardcoded value
within /home instead:

 /* The directory containing the VxWorks AE target headers.  */

This patch adjusts the definition and users to leverage
$WIND_BASE instead (this is !rtp only).

We have been using a variant of this for years in our gcc 4.7
based compiler series, checked that the patch works fine with
gcc-4.9 and that it applies as-is on the current mainline.

OK to commit ?

Thanks in advance,

With Kind Regards,


2014-09-01  Olivier Hainque  <hainque@adacore.com>

        * config/vxworksae.h (VXWORKSAE_TARGET_DIR): Rely on
        $WIND_BASE instead of designating a harcoded arbitrary home dir.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: vxae-targetdir.diff
Type: application/octet-stream
Size: 1309 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20140901/47b075ba/attachment.obj>

More information about the Gcc-patches mailing list