This is the mail archive of the libc-hacker@cygnus.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Proposed solution for nsswitch.c compilation



AFAIK the compilation of nsswitch.c might fail due to the inlining of
the string functions.  This occurs at least on Alpha and MIPS.  Since
I don't want the bug database filled with glibc 2.1 failure reports
because of nsswitch.c, I propose the following patch.

Could somebody running Linux/Alpha please tell me if this fixes the
problem?

An alternative would be to add the following in an architecture
specific directory for each architecture that has problems:
ifeq ($(subdir),nss)
CFLAGS-nsswitch.c = -D__NO_STRING_INLINES
endif

ix86 doesn't have problems with egcs 1.1.1 and egcs cvs current
(tested myself) but AFAIK Alpha and MIPS (tested myself) fail.  I
don't have any information about other ports.

Ulrich, please add this - or a similiar solution for glibc 2.1 - I
hope we can remove it in 2.2;-).

Andreas

1999-02-01  Andreas Jaeger  <aj@arthur.rhein-neckar.de>

	* nss/Makefile (CFLAGS-nsswitch.c): Added.

--- nss/Makefile.~1~	Sun Nov 29 07:20:05 1998
+++ nss/Makefile	Mon Feb  1 23:37:15 1999
@@ -1,4 +1,4 @@
-# Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
 # This file is part of the GNU C Library.
 
 # The GNU C Library is free software; you can redistribute it and/or
@@ -97,3 +97,9 @@
 # This ensures they will load libc.so for needed symbols if loaded by
 # a statically-linked program that hasn't already loaded it.
 $(services:%=$(objpfx)libnss_%.so): $(common-objpfx)libc.so
+
+# The inlining of string functions in nsswitch.c puts might put so
+# severe stress on the compiler that compilation fails.  Disable the
+# inlining of string functions until a working compiler for all
+# architectures exist
+CFLAGS-nsswitch.c = -D__NO_STRING_INLINES

-- 
 Andreas Jaeger   aj@arthur.rhein-neckar.de    jaeger@informatik.uni-kl.de
  for pgp-key finger ajaeger@aixd1.rhrk.uni-kl.de


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]