[MacPorts] #63038: clang12: please re-enable the +analyzer as a default variant
MacPorts
noreply at macports.org
Mon Jun 14 12:06:41 UTC 2021
#63038: clang12: please re-enable the +analyzer as a default variant
-------------------------+----------------------
Reporter: mouse07410 | Owner: kencu
Type: request | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: clang-12 |
-------------------------+----------------------
Comment (by mouse07410):
Well, trying {{{ build-scan make}}} for Crypto++ failed (in a way I don't
quite understand):
{{{
$ cat ~/src/cryptopp/scan-report.txt
/opt/local/libexec/llvm-12/bin/scan-view:9: DeprecationWarning: the imp
module is deprecated in favour of importlib; see the module's
documentation for alternative uses
import imp
Traceback (most recent call last):
File "/opt/local/libexec/llvm-12/bin/scan-view", line 150, in <module>
main()
File "/opt/local/libexec/llvm-12/bin/scan-view", line 147, in main
run(port, args, args.root)
File "/opt/local/libexec/llvm-12/bin/scan-view", line 74, in run
import ScanView
File "/opt/local/libexec/llvm-12/bin/../share/scan-view/ScanView.py",
line 29, in <module>
import Reporter
ModuleNotFoundError: No module named 'Reporter'
WARNING: Unable to detect that server started.
$
}}}
Here's how that report was generated:
{{{
$ sudo port select --list clang
Enter PIN for 'Certificate For PIV Authentication (Blumenthal, Uri
(UR20980))':
Available versions for clang:
apple-clang (active)
mp-clang-10
mp-clang-11
mp-clang-9.0
none
$ scan-build-mp-12 make
scan-build: Using '/opt/local/libexec/llvm-12/bin/clang' for static
analysis
Using testing flags: -std=gnu++17 -O3 -march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
Running make again to see what failed
TestPrograms/test_x86_sse2.cpp:5:5: warning: Value stored to 'x' is never
read [deadcode.DeadStores]
x=_mm_add_epi64(x,x);
^ ~~~~~~~~~~~~~~~~~~
1 warning generated.
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c cryptlib.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c cpu.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c integer.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c 3way.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c adler32.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c algebra.cpp
/opt/local/libexec/llvm-12/bin/../libexec/c++-analyzer
-DCRYPTOPP_DISABLE_ASM -fPIC -fno-common -pipe -std=gnu++17 -O3
-march=native -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
-c algparam.cpp
In file included from algparam.cpp:3:
In file included from ./pch.h:14:
In file included from ./config.h:22:
In file included from ./config_align.h:27:
In file included from ./config_cxx.h:37:
In file included from
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/string:506:
In file included from
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/string_view:175:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__string:58:10:
fatal error: 'cstdio' file not found
#include <cstdio> // For EOF.
^~~~~~~~
1 error generated.
make: *** [GNUmakefile:1790: algparam.o] Error 1
scan-build: Analysis run complete.
scan-build: 2 bugs found.
scan-build: Run 'scan-view
/var/folders/c6/lnc_0m093ys8w16md_fm1mnxhtfnj8/T/scan-
build-2021-06-13-211957-91810-1' to examine bug reports.
$ scan-view-mp-12 /var/folders/c6/lnc_0m093ys8w16md_fm1mnxhtfnj8/T/scan-
build-2021-06-13-211957-91810-1 > scan-report.txt 2>&1
}}}
As far as I can tell, Xcode-12.5 does **not** include {{{build-scan}}} or
{{{scan-view}}}.
--
Ticket URL: <https://trac.macports.org/ticket/63038#comment:27>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list