-
Notifications
You must be signed in to change notification settings - Fork 0
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
Forward compatibility with YARP 3.0 #65
Comments
Marking as blocked, I'd close #54 first. |
Forgot to add: YARP 3.0 requires CMake 3.5. Bump it in non-superbuild repos, teo-main and the like have been already updated in order to support stricter requirements in orchestrated subprojects. |
As spoken with @jgvictores, in the future, we'd like to create one tag per repo prior to requiring YARP 3.0 everywhere. The goal is to keep track of the last point in the commit history that supported YARP 2.x. |
See roboticslab-uc3m/kinematics-dynamics@d52434c. Testing our new policy: run a job for every supported minor YARP release (currently: v2.3.70, v2.3.72), which in total accounts for six jobs considering gcc/clang and YARP's master branch, on every push action (example). In addition, cron builds would add another couple of jobs against YARP's devel branch, thus totalling eight jobs (example). Also, we pull YCM's master branch in the former build set, and YCM's devel in the latter. |
I've come up with a possibly elegant solution at #48 (comment). I mark this therefore as blocked because of build times having considerably increased as a consequence of adding new jobs. Let's solve the dependency caching issue first. |
Support for optional components has been approved and merged into current YARP master with robotology/yarp#1741. YARP v3.0.1 is expected to come out soon, hence I'd like to review all |
Keep robotology/yarp#1778 in mind while updating the speech project. |
Since robotology/yarp#1778, looking for YCM before YARP leads to CI builds errors in superbuild-like repos that orchestrate subprojects in which a # Registers and sets a _CMAKE_YARP_TYPE=REQUIRED global property.
find_package(YARP REQUIRED)
message(STATUS "YARP_FOUND: ${YARP_FOUND}") # 1 (found)
# Let's assume we didn't get there yet. Note the QUIET OPTION.
find_package(YARP 99 QUIET)
message(STATUS "YARP_FOUND: ${YARP_FOUND}") # 0 (not found)
include(FeatureSummary)
feature_summary(FATAL_ON_MISSING_REQUIRED_PACKAGES WHAT ALL) This snippet would throw an error. There is plenty of room for improvements, but I'll start with removing the Edit: forgot to add that the alternative (and counterintuitive) solution is fairly simple, just issue Edit2: this error showed up because superbuild repos fetch the master branch of YCM, whereas latest YARP master requests YCM devel (see linked PR). |
For the time being, I'm not going to use YARP 3.x components. This feature will render no benefits in our projects and would require extra care:
Again: for now, I'm happy with current component defaults and no repo of ours require anything more convolute than that. Let's adopt the following sequence (already used throughout most repos) and close this issue: # Hard dependencies.
find_package(YCM 0.8 REQUIRED)
# https://github.com/roboticslab-uc3m/questions-and-answers/issues/65
find_package(YARP 3.0 QUIET)
if(NOT YARP_FOUND)
find_package(YARP 2.3.70 REQUIRED)
endif()
find_package(COLOR_DEBUG REQUIRED) Edit:
I forgot about this. YARP 3.x will happily treat |
* reverts 9e87f28 * rationale at roboticslab-uc3m/questions-and-answers#65 (comment)
Perhaps linked with robotology/yarp@9bfd7ca. |
This code: find_package(YARP 3.0 QUIET COMPONENTS ...)
# in the future, remove this check and use REQUIRED above
if(NOT YARP_FOUND)
find_package(YARP 2.3.70 REQUIRED)
endif() ...is causing trouble on Windows and YARP 2.3.70. The |
YARP 3.0 is finally out! And back compat is broken with YARP 2.x code. There are two sides to this coin:
find_package(YARP 2.3.x)
won't find YARP anymore if only YARP 3.x is found on system, while oldfind_package(YARP)
(no version specified) will.The former is causing Travis build failures since the past few days (said line was added shortly before the final release). I'm not prone to blindly remove the version specifier to
find_package()
(see #54 for background), but this could be easily solved by arranging some convenient checks in the following manner:Alternatively:
See also #54 (comment) regarding YARP components and #18 regarding optional project components.
Migration is a gradual step. Once fixed, CI builds will test our code against YARP master and devel (to keep up with YARP's development, see #7), both currently at 3.0+, but we'll surely keep using YARP 2.3.x in our PCs. My second proposal covers the improvement of
.travis.yml
files across the organization in order to add an additional job for said legacy YARP version. Thus, we'll make sure both the previous and current release cycles of YARP are compatible with our code. In that vein, I found this reference page useful since conditional jobs shall be run: two per pr/push action (YARP 2.3.72.1 and YARP master), only one for cron-enabled builds (YARP devel, like usual). Some YAML code improvements laid out at #48 might come in handy here.The text was updated successfully, but these errors were encountered: