Menu

#2 Cant run PMD Analisis on Java sources

open
nobody
None
5
2014-08-23
2010-06-25
RSE
No

Hi,

I was looking for an alternative for the over budget static code analizers and foud about PMD. But i found that PMD by itself is not really easy to use, and got to analyze file by file.

Giving a second try on my research a found about yasca, something easier to use, capable of running PMD analysis and able to scan folders with multiple source files.

I want to make it work on a Windows XP computer. i downloaded it and extract it to "C:\Yasca\" folder.

After that, i copied all the files i wanted to review (.java files) to the "C:\Files\" Folder

Then, i uncompressed yasca-2.1-pmd.zip pluggin to the "C:\pmd" folder

With those components installed i set the SA_HOME to the "C:\pmd" folder

The next step i executed the following command:

yasca -sa_home C:\PMD c:\Files\WebServiceProject\

And i received the following answer:

Yasca 2.1 - http://www.yasca.org/ - Michael V. Scovetta
Commercial support is now available for Yasca. Contact scovetta@users.sourceforg
e.net for more information.

Initializing components...
Using Static Analyzers located at [c:\PMD\]

Starting scan. This may take a few minutes to complete...
Plugin "jlint" not installed. Download it at yasca.org.
Plugin "ClamAV" not installed. Download it at yasca.org.
Plugin "cppcheck" not installed. Download it at yasca.org.
Plugin "findbugs" not installed. Download it at yasca.org.
Forking external process (FxCop)...
[E_WARNING] [ C:\yasca\plugins\FxCop.php:68 ] DOMDocument::loadXML(): Start tag
expected, '<' not found in Entity, line: 1
FxCop did not return a valid XML document. Ignoring.
Plugin "javascriptlint" not installed. Download it at yasca.org.
Plugin "pmd" not installed. Download it at yasca.org.
Plugin "rats" not installed. Download it at yasca.org.
Creating report...
Results have been written to C:\Documents and Settings\user\Desktop\Yasca\Yasca-
Report-20100625183150.html

The report just finds "Code Correctness", "Unknown, Non-Standard, or Obsolete Library Used" and "Arbitrary File Disclosure (potential)" warnings/violations, only 10, when i tried PMD with the basic rules with the optimal advisor tool htye foud abour 200 violations, so im guessing PMD rules are not being checked, and i tried to research about it, but i havent found anything yet.

I already have installed java installed, when i enter the following command i get this response:

C:\yasca>java -version
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) Client VM (build 16.3-b01, mixed mode, sharing)

Can u help to to figure out what i need or what im doing wrong?

Regards,

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.