Bug 478911 - Midisport firmware not loaded - 42-midisport-firmware.rules.in used in spec-file as is
Summary: Midisport firmware not loaded - 42-midisport-firmware.rules.in used in spec-f...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: midisport-firmware
Version: 10
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Dave Jones
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-01-05 22:54 UTC by Patrik Elmberg
Modified: 2015-01-04 22:30 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-02-05 02:17:44 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Patrik Elmberg 2009-01-05 22:54:37 UTC
Description of problem:
Wrong path to fxload and firmware files in installed file,
/etc/udev/rules.d/42-midisport-firmware.rules.

Cause: Faulty spec file doesn't make and install correct rules file.
install -pm 0644 42-midisport-firmware.rules.in $RPM_BUILD_ROOT/%{_sysconfdir}
                                            ^^^
/udev/rules.d/42-midisport-firmware.rules

Version-Release number of selected component (if applicable):
# rpm -q midisport-firmware fxload udev; uname -r
midisport-firmware-1.2-2.noarch
fxload-2002_04_11-7.fc9.i386
udev-127-3.fc10.i386
2.6.27.9-159.fc10.i686

How reproducible:
Always

Steps to Reproduce:
1. udevadm control --log_priority=debug
2. tail -f /var/log/messages
3. unplug and re-plug midisport usb device
4. look at faulty path reported by udevd-event (/lib/udev/@fxload@)
  
Actual results:
No firmware loaded to device, thus not functioning
lsusb listing "non-ready" device
Bus 007 Device 032: ID 0763:1010 Midiman MidiSport 1x1
                 ^             ^
Expected results:
Green LEDs turned on under my desk, working midi
lsusb reporting new device as a result of firmware loaded
Bus 007 Device 033: ID 0763:1011 Midiman MidiSport 1x1
                 ^             ^

Additional info:
Fixing paths manually as a work-around.
udevd-event[24260]: run_program: '/sbin/fxload -s /lib/firmware/MidiSportLoader.ihx -I /lib/firmware/MidiSport1x1.ihx'

Comment 1 Dave Jones 2009-01-23 21:46:11 UTC
I don't have one of these devices any more. Are you interested in taking over this package at all ?

Comment 2 Patrik Elmberg 2009-01-24 18:52:46 UTC
Sorry no, but I will gladly test any updated rpm.

Comment 3 Dave Jones 2009-01-28 16:42:27 UTC
ok, can you send me a diff of what you want changed, and I'll get it built.
I'm not understanding what exactly is going wrong, as rpm -ql shows the expected files end up in the right places in the rpm.

Comment 4 Patrik Elmberg 2009-01-28 20:05:18 UTC
Sorry for being vague. It is the *content* of a file that is wrong.
Here's a diff for a simple sed-fix in the SPEC file that should do the trick:

[root@localhost SPECS]# diff -Nau midisport-firmware.spec midisport-firmware.spec-new
--- midisport-firmware.spec	2008-08-22 19:19:18.000000000 +0200
+++ midisport-firmware.spec-new	2009-01-28 20:53:41.000000000 +0100
@@ -1,6 +1,6 @@
 Name:           midisport-firmware
 Version:        1.2
-Release:        2
+Release:        3
 Summary:        Firmware for the M-Audio/Midiman USB MIDI and Audio devices
 Group:          System Environment/Kernel
 License:        (MIT or GPLv2+) and Redistributable, no modification permitted
@@ -17,7 +17,7 @@
 %setup -q
 
 %build
-# Nothing to build
+sed -i -e 's|@fxload@|/sbin/fxload|g' -e 's|@firmwaredir@|/lib/firmware|g' 42-midisport-firmware.rules.in
 
 %install
 rm -rf $RPM_BUILD_ROOT

Comment 5 Dave Jones 2009-01-28 20:53:46 UTC
ah, I see.

Actually, looking closer, there's stuff in the makefile to do all this for us.

does just adding 'configure ; make' to the build do everything necessary?

(oh, and add a BuildRequires: fxload)

Comment 6 Patrik Elmberg 2009-01-29 21:16:42 UTC
A simple configure; make will give you /usr/local/share/usb/maudio.

Counting the number of rows in configure and Makefile, I believe my one-liner is far more easier to read and maintain. And the minimal effort of making this work.

I don't see why fxload should be required during build.
Possibly adding "Requires: udev" as is done in the upstream spec file.
Sorry, still not enough interest to become a package maintainer. =)

Comment 7 Dave Jones 2009-01-30 02:11:14 UTC
I agree. I'll patch it up with your diff, and get an update built.

Thanks.

Comment 8 Dave Jones 2009-01-30 02:33:25 UTC
Care to test 
http://kojipkgs.fedoraproject.org/packages/midisport-firmware/1.2/4.fc10/noarch/midisport-firmware-1.2-4.fc10.noarch.rpm

Just to make sure I didn't do something silly?

Thanks.

Comment 9 Patrik Elmberg 2009-01-30 13:45:43 UTC
Sweet music here.
(Maybe no need to bump the Release: from 2 to 4.)

Comment 10 Dave Jones 2009-01-30 15:30:53 UTC
release bump was a side-effect of me screwing something up in CVS.

I'll push it out as an update, thanks for testing.

Comment 11 Fedora Update System 2009-02-05 02:17:42 UTC
midisport-firmware-1.2-4.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.