~ubuntu-branches/debian/stretch/gpsd/stretch

« back to all changes in this revision

Viewing changes to setup.py

  • Committer: Bazaar Package Importer
  • Author(s): Bernd Zeimetz
  • Date: 2010-07-15 14:46:02 UTC
  • mto: (1.1.11)
  • mto: This revision was merged to the branch mainline in revision 25.
  • Revision ID: james.westby@ubuntu.com-20100715144602-v68en708flyrtgcm
Tags: upstream-2.95
ImportĀ upstreamĀ versionĀ 2.95

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
    where = sys.argv.index('--mangenerator')
26
26
    # Doesn't matter what it is, just that we have one
27
27
    if sys.argv[where+1]:
28
 
        manpages=[('share/man/man1', ['gpscat.1', 'gpsfake.1','gpsprof.1'])]
 
28
        manpages=[('share/man/man1', ['gpscat.1', 'gpsfake.1','gpsprof.1',
 
29
                                      'xgps.1', 'xgpsspeed.1'])]
29
30
        print("Installing manual pages, generator is %s" %( sys.argv[where+1]))
30
31
    sys.argv = sys.argv[:where] + sys.argv[where+2:]
31
32
except ValueError:
33
34
if not manpages:
34
35
    print("No XML processor, omitting manual-page installation.")
35
36
 
 
37
MAKE = ("MAKE" in os.environ) and os.environ["MAKE"] or "make"
36
38
if not 'clean' in sys.argv:
37
39
    abs_builddir = ("abs_builddir" in os.environ) and os.environ["abs_builddir"] or ""
38
40
    if not os.path.exists(os.path.join(abs_builddir, 'gpsd_config.h')):
40
42
        sys.exit(1)
41
43
 
42
44
    cdcmd = abs_builddir and ("cd '" + abs_builddir + "' && ") or ""
43
 
    MAKE = ("MAKE" in os.environ) and os.environ["MAKE"] or "make"
44
45
    for f_name in needed_files:
45
46
        # TODO:  Shouldn't make be run unconditionally in case a
46
47
        # dependency of f_name has been updated?
56
57
gpspacket_sources = ["gpspacket.c", "packet.c", "isgps.c",
57
58
            "driver_rtcm2.c", "strl.c", "hex.c", "crc24q.c"]
58
59
include_dirs = [ os.path.realpath(os.path.dirname(__file__)) ]
59
 
version_out = os.popen(MAKE + " version")
 
60
version_out = os.popen(MAKE + " -s version")
60
61
version = version_out.read()
61
62
print(version)
62
63
if version_out.close():
76
77
        Extension("gps.clienthelpers", ["gpsclient.c", "geoid.c", "gpsdclient.c", "strl.c"], include_dirs=include_dirs)
77
78
        ],
78
79
       packages = ['gps'],
79
 
       scripts = ['gpscat','gpsfake','gpsprof', 'xgps'],
 
80
       scripts = ['gpscat','gpsfake','gpsprof', 'xgps', 'xgpsspeed'],
80
81
       data_files= manpages
81
82
     )