Skip to content

Commit

Permalink
sys-firmware/midisport-firmware: Initial import from proaudio overlay.
Browse files Browse the repository at this point in the history
Signed-off-by: Patrice Clement <[email protected]>
  • Loading branch information
karllinden authored and monsieurp committed Jun 2, 2016
1 parent 9f9f517 commit 0061153
Show file tree
Hide file tree
Showing 6 changed files with 135 additions and 0 deletions.
23 changes: 23 additions & 0 deletions licenses/Midisport
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
The firmware files (*.ihx) are copyrighted by Midiman, and can be used
and redistributed only as part of this package.

All other files are distributed under the following license:

Copyright (c) 2003-2006 Clemens Ladisch <[email protected]>

Permission to use, copy, modify, and distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.

Alternatively, this software may be distributed and/or modified under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your
option) any later version.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
1 change: 1 addition & 0 deletions sys-firmware/midisport-firmware/Manifest
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DIST midisport-firmware-1.2.tar.gz 62948 SHA256 2aa82ef0bf26647fbdda4c2e9ed0033b41bd0f1b4020b87fa073e4462a048b2d SHA512 ac46b1e16dbee628d41e0c5b39730a4ee51e1f62187e5e56ed393f136937fdffa86ca84882d2627397f074ca2eb12be3a8701a5027999a0d00b84b706e227a0b WHIRLPOOL d8cfdf90d17eda43ee80727be7c32f63cfe7c755a85e28ab7085aae9ef892ecf7da2ad6b45bf7047d420dfc17c1ee91b537eb08f1f5ef8c5b167753ab6ab122e
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
--- midisport-firmware-1.2.orig/configure.ac 2006-03-05 22:01:45.000000000 +0100
+++ midisport-firmware-1.2/configure.ac 2013-01-06 22:08:40.479938650 +0100
@@ -1,9 +1,12 @@
# Process this file with autoconf to produce a configure script
AC_PREREQ(2.0)
AC_INIT(midisport-firmware, 1.2, [[email protected]])
-AM_INIT_AUTOMAKE($PACKAGE_NAME, $PACKAGE_VERSION)
+AM_INIT_AUTOMAKE
AC_REVISION($Revision$)
AC_CONFIG_SRCDIR(MidiSportLoader.ihx)
+m4_ifndef([PKG_PROG_PKG_CONFIG],
+ [m4_fatal([pkg-config is required])])
+PKG_PROG_PKG_CONFIG

AC_ARG_WITH([fxload],
AS_HELP_STRING([--with-fxload=name],
@@ -22,17 +25,8 @@
AC_MSG_ERROR([$FXLOAD not found; please install the fxload package first])
fi

-AC_MSG_CHECKING([for udev version])
-udev_ver=`udevinfo -V | awk '{ print $3 }'`
-if test -n "$udev_ver"; then
- AC_MSG_RESULT([$udev_ver])
-else
- AC_MSG_RESULT([none])
- udev_ver="0"
-fi
-if test "$udev_ver" -lt 057; then
- AC_MSG_ERROR([udev version 057 or later is required])
-fi
+PKG_CHECK_MODULES([udev], [udev >= 057], [], [
+ AC_MSG_ERROR(["udev of at least version 057 is required"])])

AC_ARG_WITH([udev],
AS_HELP_STRING([--with-udev=dir],
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
--- midisport-firmware-1.2.orig/42-midisport-firmware.rules.in 2006-03-05 22:01:45.000000000 +0100
+++ midisport-firmware-1.2/42-midisport-firmware.rules.in 2013-01-06 22:07:03.385941852 +0100
@@ -1,18 +1,13 @@
# midisport-firmware.rules - udev rules for loading firmware into MidiSport devices

-# DEVPATH=="/*.0" selects interface 0 only
-# (some udev versions don't work with SYSFS{bInterfaceNumber})
-
# MidiSport 2x2
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1001/*", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport2x2.ihx"
+ACTION=="add", SUBSYSTEM=="usb*", ATTRS{idVendor}=="0763", ATTRS{idProduct}=="1001", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport2x2.ihx -D %N"
# MidiSport 1x1
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1010/*", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport1x1.ihx"
+ACTION=="add", SUBSYSTEM=="usb*", ATTRS{idVendor}=="0763", ATTRS{idProduct}=="1010", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport1x1.ihx -D %N"
# KeyStation
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1014/*", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSportKS.ihx"
+ACTION=="add", SUBSYSTEM=="usb*", ATTRS{idVendor}=="0763", ATTRS{idProduct}=="1014", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSportKS.ihx -D %N"
# MidiSport 4x4
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1020/*", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport4x4.ihx"
+ACTION=="add", SUBSYSTEM=="usb*", ATTRS{idVendor}=="0763", ATTRS{idProduct}=="1020", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport4x4.ihx -D %N"
# MidiSport 8x8
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1031/110", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport8x8-2.10.ihx"
-ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1031/121", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport8x8-2.21.ihx"
-
-# vim: ft=conf
+#ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1031/110", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport8x8-2.10.ihx"
+#ACTION=="add", SUBSYSTEM=="usb", DEVPATH=="/*.0", ENV{PRODUCT}=="763/1031/121", RUN+="@fxload@ -s @firmwaredir@/MidiSportLoader.ihx -I @firmwaredir@/MidiSport8x8-2.21.ihx"
12 changes: 12 additions & 0 deletions sys-firmware/midisport-firmware/metadata.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>[email protected]</email>
<name>Karl Linden</name>
</maintainer>
<maintainer type="project">
<email>[email protected]</email>
<name>Proxy Maintainers</name>
</maintainer>
</pkgmetadata>
36 changes: 36 additions & 0 deletions sys-firmware/midisport-firmware/midisport-firmware-1.2.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI="6"

inherit autotools linux-info udev

DESCRIPTION="Firmware for M-Audio/Midiman USB MIDI devices"
HOMEPAGE="http://usb-midi-fw.sourceforge.net"
SRC_URI="http://downloads.sourceforge.net/usb-midi-fw/${P}.tar.gz"

LICENSE="Midisport"
SLOT="0"
KEYWORDS="~amd64 ~x86"

RDEPEND="sys-apps/fxload
virtual/udev"
DEPEND="${RDEPEND}
virtual/pkgconfig"

CONFIG_CHECK="~SND_USB_AUDIO"

PATCHES=(
"${FILESDIR}"/${P}-configure.patch
"${FILESDIR}"/${P}-rules.patch
)

src_prepare() {
default
eautoreconf
}

src_configure() {
econf --with-udev="$(get_udevdir)"
}

0 comments on commit 0061153

Please sign in to comment.