Skip to content
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

[pcl] Build error on x64-windows #42141

Closed
kemarve opened this issue Nov 13, 2024 · 4 comments
Closed

[pcl] Build error on x64-windows #42141

kemarve opened this issue Nov 13, 2024 · 4 comments
Assignees
Labels
requires:repro The issue is not currently repro-able

Comments

@kemarve
Copy link

kemarve commented Nov 13, 2024

When I was building PCL, I encountered the following problems(Check the attachment):
issue_body.md

It was expressed not using ";" after "#include" in microsoft link (https://learn.microsoft.com/zh-cn/cpp/error-messages/compiler-warnings/compiler-warning-level-1-c4067?view=msvc-150).

But the code is:

#if __has_cpp_attribute(unlikely)
  #define PCL_CONDITION_UNLIKELY(x) (static_cast<bool>(x)) [[unlikely]]
#elif defined(__GNUC__)
  #define PCL_CONDITION_UNLIKELY(x) (__builtin_expect(static_cast<bool>(x), 0))
#elif defined(__clang__) && (PCL_LINEAR_VERSION(__clang_major__, __clang_minor__, 0) >= PCL_LINEAR_VERSION(3, 9, 0))
  #define PCL_CONDITION_UNLIKELY(x) (__builtin_expect(static_cast<bool>(x), 0))
#else  // MSVC has no such alternative
  #define PCL_CONDITION_UNLIKELY(x) (x)
#endif

Package: pcl:[email protected]#3

Host Environment

  • Host: x64-windows
  • Compiler: MSVC 19.16.27051.0
  • vcpkg-tool version: 2024-10-18-e392d7347fe72dff56e7857f7571c22301237ae6
    vcpkg-scripts version: unknown

To Reproduce

vcpkg install PCL:x64-windows

Failure logs

-- Using cached PointCloudLibrary-pcl-pcl-1.14.1.tar.gz.
-- Cleaning sources at C:/toPath/vcpkg/buildtrees/pcl/src/pcl-1.14.1-4adff1819e.clean. Use --editable to skip cleaning for the packages you specify.
-- Extracting source C:/toPath/vcpkg/downloads/PointCloudLibrary-pcl-pcl-1.14.1.tar.gz
-- Applying patch add-gcc-version-check.patch
-- Applying patch fix-check-sse.patch
-- Applying patch fix-numeric-literals-flag.patch
-- Applying patch install-layout.patch
-- Applying patch install-examples.patch
-- Applying patch fix-clang-cl.patch
-- Applying patch gh-5985-inline.patch
-- Applying patch io_ply.patch
-- Applying patch 6053.diff
-- Applying patch 6990a3b0d7dd3c1ca04a1a473cc172a937418060.diff
-- Applying patch 0012-msvc-optimizer-workaround.patch
-- Using source at C:/toPath/vcpkg/buildtrees/pcl/src/pcl-1.14.1-4adff1819e.clean
CMake Warning (dev) at scripts/cmake/vcpkg_find_acquire_program.cmake:70 (cmake_parse_arguments):
The INTERPRETER keyword was followed by an empty string or no value at all.
Policy CMP0174 is not set, so cmake_parse_arguments() will unset the
arg_INTERPRETER variable rather than setting it to an empty string.
Call Stack (most recent call first):
scripts/cmake/vcpkg_find_acquire_program.cmake:143 (z_vcpkg_find_acquire_program_find_internal)
installed/x64-windows/share/vcpkg-cmake/vcpkg_cmake_configure.cmake:116 (vcpkg_find_acquire_program)
ports/pcl/portfile.cmake:45 (vcpkg_cmake_configure)
scripts/ports.cmake:192 (include)
This warning is for project developers. Use -Wno-dev to suppress it.

-- Configuring x64-windows
-- Building x64-windows-dbg
CMake Error at scripts/cmake/vcpkg_execute_build_process.cmake:134 (message):
Command failed: "C:/Program Files/CMake/bin/cmake.exe" --build . --config Debug --target install -- -v -j13
Working Directory: C:/toPath/vcpkg/buildtrees/pcl/x64-windows-dbg
See logs for more information:
C:\toPath\vcpkg\buildtrees\pcl\install-x64-windows-dbg-out.log

Call Stack (most recent call first):
installed/x64-windows/share/vcpkg-cmake/vcpkg_cmake_build.cmake:74 (vcpkg_execute_build_process)
installed/x64-windows/share/vcpkg-cmake/vcpkg_cmake_install.cmake:16 (vcpkg_cmake_build)
ports/pcl/portfile.cmake:80 (vcpkg_cmake_install)
scripts/ports.cmake:192 (include)

C:\toPath\vcpkg\buildtrees\pcl\install-x64-windows-dbg-out.log [109/296] C:\PROGRA~2\MICROS~2\2017\COMMUN~1\VC\Tools\MSVC\1416~1.270\bin\Hostx64\x64\cl.exe /TP -DPCLAPI_EXPORTS -D_ENABLE_EXTENDED_ALIGNED_STORAGE -IC:\toPath\vcpkg\buildtrees\pcl\x64-windows-dbg\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\common\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\geometry\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\search\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\sample_consensus\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\kdtree\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\octree\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\features\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\filters\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\ml\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\OpenMP\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\segmentation\include -IC:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\recognition\include\pcl\recognition\3rdparty -IC:\toPath\vcpkg\installed\x64-windows\include -IC:\toPath\vcpkg\installed\x64-windows\include\eigen3 /nologo /DWIN32 /D_WINDOWS /utf-8 /GR /EHsc /MP /bigobj /FS -openmp -DBOOST_ALL_DYN_LINK -DBOOST_ALL_NO_LIB /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 -std:c++14 -DBOOST_ALL_NO_LIB -D_SCL_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -DNOMINMAX -DPCL_ONLY_CORE_POINT_TYPES -D__SSE4_2__ -D__SSE4_1__ -D__SSSE3__ -D__SSE3__ -D__SSE2__ -D__SSE__ -openmp /showIncludes /Fosegmentation\CMakeFiles\pcl_segmentation.dir\src\organized_multi_plane_segmentation.cpp.obj /Fdsegmentation\CMakeFiles\pcl_segmentation.dir\ /FS -c C:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\segmentation\src\organized_multi_plane_segmentation.cpp C:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\common\include\pcl/pcl_macros.h(470): warning C4067: unexpected tokens following preprocessor directive - expected a newline ninja: build stopped: subcommand failed.
@Osyotr
Copy link
Contributor

Osyotr commented Nov 13, 2024

FAILED: segmentation/CMakeFiles/pcl_segmentation.dir/src/extract_clusters.cpp.obj 
...
C:\toPath\vcpkg\buildtrees\pcl\src\pcl-1.14.1-4adff1819e.clean\segmentation\include\pcl/segmentation/extract_labeled_clusters.h(190): error C2397: conversion from 'int' to 'unsigned int' requires a narrowing conversion

Looks like an upstream issue.

@dg0yt
Copy link
Contributor

dg0yt commented Nov 13, 2024

MSVC 19.16.27051.0

Which version of Visual Studio is that? Maybe too old?

@Cheney-W
Copy link
Contributor

MSVC 19.16.27051.0

This version is VS2017 15.9.

@Cheney-W Cheney-W added the requires:repro The issue is not currently repro-able label Nov 14, 2024
@kemarve
Copy link
Author

kemarve commented Nov 14, 2024

MSVC 19.16.27051.0

那是哪个版本的 Visual Studio?也许太老了?

you are right, i succeed in vs2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
requires:repro The issue is not currently repro-able
Projects
None yet
Development

No branches or pull requests

4 participants