update to 1.2.2.20120813 [release 1.2.2.20120813-1mamba;Mon Aug 13 2012]

This commit is contained in:
Silvan Calarco 2024-01-06 05:30:53 +01:00
parent 0f1adf7fa6
commit c91049349d
4 changed files with 328 additions and 0 deletions

109
FindQtMobility.cmake Normal file
View File

@ -0,0 +1,109 @@
# - Try to find the QtMobility libraries
#
# This module will search for the QtMobility libraries.
#
# It supports both a minimum version and searching for individual
# components. For the minimum version, use
# find_package(QtMobility 1.2.0). For specific components, use
# find_package(QtMobility COMPONENTS ...). See below for a list of known
# components.
#
# Once done this will define
# QTMOBILITY_FOUND - QtMobility and all specified components were found.
# QTMOBILITY_INCLUDE_DIR - Include directory for global QtMobility files.
# QTMOBILITY_INCLUDE_DIRS - All found QtMobility components' include dirs.
# QTMOBILITY_LIBRARIES - All found QtMobility components' libraries.
# QTMOBILITY_VERSION - The version of QtMobility that was found.
#
# For each found component the following will be defined:
# QTMOBILITY_{COMPONENT}_INCLUDE_DIR - The include directory for the component.
# QTMOBILITY_{COMPONENT}_LIBRARY - The location of the library for the component.
#
# Note that searching for components will be limited to the specified components
# if the components option is used.
#
# Copyright (c) 2011 Arjen Hiemstra <ahiemstra@heimr.nl>
# Redistribution and use is allowed according to the terms of the BSD license.
#
# Modified by Arnaud Barré to test if QtMobility is included into Qt (when configured with the option -mac-deploy)
set(QTMOBILITY_COMPONENTS
Bearer
Connectivity
Contacts
Feedback
Gallery
Location
Messaging
MultimediaKit
Organizer
PublishSubscribe
Sensors
ServiceFramework
SystemInfo
Versit
)
if (QtMobility_FIND_COMPONENTS)
foreach (component ${QtMobility_FIND_COMPONENTS})
string(TOUPPER ${component} _COMPONENT)
set(QTMOBILITY_USE_${_COMPONENT} 1)
endforeach (component)
endif (QtMobility_FIND_COMPONENTS)
find_path(QTMOBILITY_INCLUDE_DIR qmobilityglobal.h PATH_SUFFIXES QtMobility)
if (NOT QTMOBILITY_INCLUDE_DIR AND QT4_FOUND)
find_path(QTMOBILITY_INCLUDE_DIR qmobilityglobal.h PATH_SUFFIXES QtMobility PATHS ${QT_INCLUDE_DIR})
endif (NOT QTMOBILITY_INCLUDE_DIR AND QT4_FOUND)
#Find the mobility version
if(QTMOBILITY_INCLUDE_DIR)
file(READ "${QTMOBILITY_INCLUDE_DIR}/qmobilityglobal.h" _qtmobility_global_header LIMIT 5000)
string(REGEX MATCH "#define QTM_VERSION_STR \"([0-9.]*)\"" _qtmobility_version_match "${_qtmobility_global_header}")
set(QTMOBILITY_VERSION "${CMAKE_MATCH_1}")
endif(QTMOBILITY_INCLUDE_DIR)
set(QTMOBILITY_VARIABLES "QTMOBILITY_INCLUDE_DIR")
set(QTMOBILITY_INCLUDE_DIRS ${QTMOBILITY_INCLUDE_DIR})
#A list of files to find for specific components
set(QTMOBILITY_FIND_FILES
QNetworkConfiguration #Bearer
QBluetoothSocket #Connectivity
QContact #Contacts
QFeedbackInterface #Feedback
QAbstractGallery #Gallery
QLandmark #Location
QMessage #Messaging
QMediaPlayer #MultimediaKit
QOrganizerItem #Organizer
QValueSpace #PublishSubscribe
QSensor #Sensors
QService #ServiceFramework
QSystemInfo #SystemInfo
QVersitDocument #Versit
)
list(LENGTH QTMOBILITY_COMPONENTS _component_count)
math(EXPR _component_count "${_component_count} - 1")
foreach (index RANGE ${_component_count})
list(GET QTMOBILITY_COMPONENTS ${index} component)
list(GET QTMOBILITY_FIND_FILES ${index} file)
string(TOUPPER ${component} _COMPONENT)
if (NOT QtMobility_FIND_COMPONENTS OR QTMOBILITY_USE_${_COMPONENT})
find_path(QTMOBILITY_${_COMPONENT}_INCLUDE_DIR ${file} PATH_SUFFIXES Qt${component} qt4/Qt${component})
find_library(QTMOBILITY_${_COMPONENT}_LIBRARY NAMES Qt${component})
list(APPEND QTMOBILITY_VARIABLES "QTMOBILITY_${_COMPONENT}_INCLUDE_DIR" "QTMOBILITY_${_COMPONENT}_LIBRARY")
list(APPEND QTMOBILITY_INCLUDE_DIRS ${QTMOBILITY_${_COMPONENT}_INCLUDE_DIR})
list(APPEND QTMOBILITY_LIBRARIES ${QTMOBILITY_${_COMPONENT}_LIBRARY})
endif (NOT QtMobility_FIND_COMPONENTS OR QTMOBILITY_USE_${_COMPONENT})
endforeach (index)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(QtMobility REQUIRED_VARS ${QTMOBILITY_VARIABLES} VERSION_VAR QTMOBILITY_VERSION)
mark_as_advanced(${QTMOBILITY_VARIABLES})

