Compiling Pyspades on Windows

Host your own server and communicate with server operators.
1 post Page 1 of 1 First unread post
Heatguts
Deuce
Posts: 5
Joined: Sun May 22, 2016 6:27 am


I decided yesterday I wanted to see what all I could do with the few released AoS bot scripts (mainly the zombie one). So I set up a PySnips server, forwarded some ports, couldn't connect through localhost, couldn't connect through the server listings in OpenSpades, then found out there's a very specific ip you have to connect to and finally got into my server. Well that's great. So I close Openspades, open the server config, and add the zombie script, then try to run my server and it crashes. So I go back to google to figure out what's wrong and guess what, this site went down. Luckily google bothered to cache the first pages of most of the threads on this forum and I found that first of all I needed to be running pyspades not PySnips and secondly that I needed to add an element to the ServerConnection class in server.py. That meant I couldn't just download the Windows binary, I'd actually have to compile my own. Unfortunately the instructions for that are rather lackluster on Windows. So I googled "pyspades", found a github for it, cloned the github into a zip, unzipped it, changed the script pretty easy and then was instantly lost so I just tried running every batch file I could find with "build" in the name. They all exited pretty much instantaneously and nothing ever happened. So after some more google searching I found this page with "instructions" on compiling the binaries for windows - https://github.com/infogulch/pyspades/w ... structions. Ok so I was missing py2exe and in the process of getting that I realized I had the wrong python version installed so I got 2.7.3 installed as well. I also picked up a missing "geolitecity.dat" and 7Zip (I usually use WinRar). Now I was finally ready to make some progress.

So I ran build_all_mingw.bat which quit immediately and then ran build.bat in the py2exe folder. That didn't do much but the note at the bottom of the webpage about 7Zip on the command line sure got me thinking so I tried running python from the command line and turns out I couldn't do it. So I enter PATH to make sure I'm gonna be adding the python path to the right variable and it displays path then I type "PATH =" and while I'm trying to think of the right way to add to the end of the path (it's been a while since I used the prompt) and I accidentally hit enter and I'm like "Oh crap did I just do that" so I scroll up a bit and prntscr that window and paste that in paint and then re-enter the path one character at a time adding python and 7zip to the end of it. So now I was ready to run the build script. Well now I got a little farther and it generated two folders named build and dist but within those folders there was no executable. I back out, add a pause at the end of the build batch file (I later did this for all the build batch files) and ran it again - this time, it paused and I saw there was an error - a missing module called zope. So I google that and find an installer for a module called zope.interface and install that and run it again and crap another missing module. This one was called Twisted and it didn't come with an installer, just a wheel file. I had no idea what to do with that but I quickly found I needed a utility called pip so I downloaded that and found out I didn't need the wheel file because I could just type the name of the module and pip would install it for me. But first I had to get a visual C++ thingie for python, so I did that and finally installed Twisted. Now I entered a cycle of installing a module, running the build file to see what the next missing module was, then installing that module, until the whole thing actually finished and spit out an executable. I eagerly run this executable and guess what it exits immediately so I run the batch file and it lets me know I'm missing the module bytes. Then I try installing that module with pip and rebuilding and still get the error so I follow the traceback to line 19 in protocol.py where it tries to import from pyspades.bytes. Well there's no way I can install the pyspades module now is there cuz it's all right here so I go back to google and it turns out lots of people on this forum have this same problem. Too bad I can't go past page one to see if it ever gets resolved but the general first step is to run build_all_mingw.bat. So I add the pause to the end of this one and guess what it returns a bunch of errors. So I start installing modules again and I get an error about gcc not being found so I go to google and avert another error by finding out that windows actually needs special unofficial gcc binaries. Well that's great I saved some time and now it actually finishes the whole script so that's good but the server still doesn't run so there's still problems. I look into it and up near the top it says I'm missing the module compressedvxl.pyo or something similar. I actually found a forum thread where someone managed to get this far and they had the same issue, but they never resolved it. After looking at the Pysnips github where they didn't include it in the build script I decided I'd just comment it out and see how far I got. I commented it out and ran it and now I was getting a gcc error up there as well - and now, finally, almost 24 hours later, I finally hit a problem I can't solve myself. So I inquire here, now that the site is back up, how do I fix the following error:
Code: Select all
./pyspades/common.cpp:6402: error: no match for 'operator!' in '!__pyx_t_6'
.pyspades/common.cpp:6402: note: candidates are: operator!(bool) <built-in>
error: command 'gcc' failed with exit status 1
(note - excerpt from the output of build_all_mingw.bat in command prompt - this isn't the whole thing, but I can't seem to redirect the whole output to a text file, so this part will have to suffice. I'm pretty sure the error is one of these errors.)

Ok so there's two error here - first of all, the "no match for operator! in !__pyx_t_6", which, according to the file itself, is automatically built by cython. Next, there's gcc failing with exit status 1. I'm not sure if the real problem is the operator, causing gcc to exit, or simply gcc on windows being hard to work with.

Or maybe someone just has a pyspades server with the local attribute added already compiled. If you could lend me a copy, that'd be great. Although I'm fine with compiling it, if that's even possible anymore.
1 post Page 1 of 1 First unread post
Return to “Servers”

Who is online

Users browsing this forum: No registered users and 13 guests