| OLD | NEW |
| (Empty) | |
| 1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
| 2 # Copyright 1999-2010 Gentoo Foundation |
| 3 # Distributed under the terms of the GNU General Public License v2 |
| 4 # |
| 5 # This file is a heavily edited version of the Gentoo original streamlined for |
| 6 # ChromeOS base hardware. |
| 7 |
| 8 PYTHON_DEPEND="python? *" |
| 9 inherit autotools eutils distutils flag-o-matic |
| 10 |
| 11 DESCRIPTION="GPS daemon and library to interface GPS devices and clients" |
| 12 HOMEPAGE="http://gpsd.berlios.de/" |
| 13 SRC_URI="mirror://berlios/gpsd/${P}.tar.gz" |
| 14 |
| 15 LICENSE="BSD" |
| 16 SLOT="0" |
| 17 KEYWORDS="~amd64 ~arm x86" |
| 18 |
| 19 IUSE="dbus ntp usb" |
| 20 |
| 21 RDEPEND="dbus? ( >=sys-apps/dbus-0.94 |
| 22 >=dev-libs/glib-2.6 |
| 23 dev-libs/dbus-glib ) |
| 24 ntp? ( net-misc/ntp ) |
| 25 usb? ( virtual/dev-manager )" |
| 26 |
| 27 DEPEND="${RDEPEND} |
| 28 python? ( dev-lang/python )" |
| 29 |
| 30 src_unpack() { |
| 31 unpack ${A} |
| 32 cd "${S}" |
| 33 |
| 34 # Drop extensions requiring Python. |
| 35 sed -i -e 's:^\s\+Extension("gps\.\(packet\|clienthelpers\)",.*$:#:' \ |
| 36 setup.py || die "sed failed" |
| 37 eautoreconf |
| 38 } |
| 39 |
| 40 src_compile() { |
| 41 local max_clients="5" |
| 42 local max_devices="2" |
| 43 local my_conf="--enable-shared --with-pic --enable-static" |
| 44 |
| 45 use python && distutils_python_version |
| 46 |
| 47 if use ntp; then |
| 48 my_conf="${my_conf} --enable-ntpshm --enable-pps" |
| 49 else |
| 50 my_conf="${my_conf} --disable-ntpshm --disable-pps" |
| 51 fi |
| 52 |
| 53 my_conf+=" --enable-max-devices=${max_devices}\ |
| 54 --enable-max-clients=${max_clients}" |
| 55 |
| 56 WITH_XSLTPROC=no WITH_XMLTO=no econf ${my_conf} \ |
| 57 $(use_enable dbus) $(use_enable ocean oceanserver) \ |
| 58 $(use_enable tntc tnt) \ |
| 59 $(use_enable garmin garmintxt) || die "econf failed" |
| 60 |
| 61 emake -j1 || die "emake failed" |
| 62 } |
| 63 |
| 64 src_install() { |
| 65 make DESTDIR="${D}" install || die "make install failed" |
| 66 insinto /etc/init || die "insinto failed" |
| 67 doins "${FILESDIR}/gpsd.conf" || die "doins failed" |
| 68 |
| 69 # TODO(vbendeb): to reintroduce support of USB devices plug in |
| 70 # populate udev rules here. |
| 71 } |
| OLD | NEW |