2011-06-08 Stefano Lattarini <stefano.lattarini@gmail.com>
+ py-compile: the '--destdir' option now accepts a blank argument
+ * lib/py-compile (Option parsing): Do not count an empty argument
+ to `--destdir' or `--basedir' as a missing argument.
+ * lib/python.am: Simplify accordingly, passing the `--destdir'
+ option to py-compile unconditionally, even if `$(DESTDIR)' is
+ empty.
+ * NEWS: Update.
+
+2011-06-08 Stefano Lattarini <stefano.lattarini@gmail.com>
+
python: run the 'py-compile' script with $(SHELL)
* lib/python.am (install-%DIR%PYTHON): Run each instance of
py-compile using $(SHELL). Since we are at it, break overly
- The `lzma' compression scheme and associated automake option `dist-lzma'
is obsoleted by `xz' and `dist-xz' due to upstream changes.
+ - The py-compile script now accepts empty arguments passed to the options
+ `--destdir' and `--basedir'.
+
Bugs fixed in 1.11.0a:
* Bugs introduced by 1.11:
## Byte-compile must be done at install time, since file times are
## encoded in the actual files.
if test -n "$$dlist"; then \
- if test -z "$(DESTDIR)"; then \
- $(am__py_compile) --basedir "$(%NDIR%dir)" $$dlist; \
- else \
- $(am__py_compile) --destdir "$(DESTDIR)" \
- --basedir "$(%NDIR%dir)" $$dlist; \
- fi; \
+ $(am__py_compile) --destdir "$(DESTDIR)" \
+ --basedir "$(%NDIR%dir)" $$dlist; \
else :; fi
else !%?BASE%
@list='$(%DIR%_PYTHON)'; test -n "$(%NDIR%dir)" || list=; \
## Byte-compile must be done at install time, since file times are
## encoded in the actual files.
if test -n "$$dlist"; then \
- if test -z "$(DESTDIR)"; then \
- $(am__py_compile) --basedir "$(%NDIR%dir)" $$dlist; \
- else \
- $(am__py_compile) --destdir "$(DESTDIR)" \
- --basedir "$(%NDIR%dir)" $$dlist; \
- fi; \
+ $(am__py_compile) --destdir "$(DESTDIR)" \
+ --basedir "$(%NDIR%dir)" $$dlist; \
else :; fi \
done
endif !%?BASE%
#!/bin/sh
# py-compile - Compile a Python program
-scriptversion=2009-04-28.21; # UTC
+scriptversion=2011-06-08.12; # UTC
-# Copyright (C) 2000, 2001, 2003, 2004, 2005, 2008, 2009 Free Software
-# Foundation, Inc.
+# Copyright (C) 2000, 2001, 2003, 2004, 2005, 2008, 2009, 2011 Free
+# Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
while test $# -ne 0; do
case "$1" in
--basedir)
- basedir=$2
- if test -z "$basedir"; then
+ if test $# -lt 2; then
echo "$0: Missing argument to --basedir." 1>&2
exit 1
+ else
+ basedir=$2
fi
shift
;;
--destdir)
- destdir=$2
- if test -z "$destdir"; then
+ if test $# -lt 2; then
echo "$0: Missing argument to --destdir." 1>&2
exit 1
+ else
+ destdir=$2
fi
shift
;;