aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Gibson <dwg@au1.ibm.com>2009-08-24 15:37:37 +1000
committerEric B Munson <ebmunson@us.ibm.com>2009-08-24 13:56:07 +0100
commitf488659a434814af3701af7dfd97cb5bd667530b (patch)
tree1d5475058e265121a9b29f77ff7d63036b6c8ac8
parenta4b3004e3de458321387fc39448ee6512e791a98 (diff)
downloadlibhugetlbfs-f488659a434814af3701af7dfd97cb5bd667530b.tar.gz
Suppress ld.hugetlbfs warnings when building testsuite
Current versions of the ld.hugetlbfs wrapper script rightly warn if you use the old, broken linker-script based method of building a hugepage binary. However, we still have to build things with this mode to test them. It's kind of nasty having a dozen or so warnings spewing out on a perfectly full and correct build of the testsuite. Therefore, this patch provides an environment variable to suppress those warnings, and uses it from the testsuite makefile to get rid of them in this case. Signed-off-by: David Gibson <dwg@au1.ibm.com> Signed-off-by: Eric B Munson <ebmunson@us.ibm.com>
-rwxr-xr-xld.hugetlbfs6
-rw-r--r--tests/Makefile8
2 files changed, 8 insertions, 6 deletions
diff --git a/ld.hugetlbfs b/ld.hugetlbfs
index 153a4a8..d102a56 100755
--- a/ld.hugetlbfs
+++ b/ld.hugetlbfs
@@ -40,8 +40,10 @@ while [ -n "$1" ]; do
fi
;;
--hugetlbfs-link=*)
- echo -n "ld.hugetlbfs: --hugetlbfs-link is deprecated. " 1>&2
- echo "Migrate to --hugetlbfs-align." 1>&2
+ if [ -z "$HUGETLB_DEPRECATED_LINK" ]; then
+ echo -n "ld.hugetlbfs: --hugetlbfs-link is deprecated. " 1>&2
+ echo "Migrate to --hugetlbfs-align." 1>&2
+ fi
HTLB_LINK="${arg#--hugetlbfs-link=}"
;;
--hugetlbfs-script-path=*)
diff --git a/tests/Makefile b/tests/Makefile
index 29ed192..737c44d 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -175,25 +175,25 @@ obj32/xB.%: $(SCRIPTS32).xB $(HUGETLBFS_LD) obj32/%.o obj32/testutils.o
@$(VECHO) LD32 "(xB test)" $@
@mkdir -p obj32
@ln -sf ../$(HUGETLBFS_LD) obj32/ld
- $(CC32) -B./obj32 $(LDFLAGS) $(LDFLAGS32) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=B $(filter %.o,$^)
+ HUGETLB_DEPRECATED_LINK=1 $(CC32) -B./obj32 $(LDFLAGS) $(LDFLAGS32) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=B $(filter %.o,$^)
obj64/xB.%: $(SCRIPTS64).xB $(HUGETLBFS_LD) obj64/%.o obj64/testutils.o
@$(VECHO) LD64 "(xB test)" $@
@mkdir -p obj64
@ln -sf ../$(HUGETLBFS_LD) obj64/ld
- $(CC64) -B./obj64 $(LDFLAGS) $(LDFLAGS64) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=B $(filter %.o,$^)
+ HUGETLB_DEPRECATED_LINK=1 $(CC64) -B./obj64 $(LDFLAGS) $(LDFLAGS64) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=B $(filter %.o,$^)
obj32/xBDT.%: $(SCRIPTS32).xBDT $(HUGETLBFS_LD) obj32/%.o obj32/testutils.o
@$(VECHO) LD32 "(xBDT test)" $@
@mkdir -p obj32
@ln -sf ../$(HUGETLBFS_LD) obj32/ld
- $(CC32) -B./obj32 $(LDFLAGS) $(LDFLAGS32) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=BDT $(filter %.o,$^)
+ HUGETLB_DEPRECATED_LINK=1 $(CC32) -B./obj32 $(LDFLAGS) $(LDFLAGS32) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=BDT $(filter %.o,$^)
obj64/xBDT.%: $(SCRIPTS64).xBDT $(HUGETLBFS_LD) obj64/%.o obj64/testutils.o
@$(VECHO) LD64 "(xBDT test)" $@
@mkdir -p obj64
@ln -sf ../$(HUGETLBFS_LD) obj64/ld
- $(CC64) -B./obj64 $(LDFLAGS) $(LDFLAGS64) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=BDT $(filter %.o,$^)
+ HUGETLB_DEPRECATED_LINK=1 $(CC64) -B./obj64 $(LDFLAGS) $(LDFLAGS64) -o $@ $(LDLIBS) -Wl,--hugetlbfs-link=BDT $(filter %.o,$^)
$(HELPERS:%=obj32/%): %: %.o
@$(VECHO) LD32 "(helper)" $@