unit-e icon indicating copy to clipboard operation
unit-e copied to clipboard

Missing build dependencies for libusb

Open cornelius opened this issue 6 years ago • 3 comments

Describe the bug When doing a gitian build of unit-e the build of the dependencies fails with an error message configure: error: udev support requested but libudev header not installed when building libusb.

To Reproduce Steps to reproduce the behavior:

  1. Run contrib/gitian-build.py
  2. See the logs in /gitian-builder/var/build.log

Expected behavior Dependencies should be installed by the build system and the build should succeed.

Environment Tested on Mac and Ubuntu using unit-e 3f2db48fba04e3f4006d62a11eed44588f232749.

cornelius avatar Feb 13 '19 11:02 cornelius

Libusb depends on libudev-dev on Linux. On Mac, it depends on IOKit and CoreFoundation: seeing it complaining about udev is really weird :confused:

cmihai avatar Feb 13 '19 11:02 cmihai

It's not possible not to depend on libudev (credit @cmihai).

We can split this issue into three parts:

  1. Only add libusb as dependency on Linux, after which both Mac and Windows will build.
  2. Install libudev-dev in the linux gitian, so that linux build works (this is what is done in particl)
  3. Make libudev Unit-e core's proper dependency to improve security.

@cornelius @cmihai @thothd

Ruteri avatar Feb 14 '19 16:02 Ruteri

I think adding the dependency in the container so that it builds again is fine. We can leave further steps for later.

If it would improve security to add it as a proper dependency needs some more detailed review, I think.

And we have to see if it affects the reproducibility of unit-e. But we can fix that in case we see it causing issues.

cornelius avatar Feb 14 '19 16:02 cornelius