[Osgeo4w-trac] [osgeo4w] #876: saga 9.7.1-1 fails to start (MSVCP140.dll error)

OSGeo4W trac_osgeo4w at osgeo.org
Sun Mar 30 23:52:49 PDT 2025


#876: saga 9.7.1-1 fails to start (MSVCP140.dll error)
------------------------+----------------------------
Reporter:  andreaerdna  |       Owner:  osgeo4w-dev@…
    Type:  defect       |      Status:  new
Priority:  critical     |   Component:  Package
 Version:               |  Resolution:
Keywords:               |
------------------------+----------------------------
Comment (by jef):

 Replying to [comment:3 andreaerdna]:
 > Why GRASS-GIS and SAGA-GIS (and other ones) executable don't use the
 msvcp140.dll shipped by OSGeo4W with the msvcrt2019 package (shouldn't it
 be named msvcrt2022)? Is there a way to enforce the use of the one shipped
 by OSGeo4W instead of the one installed in the system (apart from copying
 the msvcp*.dll in the same folder of the executable)?

 No. That's the problem.  QGIS (and python) use AddDllDirectory internally
 to make sure system32 doesn't take priority over PATH - but that's not the
 default.  By default t directory of a DLL or EXE has the highest priority
 - that's why copying the runtime everywhere helps, then system32, then
 whatever is in PATH.

 My question is why this is a problem all of a sudden on some machines.
 I'm not aware of any updates in OSGeo4W that would cause this.  Installing
 the latest runtime would require admin rights, but I don't think that the
 latest one is even required - any not too ancient one should do - so I
 wonder why/if/how you got yours.
-- 
Ticket URL: <https://trac.osgeo.org/osgeo4w/ticket/876#comment:6>
OSGeo4W <http://trac.osgeo.org/osgeo4w>
OSGeo4W is the Windows installer and package environment for the OSGeo stack.


More information about the Osgeo4w-trac mailing list