summaryrefslogtreecommitdiffstats
path: root/src/network/bearer/bearer.pro
blob: 2255b7c8a50728c21afcb0de06783d8ed11d2658 (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
163
# Qt bearer management library
TEMPLATE = lib
TARGET = QtBearer

QT += network
include (../../common.pri)

DEFINES += QT_BUILD_BEARER_LIB QT_MAKEDLL

#DEFINES += BEARER_MANAGEMENT_DEBUG

PUBLIC_HEADERS += qnetworkconfiguration.h \
           qnetworksession.h \
           qnetworkconfigmanager.h

HEADERS += $$PUBLIC_HEADERS
SOURCES += qnetworksession.cpp \
           qnetworkconfigmanager.cpp \
           qnetworkconfiguration.cpp

symbian: {
    exists($${EPOCROOT}epoc32/release/winscw/udeb/cmmanager.lib)| \
    exists($${EPOCROOT}epoc32/release/armv5/lib/cmmanager.lib) {
        message("Building with SNAP support")
        DEFINES += SNAP_FUNCTIONALITY_AVAILABLE=1
        LIBS += -lcmmanager
    } else {
        message("Building without SNAP support")
	LIBS += -lapengine
    }
    
    INCLUDEPATH += $$APP_LAYER_SYSTEMINCLUDE

    HEADERS += qnetworkconfigmanager_s60_p.h \
               qnetworkconfiguration_s60_p.h \
               qnetworksession_s60_p.h
    SOURCES += qnetworkconfigmanager_s60_p.cpp \
               qnetworkconfiguration_s60_p.cpp \
               qnetworksession_s60_p.cpp
               
    LIBS += -lcommdb \
            -lapsettingshandlerui \
            -lconnmon \
            -lcentralrepository \
            -lesock \
            -linsock \
            -lecom \
            -lefsrv \
            -lnetmeta

    deploy.path = $${EPOCROOT}
    exportheaders.sources = $$PUBLIC_HEADERS
    exportheaders.path = epoc32/include
    
    for(header, exportheaders.sources) {
        BLD_INF_RULES.prj_exports += "$$header $$deploy.path$$exportheaders.path/$$basename(header)"
    }

    bearer_deployment.sources = QtBearer.dll
    bearer_deployment.path = /sys/bin
    DEPLOYMENT += bearer_deployment

    TARGET.CAPABILITY = All -TCB
} else {
    maemo {
        QT += dbus
	CONFIG += link_pkgconfig

	exists(../debug) {
		message("Enabling debug messages.")
		DEFINES += BEARER_MANAGEMENT_DEBUG
	}

        HEADERS += qnetworksession_maemo_p.h \
                   qnetworkconfigmanager_maemo_p.h \
                   qnetworkconfiguration_maemo_p.h

        SOURCES += qnetworkconfigmanager_maemo.cpp \
		   qnetworksession_maemo.cpp

	documentation.path = $$QT_MOBILITY_PREFIX/doc
        documentation.files = doc/html

	PKGCONFIG += glib-2.0 dbus-glib-1 gconf-2.0 osso-ic conninet

	CONFIG += create_pc create_prl
	QMAKE_PKGCONFIG_REQUIRES = glib-2.0 dbus-glib-1 gconf-2.0 osso-ic conninet
	pkgconfig.path = $$QT_MOBILITY_LIB/pkgconfig
	pkgconfig.files = QtBearer.pc

	INSTALLS += pkgconfig documentation

    } else {

        DEFINES += BEARER_ENGINE

        HEADERS += qnetworkconfigmanager_p.h \
                   qnetworkconfiguration_p.h \
                   qnetworksession_p.h \
                   qnetworksessionengine_p.h \
                   qgenericengine_p.h

        SOURCES += qnetworkconfigmanager_p.cpp \
                   qnetworksession_p.cpp \
                   qnetworksessionengine.cpp \
                   qgenericengine.cpp

        unix:!mac:contains(networkmanager_enabled, yes) {
            contains(QT_CONFIG,dbus) {
                DEFINES += BACKEND_NM
                QT += dbus

                HEADERS += qnmdbushelper_p.h \
                           qnetworkmanagerservice_p.h \
                           qnmwifiengine_unix_p.h

                SOURCES += qnmdbushelper.cpp \
                           qnetworkmanagerservice_p.cpp \
                           qnmwifiengine_unix.cpp
            } else {
                message("NetworkManager backend requires Qt DBus support")
            }
        }

        win32: {
            HEADERS += qnlaengine_win_p.h \
                   qnetworksessionengine_win_p.h

            !wince*:HEADERS += qnativewifiengine_win_p.h

            SOURCES += qnlaengine_win.cpp

            !wince*:SOURCES += qnativewifiengine_win.cpp

            !wince*:LIBS += -lWs2_32
            wince*:LIBS += -lWs2
        }
    }
    macx: {
        HEADERS += qcorewlanengine_mac_p.h
        SOURCES+= qcorewlanengine_mac.mm
        LIBS += -framework Foundation -framework SystemConfiguration

            contains(corewlan_enabled, yes) {
                     isEmpty(QMAKE_MAC_SDK) {
                         SDK6="yes"
                     } else {
                         contains(QMAKE_MAC_SDK, "/Developer/SDKs/MacOSX10.6.sdk") {
                             SDK6="yes"
                     }     
                 }
            
                !isEmpty(SDK6) {
                        LIBS += -framework CoreWLAN
                        DEFINES += MAC_SDK_10_6
                }
           }


    }
}

include(../../features/deploy.pri)