fix t-vxworks fetching of $(MULTIDIR) for libgcc

Olivier Hainque hainque@adacore.com
Mon Jun 4 17:16:00 GMT 2012


Hello,

libgcc/config/t-vxworks has

<< LIBGCC2_INCLUDES = -nostdinc -I \
   `case "/$$(MULTIDIR)" in \
      */mrtp*) echo $(WIND_USR)/h ;; \
      *) echo $(WIND_BASE)/target/h ;; \
    esac`
>>

The double "$" was useful back when libgcc was built
within gcc/ and we had

<< gcc/Makefile.in

   libgcc.mvars:
        ...
        echo LIBGCC2_CFLAGS = '$(LIBGCC2_CFLAGS)' >> tmp-libgcc.mvars
>>

The latter disappeared when the libgcc build was moved to toplevel,
per svn rev 180774.

LIBGCC2_INCLUDES is now expanded in a more straightforward
fashion and the second "$" breaks the build. With bash for
example, we get "MULTIDIR: command not found" from the shell
trying to expand $(MULTIDIR) and a bogus -I argument value.

The attached patch fixes this by removing the extra '$'.

Tested by checking that a cross build for powerpc-wrs-vxworks on
x86-linux now proceeds past libgcc and finishes.

OK to commit ?

Thanks in advance,

Olivier

2012-06-04  Olivier Hainque  <hainque@adacore.com>

	libgcc/
        * config/t-vxworks (LIBGCC2_INCLUDES): Remove extraneous $
        in attempt at fetching the value of MULTIDIR.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: multidir.diff
Type: application/octet-stream
Size: 426 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120604/16363b9a/attachment.obj>


More information about the Gcc-patches mailing list