Reviewed-by: Liming Gao <liming....@intel.com>
> -----Original Message----- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Bi, > Dandan > Sent: Monday, February 18, 2019 3:36 PM > To: edk2-devel@lists.01.org > Cc: Gao, Liming <liming....@intel.com> > Subject: [edk2] [patch edk2-wiki] Update ECC wiki page > > Update ECC wiki page to record how to solve the > problem “ModuleNotFoundError: No module named 'antlr4'” > when run ECC tool with python3.x. > > Cc: Liming Gao <liming....@intel.com> > Cc: Bob Feng <bob.c.f...@intel.com> > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Dandan Bi <dandan...@intel.com> > --- > ECC-tool.md | 15 ++++++++++++--- > 1 file changed, 12 insertions(+), 3 deletions(-) > > diff --git a/ECC-tool.md b/ECC-tool.md > index eaf4137..03dbb30 100644 > --- a/ECC-tool.md > +++ b/ECC-tool.md > @@ -12,18 +12,27 @@ Steps to run ECC tool:<br> > **1). Enter edk2 directory, run: **edksetup.bat**** (**on Windows**)<br> > **Enter edk2 directory, run: **source edksetup.sh**** (**on > Linux**)<br> > > **2). Then in edk2 directory, you can type "Ecc" to run ECC tool > directly**.<br> > > -**3). If you meet following error:**<br> > +**3). If you meet following errors:**<br> > +**Error 1:**<br> > **import antlr3**<br> > **ImportError: No module named antlr3**<br> > > -Since ECC depends on antlr V3.0.1, you can download it from > http://www.antlr3.org/download/Python/ <br> > +This error may be met when you run ECC tool with python 2.x, then ECC > depends on antlr V3.0.1, you can download it from > http://www.antlr3.org/download/Python/ <br> > After download and extract it, you can enter the antlr tool directory and > run: <br> > **C:\Python27\python.exe setup.py install** to install it.(**on Windows**) > <br> > -**python setup.py install**" to install it, root access may be > required.(**on Linux**) <br> > +**python setup.py install** to install it, root access may be required.(**on > Linux**) <br> > + > +**Error 2:**<br> > + **import antlr4 as antlr** <br> > + **ModuleNotFoundError: No module named 'antlr4'** <br> > + > +This error may be met when you run ECC tool with python 3.x, then ECC > depends on antlr4, you can install it through following > command.<br> > +**py -3 -m pip install antlr4-python3-runtime** to install it.(**on > Windows**) <br> > +**sudo python3 -m pip install antlr4-python3-runtime** to install it. (**on > Linux**) <br> > > **4). You can type "Ecc -h/Ecc --help" to get the help info of ECC > tool**.<br> > > **5). Common usage model:**<br> > **Ecc -c config file -e exception file -t the target directory which need > to be scanned by ECC -r the ECC scan result csv file**<br> > -- > 2.18.0.windows.1 > > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel