X-Git-Url: http://git.ozo.com/?a=blobdiff_plain;f=tools%2Fautoconf%2Fpatches%2F000-relocatable.patch;h=0b83a2b44c39c74d5358dcb1aa93ba0669352ac3;hb=8a4c2890c8a312c6692611d66c5963d8691b635c;hp=c66e55eb019b810e561dc62f773cd52f4917677c;hpb=fccdc995da93d2bcfe5683dd24e2abdf171007ba;p=lede-git%2F.git diff --git a/tools/autoconf/patches/000-relocatable.patch b/tools/autoconf/patches/000-relocatable.patch index c66e55eb01..0b83a2b44c 100644 --- a/tools/autoconf/patches/000-relocatable.patch +++ b/tools/autoconf/patches/000-relocatable.patch @@ -50,6 +50,19 @@ # Some non-GNU m4's don't reject the --help option, so give them /dev/null. fatal "need GNU m4 1.4 or later: $m4" if system "$m4 --help &1 | grep reload-state >/dev/null"; +@@ -270,6 +272,12 @@ sub load_configuration ($) + + my @words = shellwords ($_); + my $type = shift @words; ++ ++ if ($ENV{'STAGING_DIR'}) ++ { ++ @words = map { s!^@pkgdatadir@!$ENV{'STAGING_DIR'}/../host/share/autoconf!; $_ } @words; ++ } ++ + if ($type eq 'begin-language:') + { + fatal "$file:$.: end-language missing for: $lang" --- a/bin/autoreconf.in +++ b/bin/autoreconf.in @@ -27,7 +27,8 @@ eval 'case $# in 0) exec @PERL@ -S "$0"; @@ -137,3 +150,18 @@ unshift @INC, $pkgdatadir; # Override SHELL. On DJGPP SHELL may not be set to a shell +--- a/bin/autoconf.as ++++ b/bin/autoconf.as +@@ -85,7 +85,11 @@ exit_missing_arg=' + # restore font-lock: ' + + # Variables. +-: ${AUTOM4TE='@bindir@/@autom4te-name@'} ++if test -n "$STAGING_DIR"; then ++ : ${AUTOM4TE="$STAGING_DIR/../host/bin/@autom4te-name@"} ++else ++ : ${AUTOM4TE='@bindir@/@autom4te-name@'} ++fi + autom4te_options= + outfile= + verbose=false