Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into new_vector_api
Browse files Browse the repository at this point in the history
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
  • Loading branch information
wonder-sk committed Jan 23, 2013
2 parents dda51c6 + 5f70a68 commit 5f304b3
Show file tree
Hide file tree
Showing 660 changed files with 65,222 additions and 29,264 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -48,3 +48,4 @@ i18n/*.qm
.idea
/python/plugins/sextante/resources_rc.py
/python/plugins/sextante/about/ui_aboutdialogbase.py
scripts/qgisstyle
11 changes: 10 additions & 1 deletion CMakeLists.txt
Expand Up @@ -70,6 +70,11 @@ IF (WITH_SPATIALITE)
ENDIF (WITH_INTERNAL_SPATIALITE)
ENDIF (WITH_SPATIALITE)

SET (WITH_ORACLE FALSE CACHE BOOL "Determines whether Oracle support should be built")
IF(WITH_ORACLE)
SET(HAVE_ORACLE TRUE)
ENDIF(WITH_ORACLE)

# try to configure and build python bindings by default
SET (WITH_BINDINGS TRUE CACHE BOOL "Determines whether python bindings should be built")
IF (WITH_BINDINGS)
Expand All @@ -82,6 +87,10 @@ IF (WITH_BINDINGS)
SET (WITH_PY_COMPILE FALSE CACHE BOOL "Determines whether Python modules in staged or installed locations are byte-compiled")
# concatenate QScintilla2 API files
SET (WITH_QSCIAPI TRUE CACHE BOOL "Determines whether the QScintilla2 API files will be updated and concatenated")
# path to custom Python framework on Mac
IF (APPLE)
SET (PYTHON_CUSTOM_FRAMEWORK "" CACHE PATH "Path to custom Python.framework on Mac. (should not have to specify other Python options)")
ENDIF (APPLE)
ENDIF (WITH_BINDINGS)

#BUILD WITH QtMobility by default on android only. Other platform can force it
Expand Down Expand Up @@ -157,7 +166,7 @@ ENDIF(NOT WIN32 AND NOT ANDROID)
FIND_PACKAGE(Proj)
FIND_PACKAGE(GEOS)
FIND_PACKAGE(GDAL)
FIND_PACKAGE(Expat)
FIND_PACKAGE(Expat REQUIRED)
FIND_PACKAGE(Spatialindex REQUIRED)
FIND_PACKAGE(Qwt REQUIRED)

Expand Down
26 changes: 14 additions & 12 deletions INSTALL
@@ -1,10 +1,10 @@
Quantum GIS (QGIS)
Building QGIS from source - step by step
Tuesday October 23, 2012
Friday January 04, 2013


Last Updated: Tuesday October 23, 2012
Last Change : Tuesday October 23, 2012
Last Updated: Friday January 04, 2013
Last Change : Friday January 04, 2013


1. Introduction
Expand Down Expand Up @@ -104,13 +104,14 @@ Required build deps:
- Sqlite3 >= 3.0.0
- GDAL/OGR >= 1.4.x
- Qwt >= 5.0
- expat >= 1.95

Optional dependencies:

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

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

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

=== Setting up the Visual Studio project with CMake ===

4.1.3. Setting up the Visual Studio project with CMake
======================================================

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

@cmd


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

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

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

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


4.1.3. Packaging
4.1.4. Packaging
================

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


4.1.4. Packaging your own build of QGIS
4.1.5. Packaging your own build of QGIS
=======================================

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


4.1.5. Osgeo4w packaging
4.1.6. Osgeo4w packaging
========================

The actual packaging process is currently not documented, for now please take a
Expand Down
40 changes: 20 additions & 20 deletions cmake/FindGEOS.cmake
Expand Up @@ -12,7 +12,7 @@
# GEOS_INCLUDE_DIR
# GEOS_LIBRARY
#

INCLUDE (@CMAKE_SOURCE_DIR@/cmake/MacPlistMacros.cmake)

IF(WIN32)
Expand All @@ -24,21 +24,21 @@ IF(WIN32)

IF (MSVC)
FIND_PATH(GEOS_INCLUDE_DIR geos_c.h $ENV{LIB_DIR}/include $ENV{INCLUDE})
FIND_LIBRARY(GEOS_LIBRARY NAMES geos geos_c_i PATHS
FIND_LIBRARY(GEOS_LIBRARY NAMES geos geos_c_i geos_c PATHS
"$ENV{LIB_DIR}/lib"
$ENV{LIB}
)
IF (GEOS_LIBRARY)
SET (
GEOS_LIBRARY
GEOS_LIBRARY;odbc32;odbccp32
GEOS_LIBRARY
GEOS_LIBRARY;odbc32;odbccp32
CACHE STRING INTERNAL)
ENDIF (GEOS_LIBRARY)
ENDIF (MSVC)

ELSE(WIN32)

IF(UNIX)
IF(UNIX)

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

IF (GEOS_CONFIG)

EXEC_PROGRAM(${GEOS_CONFIG}
ARGS --version
OUTPUT_VARIABLE GEOS_VERSION)
Expand All @@ -90,34 +90,34 @@ ELSE(WIN32)
IF (GEOS_VERSION_MAJOR LESS 3)
MESSAGE (FATAL_ERROR "GEOS version is too old (${GEOS_VERSION}). Use 3.0.0 or higher.")
ENDIF (GEOS_VERSION_MAJOR LESS 3)

# set INCLUDE_DIR to prefix+include
EXEC_PROGRAM(${GEOS_CONFIG}
ARGS --prefix
OUTPUT_VARIABLE GEOS_PREFIX)

FIND_PATH(GEOS_INCLUDE_DIR
geos_c.h
FIND_PATH(GEOS_INCLUDE_DIR
geos_c.h
${GEOS_PREFIX}/include
/usr/local/include
/usr/include
/usr/local/include
/usr/include
)

## extract link dirs for rpath
## extract link dirs for rpath
EXEC_PROGRAM(${GEOS_CONFIG}
ARGS --libs
OUTPUT_VARIABLE GEOS_CONFIG_LIBS )

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

## remove prefix -L because we need the pure directory for LINK_DIRECTORIES

IF (GEOS_LINK_DIRECTORIES_WITH_PREFIX)
STRING(REGEX REPLACE "[-][L]" "" GEOS_LINK_DIRECTORIES ${GEOS_LINK_DIRECTORIES_WITH_PREFIX} )
ENDIF (GEOS_LINK_DIRECTORIES_WITH_PREFIX)
Expand All @@ -126,15 +126,15 @@ ELSE(WIN32)
## split off the name
## use regular expression to match wildcard equivalent "-l*<endchar>"
## with <endchar> is a space or a semicolon
#STRING(REGEX MATCHALL "[-][l]([^ ;])+"
# GEOS_LIB_NAME_WITH_PREFIX
#STRING(REGEX MATCHALL "[-][l]([^ ;])+"
# GEOS_LIB_NAME_WITH_PREFIX
# "${GEOS_CONFIG_LIBS}" )
#MESSAGE("DBG GEOS_CONFIG_LIBS=${GEOS_CONFIG_LIBS}")
#MESSAGE("DBG GEOS_LIB_NAME_WITH_PREFIX=${GEOS_LIB_NAME_WITH_PREFIX}")
SET(GEOS_LIB_NAME_WITH_PREFIX -lgeos_c CACHE STRING INTERNAL)

## remove prefix -l because we need the pure name

IF (GEOS_LIB_NAME_WITH_PREFIX)
STRING(REGEX REPLACE "[-][l]" "" GEOS_LIB_NAME ${GEOS_LIB_NAME_WITH_PREFIX} )
ENDIF (GEOS_LIB_NAME_WITH_PREFIX)
Expand All @@ -151,7 +151,7 @@ ELSE(WIN32)
SET(GEOS_LIBRARY ${GEOS_LINK_DIRECTORIES}/lib${GEOS_LIB_NAME}.so CACHE STRING INTERNAL)
ENDIF (APPLE)
#MESSAGE("DBG GEOS_LIBRARY=${GEOS_LIBRARY}")

ELSE(GEOS_CONFIG)
MESSAGE("FindGEOS.cmake: geos-config not found. Please set it manually. GEOS_CONFIG=${GEOS_CONFIG}")
ENDIF(GEOS_CONFIG)
Expand Down
17 changes: 15 additions & 2 deletions cmake/FindPythonLibrary.cmake
Expand Up @@ -31,6 +31,19 @@ if(EXISTS PYTHON_LIBRARY)
set(PYTHONLIBRARY_FOUND TRUE)
else(EXISTS PYTHON_LIBRARY)

set(_custom_python_fw FALSE)
if(APPLE AND PYTHON_CUSTOM_FRAMEWORK)
if("${PYTHON_CUSTOM_FRAMEWORK}" MATCHES "Python\\.framework")
STRING(REGEX REPLACE "(.*Python\\.framework).*$" "\\1" _python_fw "${PYTHON_CUSTOM_FRAMEWORK}")
set(PYTHON_EXECUTABLE "${_python_fw}/Versions/Current/bin/python")
set(PYTHON_INCLUDE_PATH "${_python_fw}/Versions/Current/Headers")
set(PYTHON_LIBRARY "${_python_fw}/Versions/Current/Python")
if(EXISTS "${PYTHON_EXECUTABLE}" AND EXISTS "${PYTHON_INCLUDE_PATH}" AND EXISTS "${PYTHON_LIBRARY}")
set(_custom_python_fw TRUE)
endif()
endif("${PYTHON_CUSTOM_FRAMEWORK}" MATCHES "Python\\.framework")
endif(APPLE AND PYTHON_CUSTOM_FRAMEWORK)

FIND_PACKAGE(PythonInterp)

if(PYTHONINTERP_FOUND)
Expand Down Expand Up @@ -60,7 +73,7 @@ else(EXISTS PYTHON_LIBRARY)
endif(python_config)

# adapted from cmake's builtin FindPythonLibs
if(APPLE)
if(APPLE AND NOT _custom_python_fw)
CMAKE_FIND_FRAMEWORKS(Python)
set(PYTHON_FRAMEWORK_INCLUDES)
if(Python_FRAMEWORKS)
Expand All @@ -75,7 +88,7 @@ else(EXISTS PYTHON_LIBRARY)
endif(NOT PYTHON_LIBRARY)
set(PYTHONLIBRARY_FOUND TRUE)
endif(Python_FRAMEWORKS)
endif(APPLE)
endif(APPLE AND NOT _custom_python_fw)
endif(PYTHONINTERP_FOUND)

if(PYTHONLIBRARY_FOUND)
Expand Down
4 changes: 2 additions & 2 deletions cmake/FindQwt.cmake
Expand Up @@ -17,10 +17,10 @@ FIND_PATH(QWT_INCLUDE_DIR NAMES qwt.h PATHS
/usr/local/include
"$ENV{LIB_DIR}/include"
"$ENV{INCLUDE}"
PATH_SUFFIXES qwt-qt4 qwt qwt5
PATH_SUFFIXES qwt-qt4 qwt qwt5 qwt6
)

FIND_LIBRARY(QWT_LIBRARY NAMES qwt qwt5 qwt-qt4 qwt5-qt4 PATHS
FIND_LIBRARY(QWT_LIBRARY NAMES qwt qwt5 qwt6 qwt-qt4 qwt5-qt4 PATHS
/usr/lib
/usr/local/lib
"$ENV{LIB_DIR}/lib"
Expand Down
2 changes: 2 additions & 0 deletions cmake_templates/qgsconfig.h.in
Expand Up @@ -38,6 +38,8 @@

#cmakedefine HAVE_MSSQL

#cmakedefine HAVE_ORACLE

#cmakedefine HAVE_PYTHON

#cmakedefine HAVE_TOUCH
Expand Down

0 comments on commit 5f304b3

Please sign in to comment.