Hints after ./configure: maybe sort and remove duplicates

36 views
Skip to first unread message

Samuel Lelièvre

unread,
Mar 28, 2020, 11:03:14 PM3/28/20
to Sage-devel
Dear sage-devel

After running ./configure there is a hint on SPKGs
for which no equivalent system package was found.
I find this wonderful by the way.

In my case I got:

"""
Hint: The following SPKGs did not find equivalent system packages:
arb boost boost_cropped cbc curl eclib flint fplll gf2x gfan
givaro glpk gp2c gsl isl lcalc libatomic_ops libsemigroups
m4ri m4rie mpc mpfi mpfr ntl openblas pari pari_elldata
pari_galdata pari_galpol pari_nftables pari_seadata
pari_seadata_small r zeromq
"""

This is followed by a recommendation to install those packages.

In my case I got:

"""
Hint: installing the following system packages is recommended
and may avoid building some of the above SPKGs from source:
$ sudo apt-get install libflint-arb-dev libboost-dev libboost-dev
coinor-cbc coinor-libcbc-dev curl libcurl4-openssl-dev libec-dev
libflint-dev libgf2x-dev gfan libgivaro-dev glpk-utils libglpk-dev
pari-gp2c libgsl-dev libisl-dev lcalc liblfunction-dev libm4rie-dev
libmpc-dev libmpfi-dev libmpfr-dev libntl-dev libopenblas-dev
pari-gp2c libpari-dev pari-doc pari-elldata pari-galdata pari-galpol
pari-seadata r-base-dev libzmq3-dev
After installation, re-run configure with:
$ ./config.status --recheck && ./config-status
"""

I notice that there are some duplicates, sometimes far apart.

I am guessing this is due to adding dependencies to packages
that need them... However the end result could take a round
of sorting and removing duplicates.

I suppose this should be done in `m4/sage_spkg_collect.m4`,
if people agree about doing it.

In Python that would be achieved by

system_packages = sorted(set(system_packages))

but I don't know what one would write in a `.m4` script.

Kind regards. --Samuel

Matthias Koeppe

unread,
Mar 28, 2020, 11:22:26 PM3/28/20
to sage-devel
Yes, that's a good idea. This code is still rather primitive, and contributions are very welcome.

The m4 script is really just shell code in disguise. SYSTEM_PACKAGES is a shell variable, and you could use something like "sort -u" to process it.

I have a task ticket that lists several directions of improvement of this code related to system packages:






 
Reply all
Reply to author
Forward
0 new messages