Installing img2pdf on Windows #8

Closed
opened 3 years ago by josch · 0 comments
josch commented 3 years ago
Owner

By josch on 2015-03-15T09:41:48.162Z

Created by: mrkennethleung

Hi Josch, I have downloaded your zip file, and now wonder how to install this on my Window 7.
I tried double click on all your files, and none can install. (sorry, I am a non technical person).
It seems I need Python program to run this?
Please help, much appreciated.

Kenneth

Imported comments:

By josch on 2014-12-10 12:57:20 UTC

Hi,
unfortunately my only contact with windows is through friends who have that operating system installed. So I cannot give you any more information than I can find via online tutorials.
And yes, you need the Python interpreter to run the program.
I heard there are facilities to bundle Python scripts together with the interpreter into a self-contained *.exe but since I'm not running windows I never tried this.
I leave this bugreport open so that somebody with experience on the windows platform can potentially help you with this.
In that case, those instructions would go into the README.

By mrkennethleung on 2014-12-10 13:01:22 UTC

Thanks @josch

By bitsgalore on 2014-12-10 15:11:43 UTC

For what it's worth, I had a quick stab at building stand-alone Windows executables using PyInstaller. Results here:

https://github.com/bitsgalore/img2pdf

The .spec file contains the package definitions, the .bat file does the actual build.

The problem is that when I run the resulting executable (which you can find inside the zip file in the dist directory of the repo) it gives me this error:

ImportError: The _imaging C module is not installed

I suppose this is the result of PyInstaller not importing PIL the way it should. Perhaps someone with a better knowledge of import hooks in PyInstaller knows how to fix this ....


By josch on 2017-01-21T07:51:51.128Z


Changed title: Installing img2pdfInstalling img2pdf{+ on Windows+}


By Timo B. on 2019-04-07T12:23:50.407Z


Hi Josch

just to let you know: creating a Windows-exe by using Pyinstaller (https://www.pyinstaller.org/) works perfectly.
Envorinment used: Win7 x64, Python 3.7.2, Pyinstaller 3.4

  1. open cmd in img2pdf-src-directory containing the 'img2pdf.py'
  2. use the command: pyinstaller --onefile img2pdf.py
  3. the execution takes several seconds (some 10-seconds maybe) and creates several files and directories.
  4. the img2pdf.exe is located in the newly created dist-directory and is about 7.4MB in size (sort of)(img2pdf 0.3.3).

With what I did it seems to be fully functional so far, tested with Win7x64 and Win10.

Thank you for this great tool, absolutely awesome ! 👍 💪


By josch on 2020-04-05T13:27:49.527Z


There is now appveyor and travis CI integration that also tests windows installation and uses pyinstaller. Thanks for your suggestion!


By josch on 2020-04-05T13:27:49.759Z


Status changed to closed

*By josch on 2015-03-15T09:41:48.162Z* *Created by: mrkennethleung* Hi Josch, I have downloaded your zip file, and now wonder how to install this on my Window 7. I tried double click on all your files, and none can install. (sorry, I am a non technical person). It seems I need Python program to run this? Please help, much appreciated. Kenneth **Imported comments:** *By josch on 2014-12-10 12:57:20 UTC* Hi, unfortunately my only contact with windows is through friends who have that operating system installed. So I cannot give you any more information than I can find via online tutorials. And yes, you need the Python interpreter to run the program. I heard there are facilities to bundle Python scripts together with the interpreter into a self-contained *.exe but since I'm not running windows I never tried this. I leave this bugreport open so that somebody with experience on the windows platform can potentially help you with this. In that case, those instructions would go into the README. *By mrkennethleung on 2014-12-10 13:01:22 UTC* Thanks @josch *By bitsgalore on 2014-12-10 15:11:43 UTC* For what it's worth, I had a quick stab at building stand-alone Windows executables using PyInstaller. Results here: <https://github.com/bitsgalore/img2pdf> The .spec file contains the package definitions, the .bat file does the actual build. The problem is that when I run the resulting executable (which you can find inside the zip file in the dist directory of the repo) it gives me this error: ImportError: The _imaging C module is not installed I suppose this is the result of PyInstaller not importing PIL the way it should. Perhaps someone with a better knowledge of import hooks in PyInstaller knows how to fix this .... --- *By josch on 2017-01-21T07:51:51.128Z* --- Changed title: **Installing img2pdf** → **Installing img2pdf{+ on Windows+}** --- *By Timo B. on 2019-04-07T12:23:50.407Z* --- Hi Josch just to let you know: creating a Windows-exe by using Pyinstaller (https://www.pyinstaller.org/) works perfectly. Envorinment used: Win7 x64, Python 3.7.2, Pyinstaller 3.4 1. open cmd in img2pdf-src-directory containing the 'img2pdf.py' 2. use the command: `pyinstaller --onefile img2pdf.py` 3. the execution takes several seconds (some 10-seconds maybe) and creates several files and directories. 4. the img2pdf.exe is located in the newly created dist-directory and is about 7.4MB in size (sort of)(img2pdf 0.3.3). With what I did it seems to be fully functional so far, tested with Win7x64 and Win10. Thank you for this great tool, absolutely awesome ! :thumbsup: :muscle: --- *By josch on 2020-04-05T13:27:49.527Z* --- There is now appveyor and travis CI integration that also tests windows installation and uses pyinstaller. Thanks for your suggestion! --- *By josch on 2020-04-05T13:27:49.759Z* --- Status changed to closed
josch closed this issue 3 years ago
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: josch/img2pdf#8
Loading…
There is no content yet.