From 7af4107235e6c178d5740782fe510d2df1c825b1 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 11 Nov 2021 15:21:59 -0500 Subject: Fix Makefile issues with OSX 11.6 --- tools/nitrogfx/Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'tools/nitrogfx/Makefile') diff --git a/tools/nitrogfx/Makefile b/tools/nitrogfx/Makefile index 16b2632d..37d30b2d 100644 --- a/tools/nitrogfx/Makefile +++ b/tools/nitrogfx/Makefile @@ -1,8 +1,14 @@ CC = gcc -CFLAGS = -Wall -Wextra -Werror -Wno-sign-compare -std=c11 -O2 -DPNG_SKIP_SETJMP_CHECK $(shell pkg-config --cflags libpng) +HAVE_LIBPNG := $(shell $(PKGCONFIG) libpng; echo $?) -LIBS = $(shell pkg-config --libs libpng) +ifeq ($(HAVE_LIBPNG),1) +$(error No package 'libpng' found) +endif + +CFLAGS = -Wall -Wextra -Werror -Wno-sign-compare -std=c11 -O2 -DPNG_SKIP_SETJMP_CHECK $(shell $(PKGCONFIG) --cflags libpng) + +LIBS = $(shell $(PKGCONFIG) --libs libpng) SRCS = main.c convert_png.c gfx.c jasc_pal.c lz.c rl.c util.c font.c huff.c json.c cJSON.c -- cgit v1.2.3 From c619240caca34b085918f948da2aac55d1e76691 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Wed, 24 Nov 2021 09:38:34 -0500 Subject: Fix build system for macOS --- tools/nitrogfx/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tools/nitrogfx/Makefile') diff --git a/tools/nitrogfx/Makefile b/tools/nitrogfx/Makefile index 37d30b2d..2ed6cf1e 100644 --- a/tools/nitrogfx/Makefile +++ b/tools/nitrogfx/Makefile @@ -1,14 +1,14 @@ CC = gcc -HAVE_LIBPNG := $(shell $(PKGCONFIG) libpng; echo $?) +HAVE_LIBPNG := $(shell pkg-config libpng; echo $?) ifeq ($(HAVE_LIBPNG),1) $(error No package 'libpng' found) endif -CFLAGS = -Wall -Wextra -Werror -Wno-sign-compare -std=c11 -O2 -DPNG_SKIP_SETJMP_CHECK $(shell $(PKGCONFIG) --cflags libpng) +CFLAGS = -Wall -Wextra -Werror -Wno-sign-compare -std=c11 -O2 -DPNG_SKIP_SETJMP_CHECK $(shell pkg-config --cflags libpng) -LIBS = $(shell $(PKGCONFIG) --libs libpng) +LIBS = $(shell pkg-config --libs libpng) SRCS = main.c convert_png.c gfx.c jasc_pal.c lz.c rl.c util.c font.c huff.c json.c cJSON.c -- cgit v1.2.3