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

[OpenMVS] restore deprecated cmake scripts for configure, build & fixup targets #20422

Merged
merged 3 commits into from
Oct 7, 2021

Conversation

cenit
Copy link
Contributor

@cenit cenit commented Sep 29, 2021

During boost 1.77 upgrade, openmvs was updated to new vcpkg-cmake port for configure, build & fixup.
Unfortunately, it does not work correctly and consuming the library since then is broken.

Inside OpenMVSTargets.cmake the fixup deprecated script works correctly and produces this line

set(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_DIR}/../..")

while the new one produces this broken line

set(_IMPORT_PREFIX "${_IMPORT_PREFIX}")

We should fix the fixup script, but since i am not such an expert in dealing with regex-es, i suggest for now to revert the upgrade to a working script, while we try to understand what went wrong there (usually the new one works, but not with this port)

@strega-nil @strega-nil-ms

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.

You have modified or added at least one portfile where deprecated functions are used.

If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake -> vcpkg_cmake_install (from port vcpkg-cmake)
vcpkg_build_cmake -> vcpkg_cmake_build (from port vcpkg-cmake)
vcpkg_configure_cmake -> vcpkg_cmake_configure (Please remove the option PREFER_NINJA) (from port vcpkg-cmake)
vcpkg_fixup_cmake_targets -> vcpkg_cmake_config_fixup (from port vcpkg-cmake-config)

In the ports that use the new function, you have to add the corresponding dependencies:

{
  "name": "vcpkg-cmake",
  "host": true
},
{
  "name": "vcpkg-cmake-config",
  "host": true
}

The following files are affected:

  • ports/openmvs/portfile.cmake

@strega-nil-ms
Copy link
Contributor

Can you just switch back to vcpkg_fixup_cmake_targets? There's no reason to switch back to vcpkg_*_cmake aiui.

@cenit
Copy link
Contributor Author

cenit commented Sep 29, 2021

cmake errors due to including vcpkg-cmake port and using old fixup script

@PhoebeHui PhoebeHui self-assigned this Sep 30, 2021
@PhoebeHui PhoebeHui added the category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) label Sep 30, 2021
@cenit
Copy link
Contributor Author

cenit commented Oct 6, 2021

any news? openmvs is broken on master since 28th Sep...

@strega-nil-ms
Copy link
Contributor

strega-nil-ms commented Oct 6, 2021

@cenit vcpkg_fixup_cmake_targets doesn't check for vcpkg-cmake; it only checks for vcpkg-cmake-config. I'm going to try pushing the other change. If it fails, I'll merge the original change.

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.

You have modified or added at least one portfile where deprecated functions are used.

If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake -> vcpkg_cmake_install (from port vcpkg-cmake)
vcpkg_build_cmake -> vcpkg_cmake_build (from port vcpkg-cmake)
vcpkg_configure_cmake -> vcpkg_cmake_configure (Please remove the option PREFER_NINJA) (from port vcpkg-cmake)
vcpkg_fixup_cmake_targets -> vcpkg_cmake_config_fixup (from port vcpkg-cmake-config)

In the ports that use the new function, you have to add the corresponding dependencies:

{
  "name": "vcpkg-cmake",
  "host": true
},
{
  "name": "vcpkg-cmake-config",
  "host": true
}

The following files are affected:

  • ports/openmvs/portfile.cmake

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 e1c8bbd3c6731cd988eb7e27d2fd0de7983e454d -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/o-/openmvs.json b/versions/o-/openmvs.json
index 50afb3e..8ce9dd4 100644
--- a/versions/o-/openmvs.json
+++ b/versions/o-/openmvs.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "4567d6956e82463039bc521d479144cff5db305f",
+      "git-tree": "168233263a9b959a9a19f1eb2d6f462d5257d18f",
       "version": "1.1.1",
       "port-version": 1
     },

You have modified or added at least one portfile where deprecated functions are used.

If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake -> vcpkg_cmake_install (from port vcpkg-cmake)
vcpkg_build_cmake -> vcpkg_cmake_build (from port vcpkg-cmake)
vcpkg_configure_cmake -> vcpkg_cmake_configure (Please remove the option PREFER_NINJA) (from port vcpkg-cmake)
vcpkg_fixup_cmake_targets -> vcpkg_cmake_config_fixup (from port vcpkg-cmake-config)

In the ports that use the new function, you have to add the corresponding dependencies:

{
  "name": "vcpkg-cmake",
  "host": true
},
{
  "name": "vcpkg-cmake-config",
  "host": true
}

The following files are affected:

  • ports/openmvs/portfile.cmake

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!

All manifest files must be formatted

