のねのBlog

パソコンの問題や、ソフトウェアの開発で起きた問題など書いていきます。よろしくお願いします^^。

mac Error: Your Xcode (7.3) is outdated

$ brew install tree
Error: Your Xcode (7.3) is outdated.
Please update to Xcode 8.0 (or delete it).
Xcode can be updated from the App Store.
$ brew install tree
Error: Your Xcode (7.3) is outdated.
Please update to Xcode 8.0 (or delete it).
Xcode can be updated from the App Store.
$ brew config
Error: You have not agreed to the Xcode license. Please resolve this by running:
  sudo xcodebuild -license
$ sudo xcodebuild -license
Password:
You have not agreed to the Xcode license agreements. You must agree to both license agreements below in order to use Xcode.

Hit the Enter key to view the license agreements at '/Applications/Xcode.app/Contents/Resources/English.lproj/License.rtf'

git clone fatal: Could not read from remote repository.

$ git clone git@bitbucket.org:user01/android.git
Cloning into 'android'...
The authenticity of host 'bitbucket.org (104.192.143.3)' can't be established.
RSA key fingerprint is SHA256:.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'bitbucket.org,104.192.143.3' (RSA) to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
$ ssh -V
OpenSSH_7.2p2, LibreSSL 2.4.1
$ ls -a ~/.ssh
./              ../             known_hosts
$ ssh-keygen

Generating public/private rsa key pair.
Enter file in which to save the key (/Users/user01/.ssh/id_rsa): 
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in /Users/user01/.ssh/id_rsa.
Your public key has been saved in /Users/user01/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256: user01@host.local
The key's randomart image is:
+---[RSA 2048]----+
+----[SHA256]-----+
$ ls -a ~/.ssh
./              id_rsa          known_hosts
../             id_rsa.pub
$ pbcopy < ~/.ssh/id_rsa.pub 

Set up SSH for Git - Atlassian Documentation

mac source build/envsetup.sh lunch

build/core/combo/mac_version.mk:26: none of the installed SDKs (wifi-serviceac_sdk_versions_installed) match supported versions (10.8 10.9 10.10 10.11), trying 10.8
build/core/combo/mac_version.mk:36: no SDK 10.8 at /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk, trying legacy dir
build/core/combo/mac_version.mk:40: *****************************************************
build/core/combo/mac_version.mk:41: * Can not find SDK 10.8 at /Developer/SDKs/MacOSX10.8.sdk
build/core/combo/mac_version.mk:42: *****************************************************
build/core/combo/mac_version.mk:43: *** Stop..  Stop.

apple.stackexchange.com

mac aosp 10.12 error: 'syscall' is deprecated: first deprecated in OS X 10.12

system/core/libcutils/threads.c:38:10: error: 'syscall' is deprecated: first deprecated in OS X 10.12 - syscall(2) is unsupported; please switch to a supported interface. For SYS_kdebug_trace use kdebug_signpost(). [-Werror,-Wdeprecated-declarations]
  return syscall(SYS_thread_selfid);
         ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/include/unistd.h:733:6: note: 'syscall' has been explicitly marked deprecated here
int      syscall(int, ...);
         ^
1 error generated.
[  0% 192/44861] host Java: dx (out/host/common/obj/JAVA_LIBRARIES/dx_intermediates/classes)
注意:入力ファイルの操作のうち、未チェックまたは安全ではないものがあります。
注意:詳細は、-Xlint:uncheckedオプションを指定して再コンパイルしてください。
[  0% 192/44861] host C++: libc++abi <= external/libcxxabi/src/cxa_demangle.cpp
ninja: build stopped: subcommand failed.
make: *** [ninja_wrapper] Error 1

mac ln

$ sudo ln -s /Applications/Xcode_7.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk /Developer/SDKs/
MacOs/ 10:50:09  $ sudo ln -s /Applications/Xcode_8.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk /Developer/SDKs/
MacOs/ 10:51:34  $ sudo ln -s /Applications/Xcode_8.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk /Developer/SDKs/
$ sudo xcode-select -switch /Applications/Xcode_7.3.1.app/Contents/Developer/

$ xcode-select -p
/Applications/Xcode_7.3.1.app/Contents/Developer

Mac CommandLineTools

$ xcode-select -r
xcode-select: error: --reset must be run as root (e.g. sudo xcode-select --reset).

$ sudo xcode-select -r
Password:

$ xcode-select -p
/Library/Developer/CommandLineTools
$ /usr/bin/clang --version
Apple LLVM version 8.0.0 (clang-800.0.38)
Target: x86_64-apple-darwin16.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

>||
$ sudo xcode-select -switch /Applications/Xcode_7.3.1.app/Contents/Developer/
$ /usr/bin/clang --version
Apple LLVM version 7.3.0 (clang-703.0.31)
Target: x86_64-apple-darwin16.0.0
Thread model: posix
InstalledDir: /Applications/Xcode_7.3.1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin