@@ -54,6 +54,15 @@ echo.%CC%| findstr /I "gcc">Nul && (
5454 if errorlevel 1 (
5555 exit /B 1
5656 )
57+
58+ echo > %INSTALL_DIR% \lib\canary.txt
59+
60+ dir %INSTALL_DIR% \share\mongo-c-driver
61+
62+ %CMAKE_MAKE_PROGRAM% uninstall
63+ if errorlevel 1 (
64+ exit /B 1
65+ )
5766) || (
5867 %CMAKE% -G " %CC% " " -DCMAKE_INSTALL_PREFIX=%INSTALL_DIR% " " -DCMAKE_BUILD_TYPE=Debug" %BSON_ONLY_OPTION% .
5968 MSBuild.exe /m ALL_BUILD.vcxproj
@@ -64,15 +73,15 @@ echo.%CC%| findstr /I "gcc">Nul && (
6473 if errorlevel 1 (
6574 exit /B 1
6675 )
67- )
6876
69- echo > %INSTALL_DIR% \lib\canary.txt
77+ echo > %INSTALL_DIR% \lib\canary.txt
7078
71- dir %INSTALL_DIR% \share\mongo-c-driver
79+ dir %INSTALL_DIR% \share\mongo-c-driver
7280
73- call %INSTALL_DIR% \share\mongo-c-driver\uninstall.cmd
74- if errorlevel 1 (
75- exit /B 1
81+ MSBuild.exe /m generate_uninstall\uninstall.vcxproj
82+ if errorlevel 1 (
83+ exit /B 1
84+ )
7685)
7786
7887if exist %INSTALL_DIR% \lib\pkgconfig\libbson-1.0.pc (
@@ -163,6 +172,24 @@ if "%BSON_ONLY%" NEQ "1" (
163172 echo $INSTALL_DIR\include\libmongoc-1.0 check ok
164173 )
165174)
175+ if exist %INSTALL_DIR% \share\mongo-c-driver\uninstall-bson.cmd (
176+ echo uninstall-bson.cmd found!
177+ exit /B 1
178+ ) else (
179+ echo uninstall-bson.cmd check ok
180+ )
181+ if exist %INSTALL_DIR% \share\mongo-c-driver\uninstall.cmd (
182+ echo uninstall.cmd found!
183+ exit /B 1
184+ ) else (
185+ echo uninstall.cmd check ok
186+ )
187+ if exist %INSTALL_DIR% \share\mongo-c-driver\uninstall-bson.sh (
188+ echo uninstall-bson.sh found!
189+ exit /B 1
190+ ) else (
191+ echo uninstall-bson.sh check ok
192+ )
166193if exist %INSTALL_DIR% \share\mongo-c-driver\uninstall.sh (
167194 echo uninstall.sh found!
168195 exit /B 1
0 commit comments