Re: Review Request 67412: Improved coverage with configure and `PYTHON` or `PYTHON_VERSION` set.

2018-06-15 Thread Kevin Klues

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67412/#review204843
---


Ship it!




Ship It!

- Kevin Klues


On June 1, 2018, 3:14 p.m., Armand Grillet wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67412/
> ---
> 
> (Updated June 1, 2018, 3:14 p.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer, Benjamin Bannier, Eric Chung, 
> and Kevin Klues.
> 
> 
> Bugs: MESOS-8955
> https://issues.apache.org/jira/browse/MESOS-8955
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We set `PYTHON` and `PYTHON_VERSION` when configuring the build.
> We now cover all possible cases (both variables set, only one, none).
> This ensures that both variables are set after being checked.
> 
> 
> Diffs
> -
> 
>   configure.ac f5a9d5bded40d2af6df7fe872395b076cbd37123 
> 
> 
> Diff: https://reviews.apache.org/r/67412/diff/3/
> 
> 
> Testing
> ---
> 
> I added two lines after the new code:
> ```
>   AC_MSG_NOTICE([$PYTHON])
>   AC_MSG_NOTICE([$PYTHON_VERSION])
> ```
> 
> Then, when using `configure`, I've checked the output.
> ```
> $ ../configure 
> ...
> configure: /usr/bin/python
> configure: 2.7
> $ PYTHON_VERSION=4 ../configure
> ...
> configure: python4
> configure: 4
> $ PYTHON=yolo ../configure
> ...
> configure: yolo
> configure:
> ```
> 
> 
> Thanks,
> 
> Armand Grillet
> 
>



Re: Review Request 67412: Improved coverage with configure and `PYTHON` or `PYTHON_VERSION` set.

2018-06-15 Thread Kevin Klues

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67412/#review204842
---


Fix it, then Ship it!




Ship It!


configure.ac
Lines 2276-2277 (patched)


Changing this to the followign before I commit it:
```
+AC_CHECK_PROG([PYTHON_CHECK], [$PYTHON], [yes])
+AS_IF([test "x$PYTHON_CHECK" = "xyes"], [
+  PYTHON_VERSION=`$PYTHON -c "import sys; 
sys.stdout.write(sys.version[[:3]])"`
+], [
+  AC_MSG_ERROR([Cannot find Python executable '$PYTHON' in path.])
+])
```


- Kevin Klues


On June 1, 2018, 3:14 p.m., Armand Grillet wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67412/
> ---
> 
> (Updated June 1, 2018, 3:14 p.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer, Benjamin Bannier, Eric Chung, 
> and Kevin Klues.
> 
> 
> Bugs: MESOS-8955
> https://issues.apache.org/jira/browse/MESOS-8955
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We set `PYTHON` and `PYTHON_VERSION` when configuring the build.
> We now cover all possible cases (both variables set, only one, none).
> This ensures that both variables are set after being checked.
> 
> 
> Diffs
> -
> 
>   configure.ac f5a9d5bded40d2af6df7fe872395b076cbd37123 
> 
> 
> Diff: https://reviews.apache.org/r/67412/diff/3/
> 
> 
> Testing
> ---
> 
> I added two lines after the new code:
> ```
>   AC_MSG_NOTICE([$PYTHON])
>   AC_MSG_NOTICE([$PYTHON_VERSION])
> ```
> 
> Then, when using `configure`, I've checked the output.
> ```
> $ ../configure 
> ...
> configure: /usr/bin/python
> configure: 2.7
> $ PYTHON_VERSION=4 ../configure
> ...
> configure: python4
> configure: 4
> $ PYTHON=yolo ../configure
> ...
> configure: yolo
> configure:
> ```
> 
> 
> Thanks,
> 
> Armand Grillet
> 
>



Re: Review Request 67412: Improved coverage with configure and `PYTHON` or `PYTHON_VERSION` set.

2018-06-13 Thread Kevin Klues

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67412/#review204688
---




configure.ac
Lines 2278 (patched)


Instead of this long complicated line, can we just set PYTHON_VERSION 
directrly from:
```
PYTHON_VERSION=`$PYTHON -c "import sys; 
sys.stdout.write(sys.version[[:3]])"`
```


- Kevin Klues


On June 1, 2018, 3:14 p.m., Armand Grillet wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67412/
> ---
> 
> (Updated June 1, 2018, 3:14 p.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer, Benjamin Bannier, Eric Chung, 
> and Kevin Klues.
> 
> 
> Bugs: MESOS-8955
> https://issues.apache.org/jira/browse/MESOS-8955
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We set `PYTHON` and `PYTHON_VERSION` when configuring the build.
> We now cover all possible cases (both variables set, only one, none).
> This ensures that both variables are set after being checked.
> 
> 
> Diffs
> -
> 
>   configure.ac f5a9d5bded40d2af6df7fe872395b076cbd37123 
> 
> 
> Diff: https://reviews.apache.org/r/67412/diff/2/
> 
> 
> Testing
> ---
> 
> I added two lines after the new code:
> ```
>   AC_MSG_NOTICE([$PYTHON])
>   AC_MSG_NOTICE([$PYTHON_VERSION])
> ```
> 
> Then, when using `configure`, I've checked the output.
> ```
> $ ../configure 
> ...
> configure: /usr/bin/python
> configure: 2.7
> $ PYTHON_VERSION=4 ../configure
> ...
> configure: python4
> configure: 4
> $ PYTHON=yolo ../configure
> ...
> configure: yolo
> configure:
> ```
> 
> 
> Thanks,
> 
> Armand Grillet
> 
>



Re: Review Request 67412: Improved coverage with configure and `PYTHON` or `PYTHON_VERSION` set.

2018-06-07 Thread Eric Chung

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67412/#review204443
---


Ship it!




Ship It!

- Eric Chung


On June 1, 2018, 3:14 p.m., Armand Grillet wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67412/
> ---
> 
> (Updated June 1, 2018, 3:14 p.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer, Benjamin Bannier, Eric Chung, 
> and Kevin Klues.
> 
> 
> Bugs: MESOS-8955
> https://issues.apache.org/jira/browse/MESOS-8955
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We set `PYTHON` and `PYTHON_VERSION` when configuring the build.
> We now cover all possible cases (both variables set, only one, none).
> This ensures that both variables are set after being checked.
> 
> 
> Diffs
> -
> 
>   configure.ac 03d333d65bcab2e46cff0b1329e5ad7bb26da697 
> 
> 
> Diff: https://reviews.apache.org/r/67412/diff/1/
> 
> 
> Testing
> ---
> 
> I added two lines after the new code:
> ```
>   AC_MSG_NOTICE([$PYTHON])
>   AC_MSG_NOTICE([$PYTHON_VERSION])
> ```
> 
> Then, when using `configure`, I've checked the output.
> ```
> $ ../configure 
> ...
> configure: /usr/bin/python
> configure: 2.7
> $ PYTHON_VERSION=4 ../configure
> ...
> configure: python4
> configure: 4
> $ PYTHON=yolo ../configure
> ...
> configure: yolo
> configure:
> ```
> 
> 
> Thanks,
> 
> Armand Grillet
> 
>



Review Request 67412: Improved coverage with configure and `PYTHON` or `PYTHON_VERSION` set.

2018-06-01 Thread Armand Grillet

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67412/
---

Review request for mesos, Andrew Schwartzmeyer, Benjamin Bannier, Eric Chung, 
and Kevin Klues.


Bugs: MESOS-8955
https://issues.apache.org/jira/browse/MESOS-8955


Repository: mesos


Description
---

We set `PYTHON` and `PYTHON_VERSION` when configuring the build.
We now cover all possible cases (both variables set, only one, none).
This ensures that both variables are set after being checked.


Diffs
-

  configure.ac 03d333d65bcab2e46cff0b1329e5ad7bb26da697 


Diff: https://reviews.apache.org/r/67412/diff/1/


Testing
---

I added two lines after the new code:
```
  AC_MSG_NOTICE([$PYTHON])
  AC_MSG_NOTICE([$PYTHON_VERSION])
```

Then, when using `configure`, I've checked the output.
```
$ ../configure 
...
configure: /usr/bin/python
configure: 2.7
$ PYTHON_VERSION=4 ../configure
...
configure: python4
configure: 4
$ PYTHON=yolo ../configure
...
configure: yolo
configure:
```


Thanks,

Armand Grillet