diff mbox series

[1/1] tools/configure: remove redundancy

Message ID 20191023084841.30903-2-k.kahurani@gmail.com (mailing list archive)
State New, archived
Headers show
Series tools/configure | expand

Commit Message

David Kahurani Oct. 23, 2019, 8:48 a.m. UTC
This piece of code is redundant and results in a garbage error
message on systems that do not have a default python executable.

Signed-off-by: K. Kahurani <k.kahurani@gmail.com>
---
 tools/configure | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Marek Marczykowski-Górecki Oct. 23, 2019, 7:05 p.m. UTC | #1
On Wed, Oct 23, 2019 at 11:48:41AM +0300, K. Kahurani wrote:
> This piece of code is redundant and results in a garbage error
> message on systems that do not have a default python executable.
> 
> Signed-off-by: K. Kahurani <k.kahurani@gmail.com>
> ---
>  tools/configure | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/tools/configure b/tools/configure
> index 82947ad..a1f36d1 100755
> --- a/tools/configure
> +++ b/tools/configure

configure script is a generated file, you should edit tools/configure.ac
instead (and then generate tools/configure out of it). You may also want
to look at this commit for reasoning of the current code shape:
https://xenbits.xen.org/gitweb/?p=xen.git;a=commitdiff;h=9caed751db9110c785fd6b1def89d808baa1d907;hp=88339ae94f4309888eae81a6cceac9577a319d7e
diff mbox series

Patch

diff --git a/tools/configure b/tools/configure
index 82947ad..a1f36d1 100755
--- a/tools/configure
+++ b/tools/configure
@@ -6931,10 +6931,8 @@  fi
 if echo "$PYTHON" | grep -q "^/"; then :
 
 else
-  PYTHON=`type -p "$PYTHON"`
+  PYTHONPATH=`type -p "$PYTHON"`
 fi
-PYTHONPATH=$PYTHON
-PYTHON=`basename $PYTHONPATH`
 
 # Extract the first word of "$PYTHON", so it can be a program name with args.
 set dummy $PYTHON; ac_word=$2