I don't think you want PyInstaller here. In fact, what you are doing is simply writing a C++ application, Python, in this case, is being used as a C library.
So what you need to do is bundle up your app like any C++ app, that is to say: * It has to be linked to the Python libs * It has to have access to the Python standard library * It has to have access to your Python code I'm sure it's *possible* to do all of that in a single exe file, but it's going to be hard. So I'd plan on making an installer that creates a folder that has your exe and anything you need in it. BTW, I think you are making things harder on yourself than you could. As a rule, it's easier to call C++ from Python than the other way around (via ctypes, Cython, pybind11 etc. And there already is wxPython for a wx GUI. As the GUI isn't usually the performance bottleneck, I'd write that in Python, too :-) Good luck, -CHB On Thu, Jul 23, 2020 at 8:12 AM bwoodsend <[email protected]> wrote: > Ahh your embedding Python into C++. I’ve never done that so I probably > can’t help much. I imagine your C++ program needs to be able to find > python3.dll and all its dependents so it needs to be in either your PATH > or your current working directory. And it will also need > PythonApplication1.py to be separated from the PyInstaller exe. > > If you PyInstaller PythonApplication1.py, compile your C++ code, then > copy PythonApplication1.py and cppFile.exe into dist/PythonApplication1/. > Then launch `cppFile.exe`. Don’t try to use --onefile with PyInstaller > yet - I can show you how to turn it into a single file after we’ve got it > working as a bundle first. > > > -- > You received this message because you are subscribed to the Google Groups > "PyInstaller" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/pyinstaller/ace71e6b-cb01-4691-8b01-2eb3e6356a4fn%40googlegroups.com > <https://groups.google.com/d/msgid/pyinstaller/ace71e6b-cb01-4691-8b01-2eb3e6356a4fn%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception [email protected] -- You received this message because you are subscribed to the Google Groups "PyInstaller" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pyinstaller/CALGmxE%2BkV%2B6%2BeTyq1gPFOEN8qn0%2B34EYsDAraWY0EFX8dLWG2Q%40mail.gmail.com.
