-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Compile fails on FreeBSD with ld: error: undefined symbol: htonll #5414
Comments
The same happens on SunOS (5.10) |
Thanks for your bug report. Just for your interest: you can work around the issue by setting USE_NTLMCLIENT=OFF, but obviously this disables support for NTLM. Anyway, we should get this fixed. Could you please check whether #5417 fixes the problem? |
thanks a lot, that fixes the problem for FreeBSD. |
Thanks a lot for confirming. Will wait for @hkrummeck's feedback before merging #5417. |
@ethomson: do you know if there is an easy way for us to get at least one of the BSDs into Azure so that we have testing for them? I'd be happy to set up required scripts when we've got a VM. |
Unfortunately this does not work for SunOS 10, there is no htonll defined. At least on SPARC this should be a null operation:
I found another issue in ../src/transports/auth_ntlm.c, strndup is not available in SunOS 10. I suppose this should be git__strndup? With these 2 changes it can be compiled and linked. |
Thanks for the info. We should be cognizant of little endian machines as well, as there was SunOS for x86 platforms.
Yes, thanks, it probably should. |
I started working on this: ethomson@1fe3fa5 Maintaining a FreeBSD machine is a bit of a pain, due to cost. It gets disabled if I hit my preset spending limits in my cloud provider, which would cause the nightlies to fail. But we can and should figure out a solution here. |
@hkrummeck: I've amended my PR to hopefully fix this with SunOS<=10 |
I've also rolled in the strndup/strdup fixes. @ethomson, please let me know if I should move them into a separate PR. They seem to be trivial enough though to keep them here, though |
This LGTM |
Yes, thanks, this fix builds on SunOS 10. |
I maintain the libgit2 package for FreeBSD.
Reproduction steps
Try to compile the new version 0.99.0 on FreeBSD.
Expected behavior
It should compile.
Actual behavior
Get a linker error:
You can find the full build log here:
https://pkg.fechner.net/data/121amd64-gitlab/2020-02-20_22h51m26s/logs/errors/libgit2-0.99.0.log
Version of libgit2 (release number or SHA1)
0.99.0
Operating system(s) tested
FreeBSD
The text was updated successfully, but these errors were encountered: