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] Add feature and fix find libusb, fix pkgconfig #21276

Merged
merged 12 commits into from
Nov 22, 2021

Conversation

JackBoosY
Copy link
Contributor

This PR will fix 2 issues:

  1. Export pcl component pcl-cuda-common pkgconfig (upstream PR [pcl_cuda_common] Export the pkgconfig file PointCloudLibrary/pcl#5026).
  2. Add feature libusb and fix the condition of finding libusb (upstream PR [pcl_io] Set libusb as a required dependency of openni in non-Windows PointCloudLibrary/pcl#5028).

Fixes #21223 #21241

@JackBoosY JackBoosY added category:port-bug The issue is with a library, which is something the port should already support info:internal This PR or Issue was filed by the vcpkg team. depends:upstream-changes Waiting on a change to the upstream project labels Nov 9, 2021
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new experimental fast check for PR issues. Please let us know if this bot is helpful!

After committing all other changes, the version database must be updated
git add -u && git commit
git checkout 4df8c6d7f0468264576f1d17401277b3d401b27f -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/baseline.json b/versions/baseline.json
index a9e2bc1..479240e 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -5118,7 +5118,7 @@
     },
     "pcl": {
       "baseline": "1.12.0",
-      "port-version": 0
+      "port-version": 1
     },
     "pcre": {
       "baseline": "8.45",
diff --git a/versions/p-/pcl.json b/versions/p-/pcl.json
index bd9ea8b..8b40f86 100644
--- a/versions/p-/pcl.json
+++ b/versions/p-/pcl.json
@@ -1,5 +1,10 @@
 {
   "versions": [
+    {
+      "git-tree": "20853dcf1ac094103f8d6ec2d8d7c3011da42713",
+      "version": "1.12.0",
+      "port-version": 1
+    },
     {
       "git-tree": "6a65773e049bbdfef835781a6a61ee6a3a94dd27",
       "version": "1.12.0",

@JackBoosY JackBoosY linked an issue Nov 9, 2021 that may be closed by this pull request
@JackBoosY
Copy link
Contributor Author

@AlexLeungZ @weibingrong @raahilsha-z @LOVELESSYI Can you please test this PR?

Thanks.

@AlexLeungZ
Copy link

What about this bug?
#21241 (comment)

@JackBoosY
Copy link
Contributor Author

What about this bug? #21241 (comment)

I can't reproduce this, can you provide the repro step?

@AlexLeungZ
Copy link

What about this bug? #21241 (comment)

I can't reproduce this, can you provide the repro step?

Just the same as #21241, maybe it is some bugs on my side, I am not sure

@JackBoosY
Copy link
Contributor Author

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

@AlexLeungZ
Copy link

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

I rebuild the whole thing with this fix #21241 (comment) , so they are all gone.

@JackBoosY
Copy link
Contributor Author

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

I rebuild the whole thing with this fix #21241 (comment) , so they are all gone.

Yeah I know that, but I need to know which file you deleted in that folder first, It may be unreasonable.

@AlexLeungZ
Copy link

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

I rebuild the whole thing with this fix #21241 (comment) , so they are all gone.

Yeah I know that, but I need to know which file you deleted in that folder first, It may be unreasonable.

There is no /bin in /pcl_x64-linux right now, I just can't provide the list

@AlexLeungZ
Copy link

@AlexLeungZ @weibingrong @raahilsha-z @LOVELESSYI Can you please test this PR?

Thanks.

It fails to build on my x64-linux wsl machine

{
    "name": "robocon-lidar-pcl",
    "version": "1.2",
    "description": "LiDar dev with pcl, cuda and vtk for robocon.",
    "dependencies": [
        "libusb",
        "cuda",
        "vtk",
        {
            "name": "pcl",
            "features": [ "cuda", "vtk" ]
        }
    ]
}
[cmake] -- Configuring x64-linux-dbg
[cmake] CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:127 (message):
[cmake]     Command failed: /home/alex/.local/lib/pypy3.6/site-packages/cmake/data/bin/cmake /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/src/89d532cf08-93412c82b5.clean -DBUILD_surface_on_nurbs=ON -DPCL_BUILD_WITH_BOOST_DYNAMIC_LINKING_WIN32=0 -DPCL_BUILD_WITH_FLANN_DYNAMIC_LINKING_WIN32=0 -DPCL_BUILD_WITH_QHULL_DYNAMIC_LINKING_WIN32=0 -DPCL_SHARED_LIBS=0 -DWITH_PNG=ON -DWITH_QHULL=ON -DWITH_OPENNI2=OFF -DWITH_QT=OFF -DWITH_PCAP=OFF -DWITH_CUDA=ON -DBUILD_CUDA=ON -DBUILD_GPU=ON -DBUILD_tools=OFF -DWITH_OPENGL=OFF -DWITH_VTK=ON -DWITH_LIBUSB=OFF -DCMAKE_MAKE_PROGRAM=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/downloads/tools/ninja-1.10.2-linux/ninja -DCMAKE_SYSTEM_NAME=Linux -DBUILD_SHARED_LIBS=OFF -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/toolchains/linux.cmake -DVCPKG_TARGET_TRIPLET=x64-linux -DVCPKG_SET_CHARSET_FLAG=ON -DVCPKG_PLATFORM_TOOLSET=external -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON -DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE -DCMAKE_VERBOSE_MAKEFILE=ON -DVCPKG_APPLOCAL_DEPS=OFF -DCMAKE_TOOLCHAIN_FILE=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake -DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON -DVCPKG_CXX_FLAGS= -DVCPKG_CXX_FLAGS_RELEASE= -DVCPKG_CXX_FLAGS_DEBUG= -DVCPKG_C_FLAGS= -DVCPKG_C_FLAGS_RELEASE= -DVCPKG_C_FLAGS_DEBUG= -DVCPKG_CRT_LINKAGE=dynamic -DVCPKG_LINKER_FLAGS= -DVCPKG_LINKER_FLAGS_RELEASE= -DVCPKG_LINKER_FLAGS_DEBUG= -DVCPKG_TARGET_ARCHITECTURE=x64 -DCMAKE_INSTALL_LIBDIR:STRING=lib -DCMAKE_INSTALL_BINDIR:STRING=bin -D_VCPKG_ROOT_DIR=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg -D_VCPKG_INSTALLED_DIR=/mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg_installed -DVCPKG_MANIFEST_INSTALL=OFF -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/packages/pcl_x64-linux/debug
[cmake]     Working Directory: /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/x64-linux-dbg
[cmake]     Error code: 1
[cmake]     See logs for more information:
[cmake]       /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-out.log
[cmake]       /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-err.log
[cmake] 
[cmake] Call Stack (most recent call first):
[cmake]   /mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg_installed/x64-linux/share/vcpkg-cmake/vcpkg_cmake_configure.cmake:423 (vcpkg_execute_required_process)
[cmake]   ports/pcl/portfile.cmake:47 (vcpkg_cmake_configure)
[cmake]   scripts/ports.cmake:142 (include)
[cmake] 
[cmake] 
[cmake] Error: Building package pcl:x64-linux failed with: BUILD_FAILED
[cmake] Please ensure you're using the latest portfiles with `git pull` and `./vcpkg update`, then
[cmake] submit an issue at https://github.com/Microsoft/vcpkg/issues including:
[cmake]   package: pcl[core,cuda,vtk]:x64-linux -> 1.12.0#1
[cmake]   vcpkg version: 2021-11-02-af04ebf6274fd6f7a941bff4662b3955c64f6f42
[cmake]   vcpkg-tool version: b5a1ba275 2021-11-09 (5 hours ago)
[cmake] 
[cmake] Additionally, attach any relevant sections from the log files above.
[cmake] -- Running vcpkg install - failed
[cmake] CMake Error at vcpkg/scripts/buildsystems/vcpkg.cmake:831 (message):
[cmake]   vcpkg install failed.  See logs for more information:
[cmake]   /mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg-manifest-install.log
[cmake] Call Stack (most recent call first):
[cmake]   build/CMakeFiles/3.21.2/CMakeSystem.cmake:6 (include)
[cmake]   CMakeLists.txt:2 (project)
[cmake] 
[cmake] 
[cmake] -- Configuring incomplete, errors occurred!
[cmake] See also "/mnt/d/Git/GitHub/vcpkg-playground/build/CMakeFiles/CMakeOutput.log".
[cmake] See also "/mnt/d/Git/GitHub/vcpkg-playground/build/CMakeFiles/CMakeError.log".

/mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg-manifest-install.log
vcpkg-manifest-install.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-out.log
config-x64-linux-dbg-out.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-err.log
config-x64-linux-dbg-err.log

@LOVELESSYI
Copy link

@AlexLeungZ @weibingrong @raahilsha-z @LOVELESSYI Can you please test this PR?

Thanks.

It works for me! Thank you very much!

@jasjuang
Copy link
Contributor

@JackBoosY do you mind fixing PointCloudLibrary/pcl#4422 as well?

The problem is that target pcl_io_ply is linked to pcl_io in build phase https://github.com/PointCloudLibrary/pcl/blob/pcl-1.12.0/io/CMakeLists.txt#L341, but during install phase, pcl_io is missing an INTERFACE_LINK_LIBRARIES to pcl_io_ply in their custom PCLConfig.cmake (I still don't understand why PCL didn't use install to let cmake auto generate something like PCLTargets.cmake to guarantee consistency dependencies between build and install phase).

A quick and dirty fix I did was removing the pcl_io_ply target and merge the sources and headers that were in pcl_io_ply directly into pcl_io during add_library and that kinda worked for my situation. If you could figure out a proper patch that links pcl_io_ply to pcl_io in PCLConfig.cmake that would be amazing.

@JackBoosY
Copy link
Contributor Author

JackBoosY commented Nov 10, 2021

@AlexLeungZ @weibingrong @raahilsha-z @LOVELESSYI Can you please test this PR?
Thanks.

It fails to build on my x64-linux wsl machine

{
    "name": "robocon-lidar-pcl",
    "version": "1.2",
    "description": "LiDar dev with pcl, cuda and vtk for robocon.",
    "dependencies": [
        "libusb",
        "cuda",
        "vtk",
        {
            "name": "pcl",
            "features": [ "cuda", "vtk" ]
        }
    ]
}
[cmake] -- Configuring x64-linux-dbg
[cmake] CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:127 (message):
[cmake]     Command failed: /home/alex/.local/lib/pypy3.6/site-packages/cmake/data/bin/cmake /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/src/89d532cf08-93412c82b5.clean -DBUILD_surface_on_nurbs=ON -DPCL_BUILD_WITH_BOOST_DYNAMIC_LINKING_WIN32=0 -DPCL_BUILD_WITH_FLANN_DYNAMIC_LINKING_WIN32=0 -DPCL_BUILD_WITH_QHULL_DYNAMIC_LINKING_WIN32=0 -DPCL_SHARED_LIBS=0 -DWITH_PNG=ON -DWITH_QHULL=ON -DWITH_OPENNI2=OFF -DWITH_QT=OFF -DWITH_PCAP=OFF -DWITH_CUDA=ON -DBUILD_CUDA=ON -DBUILD_GPU=ON -DBUILD_tools=OFF -DWITH_OPENGL=OFF -DWITH_VTK=ON -DWITH_LIBUSB=OFF -DCMAKE_MAKE_PROGRAM=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/downloads/tools/ninja-1.10.2-linux/ninja -DCMAKE_SYSTEM_NAME=Linux -DBUILD_SHARED_LIBS=OFF -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/toolchains/linux.cmake -DVCPKG_TARGET_TRIPLET=x64-linux -DVCPKG_SET_CHARSET_FLAG=ON -DVCPKG_PLATFORM_TOOLSET=external -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON -DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE -DCMAKE_VERBOSE_MAKEFILE=ON -DVCPKG_APPLOCAL_DEPS=OFF -DCMAKE_TOOLCHAIN_FILE=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake -DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON -DVCPKG_CXX_FLAGS= -DVCPKG_CXX_FLAGS_RELEASE= -DVCPKG_CXX_FLAGS_DEBUG= -DVCPKG_C_FLAGS= -DVCPKG_C_FLAGS_RELEASE= -DVCPKG_C_FLAGS_DEBUG= -DVCPKG_CRT_LINKAGE=dynamic -DVCPKG_LINKER_FLAGS= -DVCPKG_LINKER_FLAGS_RELEASE= -DVCPKG_LINKER_FLAGS_DEBUG= -DVCPKG_TARGET_ARCHITECTURE=x64 -DCMAKE_INSTALL_LIBDIR:STRING=lib -DCMAKE_INSTALL_BINDIR:STRING=bin -D_VCPKG_ROOT_DIR=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg -D_VCPKG_INSTALLED_DIR=/mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg_installed -DVCPKG_MANIFEST_INSTALL=OFF -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/packages/pcl_x64-linux/debug
[cmake]     Working Directory: /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/x64-linux-dbg
[cmake]     Error code: 1
[cmake]     See logs for more information:
[cmake]       /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-out.log
[cmake]       /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-err.log
[cmake] 
[cmake] Call Stack (most recent call first):
[cmake]   /mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg_installed/x64-linux/share/vcpkg-cmake/vcpkg_cmake_configure.cmake:423 (vcpkg_execute_required_process)
[cmake]   ports/pcl/portfile.cmake:47 (vcpkg_cmake_configure)
[cmake]   scripts/ports.cmake:142 (include)
[cmake] 
[cmake] 
[cmake] Error: Building package pcl:x64-linux failed with: BUILD_FAILED
[cmake] Please ensure you're using the latest portfiles with `git pull` and `./vcpkg update`, then
[cmake] submit an issue at https://github.com/Microsoft/vcpkg/issues including:
[cmake]   package: pcl[core,cuda,vtk]:x64-linux -> 1.12.0#1
[cmake]   vcpkg version: 2021-11-02-af04ebf6274fd6f7a941bff4662b3955c64f6f42
[cmake]   vcpkg-tool version: b5a1ba275 2021-11-09 (5 hours ago)
[cmake] 
[cmake] Additionally, attach any relevant sections from the log files above.
[cmake] -- Running vcpkg install - failed
[cmake] CMake Error at vcpkg/scripts/buildsystems/vcpkg.cmake:831 (message):
[cmake]   vcpkg install failed.  See logs for more information:
[cmake]   /mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg-manifest-install.log
[cmake] Call Stack (most recent call first):
[cmake]   build/CMakeFiles/3.21.2/CMakeSystem.cmake:6 (include)
[cmake]   CMakeLists.txt:2 (project)
[cmake] 
[cmake] 
[cmake] -- Configuring incomplete, errors occurred!
[cmake] See also "/mnt/d/Git/GitHub/vcpkg-playground/build/CMakeFiles/CMakeOutput.log".
[cmake] See also "/mnt/d/Git/GitHub/vcpkg-playground/build/CMakeFiles/CMakeError.log".

/mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg-manifest-install.log vcpkg-manifest-install.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-out.log config-x64-linux-dbg-out.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-err.log config-x64-linux-dbg-err.log

OpenNI2 doesn't export its pkgconfig file, which caused this issue.
Will re-make libusb patch.

@JackBoosY
Copy link
Contributor Author

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

I rebuild the whole thing with this fix #21241 (comment) , so they are all gone.

Yeah I know that, but I need to know which file you deleted in that folder first, It may be unreasonable.

There is no /bin in /pcl_x64-linux right now, I just can't provide the list

Can you please revert your custom changes, rebuild pcl and provide the file list?

@AlexLeungZ
Copy link

AlexLeungZ commented Nov 10, 2021

@AlexLeungZ Can you provide the file list in /mnt/d/Git/GitHub/robocon-test-code/vcpkg/packages/pcl_x64-linux/bin?

I rebuild the whole thing with this fix #21241 (comment) , so they are all gone.

Yeah I know that, but I need to know which file you deleted in that folder first, It may be unreasonable.

There is no /bin in /pcl_x64-linux right now, I just can't provide the list

Can you please revert your custom changes, rebuild pcl and provide the file list?

The /bin error seems to be gone, but the libusb error is still there.
It was built from arm64-linux and x64-linux , clean build with clean vcpkg (from this PR with git pull).
No modified packages was used expect for vtk[core], as it still wasn't been fixed yet. FYI: #21195

arm64-linux

vcpkg.json

{
    "name": "vcpkg",
    "version": "1.0",
    "dependencies": [
        "vtk",
        {
            "name": "pcl",
            "features": [ "vtk" ]
        }
    ]
}

/media/robocon/nvme/vcpkg-playground/build/vcpkg-manifest-install.log
vcpkg-manifest-install.log

/media/robocon/nvme/vcpkg-playground/vcpkg/buildtrees/pcl/config-arm64-linux-dbg-out.log
config-arm64-linux-dbg-out.log

/media/robocon/nvme/vcpkg-playground/vcpkg/buildtrees/pcl/config-arm64-linux-dbg-err.log
config-arm64-linux-dbg-out.log

config-arm64-linux-dbg-err.log

CMake Error at /media/robocon/nvme/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake:788 (_find_package):
  Could not find a package configuration file provided by "libusb" with any
  of the following names:

    libusbConfig.cmake
    libusb-config.cmake

  Add the installation prefix of "libusb" to CMAKE_PREFIX_PATH or set
  "libusb_DIR" to a directory containing one of the above files.  If "libusb"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  cmake/Modules/FindOpenNI.cmake:55 (find_package)
  /media/robocon/nvme/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake:788 (_find_package)
  cmake/pcl_targets.cmake:878 (find_package)
  CMakeLists.txt:325 (PCL_ADD_GRABBER_DEPENDENCY)

x64-linux

vcpkg.json

{
    "name": "vcpkg",
    "version": "1.0",
    "dependencies": [
        "cuda",
        "vtk",
        {
            "name": "pcl",
            "features": [ "cuda", "vtk" ]
        }
    ]
}

/mnt/d/Git/GitHub/vcpkg-playground/build/vcpkg-manifest-install.log
vcpkg-manifest-install.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-out.log
config-x64-linux-dbg-out.log

/mnt/d/Git/GitHub/vcpkg-playground/vcpkg/buildtrees/pcl/config-x64-linux-dbg-err.log
config-x64-linux-dbg-err.log

config-x64-linux-dbg-err.log

CMake Error at /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake:788 (_find_package):
  Could not find a package configuration file provided by "libusb" with any
  of the following names:

    libusbConfig.cmake
    libusb-config.cmake

  Add the installation prefix of "libusb" to CMAKE_PREFIX_PATH or set
  "libusb_DIR" to a directory containing one of the above files.  If "libusb"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  cmake/Modules/FindOpenNI.cmake:55 (find_package)
  /mnt/d/Git/GitHub/vcpkg-playground/vcpkg/scripts/buildsystems/vcpkg.cmake:788 (_find_package)
  cmake/pcl_targets.cmake:878 (find_package)
  CMakeLists.txt:325 (PCL_ADD_GRABBER_DEPENDENCY)

@JackBoosY
Copy link
Contributor Author

@AlexLeungZ Can you please make sure your vcpkg is latest? There should have a file vcpkg-cmake-wrapper.cmake in installed/x64-linux/share/libusb, please check first.

@JackBoosY
Copy link
Contributor Author

Will update fix-pkgconfig.patch using the change which the upstream approved.

@JackBoosY JackBoosY removed the depends:upstream-changes Waiting on a change to the upstream project label Nov 16, 2021
@JackBoosY
Copy link
Contributor Author

The upstream approved all the 2 PRs.

Copy link
Contributor

@PhoebeHui PhoebeHui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the PR!

@PhoebeHui PhoebeHui added the info:reviewed Pull Request changes follow basic guidelines label Nov 17, 2021
@AlexLeungZ
Copy link

AlexLeungZ commented Nov 18, 2021

Is it normal that arm device can not install pcl[openni2] as it is has dependencies on kinectsdk1 which is not supported for arm??

{
  "name": "openni2",
  "version-string": "2.2.0.33",
  "port-version": 13,
  "description": "OpenNI is open source library for access to Natural Interaction (NI) devices such as RGB-D camera.",
  "homepage": "https://github.com/OpenNI/OpenNI2",
  "supports": "!uwp",
  "dependencies": [
    "kinectsdk1"
  ]
}
{
  "name": "kinectsdk1",
  "version-string": "1.8",
  "port-version": 3,
  "description": "Kinect for Windows SDK for Kinect v1 sensor.",
  "supports": "!arm"
}

@dg0yt
Copy link
Contributor

dg0yt commented Nov 18, 2021

Is it normal that arm device can not install pcl[openni2] as it is has dependencies on kinectsdk1 which is not supported for arm??

{
  "name": "openni2",
  "version-string": "2.2.0.33",
  "port-version": 13,
  "description": "OpenNI is open source library for access to Natural Interaction (NI) devices such as RGB-D camera.",
  "homepage": "https://github.com/OpenNI/OpenNI2",
  "supports": "!uwp",
  "dependencies": [
    "kinectsdk1"
  ]
}
{
  "name": "kinectsdk1",
  "version-string": "1.8",
  "port-version": 3,
  "description": "Kinect for Windows SDK for Kinect v1 sensor.",
  "supports": "!arm"
}

Hm, changing supports in ports which are dependencies has side effects on the buildability of depending ports. This is entirely unnoticed by CI because of the unsupported state being silently cascaded instead of requiring an action (adding supports to the depending port or adding platform to the dependency).

@AlexLeungZ

This comment has been minimized.

@JackBoosY JackBoosY removed the info:reviewed Pull Request changes follow basic guidelines label Nov 19, 2021
@AlexLeungZ
Copy link

AlexLeungZ commented Nov 19, 2021

Base on openni2/vcpkg.json and openni2/portfile.cmake, I think it is a windows-only feature
Seems like right now, there is no way to install openni2 on linux from vcpkg, so pcl[openni2] will not build.

@AlexLeungZ

This comment has been minimized.

@JackBoosY
Copy link
Contributor Author

JackBoosY commented Nov 22, 2021

@AlexLeungZ

  1. The VTK issue seems have a upstream issue here: https://discourse.vtk.org/t/vtk-9-0-rc1/2916.

  2. And the opennni issue is in the openni2 side: port openni2 should be refactory, it's only support Windows now.
    The official doc is https://github.com/occipital/openni2.

@JackBoosY JackBoosY added the info:reviewed Pull Request changes follow basic guidelines label Nov 22, 2021
@AlexLeungZ

This comment has been minimized.

@JackBoosY
Copy link
Contributor Author

@AlexLeungZ I think this is not related to my changes.
Please open a new issue to report that and we will fix that in other PRs.

@BillyONeal BillyONeal merged commit ff5233a into microsoft:master Nov 22, 2021
@BillyONeal
Copy link
Member

Thanks for the fixes @JackBoosY and thanks for the testing @AlexLeungZ :D

@JackBoosY JackBoosY deleted the dev/jack/21223-21241 branch November 23, 2021 02:05
@JackBoosY JackBoosY mentioned this pull request Nov 23, 2021
@mvieth
Copy link
Contributor

mvieth commented Apr 2, 2024

@JackBoosY Hi, I was wondering if you remember why you added -DWITH_OPENMP=OFF in this PR (more specifically, in the "Disable more options" commit)? I went through the PR and the linked issues, but could not find any reason why the multiprocessing library might have caused any problems, and on which triplets?
If there is no reason why it must be disabled, I would like to re-enable it so that vcpkg provides a faster, parallelized PCL. Thanks in advance for your answer.

@JackBoosY
Copy link
Contributor Author

@JackBoosY Hi, I was wondering if you remember why you added -DWITH_OPENMP=OFF in this PR (more specifically, in the "Disable more options" commit)? I went through the PR and the linked issues, but could not find any reason why the multiprocessing library might have caused any problems, and on which triplets? If there is no reason why it must be disabled, I would like to re-enable it so that vcpkg provides a faster, parallelized PCL. Thanks in advance for your answer.

Maybe there have some issues when enabling this feature.

@mvieth
Copy link
Contributor

mvieth commented Apr 8, 2024

Maybe there have some issues when enabling this feature.

@JackBoosY But you don't remember anything specific? I am currently testing with different triplets and OpenMP enabled, and so far everything works fine. If I don't find any problem, I will probably create a pull request to remove -DWITH_OPENMP=OFF

@JackBoosY
Copy link
Contributor Author

Maybe there have some issues when enabling this feature.

@JackBoosY But you don't remember anything specific? I am currently testing with different triplets and OpenMP enabled, and so far everything works fine. If I don't find any problem, I will probably create a pull request to remove -DWITH_OPENMP=OFF

Feel free to reopen this feature in another PR : )

@mvieth mvieth mentioned this pull request May 3, 2024
7 tasks
data-queue pushed a commit that referenced this pull request May 3, 2024
<!-- If your PR fixes issues, please note that here by adding "Fixes
#NNNNNN." for each fixed issue on separate lines. -->

<!-- If you are still working on the PR, open it as a Draft:
https://github.blog/2019-02-14-introducing-draft-pull-requests/. -->


- [x] Changes comply with the [maintainer
guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md).
- [x] SHA512s are updated for each updated download.
- [ ] ~~The "supports" clause reflects platforms that may be fixed by
this new version.~~
- [ ] ~~Any fixed [CI
baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt)
entries are removed from that file.~~
- [x] Any patches that are no longer applied are deleted from the port's
directory.
- [x] The version database is fixed by rerunning `./vcpkg x-add-version
--all` and committing the result.
- [x] Only one version is added to each modified port's versions file.

Updated io_ply.patch so that it applies cleanly.

Additionally, the setting `-DWITH_OPENMP=OFF` is removed because there
does not seem to be a specific reason for it, and in my tests PCL still
built fine if it was removed, see
#21276 (comment)

<!-- If this PR adds a new port, please uncomment and fill out this
checklist:

- [ ] Changes comply with the [maintainer
guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md).
- [ ] The name of the port matches an existing name for this component
on https://repology.org/ if possible, and/or is strongly associated with
that component on search engines.
- [ ] Optional dependencies are resolved in exactly one way. For
example, if the component is built with CMake, all `find_package` calls
are REQUIRED, are satisfied by `vcpkg.json`'s declared dependencies, or
disabled with
[CMAKE_DISABLE_FIND_PACKAGE_Xxx](https://cmake.org/cmake/help/latest/variable/CMAKE_DISABLE_FIND_PACKAGE_PackageName.html).
- [ ] The versioning scheme in `vcpkg.json` matches what upstream says.
- [ ] The license declaration in `vcpkg.json` matches what upstream
says.
- [ ] The installed as the "copyright" file matches what upstream says.
- [ ] The source code of the component installed comes from an
authoritative source.
- [ ] The generated "usage text" is accurate. See
[adding-usage](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/examples/adding-usage.md)
for context.
- [ ] The version database is fixed by rerunning `./vcpkg x-add-version
--all` and committing the result.
- [ ] Only one version is in the new port's versions file.
- [ ] Only one version is added to each modified port's versions file.

END OF NEW PORT CHECKLIST (delete this line) -->
yurybura pushed a commit to yurybura/vcpkg that referenced this pull request May 8, 2024
<!-- If your PR fixes issues, please note that here by adding "Fixes
#NNNNNN." for each fixed issue on separate lines. -->

<!-- If you are still working on the PR, open it as a Draft:
https://github.blog/2019-02-14-introducing-draft-pull-requests/. -->


- [x] Changes comply with the [maintainer
guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md).
- [x] SHA512s are updated for each updated download.
- [ ] ~~The "supports" clause reflects platforms that may be fixed by
this new version.~~
- [ ] ~~Any fixed [CI
baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt)
entries are removed from that file.~~
- [x] Any patches that are no longer applied are deleted from the port's
directory.
- [x] The version database is fixed by rerunning `./vcpkg x-add-version
--all` and committing the result.
- [x] Only one version is added to each modified port's versions file.

Updated io_ply.patch so that it applies cleanly.

Additionally, the setting `-DWITH_OPENMP=OFF` is removed because there
does not seem to be a specific reason for it, and in my tests PCL still
built fine if it was removed, see
microsoft#21276 (comment)

<!-- If this PR adds a new port, please uncomment and fill out this
checklist:

- [ ] Changes comply with the [maintainer
guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md).
- [ ] The name of the port matches an existing name for this component
on https://repology.org/ if possible, and/or is strongly associated with
that component on search engines.
- [ ] Optional dependencies are resolved in exactly one way. For
example, if the component is built with CMake, all `find_package` calls
are REQUIRED, are satisfied by `vcpkg.json`'s declared dependencies, or
disabled with
[CMAKE_DISABLE_FIND_PACKAGE_Xxx](https://cmake.org/cmake/help/latest/variable/CMAKE_DISABLE_FIND_PACKAGE_PackageName.html).
- [ ] The versioning scheme in `vcpkg.json` matches what upstream says.
- [ ] The license declaration in `vcpkg.json` matches what upstream
says.
- [ ] The installed as the "copyright" file matches what upstream says.
- [ ] The source code of the component installed comes from an
authoritative source.
- [ ] The generated "usage text" is accurate. See
[adding-usage](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/examples/adding-usage.md)
for context.
- [ ] The version database is fixed by rerunning `./vcpkg x-add-version
--all` and committing the result.
- [ ] Only one version is in the new port's versions file.
- [ ] Only one version is added to each modified port's versions file.

END OF NEW PORT CHECKLIST (delete this line) -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-bug The issue is with a library, which is something the port should already support info:internal This PR or Issue was filed by the vcpkg team. info:reviewed Pull Request changes follow basic guidelines
Projects
None yet
8 participants