From 717de822dcc29cc7f34e7c94e63b3f4cf572f470 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Thu, 5 Aug 2004 03:46:43 +0000 Subject: [PATCH] 2004-08-04 Roland McGrath New directory implementing glibc add-on infrastructure for ports maintained separate from the core glibc source tree. * README, configure.in, Makeconfig, Banner, ChangeLog: New files. * configure: New generated file. --- Banner | 1 + ChangeLog | 6 ++++++ Makeconfig | 35 +++++++++++++++++++++++++++++++++++ README | 39 +++++++++++++++++++++++++++++++++++++++ configure | 17 +++++++++++++++++ configure.in | 17 +++++++++++++++++ 6 files changed, 115 insertions(+) create mode 100644 Banner create mode 100644 ChangeLog create mode 100644 Makeconfig create mode 100644 README create mode 100755 configure create mode 100644 configure.in diff --git a/Banner b/Banner new file mode 100644 index 0000000..6b9c1f0 --- /dev/null +++ b/Banner @@ -0,0 +1 @@ +Support for some architectures added on, not maintained in glibc core. diff --git a/ChangeLog b/ChangeLog new file mode 100644 index 0000000..efaee34 --- /dev/null +++ b/ChangeLog @@ -0,0 +1,6 @@ +2004-08-04 Roland McGrath + + New directory implementing glibc add-on infrastructure for + ports maintained separate from the core glibc source tree. + * README, configure.in, Makeconfig, Banner, ChangeLog: New files. + * configure: New generated file. diff --git a/Makeconfig b/Makeconfig new file mode 100644 index 0000000..20a0f08 --- /dev/null +++ b/Makeconfig @@ -0,0 +1,35 @@ +# Makeconfig fragment for glibc ports add-on. + +# These rules make sure that sysdeps/CPU/preconfigure changes are noticed. +# preconfigure fragments can be written by hand, or they can be generated +# from preconfigure.in by autoconf like sysdeps/.../configure.in files. + +# Figure out the name of this add-on. The ports add-on infrastructure +# scripts can be copied into separate add-on packages by any name. +ports-sysdeps = $(..)$(Makeconfig-add-on)/sysdeps + +$(common-objpfx)config.status: $(wildcard $(ports-sysdeps)/*/preconfigure) + +ifneq ($(AUTOCONF),no) + +ifeq ($(with-cvs),yes) +define autoconf-it-cvs +test ! -d CVS || cvs $(CVSOPTS) commit -m'Regenerated: autoconf $(ACFLAGS) $<' $@ +endef +else +autoconf-it-cvs = +endif + +define autoconf-it +@-rm -f $@.new +$(AUTOCONF) $(ACFLAGS) $< > $@.new +chmod a-w,a+x $@.new +mv -f $@.new $@ +$(autoconf-it-cvs) +endef + +$(..)ports/sysdeps/%/preconfigure: $(..)ports/sysdeps/%/preconfigure.in \ + aclocal.m4 + $(autoconf-it) + +endif # $(AUTOCONF) = no diff --git a/README b/README new file mode 100644 index 0000000..8e416b7 --- /dev/null +++ b/README @@ -0,0 +1,39 @@ +This directory is an add-on for the GNU C Library (glibc). +It provides additional ports to machines and/or operating systems that are +not maintained in the official glibc source tree. + +The scripts in the top level of this directory provide the infrastructure +necessary for a glibc add-on. You can make a new add-on containing one or +more ports by copying configure, configure.in, and Makeconfig into your own +add-on directory, which you can give any name (it doesn't have to be +`ports'). You may want to include a README and Banner of your own talking +about your port's code in particular, rather than the generic ones here. + +The real source code for any ports is found in the sysdeps/ subdirectories. +These should be exactly what would go into the main libc source tree if you +were to incorporate it directly. The only exceptions are the files +sysdeps/*/preconfigure and sysdeps/*/preconfigure.in; these are fragments +used by this add-on's configure fragment. The purpose of these is to set +$base_machine et al when the main libc configure's defaults are not right +for some machine. Everything else can and should be done from a normal +sysdeps/.../configure fragment that is used only when the configuration +selects that sysdeps subdirectory. Each port that requires some special +treatment before the sysdeps directory list is calculated, should add a +sysdeps/CPU/preconfigure file; this can either be written by hand or +generated by Autoconf from sysdeps/CPU/preconfigure.in, and follow the +rules for glibc add-on configure fragments. No preconfigure file should do +anything on an unrelated configuration, so that disparate ports can be put +into a single add-on without interfering with each other. + +Like all glibc add-ons, the only way to use this is to place this directory +(just a symlink won't do) inside the top-level glibc source directory. +Then include the name of this directory (e.g. `ports') when you specify +`--enable-add-ons=...' to glibc's configure (or use just --enable-add-ons +to have it try every add-on directory sitting in your source tree). + +If you find problems with the top-level scripts in this add-on, please go +to http://sources.redhat.com/bugzilla/ and file a report for the glibc +under the "admin" component. + + +$Id$ diff --git a/configure b/configure new file mode 100755 index 0000000..e90ab67 --- /dev/null +++ b/configure @@ -0,0 +1,17 @@ +# This file is generated from configure.in by Autoconf. DO NOT EDIT! + +# The configure fragment in this file provides infrastructure for a glibc +# add-on containing one or more glibc ports. Only these few script files +# need exist in the top-level source directory of the add-on. The ports +# themselves are contained entirely within their new sysdeps/ directories. +# This makes it easy to take these few top-level files plus a new port's +# additions to the sysdeps tree, and package a small add-on for that port. +# The same infrastructure scripts work for any number of such glibc ports +# collected together into a single shared add-on package. + +cpu_frags=`(cd $srcdir/$libc_add_on; echo sysdeps/*/preconfigure)` +for frag in $cpu_frags; do + echo "$as_me:$LINENO: result: ports add-on running preconfigure fragment $frag" >&5 +echo "${ECHO_T}ports add-on running preconfigure fragment $frag" >&6 + . $srcdir/$libc_add_on/$frag +done diff --git a/configure.in b/configure.in new file mode 100644 index 0000000..d37cb8d --- /dev/null +++ b/configure.in @@ -0,0 +1,17 @@ +dnl glibc add-on configure.in fragment for a ports add-on. +GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. + +# The configure fragment in this file provides infrastructure for a glibc +# add-on containing one or more glibc ports. Only these few script files +# need exist in the top-level source directory of the add-on. The ports +# themselves are contained entirely within their new sysdeps/ directories. +# This makes it easy to take these few top-level files plus a new port's +# additions to the sysdeps tree, and package a small add-on for that port. +# The same infrastructure scripts work for any number of such glibc ports +# collected together into a single shared add-on package. + +cpu_frags=`(cd $srcdir/$libc_add_on; echo sysdeps/*/preconfigure)` +for frag in $cpu_frags; do + AC_MSG_RESULT(ports add-on running preconfigure fragment $frag) + . $srcdir/$libc_add_on/$frag +done -- 2.7.4