[arm-8-branch] Add Linaro version string and macros

Yvan Roux yvan.roux@linaro.org
Fri Aug 10 14:35:00 GMT 2018


On Fri, 10 Aug 2018 at 14:31, Yvan Roux <yvan.roux@linaro.org> wrote:
>
> On Fri, 10 Aug 2018 at 13:45, Ramana Radhakrishnan
> <ramana.gcc@googlemail.com> wrote:
> >
> > On Fri, Aug 10, 2018 at 11:09 AM, Yvan Roux <yvan.roux@linaro.org> wrote:
> > > Hi,
> > >
> > > This patch adds Linaro version string and release macros to ARM GCC 8
> > > vendor branch.
> > >
> > > Ok to commit?
> > >
> >
> >
> > Ok if no regressions. (I'm assuming you've built and eyeballed that
> > the pre-processor macros are being produced). (I have a patch to
> > www-docs for this branch that I'm writing up and should try and get
> > out today. Though it would be nice to have tests for these if
> > possible.
>
> I've not passed the regression testsuite since this patch is part of
> Linaro vendor branches for a long time, I've just built an x86_64 c
> compiler from arm-8-branch and verified the version string and macros:
>
> $ ~/wip/arm-8-install/bin/gcc --version
> gcc (Linaro GCC 8.2-2018.08~dev) 8.2.1 20180802
>
> $ ~/wip/arm-8-install/bin/gcc -E -dM - < /dev/null | grep LINARO
> #define __LINARO_SPIN__ 0
> #define __LINARO_RELEASE__ 201808
>
> I can add some tests, but it will take some time to remember me how
> these kind of thing is tested in the testsuite ;)

Updated version of the patch, with a test case for Linaro macros.  The
test is not strict w/r to the version or spin number to avoid having
to update it every release or re-spin, do you think it is sufficient ?

Testsuite ran with the included test PASS.

gcc/ChangeLog
2018-08-10  Yvan Roux  <yvan.roux@linaro.org>

    * LINARO-VERSION: New file.
    * configure.ac: Add Linaro version string.
    * configure: Regenerate.
    * Makefile.in (LINAROVER, LINAROVER_C, LINAROVER_S): Define.
    (CFLAGS-cppbuiltin.o): Add LINAROVER macro definition.
    (cppbuiltin.o): Depend on $(LINAROVER).
    * cppbuiltin.c (parse_linarover): New.
    (define_GNUC__): Define __LINARO_RELEASE__ and __LINARO_SPIN__ macros.

gcc/testsuite/ChangeLog
2018-08-10  Yvan Roux  <yvan.roux@linaro.org>

    * gcc.dg/cpp/linaro-macros.c: New test.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: arm-8-branch.diff
Type: text/x-patch
Size: 5681 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20180810/258e142c/attachment.bin>


More information about the Gcc-patches mailing list