New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#2620 Fix "Error loading Python DLL" on Windows 7 #89

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
2 participants
@jamesmudd
Contributor

jamesmudd commented Sep 7, 2017

The problem is caused by the python27.dll file being external to the
.exe See
https://stackoverflow.com/questions/19225132/pyinstaller-not-working-on-simple-helloworld-program

The fix here is to use PyInstaller with the "--onefile" or "-F" option.

This is also tidier as it results in having a combined executable.

Built with PyInstaller 3.2.1 on Python 2.7.13 on Windows-10-10.0.15063

#2607, #2620 Fix "Error loading Python DLL" (error code 14001)
The problem is caused by the python27.dll file being external to the
.exe See
https://stackoverflow.com/questions/19225132/pyinstaller-not-working-on-simple-helloworld-program

The fix here is to use PyInstaller with the "--onefile" or "-F" option.

This is also tidier as it results in having a combined executable.

Built with PyInstaller 3.2.1 on Python 2.7.13 on Windows-10-10.0.15063
@jeff5

This comment has been minimized.

Show comment
Hide comment
@jeff5

jeff5 Sep 19, 2017

Member

@jamesmudd I agree. This came up elsewhere but you found a better how-to than I did. I think you may have done this right originally and I broke it when I rebuilt the launcher. The root of the problem, I suggest, is not having a dev guide (or ant target) for the launcher.

Member

jeff5 commented Sep 19, 2017

@jamesmudd I agree. This came up elsewhere but you found a better how-to than I did. I think you may have done this right originally and I broke it when I rebuilt the launcher. The root of the problem, I suggest, is not having a dev guide (or ant target) for the launcher.

@jamesmudd

This comment has been minimized.

Show comment
Hide comment
@jamesmudd

jamesmudd Sep 20, 2017

Contributor

@jeff5 I agree the issue is there should be an ant target to generate this launcher. I will have a go at setting that up. Additionally I don't think there are any actual tests which try to use this launcher but that's a harder problem as we would need windows testing to work, preferably on all versions of Windows that are supported (I'm not even sure which Jython claims to support).

Contributor

jamesmudd commented Sep 20, 2017

@jeff5 I agree the issue is there should be an ant target to generate this launcher. I will have a go at setting that up. Additionally I don't think there are any actual tests which try to use this launcher but that's a harder problem as we would need windows testing to work, preferably on all versions of Windows that are supported (I'm not even sure which Jython claims to support).

@jeff5

This comment has been minimized.

Show comment
Hide comment
@jeff5

jeff5 Sep 20, 2017

Member

Thanks James.

sys.executable points to it, so test_subprocess etc. will exercise it. Almost by definition, we do not catch the problem fixed here.

Member

jeff5 commented Sep 20, 2017

Thanks James.

sys.executable points to it, so test_subprocess etc. will exercise it. Almost by definition, we do not catch the problem fixed here.

@jeff5 jeff5 self-assigned this Oct 21, 2017

@jeff5

This comment has been minimized.

Show comment
Hide comment
@jeff5

jeff5 Oct 21, 2017

Member

Now at https://hg.python.org/jython/rev/d638b2c5ef28.

I think we could live without an ant target (and anyway, PyInstaller wll not be available for all). I'll add a note in the devguide and jython.py, which will make it necessary I go through the process myself.

Member

jeff5 commented Oct 21, 2017

Now at https://hg.python.org/jython/rev/d638b2c5ef28.

I think we could live without an ant target (and anyway, PyInstaller wll not be available for all). I'll add a note in the devguide and jython.py, which will make it necessary I go through the process myself.

@jeff5 jeff5 closed this Oct 21, 2017

@jamesmudd jamesmudd deleted the jamesmudd:2620 branch Oct 23, 2017

@jamesmudd

This comment has been minimized.

Show comment
Hide comment
@jamesmudd

jamesmudd Oct 23, 2017

Contributor

@jeff5 Thanks for merging this. I have taken a look at the devguide and it looks good to me. I did have a look at the ant target, but it would be difficult as you mention it would need to assume you already have PyInstaller present and probably guess the path to it assuming default install directories.

Contributor

jamesmudd commented Oct 23, 2017

@jeff5 Thanks for merging this. I have taken a look at the devguide and it looks good to me. I did have a look at the ant target, but it would be difficult as you mention it would need to assume you already have PyInstaller present and probably guess the path to it assuming default install directories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment