Merged
Conversation
Contributor
b11c0b1 to
5e34104
Compare
When building git dependency on redhat 7 with git v2.50 we get a compilation error due to the include of a missing file. ``` 15:05:27 + make CURL_LDFLAGS=-lcurl 15:05:28 GIT_VERSION=2.50.0 15:05:28 * new build flags 15:05:28 CC daemon.o 15:05:28 In file included from git-compat-util.h:26:0, 15:05:28 from daemon.c:3: 15:05:28 compat/posix.h:159:24: fatal error: sys/random.h: No such file or directory 15:05:28 #include <sys/random.h> 15:05:28 ^ 15:05:28 compilation terminated. ``` Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
5e34104 to
16fc9aa
Compare
| rhel|centos) | ||
| if [ $(echo $OS_VERSION | cut -d. -f1) = 7 ] | ||
| then | ||
| # Fixes the following compilation error on rhel 7: |
Contributor
There was a problem hiding this comment.
odd, this is new? and maybe we could more easily fix the autoconfig bits which are incorrectly setting HAVE_GETRANDOM to true?
Contributor
There was a problem hiding this comment.
I think this may be happening because the function is there, but the build host is missing the development header files. They should probably additionally check #ifdef HAVE_SYS_GETRANDOM_H
Contributor
There was a problem hiding this comment.
Feel free to look at the autoconfig bits Craig :)
Contributor
96ea262 to
16fc9aa
Compare
Contributor
This was referenced Jun 30, 2025
Fixes current compilation error (found on Ubuntu 24): ``` 23:16:48 log.c:637:21: error: implicit declaration of function 'gettid'; did you mean 'getgid'? [-Wimplicit-function-declaration] 23:16:48 637 | pid_t tid = gettid(); 23:16:48 | ^~~~~~ 23:16:48 | getgid ``` Ticket: ENT-13084 Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
78afe25 to
6e0eaed
Compare
Contributor
larsewi
approved these changes
Jul 1, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automated dependency updates for the master branch