Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | DESCRIPTION = "Navit is a car navigation system with routing engine." |
| 2 | LICENSE = "GPLv2 & LGPLv2" |
| 3 | LIC_FILES_CHKSUM = "file://COPYING;md5=ed539d099d6ce08de6ea0dfed9ecb333 \ |
| 4 | file://LGPL-2;md5=3214f080875748938ba060314b4f727d \ |
| 5 | file://GPL-2;md5=751419260aa954499f7abaabaa882bbe \ |
| 6 | " |
| 7 | |
| 8 | SECTION = "x11/applications" |
| 9 | DEPENDS = "glib-2.0 gd gypsy librsvg-native" |
| 10 | RDEPENDS_${PN} = " ${PN}-icons ${PN}-config " |
| 11 | RRECOMMENDS_${PN} = "gpsd ${PN}-dbus ${PN}-speech-cmdline ${PN}-gui-internal ${PN}-graphics-gtk" |
| 12 | RSUGGESTS_${PN} = "flite-alsa espeak ${PN}-speech-dbus ${PN}-gui-gtk ${PN}-gui-qml ${PN}-graphics-sdl ${PN}-graphics-qt ${PN}-maptool" |
| 13 | |
| 14 | PE = "1" |
| 15 | INC_PR = "r11" |
| 16 | |
| 17 | # Depends on gypsy |
| 18 | PNBLACKLIST[navit] ?= "${@bb.utils.contains('DISTRO_FEATURES', 'bluez5', 'bluez5 conflicts with bluez4 and bluez5 is selected in DISTRO_FEATURES', '', d)}" |
| 19 | |
| 20 | inherit autotools gettext pkgconfig |
| 21 | |
| 22 | PACKAGECONFIG ?= "" |
| 23 | PACKAGECONFIG[fribidi] = "--enable-fribidi,--disable-fribidi,fribidi" |
| 24 | PACKAGECONFIG[imlib2] = "--enable-imlib2,--disable-imlib2,imlib2" |
| 25 | PACKAGECONFIG[sdl] = "--enable-graphics-sdl,--disable-graphics-sdl,libsdl" |
| 26 | PACKAGECONFIG[gtk] = "--enable-graphics-gtk-drawing-area --enable-gui-gtk,--disable-graphics-gtk-drawing-area --disable-gui-gtk,gtk+" |
| 27 | PACKAGECONFIG[qt] = "--enable-graphics-qt-qpainter --enable-gui-qml,--disable-graphics-qt-qpainter --disable-gui-qml,qt4-x11-free,qt4-plugin-imageformat-svg" |
| 28 | |
| 29 | EXTRA_OECONF += " \ |
| 30 | --disable-binding-python \ |
| 31 | --disable-samplemap \ |
| 32 | --enable-avoid-unaligned \ |
| 33 | --enable-svg2png-scaling-flag=32 \ |
| 34 | --disable-speech-speech-dispatcher \ |
| 35 | --enable-cache-size=20971520 \ |
| 36 | " |
| 37 | |
| 38 | # --enable-avoid-float \ |
| 39 | #check for TARGET_FPU=soft and inform configure of the result so it can disable some floating points |
| 40 | require navit-fpu.inc |
| 41 | EXTRA_OECONF += "${@get_navit_fpu_setting(bb, d)}" |
| 42 | |
| 43 | PACKAGES =+ "${PN}-maptool ${PN}-config ${PN}-dbus ${PN}-speech-cmdline ${PN}-speech-dbus ${PN}-gui-gtk ${PN}-gui-internal ${PN}-gui-qml ${PN}-graphics-sdl ${PN}-graphics-gtk ${PN}-graphics-qt ${PN}-icons" |
| 44 | |
| 45 | EXTRA_AUTORECONF = " -I m4" |
| 46 | |
| 47 | CONFFILES_${PN}-config += "${datadir}/navit/navit.default.xml \ |
| 48 | ${datadir}/navit/navit.xml \ |
| 49 | ${datadir}/navit/maps.xml \ |
| 50 | ${datadir}/navit/osd.xml \ |
| 51 | ${datadir}/navit/speech.xml \ |
| 52 | ${datadir}/navit/plugins.xml \ |
| 53 | " |
| 54 | |
| 55 | SRC_URI += "file://navit.xml \ |
| 56 | file://maps.xml \ |
| 57 | file://osd.xml \ |
| 58 | file://speech.xml \ |
| 59 | file://plugins.xml \ |
| 60 | " |
| 61 | |
| 62 | FILES_${PN} += "${libdir}/${BPN}/*/*.so ${datadir}/icons" |
| 63 | FILES_${PN}-dbg += "${libdir}/${BPN}/*/.debug" |
| 64 | FILES_${PN}-maptool = " ${bindir}/maptool " |
| 65 | FILES_${PN}-config = " ${datadir}/navit/*.xml " |
| 66 | FILES_${PN}-dbus = " ${datadir}/dbus-1/services/ ${libdir}/${BPN}/binding/libbinding_dbus.so " |
| 67 | FILES_${PN}-speech-cmdline = " ${libdir}/${BPN}/speech/libspeech_cmdline.so " |
| 68 | FILES_${PN}-speech-dbus = " ${libdir}/${BPN}/speech/libspeech_dbus.so " |
| 69 | FILES_${PN}-gui-gtk = " ${libdir}/${BPN}/gui/libgui_gtk.so " |
| 70 | FILES_${PN}-gui-qml = " ${libdir}/${BPN}/gui/libgui_qml.so ${datadir}/navit/skins/ " |
| 71 | FILES_${PN}-gui-internal = " ${libdir}/${BPN}/gui/libgui_internal.so " |
| 72 | FILES_${PN}-graphics-sdl = " ${libdir}/${BPN}/graphics/libgraphics_sdl.so " |
| 73 | FILES_${PN}-graphics-qt = " ${libdir}/${BPN}/graphics/libgraphics_qt_qpainter.so " |
| 74 | FILES_${PN}-graphics-gtk = " ${libdir}/${BPN}/graphics/libgraphics_gtk_drawing_area.so " |
| 75 | FILES_${PN}-icons = "/usr/share/navit/xpm/" |
| 76 | |
| 77 | do_configure_prepend() { |
| 78 | # MOC=`$PKG_CONFIG QtGui --variable=moc_location` returns only /usr/bin/moc4 which is not available on hosts without Qt |
| 79 | sed -i "s#MOC=#MOC=${STAGING_DIR_NATIVE}#g" ${S}/configure.in |
| 80 | } |
| 81 | |
| 82 | do_install_append() { |
| 83 | # fix QA issue |
| 84 | sed -i 's#Categories=GTK;Utility;Geography;#Categories=Graphics;#g' ${D}${datadir}/applications/navit.desktop |
| 85 | |
| 86 | rm ${D}${libdir}/${BPN}/*/*.la |
| 87 | |
| 88 | #Use split config |
| 89 | mv ${D}${datadir}/navit/navit.xml ${D}${datadir}/navit/navit.default.xml |
| 90 | install -m 0644 ${WORKDIR}/navit.xml ${D}${datadir}/navit/navit.xml |
| 91 | install -m 0644 ${WORKDIR}/maps.xml ${D}${datadir}/navit/maps.xml |
| 92 | install -m 0644 ${WORKDIR}/osd.xml ${D}${datadir}/navit/osd.xml |
| 93 | install -m 0644 ${WORKDIR}/speech.xml ${D}${datadir}/navit/speech.xml |
| 94 | install -m 0644 ${WORKDIR}/plugins.xml ${D}${datadir}/navit/plugins.xml |
| 95 | } |