wmutils

X windows manipulation utilities
git clone git://z3bra.org/wmutils
Log | Files | Refs | LICENSE

commit 43cfe64796c8df2648071aa15983e0ff8b998858
parent ddf0c5b66b546622c7b2e4ed7978ac9682dbba7f
Author: z3bra <willy@mailoo.org>
Date:   Tue Jun  9 23:29:34 2015

Change variables in Makfile for POSIX-compliance

POSIX only specifies one variable attribution:

    CC = cc

All the other (:=, ?=, ...) are implementation specific and interfere
with the .POSIX: target. For example, using

    CC ?= cc

Would make the $(CC) macro be assigned to 'cc' if the $CC environment
variable is empty.
The problem here is that the .POSIX target implies that if the $(CC)
macro is empty, it should be set to it's default, POSIX value: 'c99'.
Thus, the ?= assignment is useless in the caase of a POSIX makefile.
To use the environment variables, POSIX specifies the `-e` flags, which
will make make(1) use environment variables instead of it's own local
variables.

Please use it instead starting from now. Thanks.

Also, I'm sorry I asked dcat to change the CC declaration in the
previous commit. That's my fault bro, I didn't tested.

Diffstat:
 config.mk | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/config.mk b/config.mk @@ -1,9 +1,9 @@ -PREFIX ?= /usr -MANPREFIX := $(PREFIX)/man +PREFIX = /usr +MANPREFIX = $(PREFIX)/man -CC ?= cc -LD := $(CC) +CC = cc +LD = $(CC) -CFLAGS += -std=c99 -pedantic -Wall -Os -LDFLAGS += -lxcb +CFLAGS = -std=c99 -pedantic -Wall -Os +LDFLAGS = -lxcb