Skip to content
Browse files

Now binfmt_misc.sh handles 32bit Mach-O as well

  • Loading branch information...
1 parent 4654369 commit 23449235941df3d6c4905a38ee53c29a8ddaee26 @shinh committed
Showing with 3 additions and 1 deletion.
  1. +3 −1 binfmt_misc.sh
View
4 binfmt_misc.sh
@@ -50,14 +50,16 @@ case $cmd in
start)
sudo sh -c "
echo :Mach-O '64bit:M::\\xcf\\xfa\\xed\\xfe::$ld_mac:' > /proc/sys/fs/binfmt_misc/register
+echo :Mach-O '32bit:M::\\xce\\xfa\\xed\\xfe::$ld_mac:' > /proc/sys/fs/binfmt_misc/register
echo :Mach-O 'fat:M::\\xca\\xfe\\xba\\xbe::$ld_mac:' > /proc/sys/fs/binfmt_misc/register
"
echo "binfmt_misc for mach-o was registered"
;;
stop)
sudo sh -c '
-echo -1 > /proc/sys/fs/binfmt_misc/Mach-O\ fat
echo -1 > /proc/sys/fs/binfmt_misc/Mach-O\ 64bit
+echo -1 > /proc/sys/fs/binfmt_misc/Mach-O\ 32bit
+echo -1 > /proc/sys/fs/binfmt_misc/Mach-O\ fat
'
echo "binfmt_misc for mach-o was unregistered"
;;

0 comments on commit 2344923

Please sign in to comment.
Something went wrong with that request. Please try again.