This is the mail archive of the glibc-cvs@sourceware.org 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]
Other format: [Raw text]

GNU C Library master sources branch, hjl/abi, updated. glibc-2.15-1035-g27195a4


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, hjl/abi has been updated
       via  27195a4ed7e30d314c6106555f6b382dc0674de5 (commit)
       via  a665a05cb5ddae39db39f50bffa33acc59f49106 (commit)
       via  1d41e78eeac97acdec714e79c4845d9986dd6d83 (commit)
       via  fc933600445ee549605188d32fec713ad9ce11cc (commit)
       via  ffdbc09630f02698e11b4f174f3db360c27c38c1 (commit)
      from  bec9238f1a77ae742201afa46f8eddc94b4d6d08 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=27195a4ed7e30d314c6106555f6b382dc0674de5

commit 27195a4ed7e30d314c6106555f6b382dc0674de5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 23 15:50:27 2012 -0700

    Include $(abi-list-include) only if needed

diff --git a/ChangeLog.abi b/ChangeLog.abi
index f3b2221..aaf7b2f 100644
--- a/ChangeLog.abi
+++ b/ChangeLog.abi
@@ -1,5 +1,18 @@
 2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* Makeconfig (abi-list-includes): Moved to ...
+	* sysdeps/unix/sysv/linux/Makefile: Here.
+	* Makeconfig ($(common-objpfx)gnu/lib-names.stmp): Include
+	$(abi-list-include) only if needed.
+	* shlib-versions: Remove WORDSIZE.
+	* scripts/soversions.awk: Remove WORDSIZE support.
+	* /sysdeps/unix/sysv/linux/i386/Makefile (abi-list-includes):
+	Cleared.
+	* sysdeps/unix/sysv/linux/x86_64/Makefile (abi-list-includes):
+	Likewise.
+
+2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* Makeconfig ($(common-objpfx)soversions.mk): Remove ABI,
 	DEFAULT-ABI and ABI-LIST support
 	($(common-objpfx)gnu/lib-names.stmp): Support alternate library
diff --git a/Makeconfig b/Makeconfig
index af66682..c8b6d48 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -802,10 +802,6 @@ abi-list-default-options :=
 abi-list-default-condition :=
 endif
 
-ifndef abi-list-includes
-abi-list-includes := bits/wordsize.h
-endif
-
 # Process the shlib-versions file, which tells us what shared library
 # version numbers to use when we install shared objects on this system.
 # We need to wait until $(subdirs) is complete.
@@ -865,8 +861,9 @@ $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 	 echo '#ifndef __GNU_LIB_NAMES_H'; \
 	 echo '#define __GNU_LIB_NAMES_H	1'; \
 	 echo ''; \
-	 $(foreach h,$(abi-list-includes), echo '#include <$(h)>';) \
-	 echo ''; \
+	 $(if $(abi-list-includes), \
+	  $(foreach h,$(abi-list-includes), echo '#include <$(h)>';) \
+	  echo '';) \
 	 $(foreach v,$(abi-list-variants),\
 	 $(if $(abi-list-$(v)-condition),\
 	 echo '#if $(abi-list-$(v)-condition)'; \
diff --git a/scripts/soversions.awk b/scripts/soversions.awk
index 0b74182..6f02e68 100644
--- a/scripts/soversions.awk
+++ b/scripts/soversions.awk
@@ -7,17 +7,6 @@ BEGIN {
 
 { thiscf = $1 }
 
-$2 ~ /WORDSIZE[3264]/ {
-  if ((config ~ thiscf) && !othercf) {
-    othercf = $3;
-    sub(/@CPU@/, cpu, othercf);
-    sub(/@VENDOR@/, vendor, othercf);
-    sub(/@OS@/, os, othercf);
-    configs[othercf] = $2;
-  }
-  next;
-}
-
 $2 == "ABI" {
   if ((config ~ thiscf) && !abiname) {
     abiname = $3;
diff --git a/shlib-versions b/shlib-versions
index ca112c2..2a9ffc6 100644
--- a/shlib-versions
+++ b/shlib-versions
@@ -18,11 +18,6 @@
 # library has no third column.  The defaults must precede the entries they
 # apply to.
 #
-# An entry with WORDSIZE* in the second column gives an alternate
-# configuration tuple whose macros will be conditionally defined in
-# gnu/lib-names.h; @CPU@, @VENDOR@, @OS@ can be used in the third
-# column to compose the alternate tuple matched against the patterns here.
-
 # Configuration		DEFAULT			Earliest symbol set
 # -------------		---------------		------------------------------
 
@@ -30,15 +25,6 @@ s390x-.*-linux.*        DEFAULT			GLIBC_2.2
 powerpc64-.*-linux.*	DEFAULT			GLIBC_2.3
 .*-.*-gnu-gnu.*		DEFAULT			GLIBC_2.2.6
 
-# Configuration		WORDSIZE[32|64]		Alternate configuration
-# -------------		----------		-----------------------
-s390x-.*-.*		WORDSIZE32		s390-@VENDOR@-@OS@
-s390-.*-.*		WORDSIZE64		s390x-@VENDOR@-@OS@
-powerpc64-.*-.*		WORDSIZE32		powerpc-@VENDOR@-@OS@
-powerpc.*-.*-.*		WORDSIZE64		powerpc64-@VENDOR@-@OS@
-sparc64.*-.*-.*		WORDSIZE32		sparc-@VENDOR@-@OS@
-sparc.*-.*-.*		WORDSIZE64		sparc64-@VENDOR@-@OS@
-
 # Configuration		ABI			Identifier for ABI data files
 # -------------		----------		-----------------------------
 sparc64.*-.*-.*		ABI			sparc64-@OS@
diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
index 9df165f..db05c9e 100644
--- a/sysdeps/unix/sysv/linux/Makefile
+++ b/sysdeps/unix/sysv/linux/Makefile
@@ -40,6 +40,10 @@ sysdep_headers += sys/mount.h sys/acct.h sys/sysctl.h \
 
 tests += tst-clone
 
+ifndef abi-list-includes
+abi-list-includes := bits/wordsize.h
+endif
+
 # Generate the list of SYS_* macros for the system calls (__NR_* macros).
 $(objpfx)bits/syscall%h $(objpfx)bits/syscall%d: ../sysdeps/unix/sysv/linux/sys/syscall.h
 	$(make-target-directory)
diff --git a/sysdeps/unix/sysv/linux/i386/Makefile b/sysdeps/unix/sysv/linux/i386/Makefile
index 54b18cd..7077d6d 100644
--- a/sysdeps/unix/sysv/linux/i386/Makefile
+++ b/sysdeps/unix/sysv/linux/i386/Makefile
@@ -1,5 +1,8 @@
 default-abi := 32
 
+# We don't need any header files.
+abi-list-includes :=
+
 abi-list-variants := 32 64 x32
 abi-list-32-options := -D__i386__ -U__x86_64__
 abi-list-32-condition := !defined __x86_64__
diff --git a/sysdeps/unix/sysv/linux/x86_64/Makefile b/sysdeps/unix/sysv/linux/x86_64/Makefile
index 72462d7..fbd1df9 100644
--- a/sysdeps/unix/sysv/linux/x86_64/Makefile
+++ b/sysdeps/unix/sysv/linux/x86_64/Makefile
@@ -1,3 +1,6 @@
+# We don't need any header files.
+abi-list-includes :=
+
 abi-list-variants := 32 64 x32
 abi-list-32-options := -D__i386__ -U__x86_64__
 abi-list-32-condition := !defined __x86_64__

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a665a05cb5ddae39db39f50bffa33acc59f49106

commit a665a05cb5ddae39db39f50bffa33acc59f49106
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 23 15:30:11 2012 -0700

    Use abi-list-*-ld-soname

diff --git a/ChangeLog.abi b/ChangeLog.abi
index b3031d8..f3b2221 100644
--- a/ChangeLog.abi
+++ b/ChangeLog.abi
@@ -1,5 +1,27 @@
 2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* Makeconfig ($(common-objpfx)soversions.mk): Remove ABI,
+	DEFAULT-ABI and ABI-LIST support
+	($(common-objpfx)gnu/lib-names.stmp): Support alternate library
+	name.
+	* sysdeps/i386/shlib-versions: Removed.
+	* sysdeps/x86_64/64/shlib-versions: Revert the last change.
+	* sysdeps/unix/sysv/linux/i386/Makefile (default-abi): New macro.
+	(abi-list-variants): Likewise.
+	(abi-list-32-ld-soname): Likewise.
+	(abi-list-64-ld-soname): Likewise.
+	(abi-list-x32-ld-soname): Likewise.
+	* sysdeps/unix/sysv/linux/x86_64/Makefile (abi-list-variants):
+	Restored.
+	(abi-list-32-ld-soname): New macro.
+	(abi-list-64-ld-soname): Likewise.
+	(abi-list-x32-ld-soname): Likewise.
+	* sysdeps/unix/sysv/linux/x86_64/64/Makefile: New file.
+	* sysdeps/unix/sysv/linux/x86_64/x32/Makefile (default-abi): New
+	macro.
+
+2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* sysdeps/unix/sysv/linux/Makefile (abi-list-default-options,
 	abi-list-default-condition, abi-list-includes): Moved to ...
 	* Makeconfig: Here.
diff --git a/Makeconfig b/Makeconfig
index 0f6ee71..af66682 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -834,21 +834,12 @@ $(common-objpfx)soversions.mk: $(common-objpfx)soversions.i $(..)Makeconfig
 	(while read which lib number setname; do \
 	   eval seen_$$which=1; \
 	   test x"$$which" != xABI || echo abi-name = "$$lib"; \
-	   test x"$$which" != xDEFAULT-ABI || echo default-abi = "$$lib"; \
-	   if test x"$$which" == xABI-LIST; then \
-	     echo "abi-list-variants = \$$(subst :, ,$$lib)"; \
-	   fi; \
 	   test x"$$which" = xDEFAULT || continue; \
 	   case $$number in \
 	     [0-9]*) echo "$$lib.so-version=.$$number"; \
 		     echo "all-sonames+=$$lib=$$lib.so\$$($$lib.so-version)";;\
-	     *)	\
-	       case $$number in \
-	       *:*) echo "$$lib-list-variants = \$$(subst :, ,$$number)"; \
-		    echo "$$lib.so-version = \$$(firstword \$$($$lib-list-variants))";; \
-	       *)   echo "$$lib.so-version=$$number";; \
-	       esac; \
-	       echo "all-sonames+=$$lib=\$$($$lib.so-version)";;\
+	     *)	     echo "$$lib.so-version=$$number"; \
+		     echo "all-sonames+=$$lib=\$$($$lib.so-version)";;\
 	   esac; \
 	 done; \
 	 echo soversions.mk-done = t;) < $< > $@T; exit 0
@@ -864,8 +855,6 @@ postclean-generated += soversions.mk soversions.i \
 before-compile += $(common-objpfx)gnu/lib-names.h
 ifeq ($(soversions.mk-done),t)
 $(common-objpfx)gnu/lib-names.h: $(common-objpfx)gnu/lib-names.stmp; @:
-ifeq ($(default-abi),)
-else
 $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 				    $(common-objpfx)soversions.i
 	$(make-target-directory)
@@ -882,8 +871,10 @@ $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 	 $(if $(abi-list-$(v)-condition),\
 	 echo '#if $(abi-list-$(v)-condition)'; \
 	 ($(foreach s,$(all-sonames), \
-	   echo $(s) | LC_ALL=C $(AWK) -v multi=1 -f $(firstword $^);)) \
-	 | LC_ALL=C sort;) \
+	   $(if $(abi-list-$(v)-$(firstword $(subst =, ,$(s)))-soname),\
+	     echo $(firstword $(subst =, ,$(s)))=$(abi-list-$(v)-$(firstword $(subst =, ,$(s)))-soname);, \
+	     echo $(s);))) \
+	 | LC_ALL=C $(AWK) -v multi=1 -f $(firstword $^) | LC_ALL=C sort;) \
 	 $(if $(abi-list-$(v)-condition),echo '#endif';) \
 	 rm -f $(@:.d=.h).new$(v); \
 	 ) \
@@ -893,7 +884,6 @@ $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 	$(move-if-change) ${@:stmp=T} ${@:stmp=h}
 	touch $@
 endif
-endif
 
 common-generated += gnu/lib-names.h gnu/lib-names.stmp
 
diff --git a/sysdeps/i386/shlib-versions b/sysdeps/i386/shlib-versions
deleted file mode 100644
index 7093380..0000000
--- a/sysdeps/i386/shlib-versions
+++ /dev/null
@@ -1,7 +0,0 @@
-# Configuration		DEFAULT							Earliest symbol set
-# -------------		---------------						-------------------
-i.86-.*-linux.*		ld=ld-linux.so.2:ld-linux-x86-64.so.2:ld-linux-x32.so.2
-
-# Configuration		ABI list		Supported ABIs
-# -------------		---------------		-------------------
-i.86-.*-linux.*		ABI-LIST		32:64:x32
diff --git a/sysdeps/unix/sysv/linux/i386/Makefile b/sysdeps/unix/sysv/linux/i386/Makefile
index 1398a36..54b18cd 100644
--- a/sysdeps/unix/sysv/linux/i386/Makefile
+++ b/sysdeps/unix/sysv/linux/i386/Makefile
@@ -1,9 +1,15 @@
+default-abi := 32
+
+abi-list-variants := 32 64 x32
 abi-list-32-options := -D__i386__ -U__x86_64__
 abi-list-32-condition := !defined __x86_64__
+abi-list-32-ld-soname := ld-linux.so.2
 abi-list-64-options := -U__i386__ -D__x86_64__ -U__ILP32__ -D__LP64__
 abi-list-64-condition := defined __x86_64__ && defined __LP64__
+abi-list-64-ld-soname := ld-linux-x86-64.so.2
 abi-list-x32-options := -U__i386__ -D__x86_64__ -D__ILP32__ -U__LP64__
 abi-list-x32-condition := defined __x86_64__ && defined __ILP32__
+abi-list-x32-ld-soname := ld-linux-x32.so.2
 
 ifeq ($(subdir),misc)
 sysdep_routines += ioperm iopl vm86 call_pselect6 call_fallocate
diff --git a/sysdeps/unix/sysv/linux/x86_64/64/Makefile b/sysdeps/unix/sysv/linux/x86_64/64/Makefile
new file mode 100644
index 0000000..c8991d3
--- /dev/null
+++ b/sysdeps/unix/sysv/linux/x86_64/64/Makefile
@@ -0,0 +1 @@
+default-abi := 64
diff --git a/sysdeps/unix/sysv/linux/x86_64/Makefile b/sysdeps/unix/sysv/linux/x86_64/Makefile
index 0c958c2..72462d7 100644
--- a/sysdeps/unix/sysv/linux/x86_64/Makefile
+++ b/sysdeps/unix/sysv/linux/x86_64/Makefile
@@ -1,9 +1,13 @@
+abi-list-variants := 32 64 x32
 abi-list-32-options := -D__i386__ -U__x86_64__
 abi-list-32-condition := !defined __x86_64__
+abi-list-32-ld-soname := ld-linux.so.2
 abi-list-64-options := -U__i386__ -D__x86_64__ -U__ILP32__ -D__LP64__
 abi-list-64-condition := defined __x86_64__ && defined __LP64__
+abi-list-64-ld-soname := ld-linux-x86-64.so.2
 abi-list-x32-options := -U__i386__ -D__x86_64__ -D__ILP32__ -U__LP64__
 abi-list-x32-condition := defined __x86_64__ && defined __ILP32__
+abi-list-x32-ld-soname := ld-linux-x32.so.2
 
 ifeq ($(subdir),misc)
 sysdep_routines += ioperm iopl
diff --git a/sysdeps/unix/sysv/linux/x86_64/x32/Makefile b/sysdeps/unix/sysv/linux/x86_64/x32/Makefile
index aa78238..992e543 100644
--- a/sysdeps/unix/sysv/linux/x86_64/x32/Makefile
+++ b/sysdeps/unix/sysv/linux/x86_64/x32/Makefile
@@ -1,3 +1,5 @@
+default-abi := x32
+
 ifeq ($(subdir),misc)
 sysdep_routines += arch_prctl
 endif
diff --git a/sysdeps/x86_64/64/shlib-versions b/sysdeps/x86_64/64/shlib-versions
index de83ed2..c797487 100644
--- a/sysdeps/x86_64/64/shlib-versions
+++ b/sysdeps/x86_64/64/shlib-versions
@@ -1,8 +1,4 @@
-# Configuration		DEFAULT							Earliest symbol set
-# -------------		---------------						-------------------
-x86_64-.*-linux.*	DEFAULT							GLIBC_2.2.5
-x86_64-.*-linux.*	ld=ld-linux-x86-64.so.2:ld-linux.so.2:ld-linux-x32.so.2	GLIBC_2.2.5
-
-# Configuration		ABI list		Supported ABIs
-# -------------		---------------		-------------------
-x86_64-.*-linux.*	ABI-LIST		64:32:x32
+# Configuration		DEFAULT			Earliest symbol set
+# -------------		---------------		------------------------------
+x86_64-.*-linux.*	DEFAULT			GLIBC_2.2.5
+x86_64-.*-linux.*	ld=ld-linux-x86-64.so.2	GLIBC_2.2.5

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=1d41e78eeac97acdec714e79c4845d9986dd6d83

commit 1d41e78eeac97acdec714e79c4845d9986dd6d83
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 23 13:35:58 2012 -0700

    Move abi-list-*  Makeconfig

diff --git a/ChangeLog.abi b/ChangeLog.abi
index e34ecb2..b3031d8 100644
--- a/ChangeLog.abi
+++ b/ChangeLog.abi
@@ -1,5 +1,11 @@
 2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* sysdeps/unix/sysv/linux/Makefile (abi-list-default-options,
+	abi-list-default-condition, abi-list-includes): Moved to ...
+	* Makeconfig: Here.
+
+2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* Makeconfig ($(common-objpfx)gnu/lib-names.stmp): Generate
 	from abi-list-variants.
 	* Makefile ($(inst_includedir)/gnu/stubs.h): Mention it is
@@ -33,7 +39,7 @@
 	(abi-list-default-options): This.
 	(syscall-list-default-condition): Renamed to ...
 	(abi-list-default-condition): This.
-	(abi-list-includes): Renamed to ...
+	(syscall-list-includes): Renamed to ...
 	(abi-list-includes): This.
 	($(objpfx)bits/syscall%h $(objpfx)bits/syscall%d): Updated.
 	* sysdeps/unix/sysv/linux/x86_64/Makefile (syscall-list-variants):
diff --git a/Makeconfig b/Makeconfig
index 5501d75..0f6ee71 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -787,6 +787,25 @@ ifeq (yes, $(build-shared))
 	sed '/^[ 	]*#/d;/^[ 	]*$$/d' $< > $@T
 	mv -f $@T $@
 
+# If there is more than one syscall list for different architecture
+# variants, the CPU/shlib-versions should have an ABI-LIST entry with a
+# list of names for those variants, separated by `:', (e.g. 32:64), and,
+# for each variant, defines abi-list-$(variant)-options to be compiler
+# options to cause <asm/unistd.h> to define the desired list of
+# syscalls and abi-list-$(variant)-condition to be the condition
+# for those options to use in a C #if condition.
+# syscall-list-includes may be defined to a list of headers to include
+# in the generated header, if the default does not suffice.
+
+ifndef abi-list-variants
+abi-list-default-options :=
+abi-list-default-condition :=
+endif
+
+ifndef abi-list-includes
+abi-list-includes := bits/wordsize.h
+endif
+
 # Process the shlib-versions file, which tells us what shared library
 # version numbers to use when we install shared objects on this system.
 # We need to wait until $(subdirs) is complete.
@@ -868,6 +887,7 @@ $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 	 $(if $(abi-list-$(v)-condition),echo '#endif';) \
 	 rm -f $(@:.d=.h).new$(v); \
 	 ) \
+	 echo ''; \
 	 echo '#endif	/* gnu/lib-names.h */'; \
 	} >  ${@:stmp=T}
 	$(move-if-change) ${@:stmp=T} ${@:stmp=h}
diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
index a012576..9df165f 100644
--- a/sysdeps/unix/sysv/linux/Makefile
+++ b/sysdeps/unix/sysv/linux/Makefile
@@ -41,26 +41,6 @@ sysdep_headers += sys/mount.h sys/acct.h sys/sysctl.h \
 tests += tst-clone
 
 # Generate the list of SYS_* macros for the system calls (__NR_* macros).
-
-# If there is more than one syscall list for different architecture
-# variants, the CPU/shlib-versions should have an ABI-LIST entry with a
-# list of names for those variants, separated by `:', (e.g. 32:64), and,
-# for each variant, defines abi-list-$(variant)-options to be compiler
-# options to cause <asm/unistd.h> to define the desired list of
-# syscalls and abi-list-$(variant)-condition to be the condition
-# for those options to use in a C #if condition.
-# syscall-list-includes may be defined to a list of headers to include
-# in the generated header, if the default does not suffice.
-
-ifndef abi-list-variants
-abi-list-default-options :=
-abi-list-default-condition :=
-endif
-
-ifndef abi-list-includes
-abi-list-includes := bits/wordsize.h
-endif
-
 $(objpfx)bits/syscall%h $(objpfx)bits/syscall%d: ../sysdeps/unix/sysv/linux/sys/syscall.h
 	$(make-target-directory)
 	{ \

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=fc933600445ee549605188d32fec713ad9ce11cc

commit fc933600445ee549605188d32fec713ad9ce11cc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 23 13:30:39 2012 -0700

    Add abi-list-variants support to gnu/lib-names.h

diff --git a/ChangeLog.abi b/ChangeLog.abi
index 7f2d65a..e34ecb2 100644
--- a/ChangeLog.abi
+++ b/ChangeLog.abi
@@ -1,5 +1,13 @@
 2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* Makeconfig ($(common-objpfx)gnu/lib-names.stmp): Generate
+	from abi-list-variants.
+	* Makefile ($(inst_includedir)/gnu/stubs.h): Mention it is
+	automatically generated.
+	* scripts/lib-names.awk: Only handle one library at a time.
+
+2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* sysdeps/unix/sysv/linux/i386/Makefile (abi-list-32-options):
 	New macro.
 	(abi-list-32-condition): Likewise.
diff --git a/Makeconfig b/Makeconfig
index 7bb774e..5501d75 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -845,14 +845,35 @@ postclean-generated += soversions.mk soversions.i \
 before-compile += $(common-objpfx)gnu/lib-names.h
 ifeq ($(soversions.mk-done),t)
 $(common-objpfx)gnu/lib-names.h: $(common-objpfx)gnu/lib-names.stmp; @:
+ifeq ($(default-abi),)
+else
 $(common-objpfx)gnu/lib-names.stmp: $(..)scripts/lib-names.awk \
 				    $(common-objpfx)soversions.i
 	$(make-target-directory)
-	@rm -f ${@:stmp=T} $@
-	LC_ALL=C $(AWK) -f $^ > ${@:stmp=T}
+	{ \
+	 echo '/* This file is automatically generated.';\
+	 echo '   It defines macros to allow user program to find the shared'; \
+	 echo '   library files which come as part of GNU libc.  */'; \
+	 echo '#ifndef __GNU_LIB_NAMES_H'; \
+	 echo '#define __GNU_LIB_NAMES_H	1'; \
+	 echo ''; \
+	 $(foreach h,$(abi-list-includes), echo '#include <$(h)>';) \
+	 echo ''; \
+	 $(foreach v,$(abi-list-variants),\
+	 $(if $(abi-list-$(v)-condition),\
+	 echo '#if $(abi-list-$(v)-condition)'; \
+	 ($(foreach s,$(all-sonames), \
+	   echo $(s) | LC_ALL=C $(AWK) -v multi=1 -f $(firstword $^);)) \
+	 | LC_ALL=C sort;) \
+	 $(if $(abi-list-$(v)-condition),echo '#endif';) \
+	 rm -f $(@:.d=.h).new$(v); \
+	 ) \
+	 echo '#endif	/* gnu/lib-names.h */'; \
+	} >  ${@:stmp=T}
 	$(move-if-change) ${@:stmp=T} ${@:stmp=h}
 	touch $@
 endif
+endif
 
 common-generated += gnu/lib-names.h gnu/lib-names.stmp
 
diff --git a/Makefile b/Makefile
index 0bae20b..e1a1995 100644
--- a/Makefile
+++ b/Makefile
@@ -178,7 +178,8 @@ installed-stubs = $(inst_includedir)/gnu/stubs-$(default-abi).h
 $(inst_includedir)/gnu/stubs.h: $(common-objpfx)soversions.mk $(+force)
 	$(make-target-directory)
 	{ \
-	 echo "/* This file selects the right generated file of \`__stub_FUNCTION' macros";\
+	 echo '/* This file is automatically generated.';\
+	 echo "   This file selects the right generated file of \`__stub_FUNCTION' macros";\
 	 echo '   based on the architecture being compiled for.  */'; \
 	 echo ''; \
 	 $(foreach h,$(abi-list-includes), echo '#include <$(h)>';) \
diff --git a/scripts/lib-names.awk b/scripts/lib-names.awk
index 77e6668..ccb7b7f 100644
--- a/scripts/lib-names.awk
+++ b/scripts/lib-names.awk
@@ -1,18 +1,17 @@
 # awk script for soversions.i -> gnu/lib-names.h; see Makeconfig.
 
-$1 != "DEFAULT" { multi = 1 }
-
 #
 {
-  lib = $2;
-  version = $3;
-  if ($3 !~ /^[0-9]/) {
-    soname = $3;
-    extra = $3;
+  split($1, fields, "=")
+  lib = fields[1];
+  soname = version = fields[2];
+  sub(/^.*=/, "", soname);
+  sub(/^lib.*\.so\./, "", version);
+  if ($soname !~ /^lib/) {
+    extra = soname;
     sub(/\.so.*$/, "", extra);
   }
   else {
-    soname = lib ".so." $3;
     extra = "";
   }
   soname = "\"" soname "\"";
@@ -26,41 +25,9 @@ $1 != "DEFAULT" { multi = 1 }
 }
 
 END {
-  print "/* This file is automatically generated.";
-  print "   It defines macros to allow user program to find the shared";
-  print "   library files which come as part of GNU libc.  */";
-  print "#ifndef __GNU_LIB_NAMES_H";
-  print "#define __GNU_LIB_NAMES_H	1";
-  print "";
-
-  pfx = multi ? "# define " : "#define ";
   for (elt in macros) {
     split(elt, x);
-    line = sprintf("%-40s%s", pfx x[2], macros[elt]);
-    if (x[1] in lines)
-      lines[x[1]] = lines[x[1]] "\n" line;
-    else
-      lines[x[1]] = line;
-  }
-
-  if (multi) {
-    # Print these in a fixed order so the result is identical
-    # on both sides of the coin.
-    if (!("WORDSIZE32" in lines))
-      lines["WORDSIZE32"] = lines["DEFAULT"];
-    if (!("WORDSIZE64" in lines))
-      lines["WORDSIZE64"] = lines["DEFAULT"];
-    print "#include <bits/wordsize.h>\n";
-    print "#if __WORDSIZE == 32";
-    cmd = "LC_ALL=C sort"; print lines["WORDSIZE32"] | cmd; close(cmd);
-    print "#else"
-    cmd = "LC_ALL=C sort"; print lines["WORDSIZE64"] | cmd; close(cmd);
-    print "#endif";
+    pfx = multi ? "# define " : "#define ";
+    printf("%-40s%s\n", pfx x[2], macros[elt]);
   }
-  else {
-    cmd = "LC_ALL=C sort"; print lines["DEFAULT"] | cmd; close(cmd);
-  }
-
-  print "";
-  print "#endif	/* gnu/lib-names.h */"
 }

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=ffdbc09630f02698e11b4f174f3db360c27c38c1

commit ffdbc09630f02698e11b4f174f3db360c27c38c1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 23 11:54:45 2012 -0700

    Add abi-list support to i386 Makefile

diff --git a/ChangeLog.abi b/ChangeLog.abi
index 61da8e7..7f2d65a 100644
--- a/ChangeLog.abi
+++ b/ChangeLog.abi
@@ -1,5 +1,15 @@
 2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* sysdeps/unix/sysv/linux/i386/Makefile (abi-list-32-options):
+	New macro.
+	(abi-list-32-condition): Likewise.
+	(abi-list-64-options): Likewise.
+	(abi-list-64-condition): Likewise.
+	(abi-list-x32-options): Likewise.
+	(abi-list-x32-condition): Likewise.
+
+2012-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* Makeconfig ($(common-objpfx)soversions.mk): Remove WORDSIZE
 	check.  Support ABI, DEFAULT-ABI and ABI-LIST.
 	* Makefile (installed-stubs): Generate from abi-list-variants.
diff --git a/sysdeps/unix/sysv/linux/i386/Makefile b/sysdeps/unix/sysv/linux/i386/Makefile
index fc5a524..1398a36 100644
--- a/sysdeps/unix/sysv/linux/i386/Makefile
+++ b/sysdeps/unix/sysv/linux/i386/Makefile
@@ -1,3 +1,10 @@
+abi-list-32-options := -D__i386__ -U__x86_64__
+abi-list-32-condition := !defined __x86_64__
+abi-list-64-options := -U__i386__ -D__x86_64__ -U__ILP32__ -D__LP64__
+abi-list-64-condition := defined __x86_64__ && defined __LP64__
+abi-list-x32-options := -U__i386__ -D__x86_64__ -D__ILP32__ -U__LP64__
+abi-list-x32-condition := defined __x86_64__ && defined __ILP32__
+
 ifeq ($(subdir),misc)
 sysdep_routines += ioperm iopl vm86 call_pselect6 call_fallocate
 sysdep_headers += sys/elf.h sys/perm.h sys/reg.h sys/vm86.h sys/debugreg.h sys/io.h

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog.abi                               |   61 ++++++++++++++++++++++++++-
 Makeconfig                                  |   54 ++++++++++++++++++------
 Makefile                                    |    3 +-
 scripts/lib-names.awk                       |   51 ++++------------------
 scripts/soversions.awk                      |   11 -----
 shlib-versions                              |   14 ------
 sysdeps/i386/shlib-versions                 |    7 ---
 sysdeps/unix/sysv/linux/Makefile            |   18 +-------
 sysdeps/unix/sysv/linux/i386/Makefile       |   16 +++++++
 sysdeps/unix/sysv/linux/x86_64/64/Makefile  |    1 +
 sysdeps/unix/sysv/linux/x86_64/Makefile     |    7 +++
 sysdeps/unix/sysv/linux/x86_64/x32/Makefile |    2 +
 sysdeps/x86_64/64/shlib-versions            |   12 ++----
 13 files changed, 143 insertions(+), 114 deletions(-)
 delete mode 100644 sysdeps/i386/shlib-versions
 create mode 100644 sysdeps/unix/sysv/linux/x86_64/64/Makefile


hooks/post-receive
-- 
GNU C Library master sources


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