%global rel 1 %global svndate 20101128 %global svn 3732 %if %svn #svn co https://navit.svn.sourceforge.net/svnroot/navit/trunk/navit #(cd navit ; svn export -r %%{svn} . ../%{name}-%%{svn}) #tar cvjf %%{name}-%%{svn}.tar.bz2 %%{name}-%%{svn} %global release 0.%{rel}.%{svndate}svn%{svn}%{?dist} %global distname %{name}-%{svn}.tar.bz2 %global dirname %{name}-%{svn} %else %global release %{rel}%{?dist} %global distname %{name}-%{version}.tar.gz %global dirname %{name}-%{version} %endif Name: navit Summary: Car navigation system with routing engine Version: 0.5.0 Release: %{release} Source0: http://downloads.sourceforge.net/%{name}/%{distname} Source1: http://www.navit-project.org/maps/osm_bbox_11.3,47.9,11.7,48.2.osm.bz2 # Don't try to download the sample map on the fly - AdamW 2009/01 # This patch isn't appropriate for upstream, it only makes sense in a # distro packaging context Patch0: navit-0.2.0-static_sample.patch Patch1: navit-0.2.0-fp_nan.patch Group: Applications/Productivity BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root License: LGPLv2 and GPLv2 BuildRequires: zlib-devel BuildRequires: gtk2-devel BuildRequires: fontconfig-devel BuildRequires: SDL_image-devel BuildRequires: SDL-devel BuildRequires: postgresql-devel BuildRequires: imlib2-devel BuildRequires: libXmu-devel BuildRequires: freeglut-devel BuildRequires: quesoglc-devel BuildRequires: python-devel BuildRequires: dbus-glib-devel BuildRequires: gettext-devel BuildRequires: gd-devel BuildRequires: speech-dispatcher-devel BuildRequires: gpsd-devel BuildRequires: qt4-devel BuildRequires: shapelib-devel BuildRequires: autoconf BuildRequires: automake BuildRequires: libtool BuildRequires: desktop-file-utils BuildRequires: freeimage-devel BuildRequires: libgarmin-devel BuildRequires: libhildon-devel BuildRequires: gypsy-devel BuildRequires: cegui-devel # autopoint requires cvs to work BuildRequires: cvs Requires: dejavu-sans-fonts URL: http://www.navit-project.org/ %description Navit is a car navigation system with routing engine. Its modular design is capable of using vector maps of various formats for routing and rendering of the displayed map. It's even possible to use multiple maps at a time. The GTK+ or SDL user interfaces are designed to work well with touch screen displays. Points of Interest of various formats are displayed on the map. The current vehicle position is either read from 'gpsd' or directly from NMEA GPS sensors. The routing engine not only calculates an optimal route to your destination, but also generates directions and even speaks to you. %package graphics-qt Summary: Qt graphics renderer for Navit navigation system Group: Applications/Productivity Requires: %{name} = %{version}-%{release} %description graphics-qt Navit is a car navigation system with routing engine. This package contains the Qt-QPainter graphics renderer for Navit. You need to enable this renderer in /etc/navit/navit.xml or ~/.navit/navit.xml to use it. %package graphics-sdl Summary: SDL graphics renderer for Navit navigation system Group: Applications/Productivity Requires: %{name} = %{version}-%{release} %description graphics-sdl Navit is a car navigation system with routing engine. This package contains the SDL graphics renderer for Navit. You need to enable this renderer in /etc/navit/navit.xml or ~/.navit/navit.xml to use it. %prep %setup -q -n %{dirname} %patch0 -p1 -b .sample %patch1 -p1 -b .fp install -m 0644 %{SOURCE1} navit/maps %build sh autogen.sh %configure \ --enable-graphics-gd \ --enable-svg2png-scaling \ --enable-plugin-pedestrian \ --enable-vehicle-null \ --disable-speech-espeak make %install rm -rf %{buildroot} make DESTDIR=%{buildroot} install # Don't need the README here rm -f %{buildroot}%{_datadir}/%{name}/README # Put the config file in /etc: upstream likes it in /usr to be # relocatable, but that doesn't concern us. The code does check # in /etc, so we don't need a patch - AdamW 2009/01 mkdir -p %{buildroot}%{_sysconfdir}/%{name} mv %{buildroot}%{_datadir}/%{name}/%{name}.xml %{buildroot}%{_sysconfdir}/%{name}/%{name}.xml # Create a README.Fedora - AdamW 2009/01 cat > README.Fedora << EOF Navit comes with a sample map of Munich, but if you live (or drive!) anywhere else, you'll need to add another map set. These are not available as packages because they're rather large and the data changes on a daily basis, so the packages would have to be refreshed very often. For instructions on downloading or generating, and installing, different types of map sets, see these Navit Wiki pages: http://wiki.navit-project.org/index.php/OpenStreetMaps http://wiki.navit-project.org/index.php/European_maps http://wiki.navit-project.org/index.php/Garmin_maps You should either add the appropriate configuration elements to /etc/navit/navit.xml, or copy /etc/navit/navit.xml to ~/.navit/navit.xml and edit it there. You may have to remove or comment out the section for the sample map set, also. EOF # icon fix, this is not complete sed -i 's|mini_roundabout.xpm|mini_roundabout.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|hotel.xpm|hotel.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|cafe.xpm|cafe.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|bar.xpm|bar.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|school.xpm|school.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|stadium.xpm|stadium.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml sed -i 's|museum.xpm|museum.png|g' %{buildroot}/%{_sysconfdir}/%{name}/%{name}.xml # remove unwanted development files find %{buildroot} -name *.la -exec rm -rf {} \; # validate the .desktop file desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop %find_lang %{name} %post touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : %postun if [ $1 -eq 0 ] ; then touch --no-create %{_datadir}/icons/hicolor &>/dev/null gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : fi %posttrans gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %clean rm -rf %{buildroot} %files -f %{name}.lang %defattr (-,root,root,-) %doc AUTHORS README README.Fedora %{_bindir}/%{name} %{_bindir}/maptool %{_libdir}/%{name} %exclude %{_libdir}/%{name}/graphics/libgraphics_qt* %exclude %{_libdir}/%{name}/graphics/libgraphics_sdl* %{_datadir}/applications/%{name}.desktop %{_datadir}/icons/hicolor/*/apps/%{name}.png %{_datadir}/dbus-1/services/*.service %{_datadir}/%{name} %config(noreplace) %{_sysconfdir}/%{name}/%{name}.xml %{_mandir}/man1/* %files graphics-qt %defattr (-,root,root,-) %{_libdir}/%{name}/graphics/libgraphics_qt* %files graphics-sdl %defattr (-,root,root,-) %{_libdir}/%{name}/graphics/libgraphics_sdl* %changelog * Sun Nov 28 2010 Viji Nair - 0.5.0-0.1.20101128svn3732 - Moved to latest SVN - Enabled graphics-qt-qpainter - Fixed isses on icon load - Added patch for is_nan sysmbol issue * Fri Nov 26 2010 Viji Nair - 0.2.0-1 - Update to latest upstream - Added pedestrian plugin support - Enabled conversion of svgs to pngs with specified sizes - Enabled graphics gd - Enabled vehicle null - Disabled espeak, licensed under GPLv3+ - Added missing BuildRequires - graphics-qt-qpainter has been disabled temporarily, old qt dependency issues * Wed Nov 17 2010 Viji Nair - 0.1.2-0.4.20101117svn3684 - Update to latest SVN - Added man pages * Fri Sep 25 2009 Adam Williamson - 0.1.2-0.2.20090918svn2578 - spec clean: + add svn snapshot source creation comment + use make install DESTDIR=buildroot, not makeinstall * Fri Sep 18 2009 Adam Williamson - 0.1.2-0.1.20090918svn2578 - update to latest SVN, bump version to 0.1.2 as upstream released a 0.1.1 - change evr to match policy (per review) - add a comment on static_sample.patch's upstream status (per review) - update static_sample.patch for 0.1.2 - add icon cache update snippets (per review) - validate the .desktop file in install (per review) - drop the warning about GPS from the README as it works even without gpsd running, now * Tue Aug 04 2009 Adam Williamson - 0.1.1-0.1.2431 - initial package (not really, but begin changelog) based on MDV spec