Skip to content

Commit 5f304b3

Browse files
committed
Merge remote-tracking branch 'origin/master' into new_vector_api
Conflicts: python/core/qgsvectordataprovider.sip src/app/legend/qgslegendlayer.cpp src/app/qgisapp.cpp src/app/qgsmergeattributesdialog.cpp src/core/qgsvectordataprovider.cpp src/core/qgsvectordataprovider.h src/core/qgsvectorlayer.cpp src/gui/qgssearchquerybuilder.cpp src/providers/postgres/qgspostgresprovider.cpp src/providers/wfs/CMakeLists.txt
2 parents dda51c6 + 5f70a68 commit 5f304b3

File tree

660 files changed

+65222
-29264
lines changed

Some content is hidden

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

660 files changed

+65222
-29264
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,4 @@ i18n/*.qm
4848
.idea
4949
/python/plugins/sextante/resources_rc.py
5050
/python/plugins/sextante/about/ui_aboutdialogbase.py
51+
scripts/qgisstyle

CMakeLists.txt

+10-1
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,11 @@ IF (WITH_SPATIALITE)
7070
ENDIF (WITH_INTERNAL_SPATIALITE)
7171
ENDIF (WITH_SPATIALITE)
7272

73+
SET (WITH_ORACLE FALSE CACHE BOOL "Determines whether Oracle support should be built")
74+
IF(WITH_ORACLE)
75+
SET(HAVE_ORACLE TRUE)
76+
ENDIF(WITH_ORACLE)
77+
7378
# try to configure and build python bindings by default
7479
SET (WITH_BINDINGS TRUE CACHE BOOL "Determines whether python bindings should be built")
7580
IF (WITH_BINDINGS)
@@ -82,6 +87,10 @@ IF (WITH_BINDINGS)
8287
SET (WITH_PY_COMPILE FALSE CACHE BOOL "Determines whether Python modules in staged or installed locations are byte-compiled")
8388
# concatenate QScintilla2 API files
8489
SET (WITH_QSCIAPI TRUE CACHE BOOL "Determines whether the QScintilla2 API files will be updated and concatenated")
90+
# path to custom Python framework on Mac
91+
IF (APPLE)
92+
SET (PYTHON_CUSTOM_FRAMEWORK "" CACHE PATH "Path to custom Python.framework on Mac. (should not have to specify other Python options)")
93+
ENDIF (APPLE)
8594
ENDIF (WITH_BINDINGS)
8695

8796
#BUILD WITH QtMobility by default on android only. Other platform can force it
@@ -157,7 +166,7 @@ ENDIF(NOT WIN32 AND NOT ANDROID)
157166
FIND_PACKAGE(Proj)
158167
FIND_PACKAGE(GEOS)
159168
FIND_PACKAGE(GDAL)
160-
FIND_PACKAGE(Expat)
169+
FIND_PACKAGE(Expat REQUIRED)
161170
FIND_PACKAGE(Spatialindex REQUIRED)
162171
FIND_PACKAGE(Qwt REQUIRED)
163172

INSTALL

+14-12
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
Quantum GIS (QGIS)
22
Building QGIS from source - step by step
3-
Tuesday October 23, 2012
3+
Friday January 04, 2013
44

55

6-
Last Updated: Tuesday October 23, 2012
7-
Last Change : Tuesday October 23, 2012
6+
Last Updated: Friday January 04, 2013
7+
Last Change : Friday January 04, 2013
88

99

1010
1. Introduction
@@ -104,13 +104,14 @@ Required build deps:
104104
- Sqlite3 >= 3.0.0
105105
- GDAL/OGR >= 1.4.x
106106
- Qwt >= 5.0
107+
- expat >= 1.95
107108

108109
Optional dependencies:
109110

110111
- for GRASS plugin - GRASS >= 6.0.0 (libraries compiled with exceptions support on Linux 32bit)
111112
- for georeferencer - GSL >= 1.8
112113
- for postgis support and SPIT plugin - PostgreSQL >= 8.0.x
113-
- for gps plugin - expat >= 1.95 and gpsbabel
114+
- for gps plugin - gpsbabel
114115
- for mapserver export and PyQGIS - Python >= 2.3 (2.5+ preferred)
115116
- for python support - SIP >= 4.8, PyQt >= must match Qt version, Qscintilla2
116117
- for qgis mapserver - FastCGI
@@ -539,7 +540,7 @@ To run QGIS just use this command
539540
==========================================
540541

541542
This section describes how to build QGIS using Visual Studio on Windows. This
542-
is currently also who the binary QGIS packages are made (earlier versions used
543+
is currently also how the binary QGIS packages are made (earlier versions used
543544
MinGW).
544545

545546
This section describes the setup required to allow Visual Studio to be used to
@@ -608,7 +609,9 @@ Earlier versions of this document also covered how to build all above
608609
dependencies. If you're interested in that, check the history of this page in the Wiki
609610
or the SVN repository.
610611

611-
=== Setting up the Visual Studio project with CMake ===
612+
613+
4.1.3. Setting up the Visual Studio project with CMake
614+
======================================================
612615

613616
To start a command prompt with an environment that both has the VC++ and the OSGeo4W
614617
variables create the following batch file (assuming the above packages were
@@ -633,7 +636,6 @@ installed in the default locations):
633636

634637
@cmd
635638

636-
637639
Start the batch file and on the command prompt checkout the QGIS source from
638640
git to the source directory Quantum-GIS:
639641

@@ -642,8 +644,8 @@ git to the source directory Quantum-GIS:
642644
Create a 'build' directory somewhere. This will be where all the build output
643645
will be generated.
644646

645-
Now run cmake-gui and in the Where is the source code: box, browse to
646-
the top level QGIS directory.
647+
Now run cmake-gui (still from cmd) and in the Where is the source code:
648+
box, browse to the top level QGIS directory.
647649

648650
In the Where to build the binaries: box, browse to the 'build' directory you
649651
created.
@@ -678,7 +680,7 @@ You will also either need to add all the dependency DLLs to the QGIS install
678680
directory or add their respective directories to your PATH.
679681

680682

681-
4.1.3. Packaging
683+
4.1.4. Packaging
682684
================
683685

684686
To create a standalone installer there is a perl script named 'creatensis.pl'
@@ -699,7 +701,7 @@ and 'bzip2') is available at:
699701
http://cygwin.com
700702

701703

702-
4.1.4. Packaging your own build of QGIS
704+
4.1.5. Packaging your own build of QGIS
703705
=======================================
704706

705707
Assuming you have completed the above packaging step, if you want to include
@@ -719,7 +721,7 @@ After this you should now have a nsis installer containing your own build
719721
of QGIS and all dependencies needed to run it on a windows machine.
720722

721723

722-
4.1.5. Osgeo4w packaging
724+
4.1.6. Osgeo4w packaging
723725
========================
724726

725727
The actual packaging process is currently not documented, for now please take a

cmake/FindGEOS.cmake

+20-20
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# GEOS_INCLUDE_DIR
1313
# GEOS_LIBRARY
1414
#
15-
15+
1616
INCLUDE (@CMAKE_SOURCE_DIR@/cmake/MacPlistMacros.cmake)
1717

1818
IF(WIN32)
@@ -24,21 +24,21 @@ IF(WIN32)
2424

2525
IF (MSVC)
2626
FIND_PATH(GEOS_INCLUDE_DIR geos_c.h $ENV{LIB_DIR}/include $ENV{INCLUDE})
27-
FIND_LIBRARY(GEOS_LIBRARY NAMES geos geos_c_i PATHS
27+
FIND_LIBRARY(GEOS_LIBRARY NAMES geos geos_c_i geos_c PATHS
2828
"$ENV{LIB_DIR}/lib"
2929
$ENV{LIB}
3030
)
3131
IF (GEOS_LIBRARY)
3232
SET (
33-
GEOS_LIBRARY
34-
GEOS_LIBRARY;odbc32;odbccp32
33+
GEOS_LIBRARY
34+
GEOS_LIBRARY;odbc32;odbccp32
3535
CACHE STRING INTERNAL)
3636
ENDIF (GEOS_LIBRARY)
3737
ENDIF (MSVC)
38-
38+
3939
ELSE(WIN32)
4040

41-
IF(UNIX)
41+
IF(UNIX)
4242

4343
# try to use framework on mac
4444
# want clean framework path, not unix compatibility path
@@ -80,7 +80,7 @@ ELSE(WIN32)
8080
#MESSAGE("DBG GEOS_CONFIG ${GEOS_CONFIG}")
8181

8282
IF (GEOS_CONFIG)
83-
83+
8484
EXEC_PROGRAM(${GEOS_CONFIG}
8585
ARGS --version
8686
OUTPUT_VARIABLE GEOS_VERSION)
@@ -90,34 +90,34 @@ ELSE(WIN32)
9090
IF (GEOS_VERSION_MAJOR LESS 3)
9191
MESSAGE (FATAL_ERROR "GEOS version is too old (${GEOS_VERSION}). Use 3.0.0 or higher.")
9292
ENDIF (GEOS_VERSION_MAJOR LESS 3)
93-
93+
9494
# set INCLUDE_DIR to prefix+include
9595
EXEC_PROGRAM(${GEOS_CONFIG}
9696
ARGS --prefix
9797
OUTPUT_VARIABLE GEOS_PREFIX)
9898

99-
FIND_PATH(GEOS_INCLUDE_DIR
100-
geos_c.h
99+
FIND_PATH(GEOS_INCLUDE_DIR
100+
geos_c.h
101101
${GEOS_PREFIX}/include
102-
/usr/local/include
103-
/usr/include
102+
/usr/local/include
103+
/usr/include
104104
)
105105

106-
## extract link dirs for rpath
106+
## extract link dirs for rpath
107107
EXEC_PROGRAM(${GEOS_CONFIG}
108108
ARGS --libs
109109
OUTPUT_VARIABLE GEOS_CONFIG_LIBS )
110110

111111
## split off the link dirs (for rpath)
112112
## use regular expression to match wildcard equivalent "-L*<endchar>"
113113
## with <endchar> is a space or a semicolon
114-
STRING(REGEX MATCHALL "[-][L]([^ ;])+"
115-
GEOS_LINK_DIRECTORIES_WITH_PREFIX
114+
STRING(REGEX MATCHALL "[-][L]([^ ;])+"
115+
GEOS_LINK_DIRECTORIES_WITH_PREFIX
116116
"${GEOS_CONFIG_LIBS}" )
117117
#MESSAGE("DBG GEOS_LINK_DIRECTORIES_WITH_PREFIX=${GEOS_LINK_DIRECTORIES_WITH_PREFIX}")
118118

119119
## remove prefix -L because we need the pure directory for LINK_DIRECTORIES
120-
120+
121121
IF (GEOS_LINK_DIRECTORIES_WITH_PREFIX)
122122
STRING(REGEX REPLACE "[-][L]" "" GEOS_LINK_DIRECTORIES ${GEOS_LINK_DIRECTORIES_WITH_PREFIX} )
123123
ENDIF (GEOS_LINK_DIRECTORIES_WITH_PREFIX)
@@ -126,15 +126,15 @@ ELSE(WIN32)
126126
## split off the name
127127
## use regular expression to match wildcard equivalent "-l*<endchar>"
128128
## with <endchar> is a space or a semicolon
129-
#STRING(REGEX MATCHALL "[-][l]([^ ;])+"
130-
# GEOS_LIB_NAME_WITH_PREFIX
129+
#STRING(REGEX MATCHALL "[-][l]([^ ;])+"
130+
# GEOS_LIB_NAME_WITH_PREFIX
131131
# "${GEOS_CONFIG_LIBS}" )
132132
#MESSAGE("DBG GEOS_CONFIG_LIBS=${GEOS_CONFIG_LIBS}")
133133
#MESSAGE("DBG GEOS_LIB_NAME_WITH_PREFIX=${GEOS_LIB_NAME_WITH_PREFIX}")
134134
SET(GEOS_LIB_NAME_WITH_PREFIX -lgeos_c CACHE STRING INTERNAL)
135135

136136
## remove prefix -l because we need the pure name
137-
137+
138138
IF (GEOS_LIB_NAME_WITH_PREFIX)
139139
STRING(REGEX REPLACE "[-][l]" "" GEOS_LIB_NAME ${GEOS_LIB_NAME_WITH_PREFIX} )
140140
ENDIF (GEOS_LIB_NAME_WITH_PREFIX)
@@ -151,7 +151,7 @@ ELSE(WIN32)
151151
SET(GEOS_LIBRARY ${GEOS_LINK_DIRECTORIES}/lib${GEOS_LIB_NAME}.so CACHE STRING INTERNAL)
152152
ENDIF (APPLE)
153153
#MESSAGE("DBG GEOS_LIBRARY=${GEOS_LIBRARY}")
154-
154+
155155
ELSE(GEOS_CONFIG)
156156
MESSAGE("FindGEOS.cmake: geos-config not found. Please set it manually. GEOS_CONFIG=${GEOS_CONFIG}")
157157
ENDIF(GEOS_CONFIG)

cmake/FindPythonLibrary.cmake

+15-2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,19 @@ if(EXISTS PYTHON_LIBRARY)
3131
set(PYTHONLIBRARY_FOUND TRUE)
3232
else(EXISTS PYTHON_LIBRARY)
3333

34+
set(_custom_python_fw FALSE)
35+
if(APPLE AND PYTHON_CUSTOM_FRAMEWORK)
36+
if("${PYTHON_CUSTOM_FRAMEWORK}" MATCHES "Python\\.framework")
37+
STRING(REGEX REPLACE "(.*Python\\.framework).*$" "\\1" _python_fw "${PYTHON_CUSTOM_FRAMEWORK}")
38+
set(PYTHON_EXECUTABLE "${_python_fw}/Versions/Current/bin/python")
39+
set(PYTHON_INCLUDE_PATH "${_python_fw}/Versions/Current/Headers")
40+
set(PYTHON_LIBRARY "${_python_fw}/Versions/Current/Python")
41+
if(EXISTS "${PYTHON_EXECUTABLE}" AND EXISTS "${PYTHON_INCLUDE_PATH}" AND EXISTS "${PYTHON_LIBRARY}")
42+
set(_custom_python_fw TRUE)
43+
endif()
44+
endif("${PYTHON_CUSTOM_FRAMEWORK}" MATCHES "Python\\.framework")
45+
endif(APPLE AND PYTHON_CUSTOM_FRAMEWORK)
46+
3447
FIND_PACKAGE(PythonInterp)
3548

3649
if(PYTHONINTERP_FOUND)
@@ -60,7 +73,7 @@ else(EXISTS PYTHON_LIBRARY)
6073
endif(python_config)
6174

6275
# adapted from cmake's builtin FindPythonLibs
63-
if(APPLE)
76+
if(APPLE AND NOT _custom_python_fw)
6477
CMAKE_FIND_FRAMEWORKS(Python)
6578
set(PYTHON_FRAMEWORK_INCLUDES)
6679
if(Python_FRAMEWORKS)
@@ -75,7 +88,7 @@ else(EXISTS PYTHON_LIBRARY)
7588
endif(NOT PYTHON_LIBRARY)
7689
set(PYTHONLIBRARY_FOUND TRUE)
7790
endif(Python_FRAMEWORKS)
78-
endif(APPLE)
91+
endif(APPLE AND NOT _custom_python_fw)
7992
endif(PYTHONINTERP_FOUND)
8093

8194
if(PYTHONLIBRARY_FOUND)

cmake/FindQwt.cmake

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ FIND_PATH(QWT_INCLUDE_DIR NAMES qwt.h PATHS
1717
/usr/local/include
1818
"$ENV{LIB_DIR}/include"
1919
"$ENV{INCLUDE}"
20-
PATH_SUFFIXES qwt-qt4 qwt qwt5
20+
PATH_SUFFIXES qwt-qt4 qwt qwt5 qwt6
2121
)
2222

23-
FIND_LIBRARY(QWT_LIBRARY NAMES qwt qwt5 qwt-qt4 qwt5-qt4 PATHS
23+
FIND_LIBRARY(QWT_LIBRARY NAMES qwt qwt5 qwt6 qwt-qt4 qwt5-qt4 PATHS
2424
/usr/lib
2525
/usr/local/lib
2626
"$ENV{LIB_DIR}/lib"

cmake_templates/qgsconfig.h.in

+2
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@
3838

3939
#cmakedefine HAVE_MSSQL
4040

41+
#cmakedefine HAVE_ORACLE
42+
4143
#cmakedefine HAVE_PYTHON
4244

4345
#cmakedefine HAVE_TOUCH

0 commit comments

Comments
 (0)