PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

classic Classic list List threaded Threaded
19 messages Options
Reply | Threaded
Open this post in threaded view
|

PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
I have followed the instructions from the tutorials for building PCL 1.7.1 64bit from source on Windows 8. After generating the files with CMake, and building ALL_BUILD in MSVC10, all 178 projects compile well apart from pcl_grabcut_2d generating lnk2019 errors (see Output build attached). Please HELP!
Please contact me if more info is required.
Thanks

 Output-Build.txt
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Jochen Sprickerhof
Administrator
Hi Ouriel,

* Ouriel Barzilay <[hidden email]> [2013-11-12 04:13]:
> I have followed the instructions from the tutorials for building PCL 1.7.1
> 64bit from source on Windows 8. After generating the files with CMake, and
> building ALL_BUILD in MSVC10, all 178 projects compile well apart from
> pcl_grabcut_2d generating lnk2019 errors (see Output build attached). Please
> HELP!

pcl_grabcut_2d is not part of pcl-1.7.1, are you sure you are using the
original sources?

Cheers Jochen
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Dear Jochen,

Thanks for your prompt answer.

I followed the instructions found on newPCL’s post, http://www.pcl-users.org/PCL-from-source-can-t-build-ALL-BUILD-td4028351.html  and downloaded the pcl trunk from GIT instead of SVN using git Windows Powershell with the instruction “git clone https://github.com/PointCloudLibrary/pcl.git”. Isn’t that a reliable repository? I am currently trying it again from scratch.
As I am interested in the open source implementation of Kinfu, I checked (among others) in CMAKE: BUILD_GPU, APPS, TOOLS, and Visualization. Pcl_grabcut_2d seems to be related to BUILD_segmentation, and is one of the projects generated by CMAKE.

Unfortunately, cmake-gui has suddenly trouble identifying MSVC10 x64 compiler: the error starts with:
"
The C compiler identification is unknown
The CXX compiler identification is unknown
Performing Test HAVE_MM_MALLOC
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
  get_filename_component called with incorrect number of arguments
Call Stack (most recent call first):
  CMakeLists.txt:3 (PROJECT)
"

Best,
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Jochen Sprickerhof
Administrator
Hi Ouriel,

* Ouriel <[hidden email]> [2013-11-13 08:28]:
> I followed the instructions found on newPCL’s post,
> http://www.pcl-users.org/PCL-from-source-can-t-build-ALL-BUILD-td4028351.html 
> and downloaded the pcl trunk from GIT instead of SVN using git Windows
> Powershell with the instruction “git clone
> https://github.com/PointCloudLibrary/pcl.git”. Isn’t that a reliable
> repository? I am currently trying it again from scratch.

Ah, that's not 1.7.1 but our git master :).

> As I am interested in the open source implementation of Kinfu, I checked
> (among others) in CMAKE: BUILD_GPU, APPS, TOOLS, and Visualization.
> Pcl_grabcut_2d seems to be related to BUILD_segmentation, and is one of the
> projects generated by CMAKE.

Sound like a cmake problem, which options did you (de-)activate exactly?

> Unfortunately, cmake-gui has suddenly trouble identifying MSVC10 x64
> compiler: the error starts with:

No idea about that, sorry.

Cheers Jochen
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
This post was updated on .
Hi Jochen,

I have reconstituted the cmake BUILD options that I enabled/disabled in the picture below. After the next click on configure, I did not change the options in BUILD (gpu_kinfu enabled, etc.). Do you see anything wrong?
CMake configuration
Thanks,
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Jochen Sprickerhof
Administrator
Hi Ouriel,

* Ouriel <[hidden email]> [2013-11-15 05:02]:
> I have reconstituted the cmake BUILD options that I enabled/disabled in the
> picture below. After the next click on configure, I do not change the
> options in BUILD (gpu_kinfu enbaled, etc.). Did I do anything wrong?
> <http://www.pcl-users.org/file/n4030787/ScreenHunter_01_Nov._15_14.53.jpg>

Octree is disabled. That's odd, because it should disable a lot of other
modules (like search and so on). Can you press configure a second time?
Otherwise just enable it ;).

