Skip to content

[proj4] Add usage, fixup target PROJ::proj#19298

Merged
dan-shaw merged 8 commits intomicrosoft:masterfrom
JackBoosY:dev/jack/16906
Aug 10, 2021
Merged

[proj4] Add usage, fixup target PROJ::proj#19298
dan-shaw merged 8 commits intomicrosoft:masterfrom
JackBoosY:dev/jack/16906

Conversation

@JackBoosY
Copy link
Copy Markdown
Contributor

@JackBoosY JackBoosY commented Aug 2, 2021

Since the upstream indicated in the document that it prefers PROJ instead of PROJ4, fixup the target PROJ and only provide the usage of target PROJ in the usage and keep the exported PROJ4 cmake configuration file.

Fixes #16906.

@JackBoosY JackBoosY added category:port-bug The issue is with a library, which is something the port should already support info:internal labels Aug 2, 2021
Copy link
Copy Markdown

@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 261c458af6e3eed5d099144aff95d2b5035f656b -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/baseline.json b/versions/baseline.json
index 7e64191..a945fb0 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -5038,7 +5038,7 @@
     },
     "proj4": {
       "baseline": "7.2.1",
-      "port-version": 2
+      "port-version": 3
     },
     "prometheus-cpp": {
       "baseline": "0.12.3",
diff --git a/versions/p-/proj4.json b/versions/p-/proj4.json
index 703424c..5be0adb 100644
--- a/versions/p-/proj4.json
+++ b/versions/p-/proj4.json
@@ -1,5 +1,10 @@
 {
   "versions": [
+    {
+      "git-tree": "e6b33c3a3987f7198d8cd25fd12640fcaccc9773",
+      "version-string": "7.2.1",
+      "port-version": 3
+    },
     {
       "git-tree": "e692e884172877640f3de4009d810061382714b7",
       "version-string": "7.2.1",

@JackBoosY JackBoosY added the depends:upstream-changes Waiting on a change to the upstream project label Aug 2, 2021
@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Aug 2, 2021

Which upstream changes does this need?
We need an update to port vtk in order to allow an update to port proj in order to follow upstream.

Copy link
Copy Markdown

@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 261c458af6e3eed5d099144aff95d2b5035f656b -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/p-/proj4.json b/versions/p-/proj4.json
index 5be0adb..2823e5e 100644
--- a/versions/p-/proj4.json
+++ b/versions/p-/proj4.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "e6b33c3a3987f7198d8cd25fd12640fcaccc9773",
+      "git-tree": "2a79aed1616c4f305f0231da48764e93a60ac74a",
       "version-string": "7.2.1",
       "port-version": 3
     },

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Aug 3, 2021

The PROJ project exports valid file names. Which problem is actually fixed by changing them?
If there is no good reason, it seems quite intrusive to ask upstream for changes. I would reject the change.

@JackBoosY
Copy link
Copy Markdown
Contributor Author

@dg0yt According to cmake docs:

Store the current build directory in the CMake user package registry for package <PackageName>. 
The find_package() command may consider the directory while searching for package <PackageName>. 
This helps dependent projects find and use a package from the current project's build tree without help from the user. 
Note that the entry in the package registry that this command creates works only in conjunction with a package configuration file (<PackageName>Config.cmake) that works with the build tree. 
In some cases, for example for packaging and for system wide installations, it is not desirable to write the user package registry.

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Aug 3, 2021

@dg0yt According to cmake docs:

Store the current build directory in the CMake user package registry for package <PackageName>. 
...

@JackBoosY Now how do we get to discussing package registries?
Vcpkg builds cmake projects with package registry export and usage disabled:

$ git grep PACKAGE_REGISTRY scripts/
scripts/buildsystems/vcpkg.cmake:set(Z_VCPKG_UNUSED "${CMAKE_EXPORT_NO_PACKAGE_REGISTRY}")
scripts/buildsystems/vcpkg.cmake:set(Z_VCPKG_UNUSED "${CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY}")
scripts/buildsystems/vcpkg.cmake:set(Z_VCPKG_UNUSED "${CMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY}")
scripts/cmake/vcpkg_configure_cmake.cmake:        "-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON"
scripts/cmake/vcpkg_configure_cmake.cmake:        "-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON"
scripts/cmake/vcpkg_configure_cmake.cmake:        "-DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON"

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Aug 3, 2021

For completeness, as posted before in PROJ, cmake's find_package explicitly looks also for <lower-case-package-name>-config.cmake. References:
https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#package-configuration-file
https://cmake.org/cmake/help/latest/command/find_package.html#full-signature-and-config-mode

@JackBoosY
Copy link
Copy Markdown
Contributor Author

JackBoosY commented Aug 3, 2021

For completeness, as posted before in PROJ, cmake's find_package explicitly looks also for <lower-case-package-name>-config.cmake. References:
https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#package-configuration-file
https://cmake.org/cmake/help/latest/command/find_package.html#full-signature-and-config-mode

Reasonable.

Copy link
Copy Markdown

@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 261c458af6e3eed5d099144aff95d2b5035f656b -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/p-/proj4.json b/versions/p-/proj4.json
index 06f48a1..05b5875 100644
--- a/versions/p-/proj4.json
+++ b/versions/p-/proj4.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "786f91b5cc03cadfa2e37e69600b8683baa7c5ca",
+      "git-tree": "b2d80efa9bd2d3eff49d1d3c2b198e2619168306",
       "version-string": "7.2.1",
       "port-version": 3
     },

Copy link
Copy Markdown
Contributor

@dg0yt dg0yt left a comment

Choose a reason for hiding this comment

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

Thank for your patience with my comments @JackBoosY.

@JackBoosY JackBoosY marked this pull request as ready for review August 5, 2021 03:07
Copy link
Copy Markdown

@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 261c458af6e3eed5d099144aff95d2b5035f656b -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/p-/proj4.json b/versions/p-/proj4.json
index 06f48a1..d5bbf1d 100644
--- a/versions/p-/proj4.json
+++ b/versions/p-/proj4.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "786f91b5cc03cadfa2e37e69600b8683baa7c5ca",
+      "git-tree": "8fc1b6bdde08a3b1f131df5a4f042885dcc7a58d",
       "version-string": "7.2.1",
       "port-version": 3
     },

@JackBoosY JackBoosY removed the depends:upstream-changes Waiting on a change to the upstream project label Aug 5, 2021
@JackBoosY JackBoosY requested a review from PhoebeHui August 5, 2021 08:08
@JackBoosY JackBoosY changed the title [proj4] Export target both proj and proj4 [proj4] Add usage, export target PROJ::proj Aug 6, 2021
@JackBoosY JackBoosY changed the title [proj4] Add usage, export target PROJ::proj [proj4] Add usage, fixup target PROJ::proj Aug 6, 2021
@PhoebeHui PhoebeHui added the info:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this. label Aug 6, 2021
@dan-shaw dan-shaw merged commit dd46239 into microsoft:master Aug 10, 2021
@@ -0,0 +1,4 @@
The package ${PORT}:${TARGET_TRIPLET} provides CMake targets:
Copy link
Copy Markdown
Contributor

@ras0219-msft ras0219-msft Aug 10, 2021

Choose a reason for hiding this comment

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

How does this work? The configure line above is @ONLY but this is using ${} syntax.

+@JackBoosY

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@ras0219-msft, thanks for pointing out this issue! I have submitted PR #19474 to fix it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ops, sorry for that.

@JackBoosY JackBoosY deleted the dev/jack/16906 branch August 11, 2021 02:27
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:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FindProj not working as expected

5 participants