[PATCH] ada: c++: Get rid of libposix4, librt on Solaris
Rainer Orth
ro@CeBiTec.Uni-Bielefeld.DE
Tue Nov 17 09:47:01 GMT 2020
I recently noticed that neither libposix4 nor librt are needed on
Solaris 11 any longer:
* libposix4 was renamed to librt in Solaris 7 back in 1998.
* librt was folded into libc in the OpenSolaris timeframe, leaving librt
only as a filter on libc. Thus, it's no longer needed on either
Solaris 11 or Illumos.
The following patch removes both uses. At the same time, Ada's use of
libthread has gone: it was folded into libc in Solaris 10 already.
TIME_LIBRARY and friends in g++ are likewise removed: Solaris was the
only user.
Bootstrapped without regressions on i386-pc-solaris2.11,
sparc-sun-solaris2.11, and x86_64-pc-linux-gnu.
Ok for master?
There are two more uses of librt left:
* On glibc targets before 2.17 it's needed for clock_gettime. I've no
idea how long gcc is supposed to support such targets (glibc 2.17 was
released in December 2012).
* On HP-UX, it is needed for sem_init in libgomp and various specs for
-fopenmp etc. There are no public HP-UX systems in the compile farm,
and the sem_init(2) man page in the public docs on hpe.com was just a
dangling link, so I cannot tell if this is still true.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
2020-11-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
gcc/cp:
* g++spec.c (TIMELIB, TIME_LIBRARY): Remove.
(lang_specific_driver): Remove TIME_LIBRARY handling.
gcc:
* config/sol2.h (TIME_LIBRARY): Remove.
libstdc++-v3:
* acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Remove libposix4
references.
<solaris*>: Don't use -lrt any longer.
* configure: Regenerate.
* doc/xml/manual/configure.xml (--enable-libstdcxx-time=OPTION):
Remove libposix4 reference.
gcc/ada:
* Makefile.rtl <sparc*-sun-solaris*> (THREADSLIB): Remove.
(MISCLIB): Remove -lposix4.
<*86-*-solaris2*>: Likewise.
* libgnarl/s-osinte__solaris.ads (System.OS_Interface): Remove
-lposix4 -lthread.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sol2-no-libposix4-librt.patch
Type: text/x-patch
Size: 6870 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/libstdc++/attachments/20201117/283905ce/attachment-0001.bin>
More information about the Libstdc++
mailing list