Menu

#656 Windows Install Bug: gm.exe unable to start correctly

v1.0_(example)
closed-fixed
windows (3)
5
2023-08-01
2021-12-07
Tim Mensch
No

After install of the prebuilt binary GraphicsMagick-1.3.36-Q16-win64-dll.exe , gm.exe just doesn't run.

I get a dialog that says "The application was unable to start correctly (0xc0150002)".

I tried Dependency Walker, and it reports a bad side-by-side config:

Error: The Side-by-Side configuration information for "c:\devel\graphicsmagick\CORE_RL_MAGICK_.DLL" contains errors. The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail (14001).

With the recommendation above, I then ran sxstrace.exe and got this error from near the end of the log:

INFO: Parsing Manifest File C:\Windows\WinSxS\manifests\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.9625_none_08e1c10da83fbc83.manifest.
        INFO: Manifest Definition Identity is Microsoft.VC90.CRT,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.30729.9625".
INFO: Parsing Manifest File C:\devel\graphicsmagick\Microsoft.VC90.OpenMP.MANIFEST.
        INFO: Manifest Definition Identity is Microsoft.VC90.OpenMP,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.30729.6161".
        ERROR: Component identity found in manifest does not match the identity of the component requested. Reference is Microsoft.VC90.OpenMP,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8". Definition is Microsoft.VC90.OpenMP,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.30729.6161".
ERROR: Activation Context generation failed.
End Activation Context Generation.

AND after some digging I fixed it by digging up the Visual Studio 2008 Redist installer, so this is, I guess, a documentation bug--or an installer bug? Somehow the installer didn't install the Redist package for me.

So: Workaround is to install the VS2008 package from this page:

https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist?view=msvc-170

As to how to fix the bug (via documentation or updating the installer), I'll leave that to the maintainers to decide.

Related

Bugs: #656

