-
Notifications
You must be signed in to change notification settings - Fork 5
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
Detect whether libatomic is needed rather than hard-coding for mips #8
Conversation
Hm, having left the build running, it fails at linking:
Seems like CMAKE_REQUIRED_LIBRARIES isn't actually being used? I guess I could add it to EXTRA_REQ_LIBRARIES; that might work? I don't really know CMake very well; maybe you know what the problem/solution is? |
The original MIPS 64 patch was written by @cvicentiu, I will let him comment on the issue. Do you @jrtc27 want me to merge this as-is already now or wait for a perfect solution? PowerPC (the 32-bit one) is not an official architecture in Stretch, but MIPS variants are, and I'd rather not want to risk MIPS build failures at this stage just to partially improve PowerPC build progress. Do you anticipate any regressions with this? I don't have time to do more than just one amd64 test build before next upload (which is urgent due to the screw-ups I did yesterday). |
Yeah, don't merge this yet, it will almost certainly break 32-bit MIPS builds. |
If you don't mind waiting a few hours before uploading, though, I'd appreciate it, as I'm going to take a look at this this morning, but I understand if you want to upload a non-broken version ASAP. |
I can wait. Thanks a lot for your contributions to this package! |
Fixes FTBFS on powerpc, since it needs libatomic too for C11 atomics, and possibly m68k.
Updated. Seems to work on powerpc (although the test suite looks like it has a couple of failures on the porterbox). I'm also doing a mipsel build on eller, but if you want to get this out quickly, I suggest you merge this and start your amd64 test build now while mipsel builds? I will report back once it has finished compiling (test suite is irrelevant since it's ignored by debian/rules). |
I'll wait for a few more hours. The 10-day limit to Feb 5th is already missed since upload yesterday evening failed, and it will not matter if I upload today at 15pm or 20pm. |
The mipsel build on eller is at 76%, and has definitely been using the atomics operations based on the compiler output. I think it's safe to assume it still works. |
@jrtc27: Yes, The second version of your commits are good. The -DEXTRA_REQ_LIBRARIES was a hack I did to tell cmake to link with libatomic. I think you're solution is better and is safe to push. The CMAKE_REQUIRED_LIBRARIES variable is only used when doing compile checks and doesn't actually tell the linker to use it at build time. You have to use TARGET_LINK_LIBRARIES, like you did in your second approach to actually link it. Looks good to me now. |
Fixes FTBFS on powerpc, since it needs libatomic too for C11 atomics, and possibly m68k. I haven't actually tested a full build, but configuring now detects that it can use C11 atomics with libatomic, so it should at least get further: