File libspe2.binfmt.patch of Package libspe2

---
 elfspe/scripts/elfspe-register |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

--- a/elfspe/scripts/elfspe-register
+++ b/elfspe/scripts/elfspe-register
@@ -1,8 +1,15 @@
 #!/bin/sh
+mount -t spufs spufs /spu
+modprobe binfmt_misc
+
 if test -f /proc/sys/fs/binfmt_misc/spe
 then
   echo "elfspe already registered"
-else	
+else
+  if test ! -f /proc/sys/fs/binfmt_misc/register
+  then
+    mount -v -t binfmt_misc binfmt_misc /proc/sys/fs/binfmt_misc
+  fi
   echo ':spe:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x17::@BINDIR@/elfspe:' \
   >/proc/sys/fs/binfmt_misc/register
 fi
openSUSE Build Service is sponsored by