`xcode-select --install` failing - xcode

Running OS X 10.9 trying to upload MacPorts following their guide
Jadam$ xcode-select --version
xcode-select version 2333.
so I have Xcode on the computer, but when I enter in xcode-select --install I get the following return in the terminal:
xcode-select: note: install requested for command line developer tools
Immediately followed by a, pop-up, update error message:
"The xcode-select command requires the command line in
developer tools. Would you like install the tools now?"
with the options "Get Xcode", "not now" & "Install". When I choose install, a "Finding Software" loading bar runs through but then ends with the following message:
"can't install the software because it is not currently
available from the software update server"
The solution here clearly did not work for me.

The other answer in the thread you linked is one of the possible solutions. It seems the installer will also display this message if your Command Line Tools are current and there are no updates available.
To check whether this is the case for you, check whether /usr/lib/tclConfig.sh exists on your system. Only the Command Line Tools contain this file on Mavericks, so if you have it, you also have the Command Line Tools installed.

I got the first message because I accidentally minimized the window installing the dev tools so might be worth checking that :)

Related

during install pod i am getting this error

Failed to extract git version from git --version. Instead I see:
xcrun: error: active developer path ("/Users/mcbook/Downloads/Xcode.app/Contents/Developer") does not exist
Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools.
See `man xcode-select` for more details.
Like all macOS apps, the Xcode app is represented in the file system as a folder, even though in Finder we see it as an icon.
In Xcode’s case its main app folder contains subdirectories that include some command line development tools that are necessary when installing apps that need to be compiled.
When you first run Xcode, it registers the location of this subfolder for you. Unfortunately, it looks like you first ran Xcode when it was still sitting in your Downloads folder, and so all your command line tools are still looking for it there.
I’m assuming that in the mean time you’ve moved Xcode – which, as you’d expect, moves all the application folder’s files and subfolders as well – to your /Applications folder.
You should be able to redirect all your tools to look in the new, correct location by using the following command line command:
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

Trouble getting root to build

I am currently trying to learn root for my research team and getting installed on my mac. I have been following the instructions detailed at this website and hit a snag. I've successfully installed the root package and command line tools, as well as assigned ownership of the folder to my user, however whenever I try to run
./configure
it gives the following error report:
Checking for Xcode OSX SDK ... no
configure: no Xcode OSX SDK found at /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk
Run xcode-select to update the developer directory path
or make sure the desired SDK version is installed
After re-downloading Xcode and the command line tools, I've hit an impasse. The folder is obviously there, albeit seemingly as an alias (as can be seen here) despite not being that before I started writing this and running
xcode-select -s '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk'
it only responds with:
invalid developer directory '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs'
Anything you can tell me to get this going will be a great help.

Git and Xcode: Why do I have to agree to Xcode's T&Cs to use Git?

Git temporarily stopped working after I updated Xcode on my Mac. The message:
"Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo."
and then started working once I'd agreed to Xcode's T&Cs and installed the update.
Why, or should I say how, are the two linked?
I installed Git using the install.
Your git binary is provided by XCode (which is an easy way to get many command line tools packaged and maintained by Apple), and Apple wants you to accept their license before using any XCode component
If you don't like this, you can install it manually using Homebrew or similar. If you want to compile it yourself you will need a compiler for that. An easy way is using the one provided by XCode (see a pattern here?).
I've found that for my needs as a cross-platform Java-using-git developer the binaries provided by XCode are fine. This especially since they are automatically updated by Apple over time.
sudo xcodebuild -license will show you the license text of Xcode.
You have to agree its terms and condition at the end or you can just run the command given below.
sudo xcodebuild -license accept
P.S.- You are giving access to xcode.
In your terminal, run your git command as sudo
sudo git status
This will give you the option to view/accept the license agreements. Press enter to view it and press space until you get to the bottom. You can then type "agree" to agree to the license agreements. This will get rid of that message and you can use git again.
tl;dr try opening xcode and installing the plugins it suggests.
Even after I installed xcode, accepted the terms, and followed the developer tools prompt, it would continue to prompt me to install developer tools as if I didn't just do it. I eventually found a thread on reddit that suggested opening xcode and going through the recommended plugin installtion that comes up and that worked for me.

xcodebuild and C standard library

I have a xcode project that was created for osx snow leopard. All it was required to be built was to run
xcodebuild
from the command prompt. I am now trying to build the same project on OS X 10.7 and the following error happens when I run the same command
/Users/repo/trunk/main.c:31:10: fatal error: 'stdlib.h' file not found
What exactly is going on? I tried to follow the instructions from this question but stdlib.h is still missing.
How can I fix this problem?
Likely you are getting bit by the repackaging of everything inside /Applications/Xcode.app starting with Xcode 4.3. In Unix-like installations stdlib.h usually lives in /usr/include and your project likely expects it to be there as it was pre-Xcode 4.3. You can fix this by installing the command line tools, which includes the tools and the associated headers and libraries in their standard location.
The easiest way to install the command line tools is from inside Xcode. In the Xcode Preferences select the "Downloads" pane and then the "Components" tab. Push the "Install" button next to "Command Line Tools".
You need to run xcode-select to tell xcodebuild and xcrun which Xcode you want to use.
See this manpage.

XCode 4.3 Command Line Tools Package with Invalid Checksum

The package Apple provides to install the command line tools with Xcode 4.3 is corrupted, and I seem to need it because I'm developing some command line tools.
Has anybody found an alternative Command Line package for Xcode 4.3 from Apple that works or an workaround for the subject?
Xcode includes a new "Downloads" preference pane to install optional components such as command line tools, and previous iOS Simulators.
So, I found a way to do this correctly.
The problem is really in one of the European mirrors from Apple.
The workaround is to:
- Install Tor: https://www.torproject.org/
- Choose a Tor node in the USA
- Logging into your Apple Developer account and download the package
It now opens correctly without any checksum warning.
I solved my own problem of downloading/installing Xcode 4.3.1 "Command Line Tools" by getting them directly from the developer's webpage. The March version yielded a checksum error just like
the download from within Xcode 4.3.1, i.e. Xcode/Preferences/Downloads . But I did have success with the February version of CLT. I don't know why things were out-of-sync.
I had the same problem when trying to install the Command Line Tools from the Downloads tab in the XCode preferences (also downloading from Europe). I fixed it by clearing the dns cache on my system.
This is the Terminal command to clear the dns cache (OSX Lion):
dscacheutil -flushcache
Restart XCode after running this command, it may not fix the problem with the checksum until you do.
try:
defaults write com.apple.frameworks.diskimages skip-verify -bool true
Just add another mirror for the download site:
Use the following to determine a valid ip:
http://www.webmaster-toolkit.com/dns-query.shtml?address=adcdownload.apple.com
and add this to /etc/hosts:
adcdownload.apple.com
Example (ip might already have changed)
64.211.144.168 adcdownload.apple.com.
You can simply click skip while the disk image is verifying. I have installed from a dmg of CLT-4.3 with this problem and built an extensive amount of software with if successfully on my te

Resources