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

[urdfdom][sdformat9] Re-fix build #22367

Merged

Conversation

JackBoosY
Copy link
Contributor

Refix sdformat9 build issue:

D:\buildtrees\sdformat9\src\mat9_9.4.0-e90e994b02.clean\src\parser_urdf.cc(30): fatal error C1083: Cannot open include file: 'urdf_model/model.h': No such file or directory
  1. Export urdfdom's targets, refactory its config file.
  2. Re-fix find urdfdom in sdformat9.

Related: #21456.

Sorry, I didn't completely fix this in #22180.

@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. labels Jan 5, 2022
@JackBoosY
Copy link
Contributor Author

JackBoosY commented Jan 5, 2022

I will make a PR to the upstream about the fix config files part.
The upstream already do that.

@JackBoosY
Copy link
Contributor Author

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Comment on lines +25 to +27
-Durdfdom_headers_VERSION_MAJOR=1
-Durdfdom_headers_VERSION_MINOR=0
-Durdfdom_headers_VERSION_PATCH=4
Copy link
Contributor Author

Choose a reason for hiding this comment

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

In BackwardCompatibility.hpp.in:

/* urdfdom_headers Version number */
// We define the version numbers of urdfdom_headers here since it doesn't expose
// the version numbers itself in source level.
#define URDFDOM_HEADERS_MAJOR_VERSION @urdfdom_headers_VERSION_MAJOR@
#define URDFDOM_HEADERS_MINOR_VERSION @urdfdom_headers_VERSION_MINOR@
#define URDFDOM_HEADERS_PATCH_VERSION @urdfdom_headers_VERSION_PATCH@

#define URDFDOM_HEADERS_VERSION_AT_LEAST(x,y,z) \
  (URDFDOM_HEADERS_MAJOR_VERSION > x || (URDFDOM_HEADERS_MAJOR_VERSION >= x && \
  (URDFDOM_HEADERS_MINOR_VERSION > y || (URDFDOM_HEADERS_MINOR_VERSION >= y && \
  URDFDOM_HEADERS_PATCH_VERSION >= z))))

#if URDFDOM_HEADERS_VERSION_AT_LEAST(1,0,0)
...

ports/urdfdom/vcpkg.json Outdated Show resolved Hide resolved
Comment on lines +36 to +53
+if (0)
foreach(lib @PKG_LIBRARIES@)
set(onelib "${lib}-NOTFOUND")
find_library(onelib ${lib}
@@ -25,3 +29,13 @@ foreach(dep @PKG_DEPENDS@)
list(APPEND @PKG_NAME@_INCLUDE_DIRS ${${dep}_INCLUDE_DIRS})
list(APPEND @PKG_NAME@_LIBRARIES ${${dep}_LIBRARIES})
endforeach()
+endif()
+
+include(CMakeFindDependencyMacro)
+find_dependency(console_bridge)
+
+foreach(exp @PKG_EXPORTS@)
+ include(${@PROJECT_NAME@_DIR}/${exp}Export.cmake)
+endforeach()
+
+set(@PKG_NAME@_LIBRARIES urdfdom::urdfdom_model urdfdom::urdfdom_world urdfdom::urdfdom_sensor urdfdom::urdfdom_model_state)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The old method still have some problems.
I've open an issue about that: ros/urdfdom#166

- DESTINATION ${CMAKE_INSTALL_BINDIR})
-INSTALL(TARGETS urdfdom_sensor DESTINATION ${CMAKE_INSTALL_LIBDIR})
-INSTALL(TARGETS urdfdom_model_state DESTINATION ${CMAKE_INSTALL_LIBDIR})
+INSTALL(
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The upstrema merged this changes in the latest master.

@PhoebeHui PhoebeHui added the info:reviewed Pull Request changes follow basic guidelines label Jan 7, 2022
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 b934807c799fd84c2e1e168b8d3472d4904a6f90 -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/s-/sdformat9.json b/versions/s-/sdformat9.json
index 166ffd0..3de7f0f 100644
--- a/versions/s-/sdformat9.json
+++ b/versions/s-/sdformat9.json
@@ -1,7 +1,7 @@
 {
   "versions": [
     {
-      "git-tree": "3f02b6228c284f5597009f5c0a4832aba019830e",
+      "git-tree": "8873210007b7610df26590b00c6f61204b08210a",
       "version": "9.4.0",
       "port-version": 3
     },

@strega-nil-ms strega-nil-ms force-pushed the dev/jack/refix-urdfdom-sdformat9 branch from 4653dfe to f5ea9fa Compare January 7, 2022 22:35
@strega-nil-ms strega-nil-ms merged commit d4acfe7 into microsoft:master Jan 7, 2022
@JackBoosY JackBoosY deleted the dev/jack/refix-urdfdom-sdformat9 branch January 10, 2022 02:16
rhuijben pushed a commit to rhuijben/vcpkg that referenced this pull request Jan 25, 2022
* [urdfdom][sdformat9] Re-fix build

* version

* Remove empty folder

* version

* [dartsim] Fix build issue

* version

* Update version name

* version

* Apply suggestions

* version

* Add PKG_EXPORTS

* version

* Update ports/sdformat9/fix-dependency-urdfdom.patch

Co-authored-by: nicole mazzuca <[email protected]>
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
Development

Successfully merging this pull request may close these issues.

3 participants