Bug 982645 - scan-build does not works
Summary: scan-build does not works
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: llvm
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jan Včelák
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 923834 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-09 13:26 UTC by Clément DAVID
Modified: 2013-12-16 23:06 UTC (History)
10 users (show)

Fixed In Version: llvm-3.3-3.fc19
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-12-14 03:21:33 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Clément DAVID 2013-07-09 13:26:30 UTC
Description of problem:
I'm unable to use it.

Version-Release number of selected component (if applicable):

clang-analyzer-3.3-0.6.rc3.fc19.x86_64
clang-3.3-0.6.rc3.fc19.x86_64
llvm-3.3-0.6.rc3.fc19.x86_64

Steps to Reproduce:

$ make CC=/usr/lib64/clang-analyzer/scan-build/ccc-analyzer
# works fine and produce warning as expected

$ scan-build make 
scan-build: error: Cannot find an executable 'clang' relative to scan-build.  Consider using --use-analyzer to pick a version of 'clang' to use for static analysis.

$ scan-build --use-analyzer /usr/lib64/clang-analyzer/scan-build/ccc-analyzer make
# produce make output with cc=gcc
# end with 
scan-build: Removing directory '/tmp/scan-build-2013-07-09-1' because it contains no reports.
scan-build: No bugs found.


Expected results:
a scan build html output


Additional info:

Comment 1 Jan Včelák 2013-11-29 23:46:20 UTC
*** Bug 923834 has been marked as a duplicate of this bug. ***

Comment 2 Fedora Update System 2013-11-30 08:44:55 UTC
llvm-3.3-3.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/llvm-3.3-3.fc19

Comment 3 Fedora Update System 2013-11-30 11:58:02 UTC
llvm-3.3-3.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/llvm-3.3-3.fc20

Comment 4 Fedora Update System 2013-12-01 09:38:41 UTC
Package llvm-3.3-3.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing llvm-3.3-3.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-22509/llvm-3.3-3.fc19
then log in and leave karma (feedback).

Comment 5 Olivier Crête 2013-12-05 19:41:20 UTC
On F20, even after this update, scan-build still does not work.

Doing scan-build --help-checkers does now list the checkers. But it seem to never run them.

Comment 6 Jan Včelák 2013-12-05 20:00:15 UTC
Works for me. How do you invoke the compilation?

$ cat main.c 
#include <stdio.h>

int main(void)
{
        int var;
        printf("test %d\n", var);
        return 0;
}
$ scan-build gcc ./main.c
scan-build: Using '/usr/bin/clang' for static analysis
./main.c:6:2: warning: Function call argument is an uninitialized value
        printf("test %d\n", var);
        ^~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
scan-build: 1 bugs found.
scan-build: Run 'scan-view /tmp/scan-build-2013-12-05-3' to examine bug reports.

Comment 7 Olivier Crête 2013-12-05 20:08:54 UTC
I did "scan-build make" in a autoconf/automake project (the core GStreamer repository).

Comment 8 Jan Včelák 2013-12-05 21:39:24 UTC
If it is an automake project, you should run even ./configure through scan-build. Have you done it?
 
[1] http://clang-analyzer.llvm.org/scan-build.html#recommended_autoconf

Comment 9 Olivier Crête 2013-12-05 22:08:19 UTC
I'm an idiot, sorry

Comment 10 Olivier Crête 2013-12-05 22:15:58 UTC
Btw, the man page isn't installed in the right place.

Comment 11 Jan Včelák 2013-12-05 22:23:22 UTC
No problem. :-) I will fix the man page in next update.

Comment 12 Fedora Update System 2013-12-14 03:21:33 UTC
llvm-3.3-3.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 13 Fedora Update System 2013-12-16 23:06:05 UTC
llvm-3.3-3.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.