Skip to content

[yoctolib] 2.1.11761 Update#49802

Merged
BillyONeal merged 9 commits into
microsoft:masterfrom
yoctopuce:master
Feb 5, 2026
Merged

[yoctolib] 2.1.11761 Update#49802
BillyONeal merged 9 commits into
microsoft:masterfrom
yoctopuce:master

Conversation

@yoctopuce
Copy link
Copy Markdown
Contributor

  • Changes comply with the maintainer guide.
  • SHA512s are updated for each updated download.
  • The "supports" clause reflects platforms that may be fixed by this new version.
  • Any fixed CI baseline entries are removed from that file.
  • Any patches that are no longer applied are deleted from the port's directory.
  • The version database is fixed by rerunning ./vcpkg x-add-version --all and committing the result.
  • Only one version is added to each modified port's versions file.

Signed-off-by: Yoctopuce <dev@yoctopuce.com>
Signed-off-by: Yoctopuce <dev@yoctopuce.com>
Signed-off-by: Yoctopuce <dev@yoctopuce.com>
Signed-off-by: Yoctopuce <dev@yoctopuce.com>
@srinsoz
Copy link
Copy Markdown

srinsoz commented Feb 4, 2026

@microsoft-github-policy-service agree company="Yoctopuce"

@srinsoz srinsoz mentioned this pull request Feb 4, 2026
7 tasks
@nickdademo
Copy link
Copy Markdown
Contributor

Nice :) Linux job failure is due to the libusb include, looks like this patch change was not applied upstream:

-#include <libusb-1.0/libusb.h>
+#include <libusb.h>

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")

vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/README.md")
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.

this needs to be changed to instead install the copyright file that was added in this PR

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

done

@srinsoz
Copy link
Copy Markdown

srinsoz commented Feb 4, 2026

Nice :) Linux job failure is due to the libusb include, looks like this patch change was not applied upstream:

-#include <libusb-1.0/libusb.h>
+#include <libusb.h>

I noticed that the previous port was handling this, but in my opinion, this approach is incorrect.
On all the Linux machines I’ve tested, you need to include <libusb-1.0/libusb.h>.

Signed-off-by: Yoctopuce <dev@yoctopuce.com>
@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Feb 4, 2026

On all the Linux machines I’ve tested, you need to include <libusb-1.0/libusb.h>.

libusb.pc (in vcpkg and Debian) has Cflags: "-I${includedir}/libusb-1.0", and the files is in ${includedir}/libusb-1.0/libusb.h. So only <libusb.h> would match the official pkgconfig file.

Comment thread ports/yoctolib/copyright Outdated
@@ -0,0 +1,28 @@
Copyright (C) 2011 and beyond by Yoctopuce Sarl, Switzerland.
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.

AFAICT copyright files shall not be added to the vcpkg repo.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

I followed the official documentation (https://learn.microsoft.com/en-us/vcpkg/reference/vcpkg-json#license) and used the strtk package (https://github.com/microsoft/vcpkg/tree/master/ports/strtk) as a reference for implementation.
However, if needed, I can revert to the previous version and simply copy the README.md from our library.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We usually require that the license come out of the actual upstream repo rather than trying to cough up the text ourselves so that updates that change the license don't end up making us install lies about what the license is.

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.

I followed the official documentation (https://learn.microsoft.com/en-us/vcpkg/reference/vcpkg-json#license) and used the strtk package (https://github.com/microsoft/vcpkg/tree/master/ports/strtk) as a reference for implementation.

The documentation is not for the copyright file but for the license manifest field.
strtk is an old port with few updates.

But there is this: https://learn.microsoft.com/en-us/vcpkg/contributing/maintainer-guide#install-copyright-file

In some ports, we use regex pattern matching to extract the licensing part from source files. I admit this needs some extra care during port updates.

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Feb 4, 2026

Is there a vendored mbedtls?

@srinsoz
Copy link
Copy Markdown

srinsoz commented Feb 4, 2026

On all the Linux machines I’ve tested, you need to include <libusb-1.0/libusb.h>.

libusb.pc (in vcpkg and Debian) has Cflags: "-I${includedir}/libusb-1.0", and the files is in ${includedir}/libusb-1.0/libusb.h. So only <libusb.h> would match the official pkgconfig file.

I will add a patch to fix this for vcpkg, but we are not changing our code since we never had any issue with this include

Signed-off-by: Yoctopuce <dev@yoctopuce.com>
Signed-off-by: Yoctopuce <dev@yoctopuce.com>
@yoctopuce
Copy link
Copy Markdown
Contributor Author

@microsoft-github-policy-service agree company="Yoctopuce"

Copy link
Copy Markdown
Member

@BillyONeal BillyONeal left a comment

Choose a reason for hiding this comment

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

Comment thread ports/yoctolib/copyright Outdated
@@ -0,0 +1,28 @@
Copyright (C) 2011 and beyond by Yoctopuce Sarl, Switzerland.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We usually require that the license come out of the actual upstream repo rather than trying to cough up the text ourselves so that updates that change the license don't end up making us install lies about what the license is.

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Feb 5, 2026

I will add a patch to fix this for vcpkg, but we are not changing our code since we never had any issue with this include

I don't know the extent for "never" here. The current approach would typically include the "right" header in native builds, due to typical installation layouts. It might also often include the "wrong" header in cross builds without the user noticing, subject to sysroot and default search paths. IMHO it is simply wrong to use pkgconfig while not using the paths provided by pkgconfig.

FTR here is a code example from official documentation:
https://libusb.sourceforge.io/api-1.0/libusb_hotplug.html

Signed-off-by: Yoctopuce <dev@yoctopuce.com>
@yoctopuce yoctopuce requested a review from BillyONeal February 5, 2026 10:33
Copy link
Copy Markdown
Member

@BillyONeal BillyONeal left a comment

Choose a reason for hiding this comment

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

❤️

@BillyONeal BillyONeal merged commit b4f070b into microsoft:master Feb 5, 2026
17 checks passed
@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Feb 6, 2026

Repeating my question:

Is there a vendored mbedtls?

@nickdademo
Copy link
Copy Markdown
Contributor

Repeating my question:

Is there a vendored mbedtls?

I investigated de-vendoring when I created this port a few months back. Didn't seem possible...
Ref: #48871 (comment)

@dg0yt
Copy link
Copy Markdown
Contributor

dg0yt commented Feb 6, 2026

So it is not used? (But it is also not removed.)

@nickdademo
Copy link
Copy Markdown
Contributor

So it is not used? (But it is also not removed.)

Not used. Portfile sets USE_YSSL=OFF

https://github.com/yoctopuce/yoctolib_cpp/blob/master/Sources/yapi/CMakeLists.txt#L7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants