[arch-commits] Commit in ladspa/trunk (PKGBUILD hardcode-path.patch)

Jan de Groot jgc at archlinux.org
Thu Nov 6 23:57:55 UTC 2008


    Date: Thursday, November 6, 2008 @ 18:57:55
  Author: jgc
Revision: 18543

upgpkg: ladspa 1.13-2
    Fix gcc dependency and mkdirhier usage (FS#11937)
Remove the profile.d scriptlet. The default path is hardcoded using a patch
Fix a memleak in the plugin scanning

Added:
  ladspa/trunk/hardcode-path.patch
Modified:
  ladspa/trunk/PKGBUILD

---------------------+
 PKGBUILD            |   27 +++++++++++++--------------
 hardcode-path.patch |   28 ++++++++++++++++++++++++++++
 2 files changed, 41 insertions(+), 14 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2008-11-06 23:52:15 UTC (rev 18542)
+++ PKGBUILD	2008-11-06 23:57:55 UTC (rev 18543)
@@ -3,24 +3,23 @@
 
 pkgname=ladspa
 pkgver=1.13
-pkgrel=1
+pkgrel=2
 pkgdesc="Linux Audio Developer's Simple Plugin API (LADSPA)"
 arch=("i686" "x86_64")
 license=('LGPL')
 url="http://www.ladspa.org/"
-depends=('gcc>=4.0.2')
-source=(http://www.ladspa.org/download/$pkgname\_sdk\_$pkgver.tgz)
+depends=('gcc-libs>=4.3')
+source=(http://www.ladspa.org/download/${pkgname}_sdk_${pkgver}.tgz
+	hardcode-path.patch)
+md5sums=('671be3e1021d0722cadc7fb27054628e'
+         '27743258232d828575d66940e6de2858')
 
 build() {
-  cd $startdir/src/$pkgname\_sdk/src
-  make targets
-  make INSTALL_PLUGINS_DIR=$startdir/pkg/usr/lib/ladspa/ \
-       INSTALL_INCLUDE_DIR=$startdir/pkg/usr/include/ \
-       INSTALL_BINARY_DIR=$startdir/pkg/usr/bin/ install || return 1
-  # fix 'Warning: You do not have a LADSPA_PATH environment variable set.'
-  mkdir -p $startdir/pkg/etc/profile.d
-  echo 'export LADSPA_PATH="/usr/lib/ladspa/"' > $startdir/pkg/etc/profile.d/ladspa.sh
-  chmod a+x $startdir/pkg/etc/profile.d/ladspa.sh
-
+  cd "${srcdir}/${pkgname}_sdk/src"
+  patch -Np1 -i "${srcdir}/hardcode-path.patch" || return 1
+  sed -i -e 's/mkdirhier/mkdir -p/' makefile || return 1
+  make targets || return 1
+  make INSTALL_PLUGINS_DIR="${pkgdir}/usr/lib/ladspa/" \
+       INSTALL_INCLUDE_DIR="${pkgdir}/usr/include/" \
+       INSTALL_BINARY_DIR="${pkgdir}/usr/bin/" install || return 1
 }
-md5sums=('671be3e1021d0722cadc7fb27054628e')

Added: hardcode-path.patch
===================================================================
--- hardcode-path.patch	                        (rev 0)
+++ hardcode-path.patch	2008-11-06 23:57:55 UTC (rev 18543)
@@ -0,0 +1,28 @@
+--- src/search.c.orig	2008-11-07 00:38:18.000000000 +0100
++++ src/search.c	2008-11-07 00:50:51.000000000 +0100
+@@ -83,6 +83,8 @@
+ 	dlclose(pcFilename);
+ 	free(pcFilename);
+       }
++    } else {
++      free(pcFilename);
+     }
+   }
+ }
+@@ -99,13 +101,10 @@
+ 
+   pcLADSPAPath = getenv("LADSPA_PATH");
+   if (!pcLADSPAPath) {
+-    fprintf(stderr,
+-	    "Warning: You do not have a LADSPA_PATH "
+-	    "environment variable set.\n");
+-    return;
++    pcStart = "/usr/lib/ladspa/";
++  } else {
++    pcStart = pcLADSPAPath;
+   }
+-  
+-  pcStart = pcLADSPAPath;
+   while (*pcStart != '\0') {
+     pcEnd = pcStart;
+     while (*pcEnd != ':' && *pcEnd != '\0')




More information about the arch-commits mailing list