diff options
Diffstat (limited to 'graphics/glew/patches/patch-Makefile')
-rw-r--r-- | graphics/glew/patches/patch-Makefile | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/graphics/glew/patches/patch-Makefile b/graphics/glew/patches/patch-Makefile new file mode 100644 index 00000000000..b0b59c69127 --- /dev/null +++ b/graphics/glew/patches/patch-Makefile @@ -0,0 +1,43 @@ +$NetBSD: patch-Makefile,v 1.1 2019/05/29 17:36:43 adam Exp $ + +On Darwin, do not put GLU as required lib in glew.pc. +Use LDFLAGS for linking. + +--- Makefile.orig 2017-07-31 11:25:39.000000000 +0000 ++++ Makefile +@@ -48,8 +48,10 @@ INCDIR ?= $(GLEW_DEST)/include/GL + PKGDIR ?= $(GLEW_DEST)/lib/pkgconfig + + ifneq ($(GLEW_NO_GLU), -DGLEW_NO_GLU) ++ifneq ($(SYSTEM), darwin) + LIBGLU = glu + endif ++endif + + DIST_NAME ?= glew-$(GLEW_VERSION) + DIST_SRC_ZIP ?= $(shell pwd)/$(DIST_NAME).zip +@@ -119,7 +121,7 @@ ifneq ($(STRIP),) + endif + + lib/$(LIB.SHARED): $(LIB.SOBJS) +- $(LD) $(LDFLAGS.SO) -o $@ $^ $(LIB.LDFLAGS) $(LIB.LIBS) ++ $(CC) $(LDFLAGS) $(LDFLAGS.SO) -o $@ $^ $(LIB.LDFLAGS) $(LIB.LIBS) + ifneq ($(LN),) + $(LN) $(LIB.SHARED) lib/$(LIB.SONAME) + $(LN) $(LIB.SHARED) lib/$(LIB.DEVLNK) +@@ -178,13 +180,13 @@ bin: + mkdir bin + + bin/$(GLEWINFO.BIN): $(GLEWINFO.BIN.OBJ) lib/$(LIB.SHARED) +- $(CC) $(CFLAGS) -o $@ $(GLEWINFO.BIN.OBJ) $(BIN.LIBS) ++ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(GLEWINFO.BIN.OBJ) $(BIN.LIBS) + ifneq ($(STRIP),) + $(STRIP) -x $@ + endif + + bin/$(VISUALINFO.BIN): $(VISUALINFO.BIN.OBJ) lib/$(LIB.SHARED) +- $(CC) $(CFLAGS) -o $@ $(VISUALINFO.BIN.OBJ) $(BIN.LIBS) ++ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(VISUALINFO.BIN.OBJ) $(BIN.LIBS) + ifneq ($(STRIP),) + $(STRIP) -x $@ + endif |