./vcpkg format-manifest ports/*/vcpkg.json

Diff
diff --git a/ports/openmvs/vcpkg.json b/ports/openmvs/vcpkg.json
index d587ebe..fa03e4d 100644
--- a/ports/openmvs/vcpkg.json
+++ b/ports/openmvs/vcpkg.json
@@ -14,10 +14,6 @@
       "name": "cgal",
       "default-features": false
     },
-    {
-      "name": "vcpkg-cmake",
-      "host": true
-    },
     "eigen3",
     "glew",
     "glfw3",
@@ -32,6 +28,10 @@
     },
     "tiff",
     "vcglib",
+    {
+      "name": "vcpkg-cmake",
+      "host": true
+    },
     "zlib"
   ],
   "features": {
After committing all other changes, the version database must be updated
git add -u && git commit
git checkout 33f02c0ae50c262da487d21ace4f5d67ae949c18 -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/o-/openmvs.json b/versions/o-/openmvs.json
index a3c313b..8ce9dd4 100644
--- a/versions/o-/openmvs.json
+++ b/versions/o-/openmvs.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "054882d44e2b35b2301b634dacc410bb3c48665f",
+      "git-tree": "168233263a9b959a9a19f1eb2d6f462d5257d18f",
       "version": "1.1.1",
       "port-version": 1
     },

You have modified or added at least one portfile where deprecated functions are used.

If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake -> vcpkg_cmake_install (from port vcpkg-cmake)
vcpkg_build_cmake -> vcpkg_cmake_build (from port vcpkg-cmake)
vcpkg_configure_cmake -> vcpkg_cmake_configure (Please remove the option PREFER_NINJA) (from port vcpkg-cmake)
vcpkg_fixup_cmake_targets -> vcpkg_cmake_config_fixup (from port vcpkg-cmake-config)

In the ports that use the new function, you have to add the corresponding dependencies:

{
  "name": "vcpkg-cmake",
  "host": true
},
{
  "name": "vcpkg-cmake-config",
  "host": true
}

The following files are affected:

  • ports/openmvs/portfile.cmake

@strega-nil-ms strega-nil-ms merged commit b1e54e8 into microsoft:master Oct 7, 2021
@cenit cenit deleted the dev/cenit/openmvs branch October 7, 2021 07:20
yurybura pushed a commit to yurybura/vcpkg that referenced this pull request Oct 7, 2021
…up targets (microsoft#20422)

* [OpenMVS] restore deprecated cmake scripts

* [OpenMVS] fix references

* switch back to vcpkg_cmake_*

Co-authored-by: nicole mazzuca <mazzucan@outlook.com>
BillyONeal added a commit that referenced this pull request Oct 12, 2021
* [scripts/boost] fix issue #20417
[boost-iostreams] replace explicit dependencies with default-features, allow to disable compression filters

* add versions

* [scripts/boost] update port version after #20421

* [boost-odeint] move boost-mpi dependency to the feature

* add version

* [boost-modular-build-helper] rework user-config generation

* [boost-python] move python3 from explicit dependency to default feature

* [boost-modular-build-helper] update version

* add verions

* [boost-modular-build-helper] fix empty flags

* update version

* Fix compilation on Emscripten / WebAssembly (#20551)

* [opencv4,opencv3] Control exported protobuf dependency (#20550)

* Control exported protobuf dependency

* Update versions

* Control exported protobuf dependency

* Update versions

* [OpenMVS] restore deprecated cmake scripts for configure, build & fixup targets (#20422)

* [OpenMVS] restore deprecated cmake scripts

* [OpenMVS] fix references

* switch back to vcpkg_cmake_*

Co-authored-by: nicole mazzuca <mazzucan@outlook.com>

* [libffi] Don't replace string in file that doesn't exist. (#20554)

* Don't replace string in file that doesn't exist.

* Update per bot.

* Update per bot again.

* Address comments.

* [json-dto] Update to 0.2.14 (#20570)

* json-dto updated to v.0.2.14.

* json-dto-0.2.14 added to baseline.

* Change deprecated commands.

* Update baseline for fresh json-dto-0.2.14.

* [sail] Update to 0.9.0-pre17 (#20562)

* [sail] Update to 0.9.0-pre17

* [sail] vcpkg x-add-version --all --overwrite-version

* [sail] Update pre17 hash

* [sail] vcpkg x-add-version --all --overwrite-version

* [freexl] Update to 1.0.6 (#20520)

* Reformat portfile

* Minimize makefiles patch

* Update to 1.0.6

* Fix uwp builds, remove skip from baseline

* Install pc file for windows

* Update versions

Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>

* [dartsim] Update to 6.11.0 (#20566)

* Update dartsim

* Use newer vcpkg functions

* Update version number

* Update ports/dartsim/portfile.cmake

Co-authored-by: Robert Schumacher <roschuma@microsoft.com>

* Update versions

Co-authored-by: Robert Schumacher <roschuma@microsoft.com>

* [scripts/boost] update Boost version in boost-modular-build.cmake to avoid manual changes

* update version

* [boost-modular-build-helper] fix USER_CONFIG_EXTRA_LINES variable name and rename generated files

* update version

* Resolve differences from rerunning generate-ports.ps1.

Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
Co-authored-by: Tobias Markus <tobbi.bugs@googlemail.com>
Co-authored-by: Kai Pastor <dg0yt@darc.de>
Co-authored-by: Stefano Sinigardi <stesinigardi@hotmail.com>
Co-authored-by: nicole mazzuca <mazzucan@outlook.com>
Co-authored-by: Lars Glud <larshg@gmail.com>
Co-authored-by: eao197 <eao197@users.noreply.github.com>
Co-authored-by: Dmitry Baryshev <dmitrymq@gmail.com>
Co-authored-by: Akash <Ace314159@users.noreply.github.com>
Co-authored-by: Robert Schumacher <roschuma@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants