Understanding the scan options in the configuration file
Wazi Analyze supports scanning of five languages: COBOL, PL/I,
Assembler, C, and Java™. The scan options are configured in the configuration file, that is, .dat
file.
Wazi Analyze is shipped with six sample
.dat
files that are
stored in /home/wazi/templates/samples/.cbl.dat
for scanning COBOL applications including COBOL CICS® and its JCLpli.dat
for scanning PL/I applications including PL/I CICS and its JCLasm.dat
for scanning Assembler applications including Assembler and its JCLc.dat
for scanning C applicationsmulti.dat
for scanning COBOL, PL/I, C, and Assembler applications together including CICS for those languages and associated JCLjava.dat
for scanning Java applications
For more information, check the following sections.
The structure of the configuration file
You can see four key sections in the configuration file that determine the behaviors when the
source files are scanned.
- OPTIONS section: This section indicates what to be considered during the scan.
- DIRS section: This section indicates the directories that Wazi Analyze will use during
the scan process.
- APPDIR
- Indicates the base directory for the sources to be scanned.
- OUTDIR
- Indicates the output directory of the scanner. Do not change this setting.
- LOGDIR
- Indicates the output directory for log files produced by the scanner. If it is not specified,
the directory under OUTDIR is used. The following files are stored in the LOGDIR directory:
Scan.log
that contains the detailed scan resultsBuild.log
that contains date and time stamps of runningscannerCrash.log
that is only created when the scanner crashes
- INCDIR
- Indicates the base directory for commonly used included files. It is scanned after the language specific directories have been scanned. Do not change this setting.
- COBCPYDIR
- Indicates the directory storing the COBOL copybook files that the source programs refer to.
- PLIINCDIR
- Indicates the directory storing the PL/I included files that the PL/I source programs refer to.
- PLICOMPILER
- Indicates the base directory for PL/I preprocessor.
- ASMLISTDIR
- Indicates the directory for ASM compiler listings.
- ASMMACDIR
- Indicates the directory for ASM macros files.
- EXT section: This section indicates the file extensions that are not listed
under the FILES section or the file extensions that are different from the default file
extension that is suggested in the Preparing the source files to be scanned.
- COBOL
- Indicates the file extension for COBOL source files.
- COBOLCPY
- Indicates the file extension for COBOL copybook files.
- COBOLCICS
- Indicates the file extension for COBOL CICS files.
- ASM
- Indicates the file extension for Assembler source files.
- ASMINC
- Indicates the file extension for Assembler included files.
- ASMCICS
-
Indicates the file extension for Assembler CICS files.
- PL1
-
Indicates the file extension for PL/I source files.
- PL1INC
- Indicates the file extension for PL/I included files.
- PL1LIST
- Indicates the file extension for PL/I listing files.
- PL1CICS
- Indicates the file extension for PL/I CICS files.
- C
- Indicates the file extension for C source files.
- CCICS
- Indicates the file extension for C CICS files.
- JCL
- Indicates the file extension for JCL files.
- JCLPROC
- Indicates the file extension for JCL procedures files.
- IMS
- Indicates the file extension for IMS files.
- DBD
- Indicates the file extension for DBD files.
- PSB
- Indicates the file extension for PSB files.
- JAVA
- Indicates the file extension for Java source files.
Note: If your host system is case sensitive, such as MacOS or Linux®, you can use this section to specify the different case sensitivity of your extensions. The following example indicates that your COBOL copybook files are.cpy
and.CPY
, and COBOL source files are.cbl
and.CBL
.COBOLCPY=cpy,CPY
COBOL=cbl,CBL
- FILES section: This section indicates the file types and the order to be scanned.
- FILENUM=x
- x is the number of FILE definitions that are specified below it. File definitions must be
numbered sequentially. For example:
[FILES] FILENUM=3 F1=*.CBL F2=*.PLI F3=*.ASM
Note: You do not need to specify the include files and macro files in the file definitions.
Scan options settings
Check different settings of configuration files for different source types in the following section.
COBOL applications
The sample configuration file for a COBOL application is available at
/home/wazi/templates/samples/cbl.dat. You can check the descriptions of
the settings on the sample
cbl.dat
and update the cbl.dat
file to
suit your source files to be scanned.- OPTIONS section:
- The following settings are recommended as the minimum settings for a COBOL application.
- OPTION_PGMNAME
- Set to 1 for the scanner to take program name from ID DIVISION of the COBOL program. Otherwise, the file name is used as program name.
- OPTION_IMPACT
- Set to 1 to enable full impact analysis. The setting must always be enabled.
- OPTION_MODULEEXT
- Set to 1 to report the source file names with the extension. If you set to 0, Wazi Analyze will display only the name of the file without the extension for analysis results. This setting must always be enabled.
- OPTION_JOBNAME
- Set to 1 for the scanner to scan the JCL feature and extract the job name within JCL files. If you do not set this option, the scanner still can scan JCL files but the job name within JCL files will not be extracted.
- OPTION_WITHCOMMENT
- Set to 1 to include comment lines in the source files to be scanned. By setting this option, you can see comment lines when you view the source content. Otherwise, comments in the source files are dropped.
- OPTION_RECURSEFOLDER
- Set to 1 to scan source files in all sub-directories that are relative to
APPDIR
. This option is only for sources files and doesn’t apply to copybook files, macros files, and included files. For copybook files, macros files, and included files, you need to specify all the sub-directories under theDIRS
section. - LANGUAGE=EN
- Set the display language of messages for the scanner. The default language is English. For more information, see Changing the display language of the scan log.
- The following settings are the additional settings that you can add to the
cbl.dat
file.- OPTION_IBM_ALLSRCEDGES
- Set to 1 to display relationships to system copybooks and macros which are used by internal processing. Set to 0 if you do not want to see the relationships to those copybooks and macros.
- OPTION_CICS
- Set to 1 for the scanner to scan all programs like CICS
programs. CICS programs will get some CICS specific variables that are defined like DFHEIBLK. Note: Using the language specific CICS file extensions as described in Preparing source files to be scan enables you to specify CICS programs without the need to change this option. The scanner uses the given extension to distinguish between normal and CICS programs.
- OPTION_IMS
- Set to 1 for the scanner to load and scan a PSB file that has the same name with a
.psb
extension as the program. - OPTION_NESTED
- Set to 1 to scan nested programs. Nested Programs are subprograms that are contained in the same source file as their main program.
- OPTION_IMPACT_SYSCALLS
- Set to 1 to run a dataflow analysis for parameters of IMS calls to make it more readable.
- OPTION_FORCE80COL
- Set to 1 to force COBOL sources to have 80 columns (actually 72 columns). Shorter lines will be concatenated with the next line(s).
- OPTION_NOTABEXPAND
- Set to 1 to read TAB chars as a single char. Otherwise, tabs will be replaced by spaces (0-7) to reach a column dividable by 8.
- OPTION_COPYCASEMAP
- Set to 1 for the scanner to recognize file names as sensitive cases. Otherwise, the scanner will recognize the file name with different cases as the same file.
- OPTION_INC_COPY
- Set to 1 to accept -INC as a replacement for COPY or % INCLUDE. -INC is a feature that is used on IBM Mainframes.
- The following settings are recommended as the minimum settings for a COBOL application.
- DIRS section:
- APPDIR
- Set to /home/wazi/data/cbl/source/ directory. Replace
cbl
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - OUTDIR
- Set to /home/wazi/data/cbl/Output/ directory. Replace
cbl
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/Output/. - INCDIR
- Set to /home/wazi/Include/MACLIB/ and /home/wazi/Include/DFHLIB/ directories. Do not change this setting.
PL/I applications
The sample configuration file for a PL/I application is available at
/home/wazi/templates/samples/pli.dat. You can check the descriptions of
the settings on the sample
pli.dat
and update the pli.dat
file to
suit your source files to be scanned.- OPTIONS section:
- The following settings are recommended as the minimum settings for a PL/I application.
- OPTION_PGMNAME
- Set to 1 for the scanner to take program name from PROC MAIN of the PL/I program. Otherwise, the file name is used as program name.
- OPTION_IMPACT
- Set to 1 to enable full impact analysis. The setting must always be enabled.
- OPTION_MODULEEXT
- Set to 1 to report the source file names with the extension. If you set to 0, Wazi Analyze will only display the name of the file without the extension for analysis results. This setting must always be enabled.
- OPTION_JOBNAME
- Set to 1 for the scanner to scan the JCL feature and extract the job name within JCL files. If you do not set this option, the scanner still can scan JCL files but the job name within JCL files will not be extracted.
- OPTION_WITHCOMMENT
- Set to 1 to include comment lines in the source files to be scanned. By setting this option, you can see comment lines when you view the source content. Otherwise, comments in the source files are dropped.
- OPTION_RECURSEFOLDER
- Set to 1 to scan source files in all sub-directories that are relative to
APPDIR
. This option is only for sources files and doesn’t apply to copybook files, macros files, and included files. For copybook files, macros files, and included files, you need to specify all the sub-directories under theDIRS
section. - OPTION_PLI_DELLST
- Set to 1 to allow the scanner to remove the listing files (
.lst
) that it generates. Otherwise, if your source folder is a Git repository, the generated listing files will be recognized by Git as changes to the repository. - OPTION_PLI_NODDNAME
- Set to 1 for the scanner to look for the include files that are specified in the source without
DDNAME
. Otherwise, the PL/I preprocessor will addDDNAME
to include file names, which causes the scanner to be unable to find the include files. - LANGUAGE=EN
- Set the display language of messages for the scanner. The default language is English. For more information, see Changing the display language of the scan log.
- The following settings are the additional settings that you can add to the
pli.dat
file.- OPTION_IBM_ALLSRCEDGES
- Set to 1 to display relationships to system copybooks and macros which are used by internal processing. Set to 0 if you do not want to see the relationships to those copybooks and macros.
- OPTION_CICS
- Set to 1 for the scanner to scan all programs like CICS
programs. CICS programs will get some CICS specific variables that are defined like DFHEIBLK. Note: Using the language specific CICS file extensions as described in Preparing source files to be scan enables you to specify CICS programs without the need to change this option. The scanner uses the given extension to distinguish between normal and CICS programs.
- OPTION_IMS
- Set to 1 for the scanner to load and scan a PSB file that has the same name with a
.psb
extension as the program. - OPTION_NESTED
- Set to 1 to scan nested programs. Nested Programs are subprograms that are contained in the same source file as their main program.
- OPTION_IMPACT_SYSCALLS
- Set to 1 to run a dataflow analysis for parameters of IMS calls to make it more readable.
- OPTION_NOTABEXPAND
- Set to 1 to read TAB chars as a single char. Otherwise, tabs will be replaced by spaces (0-7) to reach a column dividable by 8.
- OPTION_COPYCASEMAP
- Set to 1 for the scanner to recognize file names as sensitive cases. Otherwise, the scanner will recognize the file name with different cases as the same file.
- OPTION_INC_COPY
- Set to 1 to accept -INC as a replacement for COPY or % INCLUDE. -INC is a feature that is used on IBM Mainframes.
- The following settings are recommended as the minimum settings for a PL/I application.
- DIRS section:
- APPDIR
- Set to /home/wazi/data/pli/source/ directory. Replace
pli
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - OUTDIR
- Set to /home/wazi/data/pli/Output/ directory. Replace
pli
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/Output/. - INCDIR
- Set to /home/wazi/Include/MACLIB/. Do not change this setting.
- PLICOMPILER
- The folder to PL/I compiler directory. Set to /home/wazi/PLI_iLinux/plilux. Do not change this setting.
Assembler applications
The sample configuration file for an Assembler application is available at
/home/wazi/templates/samples/asm.dat. You can check the descriptions of
the settings on the sample
asm.dat
and update the asm.dat
file to
suit your source files to be scanned.- OPTIONS section:
- The following settings are recommended as the minimum settings for an Assembler application.
- OPTION_PGMNAME
- Set to 1 for the scanner to take program name from TITLE Macro of the Assembler program. Otherwise, the file name is used as program name.
- OPTION_IMPACT
- Set to 1 to enable full impact analysis. The setting must always be enabled.
- OPTION_MODULEEXT
- Set to 1 to report the source file names with the extension. If you set to 0, Wazi Analyze will only display the name of the file without the extension for analysis results. This setting must always be enabled.
- OPTION_JOBNAME
- Set to 1 for the scanner to scan the JCL feature and extract the job name within JCL files. If you do not set this option, the scanner still can scan JCL files but the job name within JCL files will not be extracted.
- OPTION_WITHCOMMENT
- Set to 1 to include comment lines in the source files to be scanned. By setting this option, you can see comment lines when you view the source content. Otherwise, comments in the source files are dropped.
- OPTION_RECURSEFOLDER
- Set to 1 to scan source files in all sub-directories that are relative to
APPDIR
. This option is only for sources files and doesn’t apply to copybook files, macros files, and included files. For copybook files, macros files, and included files, you need to specify all the sub-directories under theDIRS
section. - LANGUAGE=EN
- Set the display language of messages for the scanner. The default language is English. For more information, see Changing the display language of the scan log.
- The following settings are the additional settings that you can add to the
asm.dat
file.- OPTION_IBM_ALLSRCEDGES
- Set to 1 to display relationships to system copybooks and macros which are used by internal processing. Set to 0 if you do not want to see the relationships to those copybooks and macros.
- OPTION_CICS
- Set to 1 for the scanner to scan all programs like CICS
programs. CICS programs will get some CICS specific variables that are defined like DFHEIBLK. Note: Using the language specific CICS file extensions as described in Preparing source files to be scan enables you to specify CICS programs without the need to change this option. The scanner uses the given extension to distinguish between normal and CICS programs.
- OPTION_IMS
- Set to 1 for the scanner to load and scan a PSB file that has the same name with a
.psb
extension as the program. - OPTION_COPYCASEMAP
- Set to 1 for the scanner to recognize file names as sensitive cases. Otherwise, the scanner will recognize the file name with different cases as the same file.
- OPTION_NOTABEXPAND
- Set to 1 to read TAB chars as a single char. Otherwise, tabs will be replaced by spaces (0-7) to reach a column dividable by 8.
- OPTION_INC_COPY
- Set to 1 to accept -INC as a replacement for COPY or % INCLUDE. -INC is a feature that is used on IBM Mainframes.
- The following settings are recommended as the minimum settings for an Assembler application.
- DIRS section:
- APPDIR
- Set to /home/wazi/data/asm/source/ directory. Replace
asm
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - OUTDIR
- Set to /home/wazi/data/asm/Output/ directory. Replace
asm
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/Output/. - INCDIR to INCDIR11
- All the include files that are needed to scan Assembler source files. Do not change this setting.
C applications
The sample configuration file for a C application is available at
/home/wazi/templates/samples/c.dat. You can check the descriptions of the
settings in the sample
c.dat
and update the c.dat
file to suit
your source files to be scanned.- OPTIONS section:
- The following settings are recommended as the minimum settings for a C application.
- OPTION_NOCAPITALS
- Set to 1 for not converting the variables to all capitals.
- OPTION_IMPACT
- Set to 1 to enable full impact analysis. The setting must always be enabled.
- OPTION_MODULEEXT
- Set to 1 to report the source file names with the extension. If you set to 0, Wazi Analyze will only display the name of the file without the extension for analysis results. This setting must always be enabled.
- OPTION_RECURSEFOLDER
- Set to 1 to scan source files in all sub-directories that are relative to
APPDIR
. This option is only for sources files and doesn’t apply to copybook files, macros files, and included files. For copybook files, macros files, and included files, you need to specify all the sub-directories under theDIRS
section. - LANGUAGE=EN
- Set the display language of messages for the scanner. The default language is English. For more information, see Changing the display language of the scan log.
- The following settings are the additional settings that you can add to the
asm.dat
file.- OPTION_390C
- Set to 1 to scan C by using IBM zSystems syntax. Mixing code between C on IBM zSystems is not supported at this point.
- OPTION_SUPPRESS
- Set to 1 for the scanner not to generate unused symbols from system includes and system classes in the scan results.
- OPTION_C_LONGLONG
-
Set to 1 to accept the "long long" type for a 64-bit integer.
- DEFINES, DEFINES1 to DEFINESn
-
Set the value to all defines that are given by the compiler, system, or the makefile. See the following examples:
- DEFINES=__SIZE_TYPE__=unsigned long
- DEFINES1=__PTRDIFF_TYPE__=unsigned long
- DEFINES2=__WCHAR_TYPE__=unsigned short
- The following settings are recommended as the minimum settings for a C application.
- DIRS section:
- APPDIR
- Set to /home/wazi/data/c/source/ directory. Replace
c
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - OUTDIR
- Set to /home/wazi/data/c/Output/ directory. Replace
c
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/Output/. - INCDIR
- Set to /home/wazi/Include/MACLIB/. Do not change this setting.
- INCLUDE
- Set to /home/wazi/Include/IBM_C/. Do not change this setting.
- INCLUDE1 to INCLUDE11
- Specify any additional paths to system and third party includes for C. For example:
- INCLUDE1=/home/wazi/data/project/source/cinclude/
- INCLUDE2=/home/wazi/data/project/source/testinclude/
Multiple languages application
The sample configuration file for multi-language application is available at
/home/wazi/templates/samples/multi.dat. This configuration file is to support
the application with COBOL, PL/I, Assembler, and
C
languages. The
settings are the combination of settings from all the four languages and the
following settings: - OPTIONS section:
- The following settings are the additional settings that you can add to the
multi.dat
file.- OPTION_TPF
- Set to 1 to enable the support to scan z/TPF assembler, which uses different system macros and calling conventions.
- The following settings are the additional settings that you can add to the
Java applications
The sample configuration file for a Java application is available at /home/wazi/templates/samples/java.dat. You can check the descriptions of
the settings on the sample
java.dat
and update the java.dat
file
to suit your source files to be scanned.- OPTIONS section:
- The following settings are recommended as the minimum settings for a Java application.
- OPTION_IMPACT
- Set to 1 to enable full impact analysis. The setting must be enabled when you migrate your Java project to a newer version of Wazi Analyze. For more information, see Migrating a Java project to a newer version.
- OPTION_JAVA
- Set to 1 to activate the Java scanner.
- OPTION_NOCAPITALS
- Set to 1 to not convert keywords to capitals.
- OPTION_SUPPRESS
- Set to 1 for the scanner not to generate unused symbols from system includes and system classes.
- JAVA_PREPROC_OFFLINE
- Set to 1 to scan Maven and Gradle project files in offline mode.
- JAVA_PREPROC_REMOVE_JARS
- Set to 1 to filter out JAR file found in the project.
- OPTION_JDBC
- Set to 1 for the scanner to scan JDBC classes.
- LANGUAGE=EN
- Set the display language of messages for the scanner. The default language is English. For more information, see Changing the display language of the scan log.
- The following setting is the additional settings that you can add to the
java.dat
file.- OPTION_SUPPRESS
- Set to 1 for the scanner not to generate unused symbols from system includes and system classes in the scan results.
- The following settings are recommended as the minimum settings for a Java application.
- DIRS section:
- APPDIR
- Set to /home/wazi/data/java/source/ directory. Replace
java
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - OUTDIR
- Set to /home/wazi/data/java/Output/ directory. Replace
java
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/Output/. - JAVAROOT
- Set to /home/wazi/data/java/source/. Replace
java
directory with the directory of the project that you want to scan. For example if your project directory istestApp
, change this setting to /home/wazi/data/testApp/source/. - CLASSPATH
- The location of the processed Java system library files that are needed to scan Java source files. Do not change this setting.
- CLASSPATH1
- The location of any Java library scan output produced from user-supplied jar files. Replace java directory with the directory of the project that you want to scan. For example, if your project directory is testApp, change this setting to /home/wazi/data/testApp/Include/.