summaryrefslogtreecommitdiff
path: root/extra/portmidi
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-11-10 01:23:31 -0800
committerroot <root@rshg054.dnsready.net>2012-11-10 01:23:31 -0800
commit6eea0bd1e92ed5aa53cb5f59102529c88e9e1786 (patch)
treeb069468f4084f5af5ad3ba2ecab7e6b4deb90267 /extra/portmidi
parent3f7cb62ef558ea147661abe007a4293c0069fc62 (diff)
Sat Nov 10 01:23:30 PST 2012
Diffstat (limited to 'extra/portmidi')
-rw-r--r--extra/portmidi/PKGBUILD46
-rw-r--r--extra/portmidi/portmidi-217-build-fix.patch29
2 files changed, 75 insertions, 0 deletions
diff --git a/extra/portmidi/PKGBUILD b/extra/portmidi/PKGBUILD
new file mode 100644
index 000000000..ac16436ff
--- /dev/null
+++ b/extra/portmidi/PKGBUILD
@@ -0,0 +1,46 @@
+# $Id: PKGBUILD 170712 2012-11-10 01:03:47Z eric $
+# Maintainer: Lukas Fleischer <archlinux at cryptocrack dot de>
+# Contributor: SpepS <dreamspepser at yahoo dot it>
+# Contributor: Denis Martinez <deuns.martinez AT gmail DOT com>
+
+pkgname=portmidi
+pkgver=217
+pkgrel=3
+pkgdesc="Platform independent library for real-time MIDI input/output."
+arch=('i686' 'x86_64')
+url='http://portmedia.sourceforge.net/'
+license=('GPL')
+depends=('alsa-lib')
+makedepends=('cmake' 'java-environment')
+source=("http://downloads.sourceforge.net/project/portmedia/${pkgname}/${pkgver}/${pkgname}-src-${pkgver}.zip"
+ 'portmidi-217-build-fix.patch')
+md5sums=('03f46fd3947e2ef4c8c465baaf832241'
+ '59cb428b29a33bab3bb5811cda479a9b')
+
+build() {
+ cd "${srcdir}/${pkgname}"
+
+ sed -i "s#/usr/local#/usr#" */CMakeLists.txt pm_python/setup.py
+ mkdir -p pm_java/Release
+
+ # build fix for "pm_java/CMakeLists.txt" (fixes FS#27118)
+ patch -p1 -i ../portmidi-217-build-fix.patch
+
+ cmake . -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY=Release \
+ -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=Release \
+ -DCMAKE_RUNTIME_OUTPUT_DIRECTORY=Release
+
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}"
+
+ make DESTDIR="${pkgdir}" install
+
+ # Fix missing symlink for libporttime.so (FS#21528).
+ mv "${pkgdir}/usr/lib/libportmidi_s.a" "${pkgdir}/usr/lib/libportmidi.a"
+ ln -s "/usr/lib/libportmidi.so" "${pkgdir}/usr/lib/libporttime.so"
+ ln -s "/usr/lib/libportmidi.a" "${pkgdir}/usr/lib/libporttime.a"
+}
diff --git a/extra/portmidi/portmidi-217-build-fix.patch b/extra/portmidi/portmidi-217-build-fix.patch
new file mode 100644
index 000000000..3e2dfef29
--- /dev/null
+++ b/extra/portmidi/portmidi-217-build-fix.patch
@@ -0,0 +1,29 @@
+diff -rup portmidi.orig/pm_java/CMakeLists.txt portmidi/pm_java/CMakeLists.txt
+--- portmidi.orig/pm_java/CMakeLists.txt 2009-11-04 16:20:44.000000000 +0100
++++ portmidi/pm_java/CMakeLists.txt 2012-01-24 21:13:08.513182169 +0100
+@@ -15,13 +15,11 @@ if(UNIX)
+ add_custom_command(OUTPUT pmdefaults/PmDefaultsFrame.class
+ COMMAND javac -classpath . pmdefaults/PmDefaultsFrame.java
+ MAIN_DEPENDENCY pmdefaults/PmDefaultsFrame.java
+- DEPENDS pmdefaults/PmDefaults.java
+- WORKING_DIRECTORY pm_java)
++ DEPENDS pmdefaults/PmDefaults.java)
+ add_custom_command(OUTPUT pmdefaults/PmDefaults.class
+ COMMAND javac -classpath . pmdefaults/PmDefaults.java
+ MAIN_DEPENDENCY pmdefaults/PmDefaults.java
+- DEPENDS pmdefaults/PmDefaultsFrame.java
+- WORKING_DIRECTORY pm_java)
++ DEPENDS pmdefaults/PmDefaultsFrame.java)
+ add_custom_command(OUTPUT ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/pmdefaults.jar
+ COMMAND cp pmdefaults/portmusic_logo.png .
+ COMMAND jar cmf pmdefaults/manifest.txt pmdefaults.jar
+@@ -31,8 +29,7 @@ if(UNIX)
+ COMMAND mv pmdefaults.jar ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+ COMMAND rm portmusic_logo.png
+ MAIN_DEPENDENCY pmdefaults/PmDefaults.class
+- DEPENDS ${PMDEFAULTS_ALL_CLASSES}
+- WORKING_DIRECTORY pm_java)
++ DEPENDS ${PMDEFAULTS_ALL_CLASSES})
+ add_custom_target(pmdefaults_target ALL
+ DEPENDS ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/pmdefaults.jar)
+ # message(STATUS "add_custom_target: pmdefaults.jar")