/[gentoo-x86]/app-misc/gpsdrive/gpsdrive-2.11-r2.ebuild
Gentoo

Contents of /app-misc/gpsdrive/gpsdrive-2.11-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (hide annotations) (download)
Sun Jul 17 22:35:26 2011 UTC (3 years ago) by scarabeus
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
Revision bump to fix locating osm-icons. Should fix bug #375049.

(Portage version: 2.2.0_alpha45/cvs/Linux x86_64)

1 pacho 1.1 # Copyright 1999-2011 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 scarabeus 1.2 # $Header: /var/cvsroot/gentoo-x86/app-misc/gpsdrive/gpsdrive-2.11-r2.ebuild,v 1.1 2011/07/14 17:25:04 pacho Exp $
4 pacho 1.1
5     EAPI=4
6    
7     inherit cmake-utils eutils fdo-mime versionator
8    
9     DESCRIPTION="GPS navigation system with NMEA and Garmin support, zoomable map display, waypoints, etc."
10     HOMEPAGE="http://www.gpsdrive.de/"
11     SRC_URI="${HOMEPAGE}/packages/${P/_/}.tar.gz"
12    
13     LICENSE="GPL-2"
14     SLOT="0"
15    
16     KEYWORDS="~amd64 ~ppc ~x86"
17    
18     IUSE="dbus -debug -kismet gdal mapnik scripts -speech"
19    
20     COMMON_DEP="
21     dev-db/sqlite:3
22     dev-libs/libxml2:2
23     net-misc/curl
24     >=sci-geosciences/gpsd-2.96
25     x11-libs/gtk+:2
26     x11-libs/gdk-pixbuf:2
27     dbus? ( dev-libs/dbus-glib )
28     gdal? ( sci-libs/gdal )
29     kismet? ( net-wireless/kismet )
30     mapnik? (
31     >=sci-geosciences/mapnik-0.7.0[postgres]
32     >=dev-db/postgis-1.5.2
33     )
34     speech? ( >=app-accessibility/speech-dispatcher-0.6.7 )
35     "
36    
37     DEPEND="${COMMON_DEP}
38     dev-util/pkgconfig
39     "
40    
41     RDEPEND="${COMMON_DEP}
42     media-fonts/dejavu
43     sci-geosciences/openstreetmap-icons
44     sci-geosciences/mapnik-world-boundaries
45     "
46    
47     S=${WORKDIR}/${P/_/}
48    
49     src_prepare() {
50     # Get rid of the package's FindBoost.
51     rm "${S}"/cmake/Modules/FindBoost.cmake
52    
53     # Update mapnik font path...
54     sed -i \
55     -e "s:truetype/ttf-dejavu:dejavu:g" \
56     -e "s:mapnik/0.5:mapnik:g" \
57     tests/gpsdriverc-in \
58     src/gpsdrive_config.c || die "sed failed"
59    
60     # update OSM icon paths
61     sed -i \
62     -e "s|icons/map-icons|osm|g" \
63     cmake/Modules/DefineInstallationPaths.cmake \
64     scripts/osm/perl_lib/Geo/Gpsdrive/DB_Defaults.pm \
65     scripts/osm/perl_lib/Geo/Gpsdrive/OSM.pm \
66     src/icons.c \
67     || die "sed failed"
68    
69     # Fix desktop file...
70     sed -i -e "s:gpsicon:/usr/share/icons/gpsdrive.png:g" \
71     -e "s:Graphics;Network;Geography:Education;Science;Geography;GPS:g" \
72     data/gpsdrive.desktop || die "sed failed"
73    
74     epatch \
75     "${FILESDIR}"/${P}_DefineOptions_gpsd.patch \
76     "${FILESDIR}"/${P}-add-gdk-pixbuf2.patch \
77     "${FILESDIR}"/${P}-gpsd-2.96.patch
78     }
79    
80     src_configure() {
81     cat >> cmake/Modules/DefineProjectDefaults.cmake <<- _EOF_
82    
83     # set policy for new linker paths
84     cmake_policy(SET CMP0003 NEW) # or cmake_policy(VERSION 2.6)
85     _EOF_
86    
87     local mycmakeargs=(
88     $(cmake-utils_use_with scripts SCRIPTS)
89     $(cmake-utils_use_with mapnik MAPNIK)
90     $(cmake-utils_use_with mapnik POSTGIS)
91     $(cmake-utils_use_with kismet KISMET)
92     $(cmake-utils_use_with dbus DBUS)
93     $(cmake-utils_use_with speech SPEECH)
94     $(cmake-utils_use_with gdal GDAL)
95     -DWITH_GDA3=OFF
96     )
97     cmake-utils_src_configure
98     }
99    
100     src_install() {
101     cmake-utils_src_install
102     dodoc AUTHORS ChangeLog README \
103     Documentation/{CREDITS.i18n,FAQ.gpsdrive,FAQ.gpsdrive.fr,LEEME} \
104     Documentation/{LISEZMOI,NMEA.txt,LISEZMOI.kismet,TODO} \
105     Documentation/README.{Bluetooth,lib_map,nasamaps,tracks,kismet}
106     if use mapnik ; then
107     dodoc Documentation/install-mapnik-osm.txt
108     else
109     rm -f "${ED}"usr/bin/gpsdrive_mapnik_gentiles.py
110     rm -f "${ED}"usr/share/gpsdrive/osm-template.xml
111     fi
112     if use scripts ; then
113     dodoc Documentation/README.gpspoint2gspdrive
114     use gdal || rm -f "${ED}"usr/bin/{gdal_slice,nasaconv}.sh
115     else
116     rm -f "${ED}"usr/share/man/man1/gpsd_nmea.sh.1
117     fi
118     }
119    
120     pkg_postinst() {
121     fdo-mime_desktop_database_update
122     elog
123     elog "Be sure to see the README files in /usr/share/doc/${PF}"
124     elog "for information on using Kismet with gpsdrive."
125     elog
126     if use mapnik ; then
127     elog "Using mapnik to render online maps requires you to load"
128     elog "data into the postgis database. Follow the instructions"
129     elog "on http://wiki.openstreetmap.org/index.php/Mapnik"
130     fi
131     elog
132     elog "This version also now depends on the gpsd package, and"
133     elog "specific devices are supported there. Start gpsd first,"
134     elog "otherwise gpsdrive will only run in simulation mode (which"
135     elog "is handy for downloading maps for another location, but"
136     elog "not much else)."
137     elog
138     elog "openstreetmap-icons now installs to a more appropriate"
139     elog "location, so if you have trouble starting gpsdrive, you"
140     elog "should probably update your ~/.gpsdrive/gpsdriverc file"
141     elog "and change the path to the geoinfofile to reflect this:"
142     elog " geoinfofile = /usr/share/osm/geoinfo.db"
143     elog
144     }
145    
146     pkg_postrm() {
147     fdo-mime_desktop_database_update
148     }

  ViewVC Help
Powered by ViewVC 1.1.20