I am trying to do a Sonar scan of Objective-C on an AWS Mac instance. The environment details are as follows:
- Sonar server version: Developer Edition v10.8.1 (101195)
- build-wrapper-macosx-x86: version 6.61
- Sonar-scanner: 6.2.1
- Mac server: Macmini8,1 (AWS Instance mac1.metal. )
- Architecture of the system: x86_64
I first execute build-wrapper-macosx-x86
, which generates the required JSON. Then, while executing sonar-scanner
with the above-generated JSON, it doesn’t scan the code. I observed the following debug info in the log:
DEBUG Unpacking analyzer to: /opt/workspace/workspace/6.1/dev/Sonar-Mobile.MobileAuthenticationSDK.6.1-Iphone-v1/IPhone/SDK/SDK/.scannerwork/.sonartmp/238723421286715366
DEBUG Trying to get the architecture using ‘/usr/sbin/sysctl -n hw.optional.arm64’
DEBUG **No arm64 hardware support detected. The sysctl command exited with code (1)**:
DEBUG Total system memory: 32768MB
DEBUG Initial Java memory used: 54
DEBUG Java memory after analysis setup (used, peak): 45, 81
----
ERROR Error during SonarScanner Engine execution 08:23:41 java.lang.IllegalStateException: The “build-wrapper-dump.json” file was found but 0 C/C++/Objective-C files were analyzed. Please make sure that:
I would like to check if this '/usr/sbin/sysctl -n hw.optional.arm64'
is the root cause of this failure? If yes, how can I override this behavior?r