views:

145

answers:

1

I have a python script that calls out to two Sysinternals tools (sigcheck and accesschk). Is there a way I can bundle these executables into a py2exe so that subprocess.Popen can see it when it runs?


Full explanation: My script is made to execute over a network share (S:\share\my_script.exe) and it makes hundreds of calls to sigcheck and accesscheck. If sigcheck and accesschk also reside on the server, they seem to get transferred to the host, called once, transferred the the host again, called a second time, on and on until the almost 400-500 calls are complete.

I can probably fall back to copying these two executables to the host (C:) and then deleting them when I'm done... how would you solve this problem?

+1  A: 

I could be wrong about this, but I don't believe this is what py2exe was intended for. It's more about what you're distributing than about how you're distributing. I think what you may be looking for is the option to create a windows installer. You could probably add the executables as data files or scripts using distutils.

arggg Why can't my data_files just get bundled into the zipfile?

I've started using paver for this kind of thing. It makes it really easy to override commands or create new commands that will allow you to put some new files into the sdist.

Jason Baker
I can't install software on the host. I have to run entirely from the network share. :-(
Dan
Also, none of the hosts executing my script have Python installed.
Dan