Git "could not find xcodebuild" error after updating X Mavericks OS

When I try to run previously running git commands, I get the following:

dyld: Symbol not found: _sqlite3_intarray_bind Referenced from: /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData Expected in: /opt/local/lib/libsqlite3.dylib in /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData git: error: unable to locate xcodebuild, please make sure the path to the Xcode folder is set correctly! git: error: You can set the path to the Xcode folder using /usr/bin/xcode-select -switch 

How can i fix this?

+27
source share
10 answers

This works for me sudo xcode-select --switch /Library/Developer/CommandLineTools/

+69
source

After a lot of resorting to help and confusion, the following steps lead to a solution (with Xcode installed). Some of them may be optional, so please do not hesitate to dwell on this in detail, as I am not an expert on these errors.

  • download Mavericks command line tools https://developer.apple.com/downloads/
  • xcode-select --install
  • sudo xcode-select -switch /Library/Developer/CommandLineTools
  • brew install sqlite3
  • commented out entry DYLD_LIBRARY_PATH in my .bashrc
+24
source

If you have already installed Xcode, you can run the following command to determine and specify the correct location

 sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer 

Or use the AppStore to install the latest Xcode.

+11
source
 xcode-select --install sudo xcode-select -switch /Library/Developer/CommandLineTools 

It did it for me.

+4
source

Most likely you need to reinstall the command line tools before switching the xcode path to point there.

Install tools first

$ xcode-select --install

This will install the tools in the /Library/Developer/CommandLineTools .

Then specify the path to xcode in the place where the tools were installed, for example

$ sudo xcode-select -switch /Library/Developer/CommandLineTools

Note. The current xcode path can be seen with the $ xcode-select -p command. My originally pointed to /Applications/Xcode.app/Contents/Developer when I received the error

+3
source

You might need to install Xcode 5.0.1 for Mavericks. Check for updates.

0
source

I encountered the same problem when running Fastlane on a new High Sierra installation. Solved with:

 sudo xcode-select --switch /Applications/Xcode.app 
0
source

This worked for me, just paste into the terminal: sudo xcode-select --switch / Library / Developer / CommandLineTools /

0
source

I met this error when I run the command "git clone xxx"

dyld: library not loaded: @ rpath / libswiftCore.dylib Link to: /Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild Reason: image not found git: error: cannot find xcodebuild, please make sure the path to the Xcode folder is specified correctly! git: error: you can set the path to the Xcode folder using / usr / bin / xcode-select -switch

Then run the command

 xcode-select -p 

pointing to /Applications/Xcode.app/Contents/Developer

After running the sudo xcode-select -switch /Library/Developer/CommandLineTools

this points to /Library/Developer/CommandLineTools

0
source

On MacOS Mojave, this worked for me (git 2.21.0):

 xcode-select --install sudo xcode-select -switch /Library/Developer/CommandLineTools 
0
source

Source: https://habr.com/ru/post/956907/


All Articles