????????????iOS????????
???????????? ???????[ 2013/1/28 10:33:28 ] ????????
???????????????Xcode Plugin??Clang scan-build Plugin???iOS?????????????????????Щ???????????????????????????????????????????????????о????????Щ?????У???????????????????????????????????????????????????iOS???????????????????????????д????????£??????ο???
????#????????·??
????WORKSPACE_PATH=`pwd`
????SCAN_BUILD_PATH=~/dev-tools/clang/llvm/tools/clang/tools/scan-build/scan-build
????CLANG_PATH=/usr/bin/clang
????XCODEBUILD_PATH=/usr/bin/xcodebuild
????XCRUN_PATH=/usr/bin/xcrun
????#????????????????????????????????????????
????#??????????????????
????ERROR_COUNT=0
????#??????Target????
????APP_TARGET=
????#????????Test Target????
????#APP_TEST_TARGET=
????SIMULATOR_SDK=iphonesimulator6.0
????OS_SDK=iphoneos6.0
????#?????????????mobileprovision???λ??
????MOBILEPROVISION_PATH=
????#??????????????????
????PASSWORD=
????cd ${WORKSPACE_PATH}
????#??о?????????
????rm -rf scan.output
????rm -rf ${WORKSPACE_PATH}/clangScanBuildReports
????${SCAN_BUILD_PATH} -k -v -v -o ${WORKSPACE_PATH}/clangScanBuildReports --use-analyzer ${CLANG_PATH} xcodebuild -target ${APP_TARGET} -configuration Debug -sdk ${SIMULATOR_SDK} clean build | tee scan.output
????ACC_ERROR_COUNT=`grep -E '^scan-build: ([0-9]+) bugs found' scan.output | awk '{print $2}'`
????#????????????????????????????????????????????????????????????????????
????if [ ${ACC_ERROR_COUNT} -gt ${ERROR_COUNT} ]; then
????echo "scan-build found ${ACC_ERROR_COUNT} bugs?? larger than ${ERROR_COUNT}. Please check..."
????exit 1
????fi
????#????????????????л?????????????????
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11