



echo Testing for presence of alphamat
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_alphamat4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   alphamat
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of aruco
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_aruco4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   aruco
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of bgsegm
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_bgsegm4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   bgsegm
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of calib3d
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_calib3d4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   calib3d
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of ccalib
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_ccalib4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   ccalib
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of core
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_core4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   core
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of datasets
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_datasets4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   datasets
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of dnn_objdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_dnn_objdetect4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   dnn_objdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of dnn_superres
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_dnn_superres4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   dnn_superres
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of dnn
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_dnn4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   dnn
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of dpm
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_dpm4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   dpm
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of face
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_face4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   face
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of features2d
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_features2d4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   features2d
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of flann
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_flann4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   flann
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of fuzzy
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_fuzzy4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   fuzzy
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of gapi
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_gapi4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   gapi
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of hfs
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_hfs4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   hfs
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of highgui
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_highgui4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   highgui
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of img_hash
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_img_hash4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   img_hash
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of imgcodecs
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_imgcodecs4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   imgcodecs
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of imgproc
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_imgproc4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   imgproc
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of intensity_transform
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_intensity_transform4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   intensity_transform
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of line_descriptor
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_line_descriptor4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   line_descriptor
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of mcc
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_mcc4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   mcc
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of ml
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_ml4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   ml
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of objdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_objdetect4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   objdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of optflow
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_optflow4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   optflow
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of phase_unwrapping
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_phase_unwrapping4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   phase_unwrapping
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of photo
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_photo4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   photo
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of plot
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_plot4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   plot
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of quality
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_quality4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   quality
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of rapid
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_rapid4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   rapid
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of reg
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_reg4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   reg
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of rgbd
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_rgbd4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   rgbd
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of saliency
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_saliency4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   saliency
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of shape
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_shape4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   shape
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of stereo
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_stereo4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   stereo
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of stitching
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_stitching4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   stitching
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of structured_light
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_structured_light4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   structured_light
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of superres
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_superres4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   superres
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of surface_matching
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_surface_matching4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   surface_matching
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of text
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_text4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   text
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of tracking
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_tracking4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   tracking
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of video
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_video4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   video
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of videoio
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_videoio4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   videoio
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of videostab
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_videostab4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   videostab
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of wechat_qrcode
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_wechat_qrcode4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   wechat_qrcode
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of xfeatures2d
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_xfeatures2d4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   xfeatures2d
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of ximgproc
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_ximgproc4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   ximgproc
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of xobjdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_xobjdetect4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   xobjdetect
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of xphoto
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_xphoto4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   xphoto
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Testing for presence of freetype
IF %ERRORLEVEL% NEQ 0 exit /B 1
if not exist %PREFIX%\\Library\\bin\\opencv_freetype4100.dll exit 1
IF %ERRORLEVEL% NEQ 0 exit /B 1
echo Found                   freetype
IF %ERRORLEVEL% NEQ 0 exit /B 1
mkdir -p cmake_build_test && pushd cmake_build_test
IF %ERRORLEVEL% NEQ 0 exit /B 1
cmake -G "Ninja" ..
IF %ERRORLEVEL% NEQ 0 exit /B 1
cmake --build . --config Release
IF %ERRORLEVEL% NEQ 0 exit /B 1
popd
IF %ERRORLEVEL% NEQ 0 exit /B 1
python run_py_test.py
IF %ERRORLEVEL% NEQ 0 exit /B 1
pip check
IF %ERRORLEVEL% NEQ 0 exit /B 1
pip list
IF %ERRORLEVEL% NEQ 0 exit /B 1
exit /B 0
