The following configuration is working for vista 64-bit, VS2008 express, nvmex, and matlab 2008b.
Visual Studio 2008 express and Windows SDK (v6.1) are installed at default locations. The SDK installs the 64-bit compilers etc. This seems to be the default on 64-bit systems.
nvmex.pl and vcvarsamd64.bat are files others have contributed.
nvmexopts_9.bat is a modified file of a contributed file.
vcvarsamd64.bat must go in:
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\amd64\vcvarsamd64.bat
or you will get the error:
nvcc fatal : Visual Studio configuration file ‘(null)’ could not be found…
The modified nvmexopts_9.bat gives paths only to the 64-bit libraries. If the 32-bit libraries are found first on the the LIB path, you will get unresolved symbol errors.
:rolleyes: I don’t know how to thank you !
I had the good nvmex.pl and nvmexopts.bat but not the vcvarsamd64.bat and had always the error : nvcc fatal : Visual Studio configuration file ‘(null)’ could not be found …
Thanks External Image
Help! I could not download those attachments from the topic. If any one could download them, could you please email them to me? Thx. I use VS 2008 Professional, MAtlab 2009a and CUDA 2.2 on Windows 7 64-bit Quadro FX 770m and Quadro FX 1700.
abdelali target arch: win64
alg.cu
tmpxft_00000d64_00000000-3_alg.cudafe1.gpu
c:\cuda\include\texture_fetch_functions.h(71): error: expected a file name
c:\cuda\include\texture_fetch_functions.h(73): error: expected a file name
c:\cuda\include\texture_fetch_functions.h(75): error: expected a file name
c:\cuda\include\texture_fetch_functions.h(77): error: expected a file name
c:\cuda\include\texture_fetch_functions.h(79): error: expected a file name
…
(a lot of errors)
…
Error limit reached.
100 errors detected in the compilation of “C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/tmpxft_00000d64_00000000-7_alg.cpp2.i”.
Compilation terminated.
C:\PROGRA~1\MATLAB\R2009B\BIN\NVMEX.PL: Error: Compile of ‘alg.cu’ failed.
??? Error using ==> nvmex at 206
Unable to complete successfully.
The paths are already only in english. Could you be more precise as to what solved your problem? Am getting the same problem and my configuration is: Win7 64bit, Matlab R2009a, VS2008
Likewise! You rock mate. Got it working on Win7 64, VS2008 9.0 Express with 64bit SDK 7.0 after a mere 4 hours (was bloody using C:\CUDA\lib instead of C:\CUDA\lib64 arrh). So far it’s slower than the PC though with the Szeta example, though the PC is pretty new.
How could I get this working if I am on a 64-bit system (Windows XP x64 Pro) but still using Matlab 2008b 32-bit? External Image
I have Cuda 2.2 and VS2008 Express.
I’ve searched everywhere and it doesn’t seem like anyone is using my setup.
(Unfortunately, I am forced to use Matlab 32-bit… Mathworks is still not able to provide a 64-bit version of the Excel add-in compiler… External Image )
nvcc fatal : Visual Studio configuration file ‘(null)’ could not be found for installation
configuration: Windows 7 64 bit, CUDA 2.3 and Visual Studio Express 2008, SDK v7.0
Proposed solution can be simplified by empty file vcvarsamd64.bat. This is also working fine.
I made a guide to help people still strugling to get it to work.
I used windows 7 64bit and Matlab r2010A 64bit and CUDA 3.1.
Guide + files are attached to this post.
Note that I did not create these files. I just took them from the original post. Please let me know if there are serious errors in this guide. MEXguide.rar (29.6 KB) MEXguide.pdf (47.5 KB)
"Can’t locate File/Temp.pm in @INC (@INC contains: C:/Program Files/MATLAB/R2007b/sys/perl/win32/lib C:/Program Files/MATLAB/R2007b/sys/perl/win32/site/lib .) at C:\Program Files\MATLAB\R2007b\bin\nvmex.pl line 126.
BEGIN failed–compilation aborted at C:\Program Files\MATLAB\R2007b\bin\nvmex.pl line 126.
??? Error using ==> nvmex at 206
Unable to complete successfully.
Error in ==> example_test_compile1 at 1
nvmex -f nvmexopts.bat example.cu -IC:\cuda\include -LC:\cuda\lib -lcudart -lcufft"
(Note that Cuda 2.2 64-bit install seems to only have a \lib directory, which I assume contains 64bit libraries)
After sniffing around, I guess the problem is related to the version of Perl installed with Matlab 2007b.
In ‘C:\Program Files\MATLAB\R2007b\sys\perl\win32\bin’ it appears I have perl5.00503.
Line 126 of nvmex.pl (where the crash seems to arise) is:
“use File::Temp qw/ tempdir/;”
To be honest, I don’t know why this fails, but there is indeed no existing file in the @INC path (see the error text above) called “Temp.pm”.
Do I just have to install a newer version of Perl in the Matlab sys directory?
I would just go ahead and try this, but the forums I found on updating Matlab’s Perl - e.g. http://community.activestate.com/forum/how-update-matlab-activeperl - make me a little hesitant, unless someone tells me this will fix the problem.
But, I had an error … anyone with a solution. thanks
example.obj : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'
C:\PROGRA~1\MATLAB\R2010A\BIN\NVMEX.PL: Error: Link of 'example.mexw64' failed.