-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error: unable to find vcvarsall.bat #9
Comments
vcvarsall.bat is the script that Microsoft placed in the root of your Visual C++ compiler toolset. What version of Microsoft Visual Studio are you using? |
Ah, I didn't realise I needed to have that installed. I'll try that and will get back to you if it still fails. |
I just ran into this as well. I have MSVS 12 and found vcvarsall.bat. I'm assuming I need to add that to the path? Edit: Adding the VC directory of MSVS12 did nothing, just as copying the file to my pyfly2 directory did nothing. I'm working with Win 7 x64, python 2.7 x64 and FlyCapture_2.9.3.11_x64 |
I think maybe Cython tries to find the MSVC in all the places it thinks it might be installed. What if you executed vcvarsall.bat yourself from the same CMD prompt you are trying to build pyfly from? Perhaps that would make it easier for Cython to do whatever it is trying to do. |
I did that - it runs just fine. I keep getting the error though. So this is a Cython problem? |
It's either a Cython problem or a "kbrafford doesn't know how to set up Cython properly" problem :-/ Normally I'd do a deeper dive right now, but I am pushed for time until mid week. I'll try to look at it closer by then. |
Cool thanks. I'll update with anything I find. |
Yep, just installed all free versions of MSVS and still the same error. Thanks! |
Ok I got it all working (except registering pyfly2 for import anywhere in python...do I need to copy something to site-packages???). To start I already had MSVS 8, 10,11, and 12 installed, but Cython wasn't happy, so I followed the instructions pointed to in Becky's comment here: Windows: Unable to find vcvarsall.bat (cython, other c extensions) In recap, it ended up making me install MSVS 9.0, and then I had to copy vcvarsall.bat into the VC directory of 9.0 since it didn't have it (and modify it to set the correct version number) from one of the other versions. I then had to make sure the bat file which vcvarsall wanted was in the place it was looking and named properly. After that it compiles great. So now how do I get it to import from anywhere? |
I am pretty sure I add the path of the development directory to a file called |
Here's how I set it up. In my C:\Python27 directory I have a file called C:\Users\kbrafford\Documents\GitHub\pyfly2 Those are the paths on my development machine where I have the repos for pyfly1 and pyfly2 checked out. I'm not sure why pyfly1 is different than pyfly2, but that's how I use it. |
This just solved it for me!
|
Thanks, nortonsm! Is it ok if I add your approach to the docs? |
I've tried the above solution from nortonsm, which didn't do anything for me, as I already had the package installed (although I did overwrite, just in case), and I set the environment variables and still the same issue. I modified it for the 32-bit version first, which didn't help, then the 64-bit, which also didn't work. |
@fonty422 : So if you launch a CMD window from the Start program menu:
So it fails until I issue the two SET commands above. |
Sure. I hadn't realised I needed to set those specifically while in the correct folder. That has cleared the inability to find
|
It looks like you are trying to build a 64-bit version, but pyfly2 is a 32-bit library. |
Ah, that makes sense. Following this, I tried another package and had success with pyflycapture2 and it works well. I just had to make a few changes to the wrapper to account for full color images. |
After working around the stupid issues with python and Anaconda with respect to path issues, i managed to get somewhere with the install. But it now fails with the error message:
error: unable to find vcvarsall.bat
Any suggestions?
The text was updated successfully, but these errors were encountered: