|
|
00db10 |
# commit 1695c7737655241e1773bdddc93e82c22d8d1584
|
|
|
00db10 |
# Author: Adhemerval Zanella <azanella@linux.vnet.ibm.com>
|
|
|
00db10 |
# Date: Tue Feb 4 09:48:47 2014 -0200
|
|
|
00db10 |
#
|
|
|
00db10 |
# abilist-pattern configurability
|
|
|
00db10 |
#
|
|
|
00db10 |
# This patch creates implicit rules to match the abifiles if
|
|
|
00db10 |
# abilist-pattern is defined in the architecture Makefile. This allows
|
|
|
00db10 |
# machine specific Makefiles to define different abifiles names
|
|
|
00db10 |
# (for instance *-le.abilist for powerpc64le).
|
|
|
00db10 |
#
|
|
|
00db10 |
diff -urN glibc-2.17-c758a686/Makerules glibc-2.17-c758a686/Makerules
|
|
|
00db10 |
--- glibc-2.17-c758a686/Makerules 2014-06-02 15:29:42.000000000 +0000
|
|
|
00db10 |
+++ glibc-2.17-c758a686/Makerules 2014-06-02 15:25:21.000000000 +0000
|
|
|
00db10 |
@@ -1152,6 +1152,14 @@
|
|
|
00db10 |
LC_ALL=C $(OBJDUMP) --dynamic-syms $< > $@T
|
|
|
00db10 |
mv -f $@T $@
|
|
|
00db10 |
|
|
|
00db10 |
+# A sysdeps/.../Makefile can set abilist-pattern to something like
|
|
|
00db10 |
+# %-foo.abilist to look for libc-foo.abilist instead of libc.abilist.
|
|
|
00db10 |
+# This makes sense if multiple ABIs can be most cleanly supported by a
|
|
|
00db10 |
+# configuration without using separate sysdeps directories for each.
|
|
|
00db10 |
+ifdef abilist-pattern
|
|
|
00db10 |
+vpath $(abilist-pattern) $(+sysdep_dirs)
|
|
|
00db10 |
+endif
|
|
|
00db10 |
+
|
|
|
00db10 |
vpath %.abilist $(+sysdep_dirs)
|
|
|
00db10 |
|
|
|
00db10 |
# The .PRECIOUS rule prevents the files built by an implicit rule whose
|
|
|
00db10 |
@@ -1161,18 +1169,42 @@
|
|
|
00db10 |
.PRECIOUS: %.symlist
|
|
|
00db10 |
generated += $(extra-libs:=.symlist)
|
|
|
00db10 |
|
|
|
00db10 |
+ifdef abilist-pattern
|
|
|
00db10 |
+check-abi-%: $(common-objpfx)config.make $(abilist-pattern) $(objpfx)%.symlist
|
|
|
00db10 |
+ $(check-abi-pattern)
|
|
|
00db10 |
+check-abi-%: $(common-objpfx)config.make $(abilist-pattern) \
|
|
|
00db10 |
+ $(common-objpfx)%.symlist
|
|
|
00db10 |
+ $(check-abi-pattern)
|
|
|
00db10 |
+endif
|
|
|
00db10 |
check-abi-%: $(common-objpfx)config.make %.abilist $(objpfx)%.symlist
|
|
|
00db10 |
$(check-abi)
|
|
|
00db10 |
check-abi-%: $(common-objpfx)config.make %.abilist $(common-objpfx)%.symlist
|
|
|
00db10 |
$(check-abi)
|
|
|
00db10 |
+define check-abi-pattern
|
|
|
00db10 |
+ diff -p -U 0 $(filter $(abilist-pattern),$^) $(filter %.symlist,$^)
|
|
|
00db10 |
+endef
|
|
|
00db10 |
define check-abi
|
|
|
00db10 |
diff -p -U 0 $(filter %.abilist,$^) $(filter %.symlist,$^)
|
|
|
00db10 |
endef
|
|
|
00db10 |
|
|
|
00db10 |
+ifdef abilist-pattern
|
|
|
00db10 |
+update-abi-%: $(objpfx)%.symlist $(abilist-pattern)
|
|
|
00db10 |
+ $(update-abi-pattern)
|
|
|
00db10 |
+update-abi-%: $(common-objpfx)%.symlist $(abilist-pattern)
|
|
|
00db10 |
+ $(update-abi-pattern)
|
|
|
00db10 |
+endif
|
|
|
00db10 |
update-abi-%: $(objpfx)%.symlist %.abilist
|
|
|
00db10 |
$(update-abi)
|
|
|
00db10 |
update-abi-%: $(common-objpfx)%.symlist %.abilist
|
|
|
00db10 |
$(update-abi)
|
|
|
00db10 |
+define update-abi-pattern
|
|
|
00db10 |
+@if cmp -s $^ 2> /dev/null; \
|
|
|
00db10 |
+ then \
|
|
|
00db10 |
+ echo '+++ $(filter $(abilist-pattern),$^) is unchanged'; \
|
|
|
00db10 |
+ else cp -f $^; \
|
|
|
00db10 |
+ echo '*** Now check $(filter $(abilist-pattern),$^) changes for correctness ***'; \
|
|
|
00db10 |
+ fi
|
|
|
00db10 |
+endef
|
|
|
00db10 |
define update-abi
|
|
|
00db10 |
@if cmp -s $^ 2> /dev/null; \
|
|
|
00db10 |
then \
|
|
|
00db10 |
diff -urN glibc-2.17-c758a686/sysdeps/powerpc/Makefile glibc-2.17-c758a686/sysdeps/powerpc/Makefile
|
|
|
00db10 |
--- glibc-2.17-c758a686/sysdeps/powerpc/Makefile 2014-06-02 15:29:42.000000000 +0000
|
|
|
00db10 |
+++ glibc-2.17-c758a686/sysdeps/powerpc/Makefile 2014-06-02 15:25:21.000000000 +0000
|
|
|
00db10 |
@@ -27,3 +27,7 @@
|
|
|
00db10 |
sysdep_headers += sys/platform/ppc.h
|
|
|
00db10 |
tests += test-gettimebase
|
|
|
00db10 |
endif
|
|
|
00db10 |
+
|
|
|
00db10 |
+ifneq (,$(filter %le,$(config-machine)))
|
|
|
00db10 |
+abilist-pattern = %-le.abilist
|
|
|
00db10 |
+endif
|