Make folly compile on Debian systems#1514
Conversation
Debian, as Ubuntu's upstream, is largely compatible in its filesystem layout and package versions. Folly builds successfully on Debian's rolling "Testing" release.
Fix the error message
folly/folly/portability/Time.cpp:278:2: error: No clock_gettime(3)
compatibility wrapper available for this platform.
Presumably no compatibility layer is needed.
|
Hi @chaiken! Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks! |
|
The test failures like "file_test.File.Simple" clearly have nothing to do with my patch, which only changes the Linux build and does not affect Mac or Windows at all. Unfortunately I see no way to prove that assertion, so I'll close the pull request and carry the patch locally. |
|
The test failures are fine, we just need the CLA signed before we can do anything with it. |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks! |
|
On Linux localhost I find that EventBaseTest/EventBaseTest/0.RunInThread reproducibly fails but that everything else passes. Also, there are 928 tests that the test frameworks reports are not found. Presumably if they actually failed to compile or link, that would be reported as a build failure. |
|
Another note: clock_gettime_wrappers_test works fine with this patch. Assuredly it would fail if the patch were wrong. Here is the result: `$ build/folly/clock_gettime_wrappers_test [----------] Global test environment tear-down |
| def run_project_cmd(self, args, loader, manifest): | ||
| platforms = [ | ||
| HostType("linux", "ubuntu", "18"), | ||
| HostType("linux", None, None), |
There was a problem hiding this comment.
This needs to stay as ubuntu to run the github action on the right distro.
| } | ||
| } | ||
| #else | ||
| #if !__linux__ |
There was a problem hiding this comment.
What's causing FOLLY_HAVE_CLOCK_GETTIME to not be defined? This shouldn't be getting reached if that is defined properly.
|
Replaced by #1517. |
The attached patches make Folly compile on Debian systems without affecting the build on Ubuntu 18.04. They fix the error message
which suggested, apparently erroneously, that a compatibility wrapper is needed for Linux systems other than Ubuntu 18.04. clock_gettime() is a Linux system call.