* compile python executable file on cygwin for windows @ 2016-12-19 15:07 Goodman Leung 2016-12-19 15:13 ` Marco Atzeri 2016-12-19 16:45 ` Erik Bray 0 siblings, 2 replies; 6+ messages in thread From: Goodman Leung @ 2016-12-19 15:07 UTC (permalink / raw) To: cygwin hi all i install python and pyinstaller on cygwin , and i can run pyinstaller successfully to compile a exe file on the cygwin environment . but when i launch this executable file on window with double click , it occur a error and tell me the program can not find "cygwin.dll" (i can not remember what it exactly is ). can cygwin compile a windows python executable program .or we should treat cygwin like a pure linux OS that all things we have done on it just compatible with linux only best regards yuanxin.liang -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: compile python executable file on cygwin for windows 2016-12-19 15:07 compile python executable file on cygwin for windows Goodman Leung @ 2016-12-19 15:13 ` Marco Atzeri 2016-12-19 16:31 ` Goodman Leung 2016-12-19 16:45 ` Erik Bray 1 sibling, 1 reply; 6+ messages in thread From: Marco Atzeri @ 2016-12-19 15:13 UTC (permalink / raw) To: cygwin On 19/12/2016 16:07, Goodman Leung wrote: > hi all > > i install python and pyinstaller on cygwin , and i can run pyinstaller > successfully to compile a exe file on the cygwin environment . > > but when i launch this executable file on window with double click , it > occur a error and tell me the program can not find "cygwin.dll" (i can > not remember what it exactly is ). > > can cygwin compile a windows python executable program .or we should > treat cygwin like a pure linux OS that all things we have done on it > just compatible with linux only > > best regards > yuanxin.liang > > have you tried to run it from the Cygwin terminal (aka Mintty) ? Running from explorer (double click) do not properly set the PATH variable for cygwin programs. Regards MArco -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: compile python executable file on cygwin for windows 2016-12-19 15:13 ` Marco Atzeri @ 2016-12-19 16:31 ` Goodman Leung 0 siblings, 0 replies; 6+ messages in thread From: Goodman Leung @ 2016-12-19 16:31 UTC (permalink / raw) To: cygwin yes, i tried , the program can start at less, and it stop for unable to find a file , because the format of path of the file is wrong, i use open(path+r"\\"+filename,"rb"), but the program explain it as c:\xxx\xxx\xxx////filename,that is wired . and if i compile this source code under cmd. it works well . also, i notice when i compile the program on cygwin with command pyinstaller -F example.py , there is a error that program can not find module win32com, and it still completed the compilation . i thinks that might be the reason why the executable file which compiled under Cygwin can not run properly . module win32com might be supported by pywin32 , i try to pip install pywin32 , but i was told there was no satisfies version . and i try pip search pywin32 , the resule as below: $ pip search pywin32 PLUIE-new-realease-0.5 (0.5) - a GUI for Python, via IE with Pywin32 pywin32-ctypes (0.0.1) - UNKNOWN PLUIE-new-realease (0.5) - a GUI for Python, via IE with Pywin32 PLUIE (0.89) - a GUI for Python, via IE with Pywin32 pywin32 (214) - Python extensions for Windows there is a pywin32 in the repository . the next . i tried to compile pywin32 myself , unfortunately , i did not find the source code . only .exe file which is for the windows platform . i remember i installed a pywin32.exe on my windows OS , that meet the thing i said above , program compile under cmd can run properly . from the what i experienced, i begin to doubt if if Cygwin can compile a python executable file for windows . On 2016/12/19 23:13, Marco Atzeri wrote: > On 19/12/2016 16:07, Goodman Leung wrote: >> hi all >> >> i install python and pyinstaller on cygwin , and i can run pyinstaller >> successfully to compile a exe file on the cygwin environment . >> >> but when i launch this executable file on window with double click , it >> occur a error and tell me the program can not find "cygwin.dll" (i can >> not remember what it exactly is ). >> >> can cygwin compile a windows python executable program .or we should >> treat cygwin like a pure linux OS that all things we have done on it >> just compatible with linux only >> >> best regards >> yuanxin.liang >> >> > > have you tried to run it from the Cygwin terminal (aka Mintty) ? > > Running from explorer (double click) do not properly set the > PATH variable for cygwin programs. > > Regards > MArco > > -- > Problem reports: http://cygwin.com/problems.html > FAQ: http://cygwin.com/faq/ > Documentation: http://cygwin.com/docs.html > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: compile python executable file on cygwin for windows 2016-12-19 15:07 compile python executable file on cygwin for windows Goodman Leung 2016-12-19 15:13 ` Marco Atzeri @ 2016-12-19 16:45 ` Erik Bray 2016-12-20 16:52 ` Goodman Leung 1 sibling, 1 reply; 6+ messages in thread From: Erik Bray @ 2016-12-19 16:45 UTC (permalink / raw) To: cygwin On Mon, Dec 19, 2016 at 4:07 PM, Goodman Leung <gbcbooksmj@gmail.com> wrote: > hi all > > i install python and pyinstaller on cygwin , and i can run pyinstaller > successfully to compile a exe file on the cygwin environment . > > but when i launch this executable file on window with double click , it > occur a error and tell me the program can not find "cygwin.dll" (i can not > remember what it exactly is ). > > can cygwin compile a windows python executable program .or we should treat > cygwin like a pure linux OS that all things we have done on it just > compatible with linux only I don't think pyinstaller knows anything about Cygwin explicitly. Instead, you need to list all DLLs used by your program (namely cygwin1.dll, possibly others) in the spec file for your installer, so that it copies them into the package too. You can use the cygcheck program to check exactly which DLLs are required by the executables in your program. For example you will also likely need Cygwin's libpythonXY.dll, and possibly others. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: compile python executable file on cygwin for windows 2016-12-19 16:45 ` Erik Bray @ 2016-12-20 16:52 ` Goodman Leung 2016-12-21 14:19 ` Erik Bray 0 siblings, 1 reply; 6+ messages in thread From: Goodman Leung @ 2016-12-20 16:52 UTC (permalink / raw) To: cygwin i tried cygcheck , there was no error report from it . and i check my program again, the error info is , program can not find cygwin1.dll, i check that fell,it is under c:\cygwin\bin\cygwin1.dll cygcheck can also find it . On 2016/12/20 0:45, Erik Bray wrote: > On Mon, Dec 19, 2016 at 4:07 PM, Goodman Leung <gbcbooksmj@gmail.com> wrote: >> hi all >> >> i install python and pyinstaller on cygwin , and i can run pyinstaller >> successfully to compile a exe file on the cygwin environment . >> >> but when i launch this executable file on window with double click , it >> occur a error and tell me the program can not find "cygwin.dll" (i can not >> remember what it exactly is ). >> >> can cygwin compile a windows python executable program .or we should treat >> cygwin like a pure linux OS that all things we have done on it just >> compatible with linux only > I don't think pyinstaller knows anything about Cygwin explicitly. > Instead, you need to list all DLLs used by your program (namely > cygwin1.dll, possibly others) in the spec file for your installer, so > that it copies them into the package too. > > You can use the cygcheck program to check exactly which DLLs are > required by the executables in your program. For example you will > also likely need Cygwin's libpythonXY.dll, and possibly others. > > -- > Problem reports: http://cygwin.com/problems.html > FAQ: http://cygwin.com/faq/ > Documentation: http://cygwin.com/docs.html > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: compile python executable file on cygwin for windows 2016-12-20 16:52 ` Goodman Leung @ 2016-12-21 14:19 ` Erik Bray 0 siblings, 0 replies; 6+ messages in thread From: Erik Bray @ 2016-12-21 14:19 UTC (permalink / raw) To: cygwin On Tue, Dec 20, 2016 at 5:52 PM, Goodman Leung <gbcbooksmj@gmail.com> wrote: > i tried cygcheck , there was no error report from it . > and i check my program again, the error info is , program can not find > cygwin1.dll, > > i check that fell,it is under c:\cygwin\bin\cygwin1.dll > cygcheck can also find it . You need to make sure that cygwin1.dll and any other required DLLs are bundled with your application, preferably in the same directory, or else it won't be able to find them. There's a good tutorial here: https://www.youtube.com/watch?v=abM_ysmpenc > On 2016/12/20 0:45, Erik Bray wrote: >> >> On Mon, Dec 19, 2016 at 4:07 PM, Goodman Leung <gbcbooksmj@gmail.com> >> wrote: >>> >>> hi all >>> >>> i install python and pyinstaller on cygwin , and i can run pyinstaller >>> successfully to compile a exe file on the cygwin environment . >>> >>> but when i launch this executable file on window with double click , it >>> occur a error and tell me the program can not find "cygwin.dll" (i can >>> not >>> remember what it exactly is ). >>> >>> can cygwin compile a windows python executable program .or we should >>> treat >>> cygwin like a pure linux OS that all things we have done on it just >>> compatible with linux only >> >> I don't think pyinstaller knows anything about Cygwin explicitly. >> Instead, you need to list all DLLs used by your program (namely >> cygwin1.dll, possibly others) in the spec file for your installer, so >> that it copies them into the package too. >> >> You can use the cygcheck program to check exactly which DLLs are >> required by the executables in your program. For example you will >> also likely need Cygwin's libpythonXY.dll, and possibly others. >> >> -- >> Problem reports: http://cygwin.com/problems.html >> FAQ: http://cygwin.com/faq/ >> Documentation: http://cygwin.com/docs.html >> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple >> > > > -- > Problem reports: http://cygwin.com/problems.html > FAQ: http://cygwin.com/faq/ > Documentation: http://cygwin.com/docs.html > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-12-21 14:19 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2016-12-19 15:07 compile python executable file on cygwin for windows Goodman Leung 2016-12-19 15:13 ` Marco Atzeri 2016-12-19 16:31 ` Goodman Leung 2016-12-19 16:45 ` Erik Bray 2016-12-20 16:52 ` Goodman Leung 2016-12-21 14:19 ` Erik Bray
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).