Python Forum
I need help! How to package python code with other component into an exe file??
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
I need help! How to package python code with other component into an exe file??
#1
Ask for help:

How do I package the python code and other components(some exe,jar and dll files) it depends on to run into an executable file? I have tried pyinstaller in windows and mac. In the past few days, I checked a lot of information, but all failed.

Currently, my executable and lib folder(containing several third-party components) can be run in the same directory, but if I delete the lib folder, it will not work. But I want to keep only the executable (this is also the project's requirements)
thank you very much!
Reply
#2
(Jul-14-2019, 05:39 PM)Wendy Wrote: have tried pyinstaller in windows and mac. In the past few days, I checked a lot of information, but all failed.
What failed?
It can be a little difficult to troubleshoot in some cases,look at this post.
I usually start from virtual environment to have all isolated and working before use pyinstaller.
Then start to work out error in any,doc is also good When Things Go Wrong.
Reply
#3
thank you for your help and quick reply. I will try it. Smile
Reply
#4
The above is a very detailed solution, but unfortunately it is not very suitable, the folder where the executable leaves the third-party component still does not work. Is there any other possible solution??? thank you very much.
Reply
#5
(Jul-15-2019, 03:18 AM)Wendy Wrote: The above is a very detailed solution, but unfortunately it is not very suitable, the folder where the executable leaves the third-party component still does not work. Is there any other possible solution??? thank you very much.
It's of course impossible help with info you have given.
Here an other one Sound-player standalone,see that know which external files that i need to add avbin.dll(windows) and libavbin.so.10(Linux),as i build it for both Windows and Linux.
See command line and spec file where can extra stuff that needed in project when build with pyinstaller.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to run utilities from a Python package? LugosisGhost 1 390 Dec-27-2023, 12:00 PM
Last Post: Larz60+
  Not able to install package caldwellpy and requirement txt file Samta282006 1 669 Dec-07-2023, 11:59 PM
Last Post: Larz60+
  Python package not seen in VSCode fmccabe80 6 3,080 Mar-06-2023, 10:01 PM
Last Post: fmccabe80
  Problem with importing Python file in Visual Studio Code DXav 7 4,911 Jun-15-2022, 12:54 PM
Last Post: snippsat
  Python code to read second line from CSV files and create a master CSV file sh1704 1 2,353 Feb-13-2022, 07:13 PM
Last Post: menator01
  Math Package in python Uma 1 1,462 Dec-12-2021, 02:01 PM
Last Post: jefsummers
  Package cannot be loaded into PBS queue file emersonpl 1 1,775 Sep-09-2021, 08:06 PM
Last Post: emersonpl
Sad SyntaxError: from simple python example file from mind-monitor code (muse 2) warmcupoftea 4 2,751 Jul-16-2021, 02:51 PM
Last Post: warmcupoftea
  Request for Python code - Features extraction from JSON file (cuckoo) thinker 1 2,147 Apr-07-2021, 04:40 PM
Last Post: Larz60+
  Skeleton file export error Python Code pepapoha 4 3,426 Nov-17-2020, 02:06 AM
Last Post: pepapoha

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020