View File

@ -1,2 +1,7 @@
# libqt-mobility # libqt-mobility
These new Qt APIs, not only enable Qt developers to include standard mobile functionality in their applications, but also provide useful application functionality across desktop platforms.
* Create dynamic navigation applications with the location API;
* Support standard mobile applications such as messaging, contacts and multimedia;
* Enable network roaming using bearer management.

View File

@ -0,0 +1,74 @@
From 44b00e4a5e6cd78d832b1fdb20b8244b49652491 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bla=C5=BE=20Toma=C5=BEi=C4=8D?= <blaz.tomazic@gmail.com>
Date: Wed, 23 May 2012 13:45:33 +0200
Subject: [PATCH 1/1] Fix building where unistd.h is missing
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Include "unistd.h" header in files that were reporting undefined
references to "getpid" and "getppid".
Signed-off-by: Blaž Tomažič <blaz.tomazic@gmail.com>
---
plugins/multimedia/pulseaudio/qaudioinput_pulse.cpp | 2 ++
plugins/multimedia/pulseaudio/qaudiooutput_pulse.cpp | 2 ++
plugins/multimedia/pulseaudio/qpulseaudioengine.cpp | 2 ++
src/systeminfo/linux/qsysteminfo_linux.cpp | 2 ++
4 files changed, 8 insertions(+)
diff --git a/plugins/multimedia/pulseaudio/qaudioinput_pulse.cpp b/plugins/multimedia/pulseaudio/qaudioinput_pulse.cpp
index f916595..136f4da 100644
--- a/plugins/multimedia/pulseaudio/qaudioinput_pulse.cpp
+++ b/plugins/multimedia/pulseaudio/qaudioinput_pulse.cpp
@@ -47,6 +47,8 @@
#include "qpulseaudioengine.h"
#include "qpulsehelpers.h"
+#include <unistd.h>
+
QT_BEGIN_NAMESPACE
const int PeriodTimeMs = 50;
diff --git a/plugins/multimedia/pulseaudio/qaudiooutput_pulse.cpp b/plugins/multimedia/pulseaudio/qaudiooutput_pulse.cpp
index 90c4470..a48ab8c 100644
--- a/plugins/multimedia/pulseaudio/qaudiooutput_pulse.cpp
+++ b/plugins/multimedia/pulseaudio/qaudiooutput_pulse.cpp
@@ -47,6 +47,8 @@
#include "qpulseaudioengine.h"
#include "qpulsehelpers.h"
+#include <unistd.h>
+
QT_BEGIN_NAMESPACE
const int PeriodTimeMs = 20;
diff --git a/plugins/multimedia/pulseaudio/qpulseaudioengine.cpp b/plugins/multimedia/pulseaudio/qpulseaudioengine.cpp
index 1abf93b..05014d3 100644
--- a/plugins/multimedia/pulseaudio/qpulseaudioengine.cpp
+++ b/plugins/multimedia/pulseaudio/qpulseaudioengine.cpp
@@ -47,6 +47,8 @@
#include "qaudiooutput_pulse.h"
#include "qpulsehelpers.h"
+#include <unistd.h>
+
QT_BEGIN_NAMESPACE
static void serverInfoCallback(pa_context *context, const pa_server_info *info, void *userdata)
diff --git a/src/systeminfo/linux/qsysteminfo_linux.cpp b/src/systeminfo/linux/qsysteminfo_linux.cpp
index af4be26..5e5f7d4 100644
--- a/src/systeminfo/linux/qsysteminfo_linux.cpp
+++ b/src/systeminfo/linux/qsysteminfo_linux.cpp
@@ -43,6 +43,8 @@
#include "qsysteminfo_dbus_p.h"
+#include <unistd.h>
+
#if !defined(Q_WS_MAEMO_6)
#if defined(Q_WS_X11)
#include <QX11Info>
--
1.7.10.2

140
libqt-mobility.spec Normal file
View File

