Skip to content

Commit 470f5f1

Browse files
author
mhugent
committed
[FEATURE]: Add QGIS mapserver sources to svn repository
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14110 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 151d665 commit 470f5f1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+11668
-13
lines changed

CMakeLists.txt

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ IF (WITH_GRASS)
4949
SET (GRASS_PREFIX ${GRASS_PREFIX} CACHE PATH "Path to GRASS base directory")
5050
ENDIF (WITH_GRASS)
5151

52+
# try to configure and build mapserver by default
53+
SET (WITH_MAPSERVER TRUE CACHE BOOL "Determines whether QGIS mapserver should be built")
54+
5255
# try to configure and build POSTGRESQL support
5356
SET (WITH_POSTGRESQL TRUE CACHE BOOL "Determines whether POSTGRESQL support should be built")
5457
IF (WITH_POSTGRESQL)
@@ -239,6 +242,7 @@ IF (WIN32)
239242

240243
IF (MSVC)
241244
SET (DEFAULT_BIN_SUBDIR bin)
245+
SET (DEFAULT_CGIBIN_SUBDIR bin)
242246
# put all the build products into a single directory
243247
# under build (doesnt affect install target) to make for
244248
# easier debugging.
@@ -262,6 +266,7 @@ IF (WIN32)
262266
ENDIF (INSTALL_DEPS)
263267
ELSE(MSVC)
264268
SET (DEFAULT_BIN_SUBDIR .)
269+
SET (DEFAULT_CGIBIN_SUBDIR .)
265270
ENDIF(MSVC)
266271
ELSE (WIN32)
267272

@@ -276,6 +281,7 @@ ELSE (WIN32)
276281

277282
# common for MAC and UNIX
278283
SET (DEFAULT_BIN_SUBDIR bin)
284+
SET (DEFAULT_CGIBIN_SUBDIR bin)
279285
SET (DEFAULT_LIB_SUBDIR lib${LIB_SUFFIX})
280286
SET (DEFAULT_DATA_SUBDIR share/qgis)
281287
SET (DEFAULT_LIBEXEC_SUBDIR lib${LIB_SUFFIX}/qgis)
@@ -285,7 +291,7 @@ ELSE (WIN32)
285291
ENDIF (WIN32)
286292

287293

288-
#assume we have excaped compiler directives
294+
#assume we have escaped compiler directives
289295
#eventually we want to change this to new
290296
#since we don't need to jump through so many
291297
#hoops to escape compiler directives then
@@ -323,6 +329,7 @@ ENDIF (WIN32)
323329
# (default values are platform-specific)
324330

