dokterdok / Continuity-Activation-Tool

An all-in-one tool to activate and diagnose macOS 10.10-12 Continuity on compatible Mac configurations.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Errors with stat and chmod

bdwilson opened this issue · comments

It worked; and I thank you!! Just giving you a heads up on this error. This was a MBP Early 2011.

$ sudo ./contitool.sh activate
--- OS X Continuity Activation Tool 1.0.0 ---
                 by dokterdok

--- Initiating system compatibility check ---

Verifying Mac model reference...        OK
Verifying OS X version...               OK
Verifying Bluetooth hardware...         OK
Verifying Mac board-id...               OK
Verifying active AirPort drivers...     OK
Verifying OS kext protection...         OK
Verifying kexts readability...          OK
Verifying Bluetooth blacklist status... OK
Verifying Wi-Fi whitelist status...     OK

--- Initiating Continuity mod ---

Backing up drivers...                   OK. Wi-Fi and Bluetooth kexts were backed up in '/Users/wilson/KextsBackup'
Skipping blacklist patch...             OK
Patching whitelist...stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.stat: invalid option -- 'r'
Try 'stat --help' for more information.
chmod: invalid mode: ''
Try 'chmod --help' for more information.
.      OK
Applying correct permissions...         OK
Updating kext caches... /               OK
Updating system caches... |             OK
Applying correct permissions...         OK
Updating kext caches... /               OK
Updating system caches... |             OK
Fixing disk permissions (~5min wait)...OK

ALMOST DONE! After rebooting:
1) Make sure that both your Mac and iOS device have Bluetooth turned on, and are on the same Wi-Fi network.
2) On OS X go to SYSTEM PREFERENCES> GENERAL> and ENABLE HANDOFF.
3) On iOS go to SETTINGS> GENERAL> HANDOFF & SUGGESTED APPS> and ENABLE HANDOFF.
4) On OS X, and sign out and then sign in again to your iCloud account.
Further troubleshooting: support.apple.com/kb/TS5458

Thanks to Lem3ssie, UncleSchnitty, Skvo, TealShark, Manic Harmonic, rob3r7o for their research, testing, and support.


Please close any open applications and press any key to reboot...

Same here, I dunno if the coreutils installed via brew might be the problem, but I got exactly the same errors.

Could you please:

  • Run man chmod in Terminal, scroll to the bottom and look at the date. E.g. my version says "July 08, 2004".
  • Run chmod in Terminal and copy/paste the output here

This should help us determine if we're running the same chmod version.

Edit: please also do this with the 'stat' command.

You may also want to try this workaround:

  1. Open Continuity Activation Tool.app/Contents/MacOS/contitool.sh in your favorite text editor
  2. Find and replace 'stat -r' with '/usr/bin/stat -r'

@dokterdok at least for me the solution seemed to be removing brew's "Coreutils" bin directory from the path (as GNU's "stat" does not have an "-r" option).

Your second solution would avoid a different "stat" or "chmod" than OSX' own being executed.

As the patch worked even with those errors, I haven't felt the need to "re-execute" it.

Thanks for the info PatTheMav, that's good to know.

The latest version of CAT includes a fix for that. All utilities are called with their full paths now (thanks Chauncey Garrett for the tip). Could one of you please check it out and confirm if this is solved or not? Otherwise I'll close this issue. Thanks

@dokterdok Glad to help out! Thanks for producing the tool!

Closing, considered as fixed as no similar reports were provided since then.