diff --git a/.github/workflows/objective-c-xcode.yml b/.github/workflows/objective-c-xcode.yml new file mode 100644 index 0000000..ac3b78b --- /dev/null +++ b/.github/workflows/objective-c-xcode.yml @@ -0,0 +1,48 @@ +name: Xcode - Build, Analyze and Upload + +on: + push: + branches: [ "**" ] + pull_request: + branches: [ "**" ] + +jobs: + build: + name: Build and analyse default scheme using xcodebuild command. The Artifact is uploaded if successful. + runs-on: macos-latest + + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set Default Scheme + run: | + scheme_list=$(xcodebuild -list -json | tr -d "\n") + default=$(echo $scheme_list | ruby -e "require 'json'; puts JSON.parse(STDIN.gets)['project']['targets'][0]") + echo $default | cat >default + echo Using default scheme: $default + - name: Build + env: + scheme: ${{ 'default' }} + run: | + if [ $scheme = default ]; then scheme=$(cat default); fi + if [ "`ls -A | grep -i \\.xcworkspace\$`" ]; then filetype_parameter="workspace" && file_to_build="`ls -A | grep -i \\.xcworkspace\$`"; else filetype_parameter="project" && file_to_build="`ls -A | grep -i \\.xcodeproj\$`"; fi + file_to_build=`echo $file_to_build | awk '{$1=$1;print}'` + xcodebuild clean build analyze -configuration Release -scheme "$scheme" -destination "generic/platform=macOS,name=Any Mac" -"$filetype_parameter" "$file_to_build" CODE_SIGN_IDENTITY=”” CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO | xcpretty && exit ${PIPESTATUS[0]} + - name: Create smc.tar.gz + run: | + cd ./build/Release/ + tar -czvf smc.tar.gz smc + - name: Upload smc.tar.gz + uses: actions/upload-artifact@v3 + with: + name: smc + path: ./build/Release/smc.tar.gz + - name: Create smcFanControl.tar.gz + run: | + cd ./build/Release/ + tar -czvf smcFanControl.tar.gz smcFanControl.app + - name: Upload smcFanControl.tar.gz + uses: actions/upload-artifact@v3 + with: + name: smcFanControl + path: ./build/Release/smcFanControl.tar.gz diff --git a/Readme.md b/Readme.md index ac34f60..8ab0a98 100644 --- a/Readme.md +++ b/Readme.md @@ -18,11 +18,20 @@ $ brew install --cask smcfancontrol After that you'll be able to use Spotlight to launch smcFanControl normally. :-) -Requirements: Apple Silicon or Intel Mac / OS X 10.7 or higher +Requirements: Intel Mac with macOS 10.7 or higher Compiled version: https://www.eidac.de/smcfancontrol/smcfancontrol_2_6.zip FAQ / More info: Found in project under "Ressources/*.lproj/F.A.Q.rtf" or included in above .zip +## Nightly Builds (Supports Apple Silicon & Intel) +[smcFanControl.zip](https://nightly.link/hholtmann/smcFanControl/workflows/objective-c-xcode/master/smcFanControl.zip) + +Nightly builds are not signed and require running +``` +sudo xattr -cr /Applications/smcFanControl.app +``` + +--- License: GPL 2 diff --git a/smcFanControl.xcodeproj/project.pbxproj b/smcFanControl.xcodeproj/project.pbxproj index 0b8b701..e8c58b0 100644 --- a/smcFanControl.xcodeproj/project.pbxproj +++ b/smcFanControl.xcodeproj/project.pbxproj @@ -463,7 +463,7 @@ GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_TYPECHECK_CALLS_TO_PRINTF = NO; GCC_WARN_UNINITIALIZED_AUTOS = YES; - MACOSX_DEPLOYMENT_TARGET = 10.7; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; ONLY_ACTIVE_ARCH = NO; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; @@ -490,7 +490,7 @@ GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_TYPECHECK_CALLS_TO_PRINTF = NO; GCC_WARN_UNINITIALIZED_AUTOS = YES; - MACOSX_DEPLOYMENT_TARGET = 10.7; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; SDKROOT = macosx; @@ -524,7 +524,7 @@ "$(inherited)", "\"$(SDKROOT)/usr/lib/system\"", ); - MACOSX_DEPLOYMENT_TARGET = 10.7; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; ONLY_ACTIVE_ARCH = NO; OTHER_CODE_SIGN_FLAGS = "--deep"; PRODUCT_BUNDLE_IDENTIFIER = com.eidac.smcFanControl2; @@ -563,15 +563,15 @@ "$(inherited)", "\"$(SDKROOT)/usr/lib/system\"", ); - MACOSX_DEPLOYMENT_TARGET = 10.7; - OBJROOT = "$(HOME)/builds"; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; + OBJROOT = build; ONLY_ACTIVE_ARCH = NO; OTHER_CODE_SIGN_FLAGS = "--deep"; PRODUCT_BUNDLE_IDENTIFIER = com.eidac.smcFanControl2; PRODUCT_NAME = smcFanControl; PROVISIONING_PROFILE = ""; SDKROOT = macosx; - SYMROOT = "$(HOME)/builds"; + SYMROOT = build; VALID_ARCHS = "arm64e arm64 i386 x86_64"; WRAPPER_EXTENSION = app; }; @@ -580,13 +580,14 @@ C01FCF4F08A954540054247B /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CODE_SIGN_IDENTITY = "Mac Developer"; ENABLE_TESTABILITY = YES; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.7; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; @@ -598,17 +599,18 @@ C01FCF5008A954540054247B /* Release */ = { isa = XCBuildConfiguration; buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CODE_SIGN_IDENTITY = "Mac Developer"; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.7; + MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)"; ONLY_ACTIVE_ARCH = NO; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; SDKROOT = macosx; - SYMROOT = "~/builds"; + SYMROOT = build; VALID_ARCHS = "arm64e arm64 i386 x86_64"; }; name = Release;