Build Wrapper command not triggering xcodebuild

I am using
SonarQube *Enterprise Edition *Version 9.4 (build 54424)
SonarQube Scanner for JenkinsVersion2.17 (SonarQube Scanner)

And below is my shell script about build wrapper in Jenkins:

curl -sSLo build-wrapper-macosx-x86.zip {SonarQube_domain}/static/cpp/build-wrapper-macosx-x86.zip
unzip -o build-wrapper-macosx-x86.zip
build-wrapper-macosx-x86/build-wrapper-macosx-x86 --out-dir build_wrapper_output_directory xcodebuild -workspace myWorkSpace -scheme myScheme -configuration Debug_SANDBOX clean build -UseModernBuildSystem=YES

Jenkins Machine info:
macOS Sonoma (14.2)
Xcode 15.1

And this lead to error thrown at sonar-scanner, below is the log:

16:30:15.202 ERROR: Error during SonarScanner execution
java.lang.IllegalStateException: The "build-wrapper-dump.json" file was found empty. Please make sure that:
  * you are using the latest version of the build-wrapper and the CFamily analyzer
  * your compiler is supported
  * you are wrapping your build correctly
  * you are wrapping a full/clean build
  * if you are building your project inside a Docker container, build-wrapper is wrapping the build process inside the container and not wrapping the external Docker process
	at com.sonar.cpp.plugin.CFamilySensor.process(CFamilySensor.java:491)
	at com.sonar.cpp.plugin.CFamilySensor.execute(CFamilySensor.java:186)
	at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(AbstractSensorWrapper.java:64)
	at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:85)
	at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:62)
	at org.sonar.scanner.scan.SpringModuleScanContainer.doAfterStart(SpringModuleScanContainer.java:81)
	at org.sonar.core.platform.SpringComponentContainer.startComponents(SpringComponentContainer.java:188)
	at org.sonar.core.platform.SpringComponentContainer.execute(SpringComponentContainer.java:167)
	at org.sonar.scanner.scan.SpringProjectScanContainer.scan(SpringProjectScanContainer.java:392)
	at org.sonar.scanner.scan.SpringProjectScanContainer.scanRecursively(SpringProjectScanContainer.java:388)
	at org.sonar.scanner.scan.SpringProjectScanContainer.doAfterStart(SpringProjectScanContainer.java:357)
	at org.sonar.core.platform.SpringComponentContainer.startComponents(SpringComponentContainer.java:188)
	at org.sonar.core.platform.SpringComponentContainer.execute(SpringComponentContainer.java:167)
	at org.sonar.scanner.bootstrap.SpringGlobalContainer.doAfterStart(SpringGlobalContainer.java:134)
	at org.sonar.core.platform.SpringComponentContainer.startComponents(SpringComponentContainer.java:188)
	at org.sonar.core.platform.SpringComponentContainer.execute(SpringComponentContainer.java:167)
	at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:72)
	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:66)
	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base/java.lang.reflect.Method.invoke(Unknown Source)
	at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
	at jdk.proxy1/jdk.proxy1.$Proxy0.execute(Unknown Source)
	at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:189)
	at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:138)
	at org.sonarsource.scanner.cli.Main.execute(Main.java:112)
	at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
	at org.sonarsource.scanner.cli.Main.main(Main.java:61)
WARN: Unable to locate 'report-task.txt' in the workspace. Did the SonarScanner succeed?
ERROR: SonarQube scanner exited with non-zero code: 1

Any help with this is much appreciated :pray:t2:

Hi,

Your version is past EOL. You should upgrade to either the latest version or the current LTS at your earliest convenience. Your upgrade path is:

9.4 → 9.9.3 → 10.3 (last step optional)

You may find these resources helpful:

If you have questions about upgrading, feel free to open a new thread for that here.

If your error persists after upgrade, please come back to us.

 
Ann

Hi,

Sorry for the late reply, I missed out the email notification. Thanks for your answer, but I have a small question here as I surf through the release note and can’t find related information:

  1. Does 9.9 LTS version build wrapper support the Mac OS 14 (Sonoma) & Xcode 15?
  2. If it doesn’t which version of SonarQube will support these?

Your prompt response is much appreciated so that I can show the conversation to push the team to upgrade as soon as possible.

Thank you.

Liew

Hi Liew,

A lot of times language-specific details aren’t very visible, but the docs are versioned.

 
HTH,
Ann

Hi,

Thanks for the answer. I will push the teams and arrange for the update and try it out afterwards.

Thanks!

Regards,
Liew