diff options
-rw-r--r-- | .SRCINFO | 22 | ||||
-rw-r--r-- | .gitignore | 5 | ||||
-rw-r--r-- | PKGBUILD | 96 | ||||
-rw-r--r-- | glew-install.patch | 65 |
4 files changed, 124 insertions, 64 deletions
@@ -1,22 +1,30 @@ pkgbase = glew-git pkgdesc = The OpenGL Extension Wrangler Library - pkgver = 2.0.0.r26.g6ee72f2 + pkgver = 2.2.0.r41.g5a2307f pkgrel = 1 - url = http://glew.sourceforge.net + url = https://github.com/nigels-com/glew arch = i686 arch = x86_64 license = BSD license = MIT license = GPL - makedepends = python2 + makedepends = git + makedepends = python depends = libxmu depends = libxi depends = glu provides = glew - provides = glew-git + provides = libGLEW.so conflicts = glew - source = git://github.com/nigels-com/glew.git - sha1sums = SKIP + source = git+https://github.com/nigels-com/glew + source = git+https://github.com/KhronosGroup/OpenGL-Registry.git + source = git+https://github.com/KhronosGroup/EGL-Registry.git + source = git+https://github.com/nigels-com/glfixes + source = glew-install.patch + sha256sums = SKIP + sha256sums = SKIP + sha256sums = SKIP + sha256sums = SKIP + sha256sums = 30c77b49ff64f5b936368426f957a217b6d8a3f8d0c83a7eaa69222ed45cd811 pkgname = glew-git - diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..50c8aba9b796 --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +* +!/.gitignore +!/.SRCINFO +!/PKGBUILD +!/*.patch @@ -1,74 +1,56 @@ -####### ORIGINALLY CLONED FROM ARCHLINUX GLEW PKGBUILD -## $Id: PKGBUILD 248262 2015-10-02 13:15:34Z foutrelis $ -## Maintainer: Andreas Radke <andyrtr@archlinux.org> -## Contributor: Stéphane Gaudreault <stephane@archlinux.org> -## Contributor: SleepyDog -########################################################## -# Maintainer: mnovick1988 -# -# glew-git - -# -# PLEASE inform me of any changes or required patches to -# this file. I will fix promptly. ~ mnovick1988 -# -########################################################## -# -# Changes: -# -# 20170302 - Added changes recommended by User "haagch" -# (fix PKGVER, added python Specific vesion) -# (note: added libGLEW.so.2 Symbolic Link) -# -########################################################## +# Maintainer: a821 +# Contributor: mnovick1988 +# Contributor: Andreas Radke <andyrtr@archlinux.org> +# Contributor: Stéphane Gaudreault <stephane@archlinux.org> +# Contributor: SleepyDog pkgname=glew-git -_pkgname=glew -pkgver=2.0.0.r26.g6ee72f2 +pkgver=2.2.0.r41.g5a2307f pkgrel=1 pkgdesc="The OpenGL Extension Wrangler Library" arch=('i686' 'x86_64') -url="http://glew.sourceforge.net" +url="https://github.com/nigels-com/glew" license=('BSD' 'MIT' 'GPL') depends=('libxmu' 'libxi' 'glu') -makedepends=('python2') -provides=('glew' 'glew-git') +makedepends=('git' 'python') +provides=('glew' 'libGLEW.so') conflicts=('glew') -source=(git://github.com/nigels-com/glew.git) -sha1sums=('SKIP') +source=("git+$url" + "git+https://github.com/KhronosGroup/OpenGL-Registry.git" + "git+https://github.com/KhronosGroup/EGL-Registry.git" + "git+https://github.com/nigels-com/glfixes" + "glew-install.patch" +) +sha256sums=('SKIP' + 'SKIP' + 'SKIP' + 'SKIP' + '30c77b49ff64f5b936368426f957a217b6d8a3f8d0c83a7eaa69222ed45cd811') pkgver() { -cd "glew" -git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' | sed 's/glew.//g' + cd ${pkgname%-git} + git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g; s/glew.//' +} + +prepare() { + cd ${pkgname%-git} + patch -Np1 -i ../glew-install.patch + cd ../glfixes + git checkout -b glew origin/glew } build() { - cd ${_pkgname} - - cd auto - make PYTHON=python2 - cd ../ - cmake build/cmake/. - make - + cd ${pkgname%-git}/auto + make REPO_OPENGL="$srcdir/OpenGL-Registry" REPO_EGL="$srcdir/EGL-Registry" \ + REPO_GLFIXES="$srcdir/glfixes" + cd .. + make STRIP= GLEW_PREFIX=/usr GLEW_DEST=/usr LIBDIR=/usr/lib } package() { - cd ${_pkgname} - - install -D -m755 ${srcdir}/${_pkgname}/bin/glewinfo ${pkgdir}/usr/bin/glewinfo - install -D -m755 ${srcdir}/${_pkgname}/bin/visualinfo ${pkgdir}/usr/bin/visualinfo - install -D -m755 ${srcdir}/${_pkgname}/include/GL/glew.h ${pkgdir}/usr/include/GL/glew.h - install -D -m755 ${srcdir}/${_pkgname}/include/GL/glxew.h ${pkgdir}/usr/include/GL/glxew.h - install -D -m755 ${srcdir}/${_pkgname}/include/GL/wglew.h ${pkgdir}/usr/include/GL/wglew.h - install -D -m755 ${srcdir}/${_pkgname}/glew.pc ${pkgdir}/usr/lib/pkgconfig/glew.pc - install -D -m755 ${srcdir}/${_pkgname}/glew.pc.in ${pkgdir}/usr/lib/pkgconfig/glew.pc.in - install -D -m755 ${srcdir}/${_pkgname}/lib/libGLEW.a ${pkgdir}/usr/lib/libGLEW.a - install -D -m755 ${srcdir}/${_pkgname}/lib/libGLEW.so ${pkgdir}/usr/lib/libGLEW.so - install -D -m644 LICENSE.txt "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE" - - cd ${pkgdir}/usr/lib/ - ln -s libGLEW.so libGLEW.so.13 - ln -s libGLEW.so.13 libGLEW.so.13.9 - ln -s libGLEW.so libGLEW.so.2 - + cd ${pkgname%-git} + make install.all DESTDIR="$pkgdir" GLEW_PREFIX=/usr GLEW_DEST=/usr LIBDIR=/usr/lib + install -D -m644 LICENSE.txt "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" } + +# vim: set ts=2 sw=2 et: diff --git a/glew-install.patch b/glew-install.patch new file mode 100644 index 000000000000..5d57e0f81ab9 --- /dev/null +++ b/glew-install.patch @@ -0,0 +1,65 @@ +diff --git a/Makefile b/Makefile +index 9a6b9ef..4a02f59 100644 +--- a/Makefile ++++ b/Makefile +@@ -120,7 +120,7 @@ ifneq ($(STRIP),) + endif + + $(LIB.SHARED.DIR)/$(LIB.SHARED): $(LIB.SOBJS) +- $(LD) $(LDFLAGS.SO) -o $@ $^ $(LIB.LDFLAGS) $(LIB.LIBS) ++ $(LD) $(LDFLAGS.SO) $(LDFLAGS) -o $@ $^ $(LIB.LDFLAGS) $(LIB.LIBS) + ifneq ($(LN),) + $(LN) $(LIB.SHARED) $(LIB.SHARED.DIR)/$(LIB.SONAME) + $(LN) $(LIB.SHARED) $(LIB.SHARED.DIR)/$(LIB.DEVLNK) +@@ -131,11 +131,11 @@ endif + + tmp/$(SYSTEM)/default/static/glew.o: src/glew.c include/GL/glew.h include/GL/wglew.h include/GL/glxew.h + @mkdir -p $(dir $@) +- $(CC) -DGLEW_NO_GLU -DGLEW_STATIC $(CFLAGS) $(CFLAGS.SO) -o $@ -c $< ++ $(CC) -DGLEW_NO_GLU -DGLEW_STATIC $(CFLAGS) $(CFLAGS.SO) $(LDFLAGS) -o $@ -c $< + + tmp/$(SYSTEM)/default/shared/glew.o: src/glew.c include/GL/glew.h include/GL/wglew.h include/GL/glxew.h + @mkdir -p $(dir $@) +- $(CC) -DGLEW_NO_GLU -DGLEW_BUILD $(CFLAGS) $(CFLAGS.SO) -o $@ -c $< ++ $(CC) -DGLEW_NO_GLU -DGLEW_BUILD $(CFLAGS) $(CFLAGS.SO) $(LDFLAGS) -o $@ -c $< + + # Force re-write of glew.pc, GLEW_DEST can vary + +@@ -178,25 +178,25 @@ endif + + bin/$(GLEWINFO.BIN): $(GLEWINFO.BIN.OBJ) $(LIB.SHARED.DIR)/$(LIB.SHARED) + @mkdir -p $(dir $@) +- $(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.SHARED.DIR)/$(LIB.SHARED) + @mkdir -p $(dir $@) +- $(CC) $(CFLAGS) -o $@ $(VISUALINFO.BIN.OBJ) $(BIN.LIBS) ++ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(VISUALINFO.BIN.OBJ) $(BIN.LIBS) + ifneq ($(STRIP),) + $(STRIP) -x $@ + endif + + $(GLEWINFO.BIN.OBJ): $(GLEWINFO.BIN.SRC) include/GL/glew.h include/GL/wglew.h include/GL/glxew.h + @mkdir -p $(dir $@) +- $(CC) -DGLEW_NO_GLU $(CFLAGS) $(CFLAGS.SO) -o $@ -c $< ++ $(CC) -DGLEW_NO_GLU $(CFLAGS) $(CFLAGS.SO) $(LDFLAGS) -o $@ -c $< + + $(VISUALINFO.BIN.OBJ): $(VISUALINFO.BIN.SRC) include/GL/glew.h include/GL/wglew.h include/GL/glxew.h + @mkdir -p $(dir $@) +- $(CC) -DGLEW_NO_GLU $(CFLAGS) $(CFLAGS.SO) -o $@ -c $< ++ $(CC) -DGLEW_NO_GLU $(CFLAGS) $(CFLAGS.SO) $(LDFLAGS) -o $@ -c $< + + # Install targets + +@@ -243,6 +243,7 @@ install.pkgconfig: glew.pc + $(INSTALL) -m 0644 glew.pc "$(DESTDIR)$(PKGDIR)/" + + uninstall: ++ $(RM) "$(DESTDIR)$(INCDIR)/eglew.h" + $(RM) "$(DESTDIR)$(INCDIR)/wglew.h" + $(RM) "$(DESTDIR)$(INCDIR)/glew.h" + $(RM) "$(DESTDIR)$(INCDIR)/glxew.h" |