[contour] initial import

Jaroslav Reznik jreznik at fedoraproject.org
Wed Dec 7 15:29:52 UTC 2011


commit 06fe1a112877b50c5b615dd029d0a0a7ebbc016d
Author: Jaroslav Reznik <jreznik at redhat.com>
Date:   Wed Dec 7 16:29:41 2011 +0100

    initial import

 .gitignore                          |    1 +
 contour-0.1.1-find-qtmobility.patch |   11 +++
 contour.spec                        |   68 ++++++++++++++++++++
 qtmobility.diff                     |  115 +++++++++++++++++++++++++++++++++++
 sources                             |    1 +
 5 files changed, 196 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..1e0f5f7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/contour-0.1.1.tar.bz2
diff --git a/contour-0.1.1-find-qtmobility.patch b/contour-0.1.1-find-qtmobility.patch
new file mode 100644
index 0000000..6fd329c
--- /dev/null
+++ b/contour-0.1.1-find-qtmobility.patch
@@ -0,0 +1,11 @@
+diff -up contour-0.1.1/CMakeLists.txt.find-qtmobility contour-0.1.1/CMakeLists.txt
+--- contour-0.1.1/CMakeLists.txt.find-qtmobility	2011-09-28 19:05:15.000000000 +0200
++++ contour-0.1.1/CMakeLists.txt	2011-11-08 11:43:56.988493119 +0100
+@@ -1,6 +1,6 @@
+ project(contour)
+ 
+-set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${nepomuk_kde_SOURCE_DIR}/cmake)
++set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH} ${nepomuk_kde_SOURCE_DIR}/cmake)
+ 
+ # set the version to be used by ContourConfig.cmake and the lib version
+ # ===============================================================================================
diff --git a/contour.spec b/contour.spec
new file mode 100644
index 0000000..1247b9a
--- /dev/null
+++ b/contour.spec
@@ -0,0 +1,68 @@
+Name:           contour
+Version:        0.1.1
+Release:        1%{?dist}
+Summary:        A context sensitive user interface for Plasma Active
+
+License:        GPLv2+
+URL:            http://community.kde.org/Plasma/Active/Contour
+Source0:        ftp://ftp.kde.org/pub/kde/stable/active/1.0/src/contour-0.1.1.tar.bz2
+Patch0:         qtmobility.diff
+Patch1:         contour-0.1.1-find-qtmobility.patch
+
+BuildRequires:  cmake
+BuildRequires:  kdelibs-devel
+BuildRequires:  qt-mobility-devel
+BuildRequires:  soprano-devel
+BuildRequires:  shared-desktop-ontologies-devel
+BuildRequires:  kdebase-runtime-devel
+BuildRequires:  kdebase-workspace-devel
+BuildRequires:  libkactivities-devel
+
+
+%description
+Contour contributes a new usage paradigm using adaptive activities and 
+intelligent recommendations. Contour creates a context-sensitive user
+interface that adapts to current context, current activities and behavioral
+patterns of the user. 
+
+Contour is part of Plasma Active project.
+
+
+%prep
+%setup -q
+
+# FindQtMobility is under review for inclusion to kdelibs, not needed
+# by any other package
+# TODO: remove once included in kdelibs
+%patch0 -p1
+%patch1 -p1 -b .find-qtmobility
+
+%build
+mkdir -p %{_target_platform}
+pushd %{_target_platform}
+%{cmake_kde4} ..
+popd
+
+make %{?_smp_mflags} -C %{_target_platform}
+
+
+%install
+make install/fast DESTDIR=%{buildroot} -C %{_target_platform}
+
+
+%files
+%doc
+%{_kde4_bindir}/contour
+%{_kde4_libdir}/kde4/contour_recommendationengine_documents.so
+%{_kde4_libdir}/kde4/plasma_engine_recommendations.so
+%{_kde4_datadir}/autostart/contour.desktop
+%{_kde4_datadir}/cmake/Contour/
+%{_kde4_appsdir}/contour/
+%{_kde4_appsdir}/plasma/
+%{_kde4_sharedir}/kde4/services/*
+%{_kde4_sharedir}/kde4/servicetypes/*
+
+
+%changelog
+* Tue Nov 08 2011 Jaroslav Reznik <jreznik at redhat.com> - 0.1.1-1
+- initial try
\ No newline at end of file
diff --git a/qtmobility.diff b/qtmobility.diff
new file mode 100644
index 0000000..930300b
--- /dev/null
+++ b/qtmobility.diff
@@ -0,0 +1,115 @@
+diff --git a/cmake/modules-tests/QtMobility/CMakeLists.txt b/cmake/modules-tests/QtMobility/CMakeLists.txt
+--- /dev/null
++++ b/cmake/modules-tests/QtMobility/CMakeLists.txt
+@@ -0,0 +1,5 @@
++include("${CMAKE_CURRENT_SOURCE_DIR}/../TestFindPackage.cmake")
++
++set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../modules" )
++
++test_find_package(QtMobility QTMOBILITY INCLUDE_DIR INCLUDE_DIRS LIBRARIES)
+diff --git a/cmake/modules/FindQtMobility.cmake b/cmake/modules/FindQtMobility.cmake
+--- /dev/null
++++ b/cmake/modules/FindQtMobility.cmake
+@@ -0,0 +1,102 @@
++# - 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 at heimr.nl>
++# Redistribution and use is allowed according to the terms of the BSD license.
++
++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)
++
++#Find the mobility version
++if(QTMOBILITY_INCLUDE_DIR)
++    file(READ "${QTMOBILITY_INCLUDE_DIR}/qmobilityglobal.h" _qtmobility_global_header LIMIT 2000)
++    string(REGEX MATCH "#define QTM_VERSION_STR \"([0-9.]*)\"" _qtmobility_version_match  "${_qtmobility_global_header}")
++    set(QTMOBILITY_VERSION "${CMAKE_MATCH_1}")
++    message(STATUS "QtMobility Version ${QTMOBILITY_VERSION} detected")
++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})
++        message(STATUS "Looking for QtMobility Component \"${component}\"")
++        find_path(QTMOBILITY_${_COMPONENT}_INCLUDE_DIR ${file} PATH_SUFFIXES 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})
diff --git a/sources b/sources
index e69de29..65916cd 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+4cccfa37612365456f4dcf77c2da6a99  contour-0.1.1.tar.bz2


More information about the scm-commits mailing list