levW has asked for the wisdom of the Perl Monks concerning the following question:

HI,

I was creating .exe files for long years with 5.8.8 pp.All was fine.

Now that I have upgraded to 5.30 strawberry , all my .exe programs complete, but fail to exit - get stuck.

Any advise will be appreciated.

thanks

Replies are listed 'Best First'.
Re: .exe fails to exit
by swl (Prior) on Jul 14, 2019 at 12:01 UTC

    Just to be sure, your program completes and exits properly when it is not run as a packed exe?

    Assuming it does, one option is to instrument the code with feedback when it completes processing, and perhaps also in an END block. If you have objects under your control then you could add DESTROY methods that simply log when they are called, perhaps only when in the global destruct phase. See https://perldoc.perl.org/perlobj.html#Destructors and the Global Destruction section immediately following it.

    Also, does this occur on machines other than those you built your exe on? Have you packed all the needed external DLLs? If not then other systems might be loading different versions (although if that is the case then I would not expect the exe to get very far in the first place).

Re: .exe fails to exit
by marto (Cardinal) on Jul 14, 2019 at 09:34 UTC

      Thanks, but not really.I dis use SysInternals for both issues with no luck so far

      Now it's a different issue - the program opens and runs well, but will not exit

      task manager shows several program handles/dlls open.No idea why

      do not see any other handle opened by my program...

        Executable distributions generated by pp are just glorified zip files. You can try to unpack your app into an empty directory, open a clean shell (no other perl in PATH), set the PATH variable so Windows can find the perl executable of your distribution and run your script. See how that works. Maybe you are just missing a dependency that pp did not find because it gets magically loaded somewhere.


        holli

        You can lead your users to water, but alas, you cannot drown them.

        Your post lacks any real detail, and doesn't reference your previous thread. How do I post a question effectively?. Posting what you've tried/discovered along with the context of the problem makes it easier to help. Posting an example which replicates the issue will make it easier for people to help.

        "Now it's a different issue" does the first problem still exist?

Re: .exe fails to exit (the cute one)
by Anonymous Monk on Jul 15, 2019 at 09:27 UTC

    doctor doctor it hurts when ...

    sounds like you should stick to 5.8.8

    2006 was a great one


    the cute one