From c050e33aa0d5f97cc9d1bfc73224f6f6d977629f Mon Sep 17 00:00:00 2001 From: Anuraag Agrawal Date: Fri, 22 Mar 2024 16:41:17 +0900 Subject: [PATCH 1/2] Define APIENTRY in osmesa build if not defined. --- auto/src/glew_head.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/auto/src/glew_head.c b/auto/src/glew_head.c index 9a3802f..96fdb6a 100644 --- a/auto/src/glew_head.c +++ b/auto/src/glew_head.c @@ -6,7 +6,15 @@ #if defined(GLEW_OSMESA) # define GLAPI extern +# ifndef APIENTRY +# define APIENTRY +# define GLEW_APIENTRY_DEFINED +# endif # include +# ifdef GLEW_APIENTRY_DEFINED +# undef APIENTRY +# undef GLEW_APIENTRY_DEFINED +# endif #elif defined(GLEW_EGL) # include #elif defined(_WIN32) From b323ebf9adeae6a3f26f91277d4f62df509037fc Mon Sep 17 00:00:00 2001 From: Ryan Schmidt Date: Mon, 24 Jul 2023 20:53:41 -0500 Subject: [PATCH 2/2] Remove everything after digits in SYSTEM Instead of just removing periods and digits from SYSTEM, remove periods and digits and everything after any digits. This handles unusual system identifiers like powerpc-apple-darwin10.0.0d2. I wasn't sure if periods can appear anywhere other than in the release number so I retained the previous behavior of removing all periods regardless where they are. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 9a6b9ef..0579ccb 100644 --- a/Makefile +++ b/Makefile @@ -31,7 +31,7 @@ include config/version SHELL = /bin/sh -SYSTEM ?= $(shell config/config.guess | cut -d - -f 3 | sed -e 's/[0-9\.]//g;') +SYSTEM ?= $(shell config/config.guess | cut -d - -f 3 | sed -e 's/\.//g' -e 's/[0-9]\{1,\}.*//') SYSTEM.SUPPORTED = $(shell test -f config/Makefile.$(SYSTEM) && echo 1) ifeq ($(SYSTEM.SUPPORTED), 1)