90f5f8ffe1
This should replace the yaboot-bin package (which should be dropped assuming this is found to be working well). This, instead of taking the binary from Debian, compiles yaboot from source. The tricky part here is e2fsprogs, or rather, libext2fs. Yaboot requires a fairly old version of it, and being a strictly ppc32 program, needs that library compiled in a minimal form for ppc32. In order to achieve that, I abuse the cross-compiler, using the musl ppc32 cross-compiler as that's universally available on all crosshosts, as well as all ppc64 (and ppc32 doesn't need it). The main reason to do this over shipping the binary is that this will actually work properly on some ppc64 machines, which require the bundled addnote executable, which can now be compiled properly for the native architecture.
20 lines
747 B
Diff
20 lines
747 B
Diff
Description: correct ofpath discovery on newer kernels
|
|
Author: Milan Kupcevic <milan@physics.harvard.edu>
|
|
Bug-Debian: http://bugs.debian.org/784387
|
|
Forwarded: no
|
|
---
|
|
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
|
|
--- a/ybin/ofpath
|
|
+++ b/ybin/ofpath
|
|
@@ -220,7 +220,10 @@
|
|
IEEE1394_ID=`cat /sys/block/$DEVNODE/device/ieee1394_id 2>/dev/null`
|
|
IEEE1394_ID=${IEEE1394_ID%%:*}
|
|
|
|
- PLUG_ID=$(ls -dv $SYS_PATH/host* 2>/dev/null | grep -n "/host$HOST_ID$")
|
|
+ PLUG_ID=$(ls -dv $SYS_PATH/*/host* 2>/dev/null | grep -n "/host$HOST_ID$")
|
|
+ [ -z "$PLUG_ID" ] && {
|
|
+ PLUG_ID=$(ls -dv $SYS_PATH/host* 2>/dev/null | grep -n "/host$HOST_ID$")
|
|
+ }
|
|
PLUG_ID=$((${PLUG_ID%%:*}-1))
|
|
|
|
PART=${PARTITION:+:$PARTITION}
|