Cheers Jochen
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Octree was enabled, I must have misclicked when trying to reconstitute the process. I have tried again with the same options as shown above + octree enabled, and obtain the same errors relative to grabcut.
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Jochen Sprickerhof
Administrator
* Ouriel <[hidden email]> [2013-11-17 06:14]:
> Octree was enabled, I must have misclicked when trying to reconstitute the
> process. I have tried again with the same options as shown above + octree
> enabled, and obtain the same errors relative to grabcut.

No Idea than, maybe someone with more Windows knowledge has an idea, as
it's working fine on Linux.

Cheers Jochen
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
I have restarted the whole process from scratch: from github to cmake and Visual Studio 10 x64.
I first got an error related to gracbut_2d.cpp l. 448:

case 'q': case 'Q':#if defined (FREEGLUT) || defined (GLUI_OPENGLUT)
      exit ();       //  exit called with no argument ERROR.  (FREEGLUT is 1)
I changed that to exit (0);.

 After building ALL_BUILD again, i got the following error at grabcut_segmentation.hpp lines 409 and 425:
       links.dists[0] = sqrt (2);      // Ambiguous call to sqrt ERROR
... solved by changing the code to sqrt (2.0).

I build again to get the grabcut_2d.obj linker errors mentioned at the beginning of the post, such as:

Error 10 error LNK2019: unresolved external symbol "public: double __cdecl pcl::segmentation::grabcut::BoykovKolmogorov::getTargetEdgeCapacity(int)const " (?getTargetEdgeCapacity@BoykovKolmogorov@grabcut@segmentation@pcl@@QEBANH@Z) referenced in function "private: void __cdecl GrabCutHelper::buildImages(void)" (?buildImages@GrabCutHelper@@AEAAXXZ) C:\PCL_GIT2_B001\apps\grabcut_2d.obj

I suppose I shouldn't have to edit the trunk at all to get it built. Could it be those errors point at something I am missing here?
Thanks
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Jochen Sprickerhof
Administrator
Hi Ouriel,

* Ouriel <[hidden email]> [2013-11-17 10:49]:
> I suppose I shouldn't have to edit the trunk at all to get it built. Could
> it be those errors point at something I am missing here?

Most of our developers use Linux, so it could very well be that there is
a problem when using Visual Studio. Could you open a pull request on
Github with you changes?

Thanks!

Jochen
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

nizar sallem
In reply to this post by Ouriel
Hi,

Could you please open an issue on the github and give me the chance to
review this aand I will get back to you ASAP, seems to be an error on my
side.

Cheers,
--
Nizar

On 17/11/2013 19:49, Ouriel wrote:

> I have restarted the whole process from scratch: from github to cmake and
> Visual Studio 10 x64.
> I first got an error related to gracbut_2d.cpp l. 448:
>
> case 'q': case 'Q':#if defined (FREEGLUT) || defined (GLUI_OPENGLUT)
>        *exit ();*       //  /exit called with no argument ERROR.  (FREEGLUT
> is 1)/
> I changed that to *exit (0);*.
>
>   After building ALL_BUILD again, i got the following error at
> grabcut_segmentation.hpp lines 409 and 425:
>         links.dists[0] = *sqrt (2)*;      // /Ambiguous call to sqrt ERROR/
> ... solved by changing the code to *sqrt (2.0)*.
>
> I build again to get the grabcut_2d.obj linker errors mentioned at the
> beginning of the post, such as:
>
> Error 10 error LNK2019: unresolved external symbol "public: double __cdecl
> pcl::segmentation::grabcut::BoykovKolmogorov::getTargetEdgeCapacity(int)const
> "
> (?getTargetEdgeCapacity@BoykovKolmogorov@grabcut@segmentation@pcl@@QEBANH@Z)
> referenced in function "private: void __cdecl
> GrabCutHelper::buildImages(void)" (?buildImages@GrabCutHelper@@AEAAXXZ)
> C:\PCL_GIT2_B001\apps\grabcut_2d.obj
>
> I suppose I shouldn't have to edit the trunk at all to get it built. Could
> it be those errors point at something I am missing here?
> Thanks
>
>
>
> --
> View this message in context: http://www.pcl-users.org/PCL-1-7-1-install-on-Windows-8-64bit-grabcut-linker-error-tp4030721p4030810.html
> Sent from the Point Cloud Library (PCL) Users mailing list mailing list archive at Nabble.com.
> _______________________________________________
> [hidden email] / http://pointclouds.org
> http://pointclouds.org/mailman/listinfo/pcl-users
>
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

