Re: build failure with GCC 9.1.0

Elliott Sales de Andrade <[email protected]>
Newsgroups gmane.comp.gis.proj-4.devel
Message-ID <CAJP_izc7wUadk57a-CvvZ5r6Sbg8wcDPsqwW-Q8A=y5LoCU8og@mail.gmail.com>
On Wed, 25 Sep 2019 at 03:55, Dechaux Eric CEN (BCQ STIG)
<[email protected]> wrote:
>
> Le 24/09/2019 à 15:37, Even Rouault a écrit :
> > Hi
> >
> >> Could it comes from my buildbox (Solaris 11.4.12) ?
> > Definitely a Solaris specific thing.
> > Should hopefully be fixed by https://github.com/OSGeo/PROJ/pull/1637
> > Can you confirm this patch fixes the issue ?
>
> I am afraid it is not enough. Please find attached 4 additional patches :
>
>      - proj-6.2.0-hanato.gpatch and proj-6.2.0-mbtfpp.gpatch
>
> In files src/projections/hatano.cpp and src/projections/mbtfpp.cpp,
> change the CS define to CSz in order to avoid overriding the CS system
> definition
>
>      - proj-6.2.0-isea.gpatch :
>
> In file src/projections/isea.cpp, change the quad variable name as it is
> overriding another system definition
>
> $ grep quad  /usr/include/sys/types.h
> typedef struct _quad { int val[2]; } quad_t;    /* used by UFS */
> typedef quad_t          quad;                   /* used by UFS */
>

I don't understand this one. It's not a macro, so the inner scope
identifier should shadow the outer one.
See https://godbolt.org/z/ZQKPKo

>      - proj-6.2.0-io.gpatch
>
> In file src/iso19111/io.cpp, change another class name that override the
> CS system define
>
> $ gegrep '[[:space:]]CS[[:space:]]' /usr/include/sys/regset.h
> #define CS              15
>

Maybe it would be better to figure out how and why this header is
included, and then disable it, since it's defined several macros which
seem useless for Proj.

>
> With those changes, 6.2.0 build and check properly on Solaris 11.4.12
> and GCC 9.1.
>
> Note : I quite understood what I changed in the first 3 patches. Not
> sure in the last one. Can you please review it ?
>
>
> Regards.
>
> --
> Eric

-- 
Elliott
_______________________________________________
PROJ mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/proj
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.