From ea7f5b3c5e738146ad37a5a7eb5f786c8479c1be Mon Sep 17 00:00:00 2001 From: horsemanoffaith Date: Mon, 27 Feb 2017 04:59:55 +0000 Subject: [PATCH 1/2] add glewmx --- .SRCINFO | 16 ++++++++++++++++ PKGBUILD | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 .SRCINFO create mode 100755 PKGBUILD diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..830b459 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,16 @@ +pkgbase = glewmx + pkgdesc = The OpenGL Extension Wrangler MX + pkgver = 1.13.0 + pkgrel = 1 + url = http://launchpad.net/ubuntu/+source/glewmx + arch = i686 + arch = x86_64 + license = GPL + depends = libxmu + depends = libxi + depends = glu + source = http://launchpad.net/ubuntu/+archive/primary/+files/glewmx_1.13.0.orig.tar.gz + sha1sums = d5b1c499f429aa91c466193b4e8ea94a84019e37 + +pkgname = glewmx + diff --git a/PKGBUILD b/PKGBUILD new file mode 100755 index 0000000..583a755 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,46 @@ +# $Id: PKGBUILD 273106 2016-08-05 12:19:53Z andyrtr $ +# Maintainer: Andreas Radke +# Contributor: Stéphane Gaudreault +# Contributor: SleepyDog + +pkgname=glewmx +pkgver=1.13.0 +pkgrel=1 +pkgdesc="The OpenGL Extension Wrangler MX" +arch=('i686' 'x86_64') +url="http://launchpad.net/ubuntu/+source/glewmx" +license=('GPL') +depends=('libxmu' 'libxi' 'glu') +source=(http://launchpad.net/ubuntu/+archive/primary/+files/${pkgname}_${pkgver}.orig.tar.gz) +sha1sums=('d5b1c499f429aa91c466193b4e8ea94a84019e37') + +build() { + + cd glew-${pkgver} + + # move include folder to subfolder 'glew-1.13.0' + sed -i 's:$(GLEW_DEST)/include/GL:$(GLEW_DEST)/include/glew-1.13.0/GL:' Makefile + + sed -i 's|lib64|lib|' config/Makefile.linux + sed -i '/^.PHONY: .*\.pc$/d' Makefile + + make +} + +package() { + + cd glew-${pkgver} + + # update glewmx include path to reflect previous changes (see build comments) + msg update glewmx.pc + sed -i 's:includedir=${prefix}/include:includedir=${prefix}/include/glew-1.13.0:' glewmx.pc + + make GLEW_DEST="${pkgdir}/usr" install.all + + rm -R ${pkgdir}/usr/bin + rm ${pkgdir}/usr/lib/{libGLEW.so,libGLEW.a} + rm ${pkgdir}/usr/lib/pkgconfig/glew.pc + + chmod 0755 "${pkgdir}"/usr/lib/libGLEW*.so.${pkgver} + +} From 667034a50e0cca6da9252f7026c9ccdd4bbfde5d Mon Sep 17 00:00:00 2001 From: Manuel Date: Tue, 14 Jun 2022 00:28:51 +0200 Subject: [PATCH 2/2] Refactor PKGBUILD --- .SRCINFO | 6 ++---- PKGBUILD | 53 +++++++++++++++++++++++++++-------------------------- 2 files changed, 29 insertions(+), 30 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index 830b459..a254fbb 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -3,14 +3,12 @@ pkgbase = glewmx pkgver = 1.13.0 pkgrel = 1 url = http://launchpad.net/ubuntu/+source/glewmx - arch = i686 arch = x86_64 license = GPL depends = libxmu depends = libxi depends = glu - source = http://launchpad.net/ubuntu/+archive/primary/+files/glewmx_1.13.0.orig.tar.gz - sha1sums = d5b1c499f429aa91c466193b4e8ea94a84019e37 + source = https://launchpad.net/ubuntu/+archive/primary/+files/glewmx_1.13.0.orig.tar.gz + sha256sums = aa25dc48ed84b0b64b8d41cdd42c8f40f149c37fa2ffa39cd97f42c78d128bc7 pkgname = glewmx - diff --git a/PKGBUILD b/PKGBUILD index 583a755..3af9bc2 100755 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,46 +1,47 @@ -# $Id: PKGBUILD 273106 2016-08-05 12:19:53Z andyrtr $ -# Maintainer: Andreas Radke +# Maintainer: Manuel Hüsers +# Contributor: Andreas Radke # Contributor: Stéphane Gaudreault # Contributor: SleepyDog pkgname=glewmx pkgver=1.13.0 pkgrel=1 -pkgdesc="The OpenGL Extension Wrangler MX" -arch=('i686' 'x86_64') +pkgdesc='The OpenGL Extension Wrangler MX' +arch=('x86_64') url="http://launchpad.net/ubuntu/+source/glewmx" license=('GPL') depends=('libxmu' 'libxi' 'glu') -source=(http://launchpad.net/ubuntu/+archive/primary/+files/${pkgname}_${pkgver}.orig.tar.gz) -sha1sums=('d5b1c499f429aa91c466193b4e8ea94a84019e37') +source=(https://launchpad.net/ubuntu/+archive/primary/+files/${pkgname}_${pkgver}.orig.tar.gz) +sha256sums=('aa25dc48ed84b0b64b8d41cdd42c8f40f149c37fa2ffa39cd97f42c78d128bc7') + +prepare() { + cd "glew-${pkgver}" + + # move include folder to subfolder 'glew-1.13.0' + sed -i 's:$(GLEW_DEST)/include/GL:$(GLEW_DEST)/include/glew-1.13.0/GL:' Makefile + + sed -i 's|lib64|lib|' config/Makefile.linux + sed -i '/^.PHONY: .*\.pc$/d' Makefile +} build() { - - cd glew-${pkgver} + cd "glew-${pkgver}" - # move include folder to subfolder 'glew-1.13.0' - sed -i 's:$(GLEW_DEST)/include/GL:$(GLEW_DEST)/include/glew-1.13.0/GL:' Makefile - - sed -i 's|lib64|lib|' config/Makefile.linux - sed -i '/^.PHONY: .*\.pc$/d' Makefile - - make + make } package() { + cd "glew-${pkgver}" - cd glew-${pkgver} - - # update glewmx include path to reflect previous changes (see build comments) - msg update glewmx.pc - sed -i 's:includedir=${prefix}/include:includedir=${prefix}/include/glew-1.13.0:' glewmx.pc + # update glewmx include path to reflect previous changes (see build comments) + msg update glewmx.pc + sed -i 's:includedir=${prefix}/include:includedir=${prefix}/include/glew-1.13.0:' glewmx.pc - make GLEW_DEST="${pkgdir}/usr" install.all + make GLEW_DEST="${pkgdir}/usr" install.all - rm -R ${pkgdir}/usr/bin - rm ${pkgdir}/usr/lib/{libGLEW.so,libGLEW.a} - rm ${pkgdir}/usr/lib/pkgconfig/glew.pc - - chmod 0755 "${pkgdir}"/usr/lib/libGLEW*.so.${pkgver} + rm -R ${pkgdir}/usr/bin + rm ${pkgdir}/usr/lib/{libGLEW.so,libGLEW.a} + rm ${pkgdir}/usr/lib/pkgconfig/glew.pc + chmod 0755 "${pkgdir}"/usr/lib/libGLEW*.so.${pkgver} }