From 1b488eb1fd5f26ac859bbb0f69e78d9620116ba7 Mon Sep 17 00:00:00 2001 From: Rodrigo Linfati Date: Mon, 4 Jan 2010 13:35:20 +0100 Subject: [PATCH] fix detection of liblocation... --- debian/control | 5 ++++- googlelatitude.pro | 5 ++++- src/gps.cpp | 2 +- src/gps.h | 4 ++-- src/gpsfake.h | 4 ++-- 5 files changed, 13 insertions(+), 7 deletions(-) diff --git a/debian/control b/debian/control index d5c9782..b551d78 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,8 @@ Source: googlelatitude Section: user/navigation Priority: optional Maintainer: Rodrigo Linfati -Build-Depends: debhelper (>= 5), libqt4-maemo5-dev, liblocation-dev, libgconf2-dev +Build-Depends: debhelper (>= 5), libqt4-maemo5-dev, libgconf2-dev, liblocation-dev +#Build-Depends: debhelper (>= 5), libqt4-dev, libqt4-phonon, libsqlite3-0, liblocation-dev, libgconf2-dev #Build-Depends: debhelper (>= 5), libqt4-dev Standards-Version: 3.7.2 Homepage: http://googlelatitude.garage.maemo.org/ @@ -10,6 +11,8 @@ Homepage: http://googlelatitude.garage.maemo.org/ Package: googlelatitude Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} +#Depends: ${shlibs:Depends}, ${misc:Depends}, libqt4-phonon, libsqlite3-0 +#Depends: ${shlibs:Depends}, ${misc:Depends} Description: Google Latitude Updater A Google Latitude Updater in QT4. Features: diff --git a/googlelatitude.pro b/googlelatitude.pro index a667d92..e8f8bd5 100644 --- a/googlelatitude.pro +++ b/googlelatitude.pro @@ -15,7 +15,10 @@ LIBS += DEFINES += CONFIG += link_pkgconfig PKGCONFIG += glib-2.0 liblocation - +exists(/usr/lib/liblocation.so) { + DEFINES += LIBLOCATION + message(liblocation found) +} install_app.commands = $(INSTALL_PROGRAM) $(TARGET) $(DESTDIR)/usr/bin/$(QMAKE_TARGET) install_dsk.commands = $(INSTALL_FILE) data/$(QMAKE_TARGET).desktop $(DESTDIR)/usr/share/applications/hildon/$(QMAKE_TARGET).desktop install.depends = $(TARGET) install_app install_dsk diff --git a/src/gps.cpp b/src/gps.cpp index 5c52eb9..cf55ed0 100644 --- a/src/gps.cpp +++ b/src/gps.cpp @@ -1,6 +1,6 @@ #include "gps.h" -#ifdef Q_WS_MAEMO_5 +#ifdef LIBLOCATION GpsMaemo5::GpsMaemo5(QObject *parent) : QObject(parent) { latitude = 0; diff --git a/src/gps.h b/src/gps.h index 3f9dde0..45c9cbb 100644 --- a/src/gps.h +++ b/src/gps.h @@ -1,9 +1,9 @@ #ifndef GPS_H #define GPS_H -#include +#ifdef LIBLOCATION -#ifdef Q_WS_MAEMO_5 +#include extern "C" { #include diff --git a/src/gpsfake.h b/src/gpsfake.h index 9d98a53..0a8cdad 100644 --- a/src/gpsfake.h +++ b/src/gpsfake.h @@ -1,9 +1,9 @@ #ifndef GPSFAKE_H #define GPSFAKE_H -#include +#ifndef LIBLOCATION -#ifndef Q_WS_MAEMO_5 +#include class GpsMaemo5 : public QObject { Q_OBJECT -- 1.7.9.5