| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
Note the program pep8 is now called pycodestyle
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Otherwise get things like:
sh: 1: Syntax error: "(" unexpected (expecting "}")
when processing INTERNAL_SET(n)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Although this isn't strictly a Python 3 requirement, using the
new-style class definition syntax improves consistency between Python
2 and Python 3. Old-style classes have been deprecated since Python
2.2, but many such definitions linger on. Python 3 eliminates
old-style classes, but instead of complaining about old-style
definitions, it simply unconditionally and silently makes all classes
new-style. The only incompatible differences are quite subtle and
rarely matter in practice, but things are more consistent across
versions if the new-style definitions are used.
Also, the preferred method for subclasses to invoke parent init
methods is via the super() construct, which is only available with
new-style classes. Using super() is especially useful with multiple
inheritance, which it handles automatically (provided that the init
methods have compatible signatures).
TESTED:
Using an SConstruct patched to run the build helpers with the target
Python, ran "scons build-all check ", as well as gpsprof and xgps,
with all six supported Python versions (except 2.6 for xgps).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This makes the "future import" statements consistently specify
absolute_import, print_function, and division, for maximum consistency
between Python 2 and Python 3. Although absolute_import is probably a
don't care for top-level programs, if unit tests were ever implemented
for the programs they would be imported as modules, making the module
import behavior relevant.
Note that previous Python 3 fixes are a prerequisite for this change.
Also makes the "polyglot comment" consistent across sources.
TESTED:
Using a version of SConstruct patched to use the target Python for
build helpers, ran "scons build-all check valgrind-audit
www/hardware.html" with all six supported Python versions. Also ran
gegps, gpscat, gpsprof, xgps, and xgpsspeed with both Python 2 and
Python 3.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
...so that @PYTHON@ can be substituted with the discovered path to
python. Avoids the nonportable assumption that "/usr/bin/env python"
will find python, because on pkgsrc systems python2.5 etc. are
installed with no bare python to avoid programs binding to a version
(and hence compiled extensions) that might change.
This should cause no functional change on systems with 'python', and
fix the build on pkgsrc-using systems.
|
|
|
|
|
|
|
| |
That is, instead of sectioning out two little config defines and
putting them in. This makes gpsd.h self-copntained (e.g. in case it
gets installed as a library header) and means we can get rid of most
inclusions of it.
|
| |
|
| |
|
| |
|
|
|