@ -0,0 +1,140 @@
%define majver %(echo %version | cut -d. -f1-3)
Name: libqt-mobility
Version: 1.2.2.20120813
Release: 1mamba
Summary: Qt Mobility Framework
Group: System/Libraries
Vendor: openmamba
Distribution: openmamba
Packager: Davide Madrisan <davide.madrisan@gmail.com>
URL: http://qt.nokia.com/products/qt-addons/mobility
# git clone git://gitorious.org/qt-mobility/qt-mobility.git
# git archive --prefix=qt-mobility-opensource-src-1.2.2/ master | xz -9 > qt-mobility-opensource-src-1.2.2.20120813.tar.xz
Source: http://get.qt.nokia.com/qt/add-ons/qt-mobility-opensource-src-%{version}.tar.xz
Source1: FindQtMobility.cmake
Patch0: %{name}-1.2.2-gcc-4.7.patch
License: LGPL
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
BuildRequires: libalsa-devel
BuildRequires: libblkid-devel
BuildRequires: libgcc
BuildRequires: libGL-devel
BuildRequires: libglib-devel
BuildRequires: libGLU-devel
BuildRequires: libgst-plugins-base-devel
BuildRequires: libgstreamer-devel
%if "%{stage1}" != "1"
BuildRequires: libpulseaudio-devel
%endif
BuildRequires: libqt4-devel
BuildRequires: libstdc++6-devel
BuildRequires: libX11-devel
BuildRequires: libXext-devel
BuildRequires: libxml2-devel
BuildRequires: libXrandr-devel
BuildRequires: libXv-devel
BuildRequires: udev-devel
## AUTOBUILDREQ-END
Provides: qt-mobility
Obsoletes: qt-mobility
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
These new Qt APIs, not only enable Qt developers to include standard mobile functionality in their applications, but also provide useful application functionality across desktop platforms.
* Create dynamic navigation applications with the location API;
* Support standard mobile applications such as messaging, contacts and multimedia;
* Enable network roaming using bearer management.
%package devel
Group: Development/Libraries
Summary: Qt Mobility Framework development files
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
Provides: qt-mobility-devel
Obsoletes: qt-mobility-devel
%description devel
%{summary}.
%package apidocs
Group: Documentation
Summary: API documentation for %{name}
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
Provides: qt-mobility-apidocs
Obsoletes: qt-mobility-apidocs
%description apidocs
%{summary}.
%prep
%setup -q -n qt-mobility-opensource-src-%{majver}
%patch0 -p1
%build
PATH=%{_qt4_bindir}:$PATH; export PATH
./configure \
-prefix %{_qt4_prefix} \
-bindir %{_bindir} \
-headerdir %{_qt4_headerdir} \
-libdir %{_qt4_libdir} \
-plugindir %{_qt4_plugindir} \
-qmake-exec %{_qt4_qmake}
# -examples
%make
# CXXFLAGS="%{optflags} -fpermissive"
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
make install INSTALL_ROOT=%{buildroot}
#install -p -m644 -D doc/qch/qtmobility.qch %{buildroot}%{_qt4_docdir}/qch/qtmobility.qch
#install -d %{buildroot}%{_qt4_docdir}/html/qtmobility
#cp -a doc/html/* %{buildroot}%{_qt4_docdir}/html/qtmobility/
install -D -m0644 %{SOURCE1} %{buildroot}%{_datadir}/cmake/Modules/FindQtMobility.cmake
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files
%defattr(-,root,root)
%{_qt4_libdir}/libQt*.so.*
%{_qt4_libdir}/qt4/imports/QtMobility/
%{_qt4_libdir}/qt4/imports/QtMultimediaKit/
%{_qt4_plugindir}/*
%doc LICENSE.LGPL LGPL_EXCEPTION.txt
%files devel
%defattr(-,root,root)
%{_bindir}/icheck
%{_bindir}/ndefhandlergen
%{_bindir}/qcrmlgen
%{_bindir}/servicedbgen
%{_bindir}/servicefw
%{_bindir}/servicexmlgen
%{_bindir}/vsexplorer
%{_qt4_datadir}/mkspecs/features/mobility.prf
%{_qt4_datadir}/mkspecs/features/mobilityconfig.prf
%{_qt4_headerdir}/Qt*/
%{_qt4_libdir}/libQt*.prl
%{_qt4_libdir}/libQt*.so
%{_datadir}/cmake/Modules/FindQtMobility.cmake
#%doc changes*
#%files apidocs
#%defattr(-,root,root,-)
#%{_qt4_docdir}/qch/qtmobility.qch
#%{_qt4_docdir}/html/qtmobility/
%changelog
* Mon Aug 13 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 1.2.2.20120813-1mamba
- update to 1.2.2.20120813
* Mon Feb 27 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 1.2.0-2mamba
- renamed from qt-mobility to libqt-mobility
- added FindQtMobility.cmake file
* Sun Sep 18 2011 Davide Madrisan <davide.madrisan@gmail.com> 1.2.0-1mamba
- package created by autospec