This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.
Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
I'd like to commit the following change to configure.in, which has to effect of making the linuxthreads add-on bring sysdeps/pthread from the main source directory into the list of sysdeps dirs searched. A simpler feature like just add-on/Implies would suffice for this case, but it seems generally useful to have sysdeps in the main source directory that is used only in some configurations and let the set of add-ons constitute another axis multiplied by the configuration tuple to choose the final set. For example, there could be a sysdeps subdir in the main source that contains code that's optimal if you have the foo facility and won't work if you don't have the foo facility. A particular add-on might provide the foo facility only on certain configurations (i.e. machine/OS combinations), and so would express with the file add-on/sysdeps/someos/somecpu/Implies containing "foo". It then becomes a degenerate case of this for any add-on to supply an add-on/sysdeps/generic/Implies file for the add-on-wide Implies. I then want to move most of the aio_*.c code from rt/ to sysdeps/pthread/ and add sysdeps/generic/ stub files. By convention, aio.h would also be split into bits/aio.h, but I'm not doing that since in fact I would like to keep the aio.h part of the ABI the same across configurations. For that reason, I'm not moving aio_error and aio_return.c, which are just structure accessors. The reason I'm doing this is because the aio routines have natural implementations not using threads on some systems (like the Hurd). POSIX.1 makes it meaningful to support _POSIX_ASYNCHRONOUS_IO (i.e. aio.h) without supporting _POSIX_THREADS (you just can't use SIGEV_THREAD) or _POSIX_REALTIME_SIGNALS (you just get plain signals for SIGEV_SIGNAL). That's what I plan to do for the Hurd in the near term. At any rate, even once we have pthreads for the Hurd, the Hurd-specific implementation will be preferable to one based on pthreads, so the aio code should be sysdeps. I see no reason not to build librt in the absence of libpthread, even if it is just built full of stubs, so I plan to make that change. (The only reason it fails to build if you try it now is because there are no aio_* stubs, only code that requires pthread.h to compile. There are stub sources for all the other routines in librt. In fact, several routines from shm_* and clock_* already have implementations that don't require pthreads.) Is all this OK? Note that this does permute slightly the sysdeps list you wind up with. I have not checked meticulously to be sure that it has not changed which sources get compiled in practice, but I don't think it has. 2001-06-14 Roland McGrath <roland@frob.com> * configure.in: Let sysdeps Implies files in add-ons bring in sysdeps directories from the main source and other add-ons too. Index: configure.in =================================================================== RCS file: /cvs/glibc/libc/configure.in,v retrieving revision 1.317 diff -u -b -p -r1.317 configure.in --- configure.in 2001/06/13 08:05:26 1.317 +++ configure.in 2001/06/14 19:59:07 @@ -495,9 +495,25 @@ while test $# -gt 0; do implied_candidate="`sed 's/#.*$//' < $xsrcdir$name/Implies`" implied= for x in $implied_candidate; do + found=no if test -d $xsrcdir$name_base/$x; then implied="$implied $name_base/$x"; - else + found=yes + fi + for d in $add_ons_pfx ''; do + try="${d}sysdeps/$x" + case $d in + /*) try_srcdir= ;; + *) try_srcdir=$srcdir/ ;; + esac + test -n "$enable_debug_configure" && + echo "[DEBUG]: $name implied $x try($d) {$try_srcdir}$try" >&2 + if test $try != $xsrcdir$name_base/$x && test -d $try_srcdir$try; then + implied="$implied $try" + found=yes + fi + done + if test $found = no; then AC_MSG_WARN($name/Implies specifies nonexistent $x) fi done
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |