xcrun produce an error during package compilation

 If you have this error:

Avis dans system2("xcrun", "--show-sdk-version", TRUE, TRUE) :

  l'exécution de la commande ''xcrun' --show-sdk-version 2>&1' renvoie un statut 1

using SDK: ‘NA’


You must reinstall Xcode:

1) Check if Xcode is installed

xcode-select -print-path

# If the output of the above command is not similar to the following line, Xcode is not installed. Skip to Step 3.
# /Library/Developer/CommandLineTools

2) Remove Bad Xcode Installation

# Remove Developer folder
sudo rm -rf $(xcode-select -print-path)

# Remove CommandLineTools folder
sudo rm -rf /Library/Developer/CommandLineTools

3) Install Xcode

sudo xcode-select --install

Messing with Xcode's Path

If the above didn't resolve your issue, you may have a problem with the path Xcode is installed at. Use the following to help if necessary.

# Switch Xcode's path
sudo xcode-select -switch /Library/Developer/CommandLineTools

# Reset Xcode's path
sudo xcode-select --reset


Commentaires

Posts les plus consultés de ce blog

Standard error from Hessian Matrix... what can be done when problem occurs

stepAIC from package MASS with AICc

Multivariable analysis and correlation of iconography