Re: Compiler warning in ctype.h
On 2020/03/09 11:34, Janne Johansson wrote: > Den fre 6 mars 2020 kl 12:29 skrev Thomas de Grivel : > > > Hello, > > > > I was using base gcc but switching to base clang fixes the warnings on > > -current at least. > > Is base gcc not supported anymore ? > > > > I think you are supposed to use whatever gets used when you call "cc" on > the OpenBSD platform you are on, and if need be, get gcc from ports for an > uptodate version of it. Some arches (aarch64) only ever had clang. Some arches (i386, armv7) moved to clang and have removed gcc. Some arches (amd64, mips64 [sgi,octeon]) have moved to clang but still have /usr/bin/gcc present, mostly so that people making changes to the base OS have some easy way to check if their changes don't negatively impact gcc 4.2.1 arches. (However this does make it harder to pick up on things in ports which hardcode "gcc" and fail if not present!). For these arches, clang is the supported compiler. Some arches still use gcc. gcc 3 for m88k. gcc 4.2.1 for alpha hppa mips64el powerpc sh sparc64. Of these, mips64el powerpc sparc64 *also* have clang built, but have not switched to it as the main system compiler. For all of these arches, gcc is the supported compiler. > Since arches are moving from gcc into clang (at various speeds), its not > unthinkable for some of them to have both over the transition, but the > "supported" one is always the binary that gets run if you use "cc" for > compiler and nothing else. yep.
Re: Compiler warning in ctype.h
Den fre 6 mars 2020 kl 12:29 skrev Thomas de Grivel : > Hello, > > I was using base gcc but switching to base clang fixes the warnings on > -current at least. > Is base gcc not supported anymore ? > I think you are supposed to use whatever gets used when you call "cc" on the OpenBSD platform you are on, and if need be, get gcc from ports for an uptodate version of it. Since arches are moving from gcc into clang (at various speeds), its not unthinkable for some of them to have both over the transition, but the "supported" one is always the binary that gets run if you use "cc" for compiler and nothing else. -- May the most significant bit of your life be positive.
Re: Compiler warning in ctype.h
Hello, I was using base gcc but switching to base clang fixes the warnings on -current at least. Is base gcc not supported anymore ? Sorry for the noise. Cheers, Le jeu. 5 mars 2020 à 16:59, Theo de Raadt a écrit : > > Todd C. Miller wrote: > > > On Thu, 05 Mar 2020 16:07:48 +0100, Thomas de Grivel wrote: > > > > > Actually I see the same problem on 6.6-stable : > > > including readline/readline.h produces warnings. > > > > > > Any -Werror hope some day ? > > > > You still haven't bothered to include: > > > > 1) the compiler you are using > > 2) the compiler flags to reproduce the problem > > 3) a sample program to reproduce the problem > > > > The _l parameter in those inline functions already has the __unused__ > > attribute set which is supposed to suppress those warnings. > > > > I can't reproduce this using clang (base or ports) or gcc (base or > > ports) using -Wall, -Wextra and -Wunused-parameter. But since you > > haven't provided any details, we just have to guess at what you are > > doing. > > Or not guess, but simply delete the mail -- Thomas de Grivel kmx.io
Re: Compiler warning in ctype.h
Todd C. Miller wrote: > On Thu, 05 Mar 2020 16:07:48 +0100, Thomas de Grivel wrote: > > > Actually I see the same problem on 6.6-stable : > > including readline/readline.h produces warnings. > > > > Any -Werror hope some day ? > > You still haven't bothered to include: > > 1) the compiler you are using > 2) the compiler flags to reproduce the problem > 3) a sample program to reproduce the problem > > The _l parameter in those inline functions already has the __unused__ > attribute set which is supposed to suppress those warnings. > > I can't reproduce this using clang (base or ports) or gcc (base or > ports) using -Wall, -Wextra and -Wunused-parameter. But since you > haven't provided any details, we just have to guess at what you are > doing. Or not guess, but simply delete the mail
Re: Compiler warning in ctype.h
On Thu, 05 Mar 2020 16:07:48 +0100, Thomas de Grivel wrote: > Actually I see the same problem on 6.6-stable : > including readline/readline.h produces warnings. > > Any -Werror hope some day ? You still haven't bothered to include: 1) the compiler you are using 2) the compiler flags to reproduce the problem 3) a sample program to reproduce the problem The _l parameter in those inline functions already has the __unused__ attribute set which is supposed to suppress those warnings. I can't reproduce this using clang (base or ports) or gcc (base or ports) using -Wall, -Wextra and -Wunused-parameter. But since you haven't provided any details, we just have to guess at what you are doing. - todd
Re: Compiler warning in ctype.h
Actually I see the same problem on 6.6-stable : including readline/readline.h produces warnings. Any -Werror hope some day ? cheers Le mer. 4 mars 2020 à 13:41, Thomas de Grivel a écrit : > > With latest OpenBSD snapshot on amd64 > > In file included from /usr/include/readline/chardefs.h:26, > from /usr/include/readline/keymaps.h:36, > from /usr/include/readline/readline.h:38, > from cli.c:21: > /usr/include/ctype.h:216: warning: unused parameter '_l' > /usr/include/ctype.h:222: warning: unused parameter '_l' > /usr/include/ctype.h:228: warning: unused parameter '_l' > /usr/include/ctype.h:234: warning: unused parameter '_l' > /usr/include/ctype.h:240: warning: unused parameter '_l' > /usr/include/ctype.h:246: warning: unused parameter '_l' > /usr/include/ctype.h:252: warning: unused parameter '_l' > /usr/include/ctype.h:258: warning: unused parameter '_l' > /usr/include/ctype.h:264: warning: unused parameter '_l' > /usr/include/ctype.h:270: warning: unused parameter '_l' > /usr/include/ctype.h:276: warning: unused parameter '_l' > /usr/include/ctype.h:282: warning: unused parameter '_l' > /usr/include/ctype.h:288: warning: unused parameter '_l' > /usr/include/ctype.h:294: warning: unused parameter '_l' > > -- > Thomas de Grivel > kmx.io -- Thomas de Grivel kmx.io