nizar sallem
In reply to this post by Jochen Sprickerhof
Hi,

Fixed the eroor on exit, I inverted conditions, sorry about that, doing
the PR right now.

Cheers,
--
Nizar

On 17/11/2013 21:23, Jochen Sprickerhof wrote:

> Hi Ouriel,
>
> * Ouriel <[hidden email]> [2013-11-17 10:49]:
>> I suppose I shouldn't have to edit the trunk at all to get it built. Could
>> it be those errors point at something I am missing here?
>
> Most of our developers use Linux, so it could very well be that there is
> a problem when using Visual Studio. Could you open a pull request on
> Github with you changes?
>
> Thanks!
>
> Jochen
> _______________________________________________
> [hidden email] / http://pointclouds.org
> http://pointclouds.org/mailman/listinfo/pcl-users
>
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

nizar sallem
In reply to this post by Ouriel
Hi Ouriel,

I tried to fix errors on gihub so would you please pull last revision
and check it out ?

Thanks,
--
Nizar

On 17/11/2013 19:49, Ouriel wrote:

> I have restarted the whole process from scratch: from github to cmake and
> Visual Studio 10 x64.
> I first got an error related to gracbut_2d.cpp l. 448:
>
> case 'q': case 'Q':#if defined (FREEGLUT) || defined (GLUI_OPENGLUT)
>        *exit ();*       //  /exit called with no argument ERROR.  (FREEGLUT
> is 1)/
> I changed that to *exit (0);*.
>
>   After building ALL_BUILD again, i got the following error at
> grabcut_segmentation.hpp lines 409 and 425:
>         links.dists[0] = *sqrt (2)*;      // /Ambiguous call to sqrt ERROR/
> ... solved by changing the code to *sqrt (2.0)*.
>
> I build again to get the grabcut_2d.obj linker errors mentioned at the
> beginning of the post, such as:
>
> Error 10 error LNK2019: unresolved external symbol "public: double __cdecl
> pcl::segmentation::grabcut::BoykovKolmogorov::getTargetEdgeCapacity(int)const
> "
> (?getTargetEdgeCapacity@BoykovKolmogorov@grabcut@segmentation@pcl@@QEBANH@Z)
> referenced in function "private: void __cdecl
> GrabCutHelper::buildImages(void)" (?buildImages@GrabCutHelper@@AEAAXXZ)
> C:\PCL_GIT2_B001\apps\grabcut_2d.obj
>
> I suppose I shouldn't have to edit the trunk at all to get it built. Could
> it be those errors point at something I am missing here?
> Thanks
>
>
>
> --
> View this message in context: http://www.pcl-users.org/PCL-1-7-1-install-on-Windows-8-64bit-grabcut-linker-error-tp4030721p4030810.html
> Sent from the Point Cloud Library (PCL) Users mailing list mailing list archive at Nabble.com.
> _______________________________________________
> [hidden email] / http://pointclouds.org
> http://pointclouds.org/mailman/listinfo/pcl-users
>
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Hi Nizar,

