1 /****************************************************************************
3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
4 ** All rights reserved.
5 ** Contact: Nokia Corporation (qt-info@nokia.com)
7 ** This file is part of the Qt Mobility Components.
9 ** $QT_BEGIN_LICENSE:LGPL$
10 ** No Commercial Usage
11 ** This file contains pre-release code and may not be distributed.
12 ** You may use this file in accordance with the terms and conditions
13 ** contained in the Technology Preview License Agreement accompanying
16 ** GNU Lesser General Public License Usage
17 ** Alternatively, this file may be used under the terms of the GNU Lesser
18 ** General Public License version 2.1 as published by the Free Software
19 ** Foundation and appearing in the file LICENSE.LGPL included in the
20 ** packaging of this file. Please review the following information to
21 ** ensure the GNU Lesser General Public License version 2.1 requirements
22 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
24 ** In addition, as a special exception, Nokia gives you certain additional
25 ** rights. These rights are described in the Nokia Qt LGPL Exception
26 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
28 ** If you have questions regarding the use of this file, please contact
29 ** Nokia at qt-info@nokia.com.
40 ****************************************************************************/
41 #ifndef QMOBILITYGLOBAL_H
42 #define QMOBILITYGLOBAL_H
45 #define QTM_VERSION_STR "1.0.0"
47 QTM_VERSION is (major << 16) + (minor << 8) + patch.
49 #define QTM_VERSION 0x010000
51 can be used like #if (QTM_VERSION >= QTM_VERSION_CHECK(1, 0, 0))
53 #define QTM_VERSION_CHECK(major, minor, patch) ((major<<16)|(minor<<8)|(patch))
55 #define QTM_PACKAGEDATE_STR "YYYY-MM-DD"
57 #define QTM_PACKAGE_TAG ""
59 #if defined(QTM_BUILD_UNITTESTS)
61 # if !defined(QT_BUILD_INTERNAL)
62 # define QT_BUILD_INTERNAL
65 #include <QtCore/qglobal.h>
67 #if defined(SYMBIAN_DATABASEMANAGER_SERVER)
68 # define Q_SERVICEFW_EXPORT
70 # if defined(Q_OS_WIN) || defined(Q_OS_SYMBIAN)
71 # if defined(QT_NODLL)
74 # elif defined(QT_MAKEDLL)
78 # if defined(QT_BUILD_BEARER_LIB)
79 # define Q_BEARER_EXPORT Q_DECL_EXPORT
81 # define Q_BEARER_EXPORT Q_DECL_IMPORT
83 # if defined(QT_BUILD_CFW_LIB)
84 # define Q_PUBLISHSUBSCRIBE_EXPORT Q_DECL_EXPORT
86 # define Q_PUBLISHSUBSCRIBE_EXPORT Q_DECL_IMPORT
88 # if defined(QT_BUILD_CONTACTS_LIB)
89 # define Q_CONTACTS_EXPORT Q_DECL_EXPORT
91 # define Q_CONTACTS_EXPORT Q_DECL_IMPORT
93 # if defined(QT_BUILD_VERSIT_LIB)
94 # define Q_VERSIT_EXPORT Q_DECL_EXPORT
96 # define Q_VERSIT_EXPORT Q_DECL_IMPORT
98 # if defined(QT_BUILD_LOCATION_LIB)
99 # define Q_LOCATION_EXPORT Q_DECL_EXPORT
101 # define Q_LOCATION_EXPORT Q_DECL_IMPORT
103 # if defined(QT_BUILD_MESSAGING_LIB)
104 # define Q_MESSAGING_EXPORT Q_DECL_EXPORT
106 # define Q_MESSAGING_EXPORT Q_DECL_IMPORT
108 # if defined(QT_BUILD_MEDIA_LIB)
109 # define Q_MEDIA_EXPORT Q_DECL_EXPORT
111 # define Q_MEDIA_EXPORT Q_DECL_IMPORT
113 # if defined(QT_BUILD_SFW_LIB)
114 # define Q_SERVICEFW_EXPORT Q_DECL_EXPORT
116 # define Q_SERVICEFW_EXPORT Q_DECL_IMPORT
118 # if defined(QT_BUILD_SYSINFO_LIB)
119 # define Q_SYSINFO_EXPORT Q_DECL_EXPORT
121 # define Q_SYSINFO_EXPORT Q_DECL_IMPORT
123 # if defined(QT_BUILD_SENSORS_LIB)
124 # define Q_SENSORS_EXPORT Q_DECL_EXPORT
126 # define Q_SENSORS_EXPORT Q_DECL_IMPORT
128 # elif defined(QT_DLL) /* use a Qt DLL library */
129 # define Q_BEARER_EXPORT Q_DECL_IMPORT
130 # define Q_PUBLISHSUBSCRIBE_EXPORT Q_DECL_IMPORT
131 # define Q_CONTACTS_EXPORT Q_DECL_IMPORT
132 # define Q_VERSIT_EXPORT Q_DECL_IMPORT
133 # define Q_LOCATION_EXPORT Q_DECL_IMPORT
134 # define Q_MEDIA_EXPORT Q_DECL_IMPORT
135 # define Q_MESSAGING_EXPORT Q_DECL_IMPORT
136 # define Q_SERVICEFW_EXPORT Q_DECL_IMPORT
137 # define Q_SYSINFO_EXPORT Q_DECL_IMPORT
138 # define Q_SENSORS_EXPORT Q_DECL_IMPORT
142 # if !defined(Q_SERVICEFW_EXPORT)
143 # if defined(QT_SHARED)
144 # define Q_BEARER_EXPORT Q_DECL_EXPORT
145 # define Q_PUBLISHSUBSCRIBE_EXPORT Q_DECL_EXPORT
146 # define Q_CONTACTS_EXPORT Q_DECL_EXPORT
147 # define Q_VERSIT_EXPORT Q_DECL_EXPORT
148 # define Q_LOCATION_EXPORT Q_DECL_EXPORT
149 # define Q_MEDIA_EXPORT Q_DECL_EXPORT
150 # define Q_MESSAGING_EXPORT Q_DECL_EXPORT
151 # define Q_SERVICEFW_EXPORT Q_DECL_EXPORT
152 # define Q_SYSINFO_EXPORT Q_DECL_EXPORT
153 # define Q_SENSORS_EXPORT Q_DECL_EXPORT
155 # define Q_BEARER_EXPORT
156 # define Q_PUBLISHSUBSCRIBE_EXPORT
157 # define Q_CONTACTS_EXPORT
158 # define Q_VERSIT_EXPORT
159 # define Q_LOCATION_EXPORT
160 # define Q_MEDIA_EXPORT
161 # define Q_MESSAGING_EXPORT
162 # define Q_SERVICEFW_EXPORT
163 # define Q_SYSINFO_EXPORT
164 # define Q_SENSORS_EXPORT
169 // The namespace is hardcoded as moc has issues resolving
170 // macros which would be a prerequisite for a dynmamic namespace
171 #define QTM_NAMESPACE QtMobility
174 # define QTM_PREPEND_NAMESPACE(name) ::QTM_NAMESPACE::name
175 # define QTM_BEGIN_NAMESPACE namespace QTM_NAMESPACE {
176 # define QTM_END_NAMESPACE }
177 # define QTM_USE_NAMESPACE using namespace QTM_NAMESPACE;
179 # define QTM_PREPEND_NAMESPACE(name) ::name
180 # define QTM_BEGIN_NAMESPACE
181 # define QTM_END_NAMESPACE
182 # define QTM_USE_NAMESPACE
185 //in case Qt is in namespace
188 #endif // QMOBILITYGLOBAL_H