325331
SET (QGIS_BIN_SUBDIR ${DEFAULT_BIN_SUBDIR} CACHE STRING "Subdirectory where executables will be installed")
332+
SET (QGIS_CGIBIN_SUBDIR ${DEFAULT_CGIBIN_SUBDIR} CACHE STRING "Subdirectory where CGI executables will be installed")
326333
SET (QGIS_LIB_SUBDIR ${DEFAULT_LIB_SUBDIR} CACHE STRING "Subdirectory where libraries will be installed")
327334
SET (QGIS_LIBEXEC_SUBDIR ${DEFAULT_LIBEXEC_SUBDIR} CACHE STRING "Subdirectory where private executables will be installed")
328335
SET (QGIS_DATA_SUBDIR ${DEFAULT_DATA_SUBDIR} CACHE STRING "Subdirectory where QGIS data will be installed")
@@ -335,6 +342,7 @@ MARK_AS_ADVANCED (QGIS_BIN_SUBDIR QGIS_LIB_SUBDIR QGIS_LIBEXEC_SUBDIR QGIS_DATA_
335342

336343
# full paths for the installation
337344
SET (QGIS_BIN_DIR ${QGIS_BIN_SUBDIR})
345+
SET (QGIS_CGIBIN_DIR ${QGIS_CGIBIN_SUBDIR})
338346
SET (QGIS_LIB_DIR ${QGIS_LIB_SUBDIR})
339347
SET (QGIS_LIBEXEC_DIR ${QGIS_LIBEXEC_SUBDIR})
340348
SET (QGIS_DATA_DIR ${QGIS_DATA_SUBDIR})

debian/control.sid

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Homepage: http://qgis.org/
1616

1717
Package: qgis
1818
Architecture: any
19-
Depends: ${shlibs:Depends}, ${misc:Depends}, qgis-common (= ${source:Version})
19+
Depends: ${shlibs:Depends}, ${misc:Depends}, qgis-providers (= ${binary:Version}), qgis-common (= ${source:Version})
2020
Recommends: qgis-plugin-grass, python-qgis
2121
Suggests: gpsbabel
2222
Conflicts: uim-qt3
@@ -114,3 +114,23 @@ Description: Python bindings to Quantum GIS - architecture-independent files
114114
This package contains architecture-independent files for the Quantum GIS
115115
Python bindings.
116116

117+
Package: qgis-providers
118+
Architecture: any
119+
Depends: ${shlibs:Depends}, ${misc:Depends}
120+
Replaces: qgis (<= 1.6)
121+
Breaks: qgis (<= 1.6)
122+
Description: collection of data providers to Quantum GIS
123+
Quantum GIS is a Geographic Information System (GIS) which manages, analyzes
124+
and display databases of geographic information.
125+
.
126+
This package contains the provider plugins for Quantum GIS.
127+
128+
Package: qgis-mapserver
129+
Architecture: any
130+
Depends: qgis-providers (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
131+
Description: Quantum GIS mapserver
132+
Quantum GIS is a Geographic Information System (GIS) which manages, analyzes
133+
and display databases of geographic information.
134+
.
135+
This package contains the Quantum GIS mapserver.
136+

debian/qgis.install

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,20 @@
11
usr/bin/qgis_help
22
usr/lib/qgis/plugins/libcopyrightlabelplugin.so
33
usr/lib/qgis/plugins/libdelimitedtextplugin.so
4-
usr/lib/qgis/plugins/libdelimitedtextprovider.so
54
usr/lib/qgis/plugins/libgeorefplugin.so
65
usr/lib/qgis/plugins/libgpsimporterplugin.so
7-
usr/lib/qgis/plugins/libgpxprovider.so
86
usr/lib/qgis/plugins/libnortharrowplugin.so
9-
usr/lib/qgis/plugins/libogrprovider.so
10-
usr/lib/qgis/plugins/libpostgresprovider.so
117
usr/lib/qgis/plugins/libquickprintplugin.so
128
usr/lib/qgis/plugins/libscalebarplugin.so
139
usr/lib/qgis/plugins/libspitplugin.so
1410
usr/lib/qgis/plugins/libwfsplugin.so
15-
usr/lib/qgis/plugins/libwfsprovider.so
16-
usr/lib/qgis/plugins/libwmsprovider.so
17-
usr/lib/qgis/plugins/libmemoryprovider.so
1811
usr/lib/qgis/plugins/libdxf2shpconverterplugin.so
1912
usr/lib/qgis/plugins/libinterpolationplugin.so
2013
usr/lib/qgis/plugins/libogrconverterplugin.so
2114
usr/lib/qgis/plugins/libcoordinatecaptureplugin.so
22-
usr/lib/qgis/plugins/libspatialiteprovider.so
2315
usr/lib/qgis/plugins/liboracleplugin.so
2416
usr/lib/qgis/plugins/libdiagramoverlay.so
2517
usr/lib/qgis/plugins/libevis.so
26-
usr/lib/qgis/plugins/libosmprovider.so
2718
usr/lib/qgis/plugins/librasterterrainplugin.so
2819
usr/lib/qgis/plugins/libspatialqueryplugin.so
2920
usr/lib/qgis/plugins/libdisplacementplugin.so

debian/rules

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ CMAKE_OPTS := \
2828
-D CMAKE_SKIP_RPATH=TRUE \
2929
-D BINDINGS_GLOBAL_INSTALL=TRUE \
3030
-D PEDANTIC=TRUE \
31-
-D WITH_SPATIALITE=TRUE
31+
-D WITH_SPATIALITE=TRUE \
32+
-D QGIS_CGIBIN_SUBDIR=/usr/lib/cgi-bin
3233

3334
ifeq (,$(findstring $(DISTRIBUTION),"squeeze lucid maverick sid"))
3435
CMAKE_OPTS += -D WITH_INTERNAL_SPATIALITE=TRUE

src/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
1-
21
SUBDIRS(core analysis ui gui app providers plugins helpviewer)
32

43
IF (WITH_BINDINGS)
54
SUBDIRS(python)
65
ENDIF (WITH_BINDINGS)
76

7+
IF (WITH_MAPSERVER)
8+
SUBDIRS(mapserver)
9+
ENDIF (WITH_MAPSERVER)
10+
811
IF (APPLE)
912
SUBDIRS(mac)
1013
ENDIF(APPLE)
14+

src/mapserver/CMakeLists.txt

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
#
2+
# Find deps
3+
#
4+
FIND_PACKAGE(Fcgi REQUIRED)
5+
IF (NOT FCGI_FOUND)
6+
MESSAGE (SEND_ERROR "Fast CGI dependency was not found!")
7+
ENDIF (NOT FCGI_FOUND)
8+
9+
# We need to define the qgis base dir so we can pass it
10+
# into the main entry point for the app so that at
11+
# runtime it can find plugins and srs.db etc
12+
ADD_DEFINITIONS(-DQGIS_LIB_DIR="\\"${QGIS_LIB_DIR}\\"")
13+
14+
#MH: for this we need to locate the headers of the diagram and interpolation plugin
15+
#ADD_DEFINITIONS(-DDIAGRAMSERVER=1)
16+
17+
IF (CMAKE_BUILD_TYPE MATCHES Debug)
18+
ADD_DEFINITIONS(-DQGSMSDEBUG=1)
19+
ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
20+
########################################################
21+
# Files
22+
23+
SET ( qgis_mapserv_SRCS
24+
qgis_map_serv.cpp
25+
qgsconfigcache.cpp
26+
qgsconfigparser.cpp
27+
qgsepsgcache.cpp
28+
qgsprojectparser.cpp
29+
qgshttprequesthandler.cpp
30+
qgsgetrequesthandler.cpp
31+
qgssoaprequesthandler.cpp
32+
qgssldparser.cpp
33+
qgssldrenderer.cpp
34+
qgswmsserver.cpp
35+
qgsmapserviceexception.cpp
36+
qgsmapserverlogger.cpp
37+
qgsmslayercache.cpp
38+
qgsfilter.cpp
39+
qgssldrule.cpp
40+
qgsbetweenfilter.cpp
41+
qgscomparisonfilter.cpp
42+
qgslogicalfilter.cpp
43+
qgsftptransaction.cpp
44+
qgsmslayerbuilder.cpp
45+
qgshostedvdsbuilder.cpp
46+
qgsinterpolationlayerbuilder.cpp
47+
qgsremoteowsbuilder.cpp
48+
qgshostedrdsbuilder.cpp
49+
qgsremotedatasourcebuilder.cpp
50+
qgssentdatasourcebuilder.cpp
51+
qgsmsutils.cpp
52+
)
53+
54+
# SET (qgis_mapserv_UIS
55+
# none used
56+
# )
57+
58+
SET (qgis_mapserv_MOC_HDRS
59+
qgsftptransaction.h
60+
)
61+
62+
SET (qgis_mapserv_RCCS
63+
# not used
64+
#qgis_mapserv.qrc
65+
)
66+
67+
QT4_WRAP_UI (qgis_mapserv_UIS_H ${qgis_mapserv_UIS})
68+
69+
QT4_WRAP_CPP (qgis_mapserv_MOC_SRCS ${qgis_mapserv_MOC_HDRS})
70+
71+
QT4_ADD_RESOURCES(qgis_mapserv_RCC_SRCS ${qgis_mapserv_RCCS})
72+
73+
ADD_EXECUTABLE(qgis_mapserv.fcgi
74+
${qgis_mapserv_SRCS}
75+
${qgis_mapserv_MOC_SRCS}
76+
${qgis_mapserv_RCC_SRCS}
77+
${qgis_mapserv_UIS_H}
78+
)
79+
80+
INCLUDE_DIRECTORIES(
81+
${GDAL_INCLUDE_DIR}
82+
${FCGI_INCLUDE_DIR}
83+
${GEOS_INCLUDE_DIR}
84+
${PROJ_INCLUDE_DIR}
85+
${POSTGRES_INCLUDE_DIR}
86+
${CMAKE_CURRENT_BINARY_DIR}
87+
${QT_INCLUDE_DIR}
88+
${QGIS_INCLUDE_DIR}
89+
../core
90+
../core/raster
91+
../core/renderer
92+
../core/symbology
93+
../core/symbology-ng
94+
../core/composer
95+
../analysis/interpolation
96+
.
97+
)
98+
99+
TARGET_LINK_LIBRARIES(qgis_mapserv.fcgi
100+
qgis_core
101+
qgis_analysis
102+
${PROJ_LIBRARY}
103+
${FCGI_LIBRARY}
104+
${POSTGRES_LIBRARY}
105+
${GDAL_LIBRARY}
106+
)
107+
108+
########################################################
109+
# Install
110+
111+
INSTALL(CODE "MESSAGE(\"Installing mapserver...\")")
112+
INSTALL(TARGETS
113+
qgis_mapserv.fcgi
114+
DESTINATION ${QGIS_CGIBIN_DIR}
115+
)
116+
INSTALL(FILES
117+
admin.sld
118+
wms_metadata.xml
119+
DESTINATION ${QGIS_CGIBIN_DIR}
120+
)
121+

src/mapserver/admin.sld

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<StyledLayerDescriptor xmlns="http://www.opengis.net/sld">
2+
<UserLayer>
3+
<Name>wfslayer</Name>
4+
<RemoteOWS>
5+
<Service>WFS</Service>
6+
<OnlineResource href="http://karlinapp.ethz.ch/cgi-bin/mapserv?map=/home/marco/mapfiles/mapfile1.map&amp;" type="states" />
7+
</RemoteOWS>
8+
<UserStyle>
9+
<Name>userstyle</Name>
10+
<FeatureTypeStyle>
11+
<Rule>
12+
<PolygonSymbolizer>
13+
<Stroke><sld:CssParameter sld:name="stroke">#0000ff</sld:CssParameter>
14+
<sld:CssParameter sld:name="stroke-width">3</sld:CssParameter>
15+
</Stroke>
16+
<Fill>
17+
<sld:CssParameter sld:name="fill">#0000ff</sld:CssParameter>
18+
</Fill>
19+
</PolygonSymbolizer>
20+
</Rule>
21+
</FeatureTypeStyle>
22+
</UserStyle>
23+
</UserLayer>
24+
</StyledLayerDescriptor>

src/mapserver/common.xml

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
<serviceCommonCapabilities xmlns="http://eu-orchestra.org/services/ms">
2+
<OA_MI_Service_CommonCapabilities>
3+
<serviceDescription>Orchestra Map and Diagram Service</serviceDescription>
4+
<serviceDiscoveryBasic>
5+
<OA_MI_Service_DiscoveryBasic>
6+
<freeKeywords>
7+
<OA_MI_Service_FreeKeywords>
8+
<OA_MI_Keywords>
9+
<keywords>Map and Diagram Service</keywords>
10+
<keywords>MS</keywords>
11+
<keywords>ORCHESTRA</keywords>
12+
</OA_MI_Keywords>
13+
</OA_MI_Service_FreeKeywords>
14+
</freeKeywords>
15+
<yellowPageInfo>
16+
<OA_MI_Service_YellowPageInfo>
17+
<business>
18+
<OA_MI_Service_BusinessClassification>
19+
<identifier>GeoVisualization</identifier>
20+
</OA_MI_Service_BusinessClassification>
21+
</business>
22+
</OA_MI_Service_YellowPageInfo>
23+
</yellowPageInfo>
24+
</OA_MI_Service_DiscoveryBasic>
25+
</serviceDiscoveryBasic>
26+
<serviceDocumentation>https://portal.opengeospatial.org/files/?artifact_id=16644</serviceDocumentation>
27+
<serviceInvocationBasic>
28+
<OA_MI_Service_InvocationBasic>
29+
<operation>
30+
<OA_MI_Operation>
31+
<accessPoints>
32+
<OA_MI_AccessPoint>
33+
<uri>http://karlinapp.ethz.ch/cgi-bin/orchestra_map_serv</uri>
34+
</OA_MI_AccessPoint>
35+
</accessPoints>
36+
<description>Delivers capabilities of the map and diagram service.</description>
37+
<name>getCapabilities</name>
38+
<parameters>
39+
<OA_MI_OperationParameter>
40+
<description>request</description>
41+
<direction>in</direction>
42+
<name>request</name>
43+
<optionality>false</optionality>
44+
<repeatability>false</repeatability>
45+
<valueType>OAGetCapabilitiesRequest</valueType>
46+
</OA_MI_OperationParameter>
47+
</parameters>
48+
<parameters>
49+
<OA_MI_OperationParameter>
50+
<description>response</description>
51+
<direction>out</direction>
52+
<name>response</name>
53+
<optionality>false</optionality>
54+
<repeatability>false</repeatability>
55+
<valueType>OAGetCapabilitiesResponse</valueType>
56+
</OA_MI_OperationParameter>
57+
</parameters>
58+
</OA_MI_Operation>
59+
</operation>
60+
<operation>
61+
<OA_MI_Operation>
62+
<accessPoints>
63+
<OA_MI_AccessPoint>
64+
<uri>http://karlinapp.ethz.ch/cgi-bin/orchestra_map_serv</uri>
65+
</OA_MI_AccessPoint>
66+
</accessPoints>
67+
<description>Returns a map from the server based on the user parameters</description>
68+
<name>getMap</name>
69+
<parameters>
70+
<OA_MI_OperationParameter>
71+
<description>request</description>
72+
<direction>in</direction>
73+
<name>request</name>
74+
<optionality>false</optionality>
75+
<repeatability>false</repeatability>
76+
<valueType>OAGetMapRequest</valueType>
77+
</OA_MI_OperationParameter>
78+
</parameters>
79+
<parameters>
80+
<OA_MI_OperationParameter>
81+
<description>response</description>
82+
<direction>out</direction>
83+
<name>response</name>
84+
<optionality>false</optionality>
85+
<repeatability>false</repeatability>
86+
<valueType>OAGetMapResponse</valueType>
87+
</OA_MI_OperationParameter>
88+
</parameters>
89+
</OA_MI_Operation>
90+
</operation>
91+
</OA_MI_Service_InvocationBasic>
92+
</serviceInvocationBasic>
93+
<serviceName>Map and Diagram Service</serviceName>
94+
<serviceSpecVersion>1.1</serviceSpecVersion>
95+
<serviceType>Map and Diagram Service</serviceType>
96+
</OA_MI_Service_CommonCapabilities>
97+
</serviceCommonCapabilities>

0 commit comments

Comments
 (0)