From d17dea6521955bfd307730ec397d8d0f30a7a652 Mon Sep 17 00:00:00 2001 From: superbonaci <superbonaci@aol.com> Date: Sun, 15 Sep 2024 12:07:24 +0200 Subject: [PATCH 1/4] Update Makefile --- Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index df20544..ae90755 100644 --- a/Makefile +++ b/Makefile @@ -13,8 +13,10 @@ override CFLAGS += \ -Wall \ -Wextra \ -Wno-incompatible-pointer-types \ --Wno-multichar \ -Wno-unused-variable \ +-Wno-unused-but-set-variable \ +-Wno-deprecated-non-prototype \ +-Wno-multichar \ -Wno-unused-parameter \ -Wno-missing-field-initializers \ -I./$(INCDIR) @@ -26,8 +28,8 @@ override LDFLAGS += # Nothing ### On macOS, include <argp.h> from Homebrew package `argp-standalone` ifneq ($(OS),Windows_NT) ifeq ($(shell uname -s),Darwin) - override CFLAGS += -I/usr/local/Cellar/argp-standalone/1.3/include/ - override LDFLAGS += -L/usr/local/Cellar/argp-standalone/1.3/lib/ -largp + override CFLAGS += -I/opt/homebrew/Cellar/argp-standalone/1.5.0/include/ + override LDFLAGS += -L/opt/homebrew/Cellar/argp-standalone/1.5.0/lib/ -largp endif endif From e42821d98102bd4afa257d0159fa27d5af8ffee9 Mon Sep 17 00:00:00 2001 From: superbonaci <superbonaci@aol.com> Date: Sun, 15 Sep 2024 12:08:07 +0200 Subject: [PATCH 2/4] Update io.h --- include/drat/io.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/drat/io.h b/include/drat/io.h index ee387b3..a5eeeae 100644 --- a/include/drat/io.h +++ b/include/drat/io.h @@ -11,7 +11,7 @@ char* get_fopen_error_msg(); char* get_fseeko_error_msg(); -int open_container__info_stream(); +int open_container__info_stream(FILE* info_stream); int open_container(); int close_container(); int end_of_container(); From 349f6b631f8498f401c7f4105d662e1286178814 Mon Sep 17 00:00:00 2001 From: superbonaci <superbonaci@aol.com> Date: Sun, 15 Sep 2024 12:10:26 +0200 Subject: [PATCH 3/4] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ef213bc..d4f0c7d 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ Documentation for versioned releases and as generated from the `main` branch - On Ubuntu, ensure that the package `libc6-dev` is installed. - On macOS, you can install just Argp via the [Homebrew](https://brew.sh) - package `argp-standalone`. The Makefile will handle this configuration + package `argp-standalone`, with command `brew install argp-standalone`. The Makefile will handle this configuration automatically. If you acquire Argp any other way, such as by installing glibc in its entirety, you may need to configure `CFLAGS` and `LDFLAGS` as appropriate. From 47b48752a9f7d06ebb7ca75e63cd9663e8cf7f32 Mon Sep 17 00:00:00 2001 From: superbonaci <superbonaci@aol.com> Date: Sun, 15 Sep 2024 13:03:36 +0200 Subject: [PATCH 4/4] Update Makefile --- Makefile | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index ae90755..5b04164 100644 --- a/Makefile +++ b/Makefile @@ -28,8 +28,18 @@ override LDFLAGS += # Nothing ### On macOS, include <argp.h> from Homebrew package `argp-standalone` ifneq ($(OS),Windows_NT) ifeq ($(shell uname -s),Darwin) - override CFLAGS += -I/opt/homebrew/Cellar/argp-standalone/1.5.0/include/ - override LDFLAGS += -L/opt/homebrew/Cellar/argp-standalone/1.5.0/lib/ -largp + UNAME_M := $(shell uname -m) + ifeq ($(UNAME_M),arm64) + # Apple Silicon + ARGP_PREFIX := /opt/homebrew/opt/argp-standalone + else ifeq ($(UNAME_M),x86_64) + # Intel Macs + ARGP_PREFIX := /usr/local/opt/argp-standalone + else + $(error Unsupported architecture $(UNAME_M)) + endif + override CFLAGS += -I$(ARGP_PREFIX)/include/ + override LDFLAGS += -L$(ARGP_PREFIX)/lib/ -largp endif endif