summaryrefslogtreecommitdiffstats
path: root/src/bluetooth/bluetooth.pro
blob: f1b00b30bbdd48d1a51a31b923e815075d162663 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
load(qt_module)

TARGET = QtBluetooth
QPRO_PWD = $PWD

CONFIG += module
MODULE_PRI = ../../modules/qt_bluetooth.pri

DEFINES += QT_BUILD_BT_LIB QT_MAKEDLL

load(qt_module_config)

PUBLIC_HEADERS += \
    qbluetoothaddress.h\
    qbluetoothuuid.h\
    qbluetoothdeviceinfo.h\
    qbluetoothserviceinfo.h\
    qbluetoothdevicediscoveryagent.h\
    qbluetoothservicediscoveryagent.h\
    qbluetoothsocket.h\
    qrfcommserver.h \
    ql2capserver.h \
    qbluetooth.h \
    qbluetoothlocaldevice.h \
    ql2capsocket.h \
    qrfcommsocket.h \
    qbluetoothtransfermanager.h \
    qbluetoothtransferrequest.h \
    qbluetoothtransferreply.h

PRIVATE_HEADERS += \
    qbluetoothaddress_p.h\
    qbluetoothdeviceinfo_p.h\
    qbluetoothserviceinfo_p.h\
    qbluetoothdevicediscoveryagent_p.h\
    qbluetoothservicediscoveryagent_p.h\
    qbluetoothsocket_p.h\
    qrfcommserver_p.h \
    ql2capserver_p.h \
    qbluetoothtransferreply_p.h \
    qbluetoothtransferrequest_p.h

SOURCES += \
    qbluetoothaddress.cpp\
    qbluetoothuuid.cpp\
    qbluetoothdeviceinfo.cpp\
    qbluetoothserviceinfo.cpp\
    qbluetoothdevicediscoveryagent.cpp\
    qbluetoothservicediscoveryagent.cpp\
    qbluetoothsocket.cpp\
    qrfcommserver.cpp \
    ql2capserver.cpp \
    qbluetoothlocaldevice.cpp \
    qbluetooth.cpp \
    ql2capsocket.cpp \
    qrfcommsocket.cpp \
    qbluetoothtransfermanager.cpp \
    qbluetoothtransferrequest.cpp \
    qbluetoothtransferreply.cpp

symbian {
    contains(S60_VERSION, 3.1) | contains(S60_VERSION, 3.2) {
        DEFINES += DO_NOT_BUILD_BLUETOOTH_SYMBIAN_BACKEND
        message("S60 3.1 or 3.2 sdk not supported by bluetooth")
        SOURCES += \
            qbluetoothdevicediscoveryagent_p.cpp \
            qbluetoothlocaldevice_p.cpp \
            qbluetoothserviceinfo_p.cpp \
            qbluetoothservicediscoveryagent_p.cpp \
            qbluetoothsocket_p.cpp \
            ql2capserver_p.cpp \
            qrfcommserver_p.cpp \
            qbluetoothtransfermanager_p.cpp
    }
}

symbian {
    !contains(DEFINES, DO_NOT_BUILD_BLUETOOTH_SYMBIAN_BACKEND) {
        DEFINES += QT_SYMBIAN_BLUETOOTH
        INCLUDEPATH += $$MW_LAYER_SYSTEMINCLUDE
        include(symbian/symbian.pri)

        PRIVATE_HEADERS += \
            qbluetoothtransferreply_symbian_p.h \
            qbluetoothlocaldevice_p.h

        SOURCES += \
            qbluetoothserviceinfo_symbian.cpp\
            qbluetoothdevicediscoveryagent_symbian.cpp\
            qbluetoothservicediscoveryagent_symbian.cpp\
            qbluetoothsocket_symbian.cpp\
            qrfcommserver_symbian.cpp \
            qbluetoothlocaldevice_symbian.cpp \
            qbluetoothtransfermanager_symbian.cpp \
            qbluetoothtransferreply_symbian.cpp \
            ql2capserver_symbian.cpp

        contains(S60_VERSION, 5.0) {
            message("NOTICE - START")
            message("Bluetooth backend needs SDK plugin from Forum Nokia for 5.0 SDK")
            message("NOTICE - END")
            LIBS *= -lirobex
        } else {
            LIBS *= -lobex
        }
        LIBS *= -lesock \
                -lbluetooth \
                -lsdpagent \
                -lsdpdatabase \
                -lestlib \
                -lbtengsettings \
                -lbtmanclient \
                -lbtdevice
    }
} else:contains(config_test_bluez, yes):contains(QT_CONFIG, dbus) {
    QT *= dbus
    DEFINES += QT_BLUEZ_BLUETOOTH

    include(bluez/bluez.pri)

    PRIVATE_HEADERS += \
        qbluetoothtransferreply_bluez_p.h \
        qbluetoothlocaldevice_p.h

    SOURCES += \
        qbluetoothserviceinfo_bluez.cpp \
        qbluetoothdevicediscoveryagent_bluez.cpp\
        qbluetoothservicediscoveryagent_bluez.cpp \
        qbluetoothsocket_bluez.cpp \
        qrfcommserver_bluez.cpp \
        qbluetoothlocaldevice_bluez.cpp \
        qbluetoothtransferreply_bluez.cpp \
        qbluetoothtransfermanager_bluez.cpp \
        ql2capserver_bluez.cpp

    exists(/usr/include/test_framework_4711.h) {
        message(Activating Nokia Bluetooth Services)
        DEFINES += NOKIA_BT_SERVICES
        QT += serviceframework
    }

} else {
    message("Unsupported bluetooth platform, will not build a working QBluetooth library")
    message("Either no Qt dBus found, no bluez headers, or not symbian")
    SOURCES += \
        qbluetoothdevicediscoveryagent_p.cpp \
        qbluetoothlocaldevice_p.cpp \
        qbluetoothserviceinfo_p.cpp \
        qbluetoothservicediscoveryagent_p.cpp \
        qbluetoothsocket_p.cpp \
        ql2capserver_p.cpp \
        qrfcommserver_p.cpp \
        qbluetoothtransfermanager_p.cpp

}

INCLUDEPATH += $$PWD
INCLUDEPATH += ..

OTHER_FILES +=

HEADERS += $$PUBLIC_HEADERS $$PRIVATE_HEADERS