On 04/21/2015 02:22 PM, Volker Braun wrote: > +1 to moving as much as possible into the individual pyx file and away > from a global module_list.py
Yes, planned since years, but we cannot handle e.g. OS-specific stuff there, AFAIK. > Can't we test for underlinking using ldd / readelf on linux? I'm sure > somebody has written a solution for that. Documenting is nice, but > testing is better. If the dependencies are correct, I think we can add needed libraries automatically (perhaps with a bit manual tweaking). -leif > On Tuesday, April 21, 2015 at 4:00:30 AM UTC-4, Jean-Pierre Flori wrote: > > Dear all, > > It seems we're shifting from the original way we were building > Cython extensions where each extension was listed in module_list.py > to use wildcards in module_list.py. > See #7987 and #15410 for wide coverage tickets, and e.g. #17767 for > more focused ones. > > This is problematic when some file need special linking or should > only be optionally compiled. > The latter matter was in part dealt with in #18145. > For both one the solution is then to explicitly list the problematic > files in module_list.py (on top of the wildcard stuff), or to add > cython directives in the file itself. > That is what was done in #17962. > > Should progressively convert all files in this direction? > That is put Cython directives for linking, including C files and so > on, at the top of the pyx file? > And uses as many wildcards as possible in module_list.py? > If we do so, we definitely need to update the doc at > http://www.sagemath.org/doc/developer/coding_in_cython.html > <http://www.sagemath.org/doc/developer/coding_in_cython.html>. > > I also take this opportunity to remember everyone that underlinking > is bad. > Linux is nice enough not to complain at compile time, but some other > platforms do. > In particular many extensions use functions from GMP (recently lots > of files in coding theory and graph theory) but did not list gmp in > the libraries to link to. > That would be another thing to add to the doc. > > Best, > JP -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.