Discussion

  • Bob Friesenhahn

    Bob Friesenhahn - 2021-12-08

    On Tue, 7 Dec 2021, Tim Mensch wrote:

    AND after some digging I fixed it by digging up the Visual Studio
    2008 Redist installer, so this is, I guess, a documentation bug--or
    an installer bug? Somehow the installer didn't install the Redist
    package for me.

    What happened is that the Visual Studio 2019 installer offered to
    apply a Visual Studio 2008 SP1 update for me. I foolishly agreed.
    This update apparently has a bug in the SP1 re-distributables in that
    there is a mis-match between provided files. If I knew what the
    correct pair of files are, then I could correct my compiler
    installation and be able to offer a more useful installer.

    I asked several times for help from Windows GraphicsMagick users with
    more knowledge than me (I am not really a Windows user since I only
    use Windows to compile GraphicsMagick and update my Garmin GPS), and
    who were using systems which exhibited the problem (of course it works
    for me) but they were not very helpful. Some were completely the
    opposite of helpful.

    Due to this problem and much larger ones (e.g. some third-party
    packages need to be updated due to security issues), I already posted
    to the graphicsmagick-announce list that there will not be any Windows
    install package corresponding to the forthcomming release.

    I need a Visual Studio literate volunteer to assist with updating to
    make the Visual Studio based build be what it should be. At this time
    (and for several years) I am the only productive developer on the
    project. Assistance is dearly needed. One person can not do
    everything in their spare time!

    So: Workaround is to install the VS2008 package from this page:

    https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist?view=msvc-170

    Yes, installing the Visual Studio 2008 SP1 redistributables will solve
    the problem.

    For modern Visual Studio, the efficient and simple two-file approach
    which worked before is no longer allowed. Instead a redistributables
    package which is 3X larger than the GraphicsMagick installer is
    required to be installed. But many/most systems won't need this. I
    refuse to make the GraphicsMagick installer package download so much
    larger by bundling the whole redistributables as some installers do.
    Either it needs to download and install from the Internet as needed or
    the end user needs to somehow know to do it.

    Bob

    Bob Friesenhahn
    bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
    GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
    Public Key, http://www.simplesystems.org/users/bfriesen/public-key.txt

     
  • Bob Friesenhahn

    Bob Friesenhahn - 2021-12-24

    I only have one Windows system to test on. A system that has Visual Studio installed on it (what I have) already has everything needed to run the program which is built, so it is useless for testing.

    It would be IMMENSELY useful if someone can provide sha1 checksums (or similar) for the Visual Studio SP1 manifest and DLL files needed in order to run GraphicsMagick. We are only talking about a total of four files. Microsoft is spectacularly unhelpful in that they only provide an installer exe package (how can I look inside of it?) and they do not appear to provide any checksums for their redistributables.

    I did find https://support.microsoft.com/en-us/topic/description-of-the-security-update-for-microsoft-visual-studio-2008-service-pack-1-july-28-2009-12eec35d-3ce4-3e9e-1ff9-86ec81394552, which at least provides file sizes for what might be the necessary files. If this represents Microsoft's approach to security, then it is doing very poorly at it.

    Windows itself maintains its collection of DLLs/manifests via Windows updates so the files that happen to be on a given computer are unlikely to represent the official SP1 files.

    Is anyone able to help me?

     
  • Pudnik

    Pudnik - 2022-06-27

    ...Bob,

    If you don't have the time nor the skill to update gm properly....give it up to a person who does.

    This person should have the skill and experience to port the build environment, with all OS dependencies, libs, correct versions, etc, into a container image.

    Then, this person could publish the container image and link to it via the downloads link on the gm home page, periodically, when the source code changes.

    All a tech savvy user such as myself would then have to do is download the container image - say docker - run that image, type BUILD at the prompt, and it would build a current version static build correctly every time, and a nix, OSX, and Windows static build executables would appear in the default folder. The user grabs those files then deletes the container.

    What do ya say?

    JB

     
    • Bob Friesenhahn

      Bob Friesenhahn - 2022-06-27

      On Mon, 27 Jun 2022, Pudnik wrote:

      ...Bob,

      If you don't have the time nor the skill to update gm properly....give it up to a person who does.

      This person should have the skill and experience to port the build environment, with all OS dependencies, libs, correct versions, etc, into a container image.

      Then, this person could publish the container image and link to it via the downloads link on the gm home page, periodically, when the source code changes.

      All a tech savvy user such as myself would then have to do is download the container image - say docker - run that image, type BUILD at the prompt, and it would build a current version static build correctly every time, and a nix, OSX, and Windows static build executables would appear in the default folder. The user grabs those files then deletes the container.

      What do ya say?

      Thank you for the helpful advice.

      Given that you are a tech savvy user, are you offering to take
      responsibility for this?

      Please note that it may be quite a lot of work.

      While I can likely repair my old compiler installation so that the
      result works (a stop-gap measure), the existing development/build
      strategy for Microsoft Windows Visual Studio builds does not appear to
      be a correct path due to not leveraging the efforts of many others.
      It made sense in 2002, but not in 2022.

      Bob

      Bob Friesenhahn
      bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
      GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
      Public Key, http://www.simplesystems.org/users/bfriesen/public-key.txt

       
      • Pudnik

        Pudnik - 2022-06-28

        Well, the words 'tech savvy' cover a HUGE range. When I wrote those words, I was thinking about a user that is tech savvy enough to download a docker image, get it running, and run the commands necessary to compile the project.
        Not necessarily a user that could modify the graphics processing engine of the solution successfully.

        There are tech savvy people that can write small scripts, stage data to data lakes, understand large platforms like Azure, secure their social media accounts properly, and the like.
        I'm one of those; I'm a data engineer by profession.

        And then, there are tech savvy people that would be capable of compiling? Azure. Or administering multiple Google or Facebook data centers. Or building a 3-D shooter game.

        I am skilled at python at that level, but I would have to see the Visual Studio solution in order to determine if I was skilled enough to take it on.

        If I did, certainly I would want to modernize the build pipeline - first off, move it to Github, then modernize all the build components.

        John Bonifas

         

        Last edit: Bob Friesenhahn 2022-07-02
  • Bob Friesenhahn

    Bob Friesenhahn - 2023-08-01
    • status: open --> closed-fixed
    • assigned_to: Bob Friesenhahn
     
  • Bob Friesenhahn

    Bob Friesenhahn - 2023-08-01

    This issue was addressed in the 1.3.40 release by installing Microsoft redistributables rather than using a side-by-side DLL configuration.

     

Log in to post a comment.