Re: [hackers] [libzahl] makefile: add ".POSIX:" line and use `c99` rather than `cc -std=c99` || Matti

From: Mattias Andrée <m_AT_maandree.se>
Date: Sun, 22 Feb 2026 18:54:56 +0100

On Sun, 22 Feb 2026 17:17:38 +0100
noneofyourbusiness <noneofyourbusiness_AT_danwin1210.de> wrote:

> git_AT_suckless.org wrote:
> > commit dd8c66cc99e31e71ae1cc9fc706f60fbb33c6d65
> > Author: Mattias Andrée <m_AT_maandree.se>
> > AuthorDate: Sun Feb 22 15:09:39 2026 +0100
> > Commit: Mattias Andrée <m_AT_maandree.se>
> > CommitDate: Sun Feb 22 15:09:39 2026 +0100
> >
> > makefile: add ".POSIX:" line and use `c99` rather than `cc -std=c99`
> >
> > Signed-off-by: Mattias Andrée <m_AT_maandree.se>
> >
> > diff --git a/Makefile b/Makefile
> > index b885258..ad92a44 100644
> > --- a/Makefile
> > +++ b/Makefile
> > _AT_@ -1,3 +1,5 @@
> > +.POSIX:
> > +
> > CONFIG = config.mk
> > include $(CONFIG)
> >
> > diff --git a/config.mk b/config.mk
> > index 2a42d3c..edb71a5 100644
> > --- a/config.mk
> > +++ b/config.mk
> > _AT_@ -7,9 +7,9 @@ EXECPREFIX = $(PREFIX)
> > MANPREFIX = $(PREFIX)/share/man
> > DOCPREFIX = $(PREFIX)/share/doc
> >
> > -CC = cc
> > +CC = c99
>
> this is not necessary, 'CC = c99' is already the default in make(1p) - deleting this line should suffice

CC = c99 is a recommendation in make(1p). Implementations can choose not to predefine anything for C.

“Implementations that do not support the C-Language Development Utilities option may omit
CC, CFLAGS, YACC, YFLAGS, LEX, LFLAGS, LDFLAGS, and the .c, .y, and .l inference rules.”

>
> > AR = ar
> >
> > CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -DGOOD_RAND
> > -CFLAGS = -std=c99 -O3 -flto -Wall -pedantic
> > +CFLAGS = -O3 -flto -Wall -pedantic
> > LDFLAGS = -s
>
>
Received on Sun Feb 22 2026 - 18:54:56 CET

This archive was generated by hypermail 2.3.0 : Sun Feb 22 2026 - 19:00:32 CET