I got the trunk revision from git (git clone https://github.com/PointCloudLibrary/pcl pcl-trunk).
Suddenly Cmake has trouble finding Boost libraries. The figure below shows the differences in cmake for the trunk versions downloaded a few days ago (left) and today (right). First, only boost debug libs are missing, but cmake produces no error.




After manually setting the paths to boost files and configuring again, cmake configuration fails.





I also tried with the git master (git clone https://github.com/PointCloudLibrary/pcl). There is no problem there with cmake, but it fails to compile, starting with the following error.
>...\pcl\io\include\pcl/io/png_io.h(147): error C2375: 'pcl::io::savePNGFile' : redefinition; different linkage
>          C:\PCL_GIT4\pcl\io\include\pcl/io/png_io.h(145) : see declaration of 'pcl::io::savePNGFile'

Thanks,
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

nizar sallem
The second url you tried is the correct one.

I think those errors are no more related to PCL but rather to a mixed
versions (probably 32_64 and 64 builds) may be some windows developers
can give more hints ? I am only guessing here sorry :(

Cheers,
--
Nizar


On 18/11/2013 19:33, Ouriel wrote:

> Hi Nizar,
>
> I got the trunk revision from git (git clone
> https://github.com/PointCloudLibrary/pcl pcl-trunk).
> Suddenly Cmake has trouble finding Boost libraries. The figure below shows
> the differences in cmake for the trunk versions downloaded a few days ago
> (left) and today (right). First, only boost debug libs are missing, but
> cmake produces no error.
>
> <http://www.pcl-users.org/file/n4030824/Cmake_config_PCL_TRUNK.jpg>
>
>
> After manually setting the paths to boost files and configuring again, cmake
> configuration fails.
>
> <http://www.pcl-users.org/file/n4030824/Cmake_config_PCL_TRUNK2.jpg>
>
>
>
> I also tried with the git master (git clone
> https://github.com/PointCloudLibrary/pcl). There is no problem there with
> cmake, but it fails to compile, starting with the following error.
>> ...\pcl\io\include\pcl/io/png_io.h(147): error C2375:
> 'pcl::io::savePNGFile' : redefinition; different linkage
>>           C:\PCL_GIT4\pcl\io\include\pcl/io/png_io.h(145) : see declaration
>> of 'pcl::io::savePNGFile'
>
> Thanks,
> Ouriel
>
>
>
>
> --
> View this message in context: http://www.pcl-users.org/PCL-1-7-1-install-on-Windows-8-64bit-grabcut-linker-error-tp4030721p4030824.html
> Sent from the Point Cloud Library (PCL) Users mailing list mailing list archive at Nabble.com.
> _______________________________________________
> [hidden email] / http://pointclouds.org
> http://pointclouds.org/mailman/listinfo/pcl-users
>
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Hi Nizar,
That's weird, I have been quite meticulous with the 64 bit install. The error is solved when I comment one of those two commands in png_io.h (lines 142 - 147):

   PCL_DEPRECATED (void savePNGFile (const std::string& file_name, const pcl::PointCloud<pcl::PointXYZL>& cloud),
    "pcl::io::savePNGFile (file_name, cloud) is deprecated, please use a new generic function "
    "pcl::io::savePNGFile (file_name, cloud, field_name) with \"label\" as the field name."
    );

    PCL_EXPORTS void
    savePNGFile (const std::string& file_name, const pcl::PointCloud<pcl::PointXYZL>& cloud);


... but only to get back to the grabcut linker errors.

In any case, I'd like to thank you and Jochen for your very much appreciated time and support.
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Just to make sure before formatting Windows again: I wish to get access to the TSDF values and weights in real time. That is why I tried to build the trunk from binaries. Is there any shortcut I could take for that purpose, like using the all-in-one installer or such?
Thanks,
Ouriel
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

nizar sallem
Well you can put the apps to OFF and build PCL without apps.
This should take care of you link issues (still I don't get them cause
now it souldn't complain anymore of symbols not being exported).

Cheers,
--
Nizar

On 19/11/2013 14:35, Ouriel wrote:

> Just to make sure before formatting Windows again: I wish to get access to
> the TSDF values and weights in real time. That is why I tried to build the
> trunk from binaries. Is there any shortcut I could take for that purpose,
> like using the all-in-one installer or such?
> Thanks,
> Ouriel
>
>
>
> --
> View this message in context: http://www.pcl-users.org/PCL-1-7-1-install-on-Windows-8-64bit-grabcut-linker-error-tp4030721p4030844.html
> Sent from the Point Cloud Library (PCL) Users mailing list mailing list archive at Nabble.com.
> _______________________________________________
> [hidden email] / http://pointclouds.org
> http://pointclouds.org/mailman/listinfo/pcl-users
>
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: PCL 1.7.1 install on Windows 8 64bit - grabcut linker error

Ouriel
Hi Nizar,
Disabling the option Build_apps made the compilation work! :)
Many thanks,
Ouriel