2 if [ "${ACTION}" = "install" ]
4 OBJROOT_LOCAL
="${TARGET_TEMP_DIR}/Objects_Local"
5 xcodebuild
install -target dyld_shared_cache_builder SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_LOCAL}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" DISABLE_SDK_METADATA_PARSING
=YES
7 # On macOS, also install dyld_shared_cache_builder to the platform so that root_util can find it.
8 if [ "${RC_PURPLE}" = "" ]
10 if [ "${PLATFORM_DIR}" != "" ]
12 # Note this is set to something like DEVELOPER_INSTALL_DIR=/Applications/Xcode.app/Contents/Developer
13 mkdir -p ${DSTROOT}/${DEVELOPER_INSTALL_DIR}/Platforms
/MacOSX.platform
/usr
/local
/bin
/
14 cp ${DSTROOT}/usr
/local
/bin
/dyld_shared_cache_builder
${DSTROOT}/${DEVELOPER_INSTALL_DIR}/Platforms
/MacOSX.platform
/usr
/local
/bin
/dyld_shared_cache_builder
18 if [ "${RC_PURPLE}" = "YES" ]
20 OBJROOT_UTILS
="${TARGET_TEMP_DIR}/Objects_Utils"
21 xcodebuild
install -target dyld_closure_util
-target dyld_shared_cache_util SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_UTILS}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" DISABLE_SDK_METADATA_PARSING
=YES
22 if [ "${RC_BRIDGE}" != "YES" ]
24 OBJROOT_SIM
="${TARGET_TEMP_DIR}/Objects_Sim"
25 xcodebuild
install -target update_dyld_sim_shared_cache SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_SIM}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" DISABLE_SDK_METADATA_PARSING
=YES
28 OBJROOT_MAC
="${TARGET_TEMP_DIR}/Objects_Mac"
29 xcodebuild
install -target update_dyld_shared_cache_tool SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_MAC}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" DISABLE_SDK_METADATA_PARSING
=YES
30 OBJROOT_MAC
="${TARGET_TEMP_DIR}/Objects2_Mac"
31 xcodebuild
install -target update_dyld_shared_cache_root_mode_tool SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_MAC}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" DISABLE_SDK_METADATA_PARSING
=YES
35 # On macOS build the kernel linker in to /usr/lib too. It defaults to the toolchain
36 if [ "${ACTION}" != "installhdrs" ]
38 if [ "${RC_PURPLE}" = "" ]
40 OBJROOT_MAC
="${TARGET_TEMP_DIR}/Objects_Linker_Mac"
41 xcodebuild
${ACTION} -target libKernelCollectionBuilder SDKROOT
="${SDKROOT}" MACOSX_DEPLOYMENT_TARGET
=${MACOSX_DEPLOYMENT_TARGET} OBJROOT
="${OBJROOT_MAC}" SRCROOT
="${SRCROOT}" DSTROOT
="${DSTROOT}" SYMROOT
="${SYMROOT}/usr/lib" RC_ProjectSourceVersion
="${RC_ProjectSourceVersion}" LD_DYLIB_INSTALL_NAME
="/usr/lib/libKernelCollectionBuilder.dylib" INSTALL_PATH
="/usr/lib"