BrainiumLLC / cargo-mobile

Rust on mobile made easy!
Apache License 2.0
1.24k stars 52 forks source link

UUID lookup failed on macOS 12.5.1 #113

Open campbellcole opened 2 years ago

campbellcole commented 2 years ago

The error left in console is as follows:

action request: Failed to install Rust Xcode plugin; this component is optional, so init will continue anyway,
but Xcode debugging won't work until this is resolved!
    Failed to lookup Xcode UUID: Command "defaults read /Library/Developer/Info DVTPlugInCompatibilityUUID" didn't complete
    successfully, exiting with code 1. stderr contents: 2022-11-25 23:51:29.990 defaults[74905:4131174]
    The domain/default pair of (/Library/Developer/Info, DVTPlugInCompatibilityUUID) does not exist

I did some digging through the source code to figure out why this was happening, and I saw the comment that says check if uuid is supported, and prompt user to open issue if not. It seems you may have forgotten to add the prompt, but that's all right 😄.

I tried to see if I could locate the UUID anywhere using the defaults command, and the entire /Library/Developer/Info domain doesn't exist. I had installed xcode but hadn't opened it yet when I initially tried to run it, so I ran xcode and updated xcode-select tools using Software Update, and still I don't have those defaults anywhere. I couldn't find anything online either, so I figured it's best to let you know. I'll see about installing the xcode rust plugin manually now...

Update 1: I tried searching for the DVTPlugInCompatibilityUUID key using defaults find DVTPlugInCompatibilityUUID and it turned up nothing. I'm thinking there must be some application I haven't launched yet that registers the domain/keys.

Update 2: I located the DVTPlugInCompatibilityUUID key. It was found using defaults read /Applications/Xcode.app/Contents/Info DVTPlugInCompatibilityUUID. I don't know if xcode-select -p is supposed to return /Library/Developer/CommandLineTools, but it is on my machine. Also I realize now that the prompt the user to open an issue is intended for when it does find the UUID but it isn't supported, I apologize.