[Tex/LaTex] Can’t locate Algorithm/Diff.pm in @INC (you may need to install the Algorithm::Diff module)

latexdiffmiktexperl

I'm having the same problem as described in the closed question "https://tex.stackexchange.com/questions/104350/problem-regarding-latexdiff-perl-and-miktex-2-9-on-win7".

Following the solution does not work in my case. However, the error message now includes the path I added (see below).

I've installed latexdiff via MikTeX 2.9 console on Win10. Originally tried with ActivePerl, then uninstalled and installed Strawberry Perl. Issue persists.

$ latexdiff
Can't locate Algorithm/Diff.pm in @INC (you may need to install the Algorithm::Diff module) (@INC contains: C \Strawberry\perl\site\lib /usr/lib/perl5/site_perl /usr/share/perl5/site_perl /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5/core_perl /usr/share/perl5/core_perl) at C:\Users\pea77\AppData\Local\Programs\MiKTeX 2.9\scripts/latexdiff\latexdiff line 193.
BEGIN failed--compilation aborted at C:\Users\pea77\AppData\Local\Programs\MiKTeX 2.9\scripts/latexdiff\latexdiff line 193.

Best Answer

Install the Algorithm::Diff package from Perl's CPAN package repository. You can do this by running the following command.

perl -MCPAN -e "install Algorithm::Diff"