Opened 3 years ago
Closed 3 years ago
#28406 closed defect (worksforme)
barvinok fails to build on Arch with system's NTL
Reported by: | vdelecroix | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | sage-duplicate/invalid/wontfix |
Component: | packages: optional | Keywords: | |
Cc: | dimpase, arojas | Merged in: | |
Authors: | Reviewers: | Dima Pasechnik | |
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
On my machine where the system NTL is used, the optional package barvinok fails to build (Sage version 8.9.beta8). The relevant
Attachments (3)
Change History (16)
Changed 3 years ago by
Changed 3 years ago by
Changed 3 years ago by
comment:1 Changed 3 years ago by
- Description modified (diff)
comment:2 Changed 3 years ago by
- Cc dimpase added
comment:3 follow-up: ↓ 7 Changed 3 years ago by
comment:4 Changed 3 years ago by
- Cc arojas added
comment:5 Changed 3 years ago by
- Summary changed from barvinok fails to build to barvinok fails to build on Arch with system's NTL
comment:6 Changed 3 years ago by
Yes, this is a bug in ntl, which fails to link to libpthread when built with multi-thread support. It is caused by them using libtool as the build command, which adds -nostdlib to the gcc flags, which in turn overrides the -pthread flag.
I reported this to Victor a long time ago (by private mail since he doesn't use a bug tracker) but hasn't been fixed yet. For a while I was linking it manually as a workaround but I stopped doing it a few releases ago since all official Arch packages that link to ntl were working fine - but this seems to be simply because they link to libpthread themselves so the issue was just being masked.
I've restored the workaroung for now, so this should be fixed on Arch with ntl 11.3.2-2. But it will affect all distros that build ntl multi-threaded unless they apply a similar workaround.
comment:7 in reply to: ↑ 3 Changed 3 years ago by
Replying to dimpase:
Could you post the output of
ldd /usr/lib/libntl.soit seems it's multi-threaded on Arch?
$ ldd /usr/lib/libntl.so linux-vdso.so.1 (0x00007ffd54c8b000) libgmp.so.10 => /usr/lib/libgmp.so.10 (0x00007fb2c0643000) libgf2x.so.1 => /usr/lib/libgf2x.so.1 (0x00007fb2c0626000) libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007fb2c043e000) libm.so.6 => /usr/lib/libm.so.6 (0x00007fb2c02f8000) libc.so.6 => /usr/lib/libc.so.6 (0x00007fb2c0135000) /usr/lib64/ld-linux-x86-64.so.2 (0x00007fb2c09aa000) libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007fb2c011b000)
comment:8 follow-up: ↓ 9 Changed 3 years ago by
If I read comment:6 correctly, you should be able to install an update to NTL that fixes the issue.
comment:9 in reply to: ↑ 8 Changed 3 years ago by
Replying to dimpase:
If I read comment:6 correctly, you should be able to install an update to NTL that fixes the issue.
Yes, I downloaded the latest version pushed by Antonio. However, in the meantime I installed Sage NTL and I have to rebuild everything from scratch... Needs some time before I confirm that this is fixed.
comment:10 Changed 3 years ago by
- Milestone changed from sage-8.9 to sage-duplicate/invalid/wontfix
- Status changed from new to needs_review
This is fixed! Thanks!
comment:11 Changed 3 years ago by
- Reviewers set to Dima Pasechnik
- Status changed from needs_review to positive_review
comment:12 Changed 3 years ago by
For what it's worth I had similar problems linking NTL into eclib. I seem to have solved it but could not possibly explain properly; but looking at eclib's configure setup might help.
comment:13 Changed 3 years ago by
- Resolution set to worksforme
- Status changed from positive_review to closed
ok, so in barvinok-config one sees
which is why it does not build.
Could you post the output of
it seems it's multi-threaded on Arch?
Without
barvinok
, did you run tests for this installation of Sage? If everything works (I hope so), we should fix the configure ofbarvinok
, or perhaps just itsspkg-install
. (It seems it needs to be linked with-lpthread
as well).It could also be that
libntl
is underlinked on Arch...