HBadertscher / Matlab_BaslerCamDriver

A universal MATLAB driver for Basler cameras
MIT License
21 stars 5 forks source link

Another make build issue #20

Closed bigblueshoe777 closed 8 years ago

bigblueshoe777 commented 8 years ago

Using R2015a, Windows 7 64-bit.

Followed all the directions for installation of C++ compiler, BOOST, and even tried the guide provided here: https://github.com/Lansbergen/BaslerCamDriver_Installation_Tutorial_Windows_7

The build process errors out when it is almost finished creating all the functions. Command window output shows:

make => Creating Libraries Building with 'Microsoft Windows SDK 7.1 (C++)'. MEX completed successfully. Building with 'Microsoft Windows SDK 7.1 (C++)'. MEX completed successfully. => Creating Functions Building with 'Microsoft Windows SDK 7.1 (C++)'. MEX completed successfully. Building with 'Microsoft Windows SDK 7.1 (C++)'. MEX completed successfully. Building with 'Microsoft Windows SDK 7.1 (C++)'. MEX completed successfully. Building with 'Microsoft Windows SDK 7.1 (C++)'. Error using mex LINK : fatal error LNK1104: cannot open file 'libboost_filesystem-vc100-mt-1_53.lib Error in make (line 63) mex(flags{:},ipaths,lpaths,libraryObjects{:},drivers{k}) `

Not sure what to do to fix it, since I'm an amateur at all of this, but I'd really like to use my new Basler cam in MATLAB.

HBadertscher commented 8 years ago

Hi! It looks like a path issue, or maybe a problem with the Boost installation.

How did you install Boost? Did you use the pre-compiled binaries, as suggested by @Lansbergen?

Can you verify that the BOOST_ROOT environment variable is set correctly? Try getenv('BOOST_ROOT') in MATLAB and post the output here please. Please check if this folder exists on your system.

If you used the pre-compiled binaries, make sure that the BOOST_ROOT folder contains a subfolder called lib64-msvc-10.0 (or something similar, if you have a different version of Boost. If that is the case, change line 45 in make.m accordingly.) Now this subfolder should contain different .lib files, such as libboost_filesystem-vc100-mt-1_53.lib.

Please check, that these paths (1. BOOST_ROOT and 2. the subfolder) are set correctly, as they are on your computer, and that the .lib files exist?

bigblueshoe777 commented 8 years ago

I installed using pre-compiled binaries, as suggested by Lansbergen.

MATLAB output:

getenv('BOOST_ROOT') ans = C:\local\boost_1_53_0

I have lib64-msvc-11.0 subfolder in the above directory. Looks like I didn't have it matched up with the newer version number in make.m line 45. After fixing line 45 I still get the same exact error, though. Maybe if I try installing the older version of Boost?

I also might add something I passed up in my original question, but I discovered that apparently Pylon versions 4 and 5 install differently, so the make.m only works with Pylon 4 and not with Pylon 5 right now, otherwise it errors out at the very beginning because it can't find the directory.

HBadertscher commented 8 years ago

Does the folder C:\local\boost_1_53_0\lib64-msvc-11.0 contain the .lib files, especially libboost_filesystem-vc100-mt-1_53.lib? If no, does that folder contain other files?

Unfortunately I have no Pylon 5 installation, so I can't test that at the moment - very sorry about that.

bigblueshoe777 commented 8 years ago

It contains one that is very similar: libboost_filesystem-vc110-mt-1_53.lib

Apparently the filenames are all changed to have a 110 instead of a 100 because of the Boost version.

HBadertscher commented 8 years ago

Ah, now I see what the problem is: You have precompiled Boost libraries for Visual Studio 2012 (msvc-11), while you are using SDK 7.1, which is based on Visual Studio 2010 (msvc-10). Please download and install the Boost libraries for the correct version, which is boost_1_55_0-msvc-10.0-64.exe , available from sourceforge.net

bigblueshoe777 commented 8 years ago

That fixed it, thank you!

HBadertscher commented 8 years ago

Great to hear! Have fun with your Basler camera.