craig - 2016-04-09

in 1.0.5 I've just discovered an issue in crgrep.bat file which I will fix in the next release, this may cause --ocr (Optical Character Recognition) option to produce no matches in some cases. If you include --warn you may see a warning about a missing DLL.

To fix this now, in <crgrep>/bin/crgrep.bat around line 115 or 118 there is this pltform check made:

IF %PROCESSOR_ARCHITECTURE% == x86 IF NOT DEFINED PROCESSOR_ARCHITEW6432 (
set CRGREP_LIB_PATH="%PATH%;%CRGREP_HOME%\ocr;%CRGREP_HOME%\lib\x86"
) ELSE (
set CRGREP_LIB_PATH="%PATH%;%CRGREP_HOME%\ocr\x64;%CRGREP_HOME%\lib\x64"
)

which is incomplete. Remove this code entirely and replace with this:

set WIN_ARCH=x64
IF /i "%PROCESSOR_ARCHITECTURE%" == "x86" (
IF NOT DEFINED PROCESSOR_ARCHITEW6432 (
set WIN_ARCH=x86
)
)

if "%WIN_ARCH%" == "x64" (
set CRGREP_LIB_PATH="%PATH%;%CRGREP_HOME%\ocr\x64;%CRGREP_HOME%\lib\x64"
) else (
set CRGREP_LIB_PATH="%PATH%;%CRGREP_HOME%\ocr;%CRGREP_HOME%\lib\x86"
)