Библиотека GEOS 3.8.1 для ЗОСРВ Нейтрино
This commit is contained in:
commit
bec8387f45
57
AUTHORS
Normal file
57
AUTHORS
Normal file
@ -0,0 +1,57 @@
|
||||
2006-Present
|
||||
GEOS is a project of the OSGEO foundation and is continually improved
|
||||
and funded by mandy FOSS4G developers as well as corporations all
|
||||
over the world.
|
||||
|
||||
Developers and Project Steering Committee (PSC):
|
||||
Active:
|
||||
Martin Davis (mtnclimb at gmail.com )(PSC) - Architecture
|
||||
Sandro Santilli (strk@kbt.io) (PSC Chair) - Bug Fixing / Maintenance
|
||||
Paul Ramsey (pramsey@cleverelephant.ca) (PSC) - Coordination / Build
|
||||
Regina Obe (lr@pcorp.us) (PSC) - QA / Windows / Coordination
|
||||
Howard Butler (howard@hobu.co) (PSC) - OS Platform support and testing
|
||||
Dale Lutz (dale.lutz@safe.com) (PSC)
|
||||
Daniel Baston (dbaston@gmail.com) - Bug Fixing / New functionality
|
||||
Kurt Schwehr ( schwehr@gmail.com ) - Bug Fixing / Test hardening
|
||||
Vicky Vergara (vicky@georepublic.de) - Refactor / Test development
|
||||
|
||||
Not Active:
|
||||
Mateusz Loskot (mateusz@loskot.net) - Unit testing
|
||||
Frank Warmerdam (warmerdam@pobox.com) - VStudio porting
|
||||
Dave Blasby (dblasby@gmail.com) - PostGIS Connectivity
|
||||
Yury Bychkov (me@yury.ca) - Initial Porting
|
||||
Sean Gillies (sgillies@frii.com) - Scripting Interface
|
||||
Fernando Villa (fvilla@zoo.uvm.edu) - GNU Build System
|
||||
Norman Vine (nvine@cape.com) - Porting / C++ Expertise
|
||||
|
||||
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
2003-11-06
|
||||
|
||||
Initial development of GEOS was funded by:
|
||||
|
||||
Vivid Solutions Inc (www.vividsolutions.com)
|
||||
Refractions Research Inc (www.refractions.net)
|
||||
British Columbia Advanced Systems Institute (www.asi.bc.ca)
|
||||
|
||||
GEOS is based on algorithms originally developed in Java
|
||||
by Martin Davis (mbdavis@refractions.net) in the
|
||||
JTS Topology Suite (www.vividsolutions.com/jts/jtshome.htm)
|
||||
|
||||
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
2004 to 2006
|
||||
|
||||
Continued development of GEOS funded by Refractions Research Inc.
|
||||
|
||||
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
2006
|
||||
|
||||
Continued development of GEOS funded by Refractions Research Inc.
|
||||
|
||||
Inclusion of new JTS functionality in JTS 1.5 to 1.7 funded
|
||||
by Safe Software and Autodesk.
|
||||
|
||||
Improved robustness of geometric operations for GEOS 3.0.0 funded
|
||||
by the Bavarian State Ministry of Agriculture and Forestry and the
|
||||
State Survey of Bavaria.
|
||||
|
||||
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
394
CMakeLists.txt
Normal file
394
CMakeLists.txt
Normal file
@ -0,0 +1,394 @@
|
||||
##############################################################################
|
||||
# Part of CMake configuration for GEOS
|
||||
#
|
||||
# Copyright (C) 2018-2019 Mateusz Loskot <mateusz@loskot.net>
|
||||
#
|
||||
# This is free software; you can redistribute and/or modify it under
|
||||
# the terms of the GNU Lesser General Public Licence as published
|
||||
# by the Free Software Foundation.
|
||||
# See the COPYING file for more information.
|
||||
##############################################################################
|
||||
|
||||
# Require CMake 3.8+ with support for meta-features that request compiler
|
||||
# modes for specific C/C++ language standard levels.
|
||||
cmake_minimum_required(VERSION 3.8)
|
||||
|
||||
# Default to release build so packagers don't release debug builds
|
||||
set(DEFAULT_BUILD_TYPE Release)
|
||||
|
||||
# Require CMake 3.13+ with VS generator for complete support of VS versions
|
||||
# and support by AppVeyor.
|
||||
if(${CMAKE_GENERATOR} MATCHES "Visual Studio")
|
||||
cmake_minimum_required(VERSION 3.13 FATAL_ERROR)
|
||||
endif()
|
||||
|
||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
|
||||
|
||||
# TODO: Follow CMake detection of git and version tagging
|
||||
# https://gitlab.kitware.com/cmake/cmake/blob/master/Source/CMakeVersionSource.cmake
|
||||
if(EXISTS ${CMAKE_SOURCE_DIR}/.git/HEAD)
|
||||
set(GEOS_BUILD_FROM_GIT ON)
|
||||
endif()
|
||||
|
||||
# Make sure we know our build type
|
||||
if(NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE ${DEFAULT_BUILD_TYPE})
|
||||
message(STATUS "GEOS: Using default build type: ${CMAKE_BUILD_TYPE}")
|
||||
else()
|
||||
message(STATUS "GEOS: Build type: ${CMAKE_BUILD_TYPE}")
|
||||
endif()
|
||||
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Options
|
||||
#-----------------------------------------------------------------------------
|
||||
include(CMakeDependentOption)
|
||||
|
||||
## CMake global variables
|
||||
option(BUILD_SHARED_LIBS "Build GEOS with shared libraries" ON)
|
||||
set(CMAKE_CXX_STANDARD 11 CACHE STRING "C++ standard version to use (default is 11)")
|
||||
|
||||
## GEOS custom variables
|
||||
cmake_dependent_option(GEOS_BUILD_DEVELOPER
|
||||
"Build with compilation flags useful for development" ON
|
||||
"GEOS_BUILD_FROM_GIT" OFF)
|
||||
mark_as_advanced(GEOS_BUILD_DEVELOPER)
|
||||
|
||||
if (POLICY CMP0092)
|
||||
# dont set /W3 warning flags by default, we already
|
||||
# set /W4 anyway
|
||||
cmake_policy(SET CMP0092 NEW)
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Setup build directories
|
||||
#-----------------------------------------------------------------------------
|
||||
# Place executables and shared libraries in the same location for
|
||||
# convenience of direct execution from common spot and for
|
||||
# convenience in environments without RPATH support.
|
||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
||||
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
|
||||
message(STATUS "GEOS: Run-time output: ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}")
|
||||
message(STATUS "GEOS: Archives output: ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}")
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Version
|
||||
#-----------------------------------------------------------------------------
|
||||
file(READ Version.txt _version_txt)
|
||||
|
||||
string(REGEX MATCH "GEOS_VERSION_MAJOR=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_major ${CMAKE_MATCH_1})
|
||||
string(REGEX MATCH "GEOS_VERSION_MINOR=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_minor ${CMAKE_MATCH_1})
|
||||
string(REGEX MATCH "GEOS_VERSION_PATCH=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_patch ${CMAKE_MATCH_1})
|
||||
# OPTIONS: "", "dev", "rc1" etc.
|
||||
string(REGEX MATCH "GEOS_PATCH_WORD=([a-zA-Z0-9]+)" _ ${_version_txt})
|
||||
set(_version_patch_word ${CMAKE_MATCH_1})
|
||||
|
||||
# Version of JTS this release is bound to
|
||||
string(REGEX MATCH "JTS_PORT=([0-9a-zA-Z\.]+)" _ ${_version_txt})
|
||||
set(JTS_PORT ${CMAKE_MATCH_1})
|
||||
|
||||
# Version of public C API
|
||||
string(REGEX MATCH "CAPI_INTERFACE_CURRENT=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_capi_current ${CMAKE_MATCH_1})
|
||||
string(REGEX MATCH "CAPI_INTERFACE_REVISION=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_capi_revision ${CMAKE_MATCH_1})
|
||||
string(REGEX MATCH "CAPI_INTERFACE_AGE=([0-9]+)" _ ${_version_txt})
|
||||
set(_version_capi_age ${CMAKE_MATCH_1})
|
||||
|
||||
unset(_version_txt)
|
||||
|
||||
math(EXPR _version_capi_major "${_version_capi_current} - ${_version_capi_age}")
|
||||
set(CAPI_VERSION_MAJOR ${_version_capi_major})
|
||||
set(CAPI_VERSION_MINOR ${_version_capi_age})
|
||||
set(CAPI_VERSION_PATCH ${_version_capi_revision})
|
||||
set(CAPI_VERSION "${_version_capi_major}.${_version_capi_age}.${_version_capi_revision}")
|
||||
|
||||
unset(_version_capi_current)
|
||||
unset(_version_capi_major)
|
||||
unset(_version_capi_age)
|
||||
unset(_version_capi_revision)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Project
|
||||
#-----------------------------------------------------------------------------
|
||||
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.9)
|
||||
list(APPEND _project_info DESCRIPTION "GEOS - C++ port of the Java Topology Suite (JTS)")
|
||||
endif()
|
||||
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.12)
|
||||
list(APPEND _project_info HOMEPAGE_URL "http://geos.osgeo.org")
|
||||
endif()
|
||||
|
||||
project(GEOS VERSION "${_version_major}.${_version_minor}.${_version_patch}"
|
||||
LANGUAGES C CXX
|
||||
${_project_info})
|
||||
|
||||
if("${_version_patch_word}" STREQUAL "")
|
||||
set(GEOS_VERSION_FULL "${GEOS_VERSION}")
|
||||
else()
|
||||
set(GEOS_VERSION_FULL "${GEOS_VERSION}${_version_patch_word}")
|
||||
endif()
|
||||
|
||||
unset(_version_major)
|
||||
unset(_version_minor)
|
||||
unset(_version_patch)
|
||||
unset(_version_patch_word)
|
||||
|
||||
message(STATUS "GEOS: Version ${GEOS_VERSION_FULL}")
|
||||
message(STATUS "GEOS: C API Version ${CAPI_VERSION}")
|
||||
message(STATUS "GEOS: JTS port ${JTS_PORT}")
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# C++ language version and compilation flags
|
||||
#-----------------------------------------------------------------------------
|
||||
message(STATUS "GEOS: Require C++${CMAKE_CXX_STANDARD}")
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Target geos_cxx_flags: common compilation flags
|
||||
#-----------------------------------------------------------------------------
|
||||
add_library(geos_cxx_flags INTERFACE)
|
||||
target_compile_features(geos_cxx_flags INTERFACE cxx_std_11)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Target geos_cxx_flags: common compilation flags
|
||||
#-----------------------------------------------------------------------------
|
||||
option(DISABLE_GEOS_INLINE "Disable inlining" ON)
|
||||
if(NOT DISABLE_GEOS_INLINE)
|
||||
target_compile_definitions(geos_cxx_flags INTERFACE GEOS_INLINE)
|
||||
else()
|
||||
message(STATUS
|
||||
"GEOS: DISABLING inlining of small functions")
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Target geos_developer_cxx_flags: developer mode compilation flags
|
||||
#-----------------------------------------------------------------------------
|
||||
# Do NOT install this target for end-users!
|
||||
add_library(geos_developer_cxx_flags INTERFACE)
|
||||
|
||||
if(GEOS_BUILD_DEVELOPER)
|
||||
message(STATUS "GEOS: Developer mode enabled")
|
||||
endif()
|
||||
|
||||
# geos_cxx_flags inherits properties from geos_developer_cxx_flags when
|
||||
# building as part of the GEOS repository or on explicit request for
|
||||
# developer compilation mode, as GEOS contributor.
|
||||
# The flags are intended only for GEOS itself and are not part of
|
||||
# usage requirements needed by GEOS consumers.
|
||||
if(GEOS_BUILD_DEVELOPER)
|
||||
target_link_libraries(geos_cxx_flags
|
||||
INTERFACE
|
||||
$<BUILD_INTERFACE:geos_developer_cxx_flags>)
|
||||
endif()
|
||||
|
||||
target_compile_definitions(geos_cxx_flags
|
||||
INTERFACE
|
||||
USE_UNSTABLE_GEOS_CPP_API)
|
||||
|
||||
target_compile_definitions(geos_developer_cxx_flags
|
||||
INTERFACE
|
||||
$<$<CXX_COMPILER_ID:MSVC>:_CRT_NONSTDC_NO_DEPRECATE>
|
||||
$<$<CXX_COMPILER_ID:MSVC>:_SCL_SECURE_NO_DEPRECATE>
|
||||
$<$<CXX_COMPILER_ID:MSVC>:_CRT_SECURE_NO_WARNINGS>
|
||||
$<$<CXX_COMPILER_ID:MSVC>:NOMINMAX>)
|
||||
|
||||
if( ${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm" )
|
||||
add_compile_options( -Wno-psabi )
|
||||
add_compile_definitions( DISABLE_GEOS_INLINE=ON )
|
||||
endif()
|
||||
|
||||
target_compile_options(geos_developer_cxx_flags
|
||||
INTERFACE
|
||||
$<$<CXX_COMPILER_ID:MSVC>:-W4>
|
||||
$<$<OR:$<CXX_COMPILER_ID:GNU>,$<CXX_COMPILER_ID:Clang>>:-pedantic -Wall -Wextra -Wno-long-long -Wcast-align -Wconversion -Wchar-subscripts -Wdouble-promotion -Wpointer-arith -Wformat -Wformat-security -Wshadow -Wuninitialized -Wunused-parameter -fno-common>
|
||||
$<$<CXX_COMPILER_ID:GNU>:-fno-implicit-inline-templates>)
|
||||
|
||||
# Disable TTMath ASM support on Windows due to build issues
|
||||
if(WIN32)
|
||||
target_compile_definitions(geos_cxx_flags
|
||||
INTERFACE TTMATH_NOASM)
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Define a coverage build
|
||||
#-----------------------------------------------------------------------------
|
||||
set(CMAKE_CXX_FLAGS_COVERAGE "-fprofile-arcs -ftest-coverage")
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Target geos: C++ API library
|
||||
#-----------------------------------------------------------------------------
|
||||
add_library(geos "")
|
||||
target_link_libraries(geos PUBLIC geos_cxx_flags)
|
||||
add_subdirectory(include)
|
||||
add_subdirectory(src)
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
target_compile_definitions(geos
|
||||
PRIVATE $<$<CXX_COMPILER_ID:MSVC>:GEOS_DLL_EXPORT>)
|
||||
|
||||
set_target_properties(geos PROPERTIES VERSION ${GEOS_VERSION})
|
||||
set_target_properties(geos PROPERTIES SOVERSION ${GEOS_VERSION})
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Target geos_c: C API library
|
||||
#-----------------------------------------------------------------------------
|
||||
add_library(geos_c "")
|
||||
target_link_libraries(geos_c PRIVATE geos)
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
target_compile_definitions(geos_c
|
||||
PRIVATE $<$<CXX_COMPILER_ID:MSVC>:GEOS_DLL_EXPORT>)
|
||||
|
||||
set_target_properties(geos_c PROPERTIES VERSION ${CAPI_VERSION})
|
||||
if(NOT WIN32)
|
||||
set_target_properties(geos_c PROPERTIES SOVERSION ${CAPI_VERSION_MAJOR})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_subdirectory(capi)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Tests
|
||||
#-----------------------------------------------------------------------------
|
||||
#include(CTest)
|
||||
#if(BUILD_TESTING)
|
||||
#add_subdirectory(tests)
|
||||
#endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Benchmarks
|
||||
#-----------------------------------------------------------------------------
|
||||
#add_subdirectory(benchmarks)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Documentation/Examples
|
||||
#-----------------------------------------------------------------------------
|
||||
#add_subdirectory(doc)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Install and export targets - support 'make install' or equivalent
|
||||
#-----------------------------------------------------------------------------
|
||||
include(CMakePackageConfigHelpers)
|
||||
write_basic_package_version_file(
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/geos-config-version.cmake"
|
||||
VERSION ${GEOS_VERSION}
|
||||
COMPATIBILITY AnyNewerVersion)
|
||||
|
||||
configure_file(cmake/geos-config.cmake
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/geos-config.cmake"
|
||||
COPYONLY)
|
||||
|
||||
install(TARGETS geos geos_cxx_flags
|
||||
EXPORT geos-targets
|
||||
LIBRARY DESTINATION lib NAMELINK_SKIP
|
||||
ARCHIVE DESTINATION lib
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
||||
install(TARGETS geos_c
|
||||
EXPORT geos-targets
|
||||
LIBRARY DESTINATION lib
|
||||
ARCHIVE DESTINATION lib
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
||||
#install(EXPORT geos-targets
|
||||
#FILE geos-targets.cmake
|
||||
#NAMESPACE GEOS::
|
||||
#DESTINATION lib/cmake/GEOS)
|
||||
|
||||
#install(FILES
|
||||
#"${CMAKE_CURRENT_BINARY_DIR}/geos-config.cmake"
|
||||
#"${CMAKE_CURRENT_BINARY_DIR}/geos-config-version.cmake"
|
||||
#DESTINATION lib/cmake/GEOS)
|
||||
#install(DIRECTORY
|
||||
#"${CMAKE_CURRENT_LIST_DIR}/include/geos"
|
||||
#"${CMAKE_CURRENT_BINARY_DIR}/include/geos"
|
||||
#DESTINATION include
|
||||
#FILES_MATCHING PATTERN "*.h")
|
||||
#if(NOT DISABLE_GEOS_INLINE)
|
||||
#install(DIRECTORY
|
||||
#"${CMAKE_CURRENT_LIST_DIR}/include/geos"
|
||||
#"${CMAKE_CURRENT_BINARY_DIR}/include/geos"
|
||||
#DESTINATION include
|
||||
#FILES_MATCHING PATTERN "*.inl")
|
||||
#endif()
|
||||
#install(FILES "${CMAKE_CURRENT_BINARY_DIR}/capi/geos_c.h"
|
||||
#DESTINATION include)
|
||||
|
||||
# 03.07.2023, A.Vasyunin: CMake fails with error: no matching function for call to 'stat::stat(const char*, stat*)'
|
||||
# In KPDA_TARGET/usr/include/sys/stat.h we have stat::stat() wrapped under #if defined(__EXT_POSIX1_198808)
|
||||
# add_subdirectory(tools)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Uninstall
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
configure_file("${PROJECT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in"
|
||||
"${PROJECT_BINARY_DIR}/cmake/cmake_uninstall.cmake"
|
||||
IMMEDIATE @ONLY)
|
||||
|
||||
add_custom_target(uninstall
|
||||
"${CMAKE_COMMAND}" -P "${PROJECT_BINARY_DIR}/cmake/cmake_uninstall.cmake")
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# "make dist" workalike
|
||||
#-----------------------------------------------------------------------------
|
||||
get_property(_is_multi_config_generator GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
|
||||
if(NOT _is_multi_config_generator)
|
||||
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "GEOS Computational Geometry Library")
|
||||
set(CPACK_PACKAGE_VENDOR "OSGeo")
|
||||
set(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_CURRENT_SOURCE_DIR}/README.md)
|
||||
set(CPACK_SOURCE_GENERATOR "TBZ2")
|
||||
set(CPACK_PACKAGE_VERSION_MAJOR ${GEOS_VERSION_MAJOR})
|
||||
set(CPACK_PACKAGE_VERSION_MINOR ${GEOS_VERSION_MINOR})
|
||||
set(CPACK_PACKAGE_VERSION_PATCH ${GEOS_VERSION_PATCH})
|
||||
set(CPACK_SOURCE_PACKAGE_FILE_NAME "geos-${GEOS_VERSION_FULL}")
|
||||
|
||||
set(CPACK_SOURCE_IGNORE_FILES
|
||||
"/\\\\.git"
|
||||
"/autogen\\\\.sh"
|
||||
"/tools/ci"
|
||||
"/HOWTO_RELEASE"
|
||||
"/autom4te\\\\.cache"
|
||||
"\\\\.yml\$"
|
||||
"\\\\.deps"
|
||||
"/debian/"
|
||||
"/php/"
|
||||
"/.*build-.*/"
|
||||
${PROJECT_BINARY_DIR}
|
||||
)
|
||||
|
||||
# message(STATUS "GEOS: CPACK_SOURCE_PACKAGE_FILE_NAME: ${CPACK_SOURCE_PACKAGE_FILE_NAME}")
|
||||
# message(STATUS "GEOS: CPACK_SOURCE_IGNORE_FILES: ${CPACK_SOURCE_IGNORE_FILES}")
|
||||
# message(STATUS "GEOS: CMAKE_MODULE_PATH: ${CMAKE_MODULE_PATH}")
|
||||
include(CPack)
|
||||
add_custom_target(dist COMMAND ${CMAKE_MAKE_PROGRAM} package_source)
|
||||
|
||||
message(STATUS "GEOS: Configured 'dist' target")
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# "make check" workalike
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
add_custom_target(check COMMAND ${CMAKE_BUILD_TOOL} test)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# "make distcheck" workalike
|
||||
#-----------------------------------------------------------------------------
|
||||
#if(NOT _is_multi_config_generator)
|
||||
#find_package(MakeDistCheck)
|
||||
#AddMakeDistCheck()
|
||||
#message(STATUS "GEOS: Configured 'distcheck' target")
|
||||
#endif()
|
||||
|
||||
unset(_is_multi_config_generator)
|
502
COPYING
Normal file
502
COPYING
Normal file
@ -0,0 +1,502 @@
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
Version 2.1, February 1999
|
||||
|
||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
[This is the first released version of the Lesser GPL. It also counts
|
||||
as the successor of the GNU Library Public License, version 2, hence
|
||||
the version number 2.1.]
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
Licenses are intended to guarantee your freedom to share and change
|
||||
free software--to make sure the software is free for all its users.
|
||||
|
||||
This license, the Lesser General Public License, applies to some
|
||||
specially designated software packages--typically libraries--of the
|
||||
Free Software Foundation and other authors who decide to use it. You
|
||||
can use it too, but we suggest you first think carefully about whether
|
||||
this license or the ordinary General Public License is the better
|
||||
strategy to use in any particular case, based on the explanations below.
|
||||
|
||||
When we speak of free software, we are referring to freedom of use,
|
||||
not price. Our General Public Licenses are designed to make sure that
|
||||
you have the freedom to distribute copies of free software (and charge
|
||||
for this service if you wish); that you receive source code or can get
|
||||
it if you want it; that you can change the software and use pieces of
|
||||
it in new free programs; and that you are informed that you can do
|
||||
these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
distributors to deny you these rights or to ask you to surrender these
|
||||
rights. These restrictions translate to certain responsibilities for
|
||||
you if you distribute copies of the library or if you modify it.
|
||||
|
||||
For example, if you distribute copies of the library, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that we gave
|
||||
you. You must make sure that they, too, receive or can get the source
|
||||
code. If you link other code with the library, you must provide
|
||||
complete object files to the recipients, so that they can relink them
|
||||
with the library after making changes to the library and recompiling
|
||||
it. And you must show them these terms so they know their rights.
|
||||
|
||||
We protect your rights with a two-step method: (1) we copyright the
|
||||
library, and (2) we offer you this license, which gives you legal
|
||||
permission to copy, distribute and/or modify the library.
|
||||
|
||||
To protect each distributor, we want to make it very clear that
|
||||
there is no warranty for the free library. Also, if the library is
|
||||
modified by someone else and passed on, the recipients should know
|
||||
that what they have is not the original version, so that the original
|
||||
author's reputation will not be affected by problems that might be
|
||||
introduced by others.
|
||||
|
||||
Finally, software patents pose a constant threat to the existence of
|
||||
any free program. We wish to make sure that a company cannot
|
||||
effectively restrict the users of a free program by obtaining a
|
||||
restrictive license from a patent holder. Therefore, we insist that
|
||||
any patent license obtained for a version of the library must be
|
||||
consistent with the full freedom of use specified in this license.
|
||||
|
||||
Most GNU software, including some libraries, is covered by the
|
||||
ordinary GNU General Public License. This license, the GNU Lesser
|
||||
General Public License, applies to certain designated libraries, and
|
||||
is quite different from the ordinary General Public License. We use
|
||||
this license for certain libraries in order to permit linking those
|
||||
libraries into non-free programs.
|
||||
|
||||
When a program is linked with a library, whether statically or using
|
||||
a shared library, the combination of the two is legally speaking a
|
||||
combined work, a derivative of the original library. The ordinary
|
||||
General Public License therefore permits such linking only if the
|
||||
entire combination fits its criteria of freedom. The Lesser General
|
||||
Public License permits more lax criteria for linking other code with
|
||||
the library.
|
||||
|
||||
We call this license the "Lesser" General Public License because it
|
||||
does Less to protect the user's freedom than the ordinary General
|
||||
Public License. It also provides other free software developers Less
|
||||
of an advantage over competing non-free programs. These disadvantages
|
||||
are the reason we use the ordinary General Public License for many
|
||||
libraries. However, the Lesser license provides advantages in certain
|
||||
special circumstances.
|
||||
|
||||
For example, on rare occasions, there may be a special need to
|
||||
encourage the widest possible use of a certain library, so that it becomes
|
||||
a de-facto standard. To achieve this, non-free programs must be
|
||||
allowed to use the library. A more frequent case is that a free
|
||||
library does the same job as widely used non-free libraries. In this
|
||||
case, there is little to gain by limiting the free library to free
|
||||
software only, so we use the Lesser General Public License.
|
||||
|
||||
In other cases, permission to use a particular library in non-free
|
||||
programs enables a greater number of people to use a large body of
|
||||
free software. For example, permission to use the GNU C Library in
|
||||
non-free programs enables many more people to use the whole GNU
|
||||
operating system, as well as its variant, the GNU/Linux operating
|
||||
system.
|
||||
|
||||
Although the Lesser General Public License is Less protective of the
|
||||
users' freedom, it does ensure that the user of a program that is
|
||||
linked with the Library has the freedom and the wherewithal to run
|
||||
that program using a modified version of the Library.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow. Pay close attention to the difference between a
|
||||
"work based on the library" and a "work that uses the library". The
|
||||
former contains code derived from the library, whereas the latter must
|
||||
be combined with the library in order to run.
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License Agreement applies to any software library or other
|
||||
program which contains a notice placed by the copyright holder or
|
||||
other authorized party saying it may be distributed under the terms of
|
||||
this Lesser General Public License (also called "this License").
|
||||
Each licensee is addressed as "you".
|
||||
|
||||
A "library" means a collection of software functions and/or data
|
||||
prepared so as to be conveniently linked with application programs
|
||||
(which use some of those functions and data) to form executables.
|
||||
|
||||
The "Library", below, refers to any such software library or work
|
||||
which has been distributed under these terms. A "work based on the
|
||||
Library" means either the Library or any derivative work under
|
||||
copyright law: that is to say, a work containing the Library or a
|
||||
portion of it, either verbatim or with modifications and/or translated
|
||||
straightforwardly into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".)
|
||||
|
||||
"Source code" for a work means the preferred form of the work for
|
||||
making modifications to it. For a library, complete source code means
|
||||
all the source code for all modules it contains, plus any associated
|
||||
interface definition files, plus the scripts used to control compilation
|
||||
and installation of the library.
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running a program using the Library is not restricted, and output from
|
||||
such a program is covered only if its contents constitute a work based
|
||||
on the Library (independent of the use of the Library in a tool for
|
||||
writing it). Whether that is true depends on what the Library does
|
||||
and what the program that uses the Library does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Library's
|
||||
complete source code as you receive it, in any medium, provided that
|
||||
you conspicuously and appropriately publish on each copy an
|
||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
||||
all the notices that refer to this License and to the absence of any
|
||||
warranty; and distribute a copy of this License along with the
|
||||
Library.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange for a
|
||||
fee.
|
||||
|
||||
2. You may modify your copy or copies of the Library or any portion
|
||||
of it, thus forming a work based on the Library, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) The modified work must itself be a software library.
|
||||
|
||||
b) You must cause the files modified to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
c) You must cause the whole of the work to be licensed at no
|
||||
charge to all third parties under the terms of this License.
|
||||
|
||||
d) If a facility in the modified Library refers to a function or a
|
||||
table of data to be supplied by an application program that uses
|
||||
the facility, other than as an argument passed when the facility
|
||||
is invoked, then you must make a good faith effort to ensure that,
|
||||
in the event an application does not supply such function or
|
||||
table, the facility still operates, and performs whatever part of
|
||||
its purpose remains meaningful.
|
||||
|
||||
(For example, a function in a library to compute square roots has
|
||||
a purpose that is entirely well-defined independent of the
|
||||
application. Therefore, Subsection 2d requires that any
|
||||
application-supplied function or table used by this function must
|
||||
be optional: if the application does not supply it, the square
|
||||
root function must still compute square roots.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Library,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Library, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote
|
||||
it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Library.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Library
|
||||
with the Library (or with a work based on the Library) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
||||
License instead of this License to a given copy of the Library. To do
|
||||
this, you must alter all the notices that refer to this License, so
|
||||
that they refer to the ordinary GNU General Public License, version 2,
|
||||
instead of to this License. (If a newer version than version 2 of the
|
||||
ordinary GNU General Public License has appeared, then you can specify
|
||||
that version instead if you wish.) Do not make any other change in
|
||||
these notices.
|
||||
|
||||
Once this change is made in a given copy, it is irreversible for
|
||||
that copy, so the ordinary GNU General Public License applies to all
|
||||
subsequent copies and derivative works made from that copy.
|
||||
|
||||
This option is useful when you wish to copy part of the code of
|
||||
the Library into a program that is not a library.
|
||||
|
||||
4. You may copy and distribute the Library (or a portion or
|
||||
derivative of it, under Section 2) in object code or executable form
|
||||
under the terms of Sections 1 and 2 above provided that you accompany
|
||||
it with the complete corresponding machine-readable source code, which
|
||||
must be distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange.
|
||||
|
||||
If distribution of object code is made by offering access to copy
|
||||
from a designated place, then offering equivalent access to copy the
|
||||
source code from the same place satisfies the requirement to
|
||||
distribute the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
5. A program that contains no derivative of any portion of the
|
||||
Library, but is designed to work with the Library by being compiled or
|
||||
linked with it, is called a "work that uses the Library". Such a
|
||||
work, in isolation, is not a derivative work of the Library, and
|
||||
therefore falls outside the scope of this License.
|
||||
|
||||
However, linking a "work that uses the Library" with the Library
|
||||
creates an executable that is a derivative of the Library (because it
|
||||
contains portions of the Library), rather than a "work that uses the
|
||||
library". The executable is therefore covered by this License.
|
||||
Section 6 states terms for distribution of such executables.
|
||||
|
||||
When a "work that uses the Library" uses material from a header file
|
||||
that is part of the Library, the object code for the work may be a
|
||||
derivative work of the Library even though the source code is not.
|
||||
Whether this is true is especially significant if the work can be
|
||||
linked without the Library, or if the work is itself a library. The
|
||||
threshold for this to be true is not precisely defined by law.
|
||||
|
||||
If such an object file uses only numerical parameters, data
|
||||
structure layouts and accessors, and small macros and small inline
|
||||
functions (ten lines or less in length), then the use of the object
|
||||
file is unrestricted, regardless of whether it is legally a derivative
|
||||
work. (Executables containing this object code plus portions of the
|
||||
Library will still fall under Section 6.)
|
||||
|
||||
Otherwise, if the work is a derivative of the Library, you may
|
||||
distribute the object code for the work under the terms of Section 6.
|
||||
Any executables containing that work also fall under Section 6,
|
||||
whether or not they are linked directly with the Library itself.
|
||||
|
||||
6. As an exception to the Sections above, you may also combine or
|
||||
link a "work that uses the Library" with the Library to produce a
|
||||
work containing portions of the Library, and distribute that work
|
||||
under terms of your choice, provided that the terms permit
|
||||
modification of the work for the customer's own use and reverse
|
||||
engineering for debugging such modifications.
|
||||
|
||||
You must give prominent notice with each copy of the work that the
|
||||
Library is used in it and that the Library and its use are covered by
|
||||
this License. You must supply a copy of this License. If the work
|
||||
during execution displays copyright notices, you must include the
|
||||
copyright notice for the Library among them, as well as a reference
|
||||
directing the user to the copy of this License. Also, you must do one
|
||||
of these things:
|
||||
|
||||
a) Accompany the work with the complete corresponding
|
||||
machine-readable source code for the Library including whatever
|
||||
changes were used in the work (which must be distributed under
|
||||
Sections 1 and 2 above); and, if the work is an executable linked
|
||||
with the Library, with the complete machine-readable "work that
|
||||
uses the Library", as object code and/or source code, so that the
|
||||
user can modify the Library and then relink to produce a modified
|
||||
executable containing the modified Library. (It is understood
|
||||
that the user who changes the contents of definitions files in the
|
||||
Library will not necessarily be able to recompile the application
|
||||
to use the modified definitions.)
|
||||
|
||||
b) Use a suitable shared library mechanism for linking with the
|
||||
Library. A suitable mechanism is one that (1) uses at run time a
|
||||
copy of the library already present on the user's computer system,
|
||||
rather than copying library functions into the executable, and (2)
|
||||
will operate properly with a modified version of the library, if
|
||||
the user installs one, as long as the modified version is
|
||||
interface-compatible with the version that the work was made with.
|
||||
|
||||
c) Accompany the work with a written offer, valid for at
|
||||
least three years, to give the same user the materials
|
||||
specified in Subsection 6a, above, for a charge no more
|
||||
than the cost of performing this distribution.
|
||||
|
||||
d) If distribution of the work is made by offering access to copy
|
||||
from a designated place, offer equivalent access to copy the above
|
||||
specified materials from the same place.
|
||||
|
||||
e) Verify that the user has already received a copy of these
|
||||
materials or that you have already sent this user a copy.
|
||||
|
||||
For an executable, the required form of the "work that uses the
|
||||
Library" must include any data and utility programs needed for
|
||||
reproducing the executable from it. However, as a special exception,
|
||||
the materials to be distributed need not include anything that is
|
||||
normally distributed (in either source or binary form) with the major
|
||||
components (compiler, kernel, and so on) of the operating system on
|
||||
which the executable runs, unless that component itself accompanies
|
||||
the executable.
|
||||
|
||||
It may happen that this requirement contradicts the license
|
||||
restrictions of other proprietary libraries that do not normally
|
||||
accompany the operating system. Such a contradiction means you cannot
|
||||
use both them and the Library together in an executable that you
|
||||
distribute.
|
||||
|
||||
7. You may place library facilities that are a work based on the
|
||||
Library side-by-side in a single library together with other library
|
||||
facilities not covered by this License, and distribute such a combined
|
||||
library, provided that the separate distribution of the work based on
|
||||
the Library and of the other library facilities is otherwise
|
||||
permitted, and provided that you do these two things:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work
|
||||
based on the Library, uncombined with any other library
|
||||
facilities. This must be distributed under the terms of the
|
||||
Sections above.
|
||||
|
||||
b) Give prominent notice with the combined library of the fact
|
||||
that part of it is a work based on the Library, and explaining
|
||||
where to find the accompanying uncombined form of the same work.
|
||||
|
||||
8. You may not copy, modify, sublicense, link with, or distribute
|
||||
the Library except as expressly provided under this License. Any
|
||||
attempt otherwise to copy, modify, sublicense, link with, or
|
||||
distribute the Library is void, and will automatically terminate your
|
||||
rights under this License. However, parties who have received copies,
|
||||
or rights, from you under this License will not have their licenses
|
||||
terminated so long as such parties remain in full compliance.
|
||||
|
||||
9. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Library or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Library (or any work based on the
|
||||
Library), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Library or works based on it.
|
||||
|
||||
10. Each time you redistribute the Library (or any work based on the
|
||||
Library), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute, link with or modify the Library
|
||||
subject to these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties with
|
||||
this License.
|
||||
|
||||
11. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Library at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Library by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Library.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under any
|
||||
particular circumstance, the balance of the section is intended to apply,
|
||||
and the section as a whole is intended to apply in other circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
12. If the distribution and/or use of the Library is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Library under this License may add
|
||||
an explicit geographical distribution limitation excluding those countries,
|
||||
so that distribution is permitted only in or among countries not thus
|
||||
excluded. In such case, this License incorporates the limitation as if
|
||||
written in the body of this License.
|
||||
|
||||
13. The Free Software Foundation may publish revised and/or new
|
||||
versions of the Lesser General Public License from time to time.
|
||||
Such new versions will be similar in spirit to the present version,
|
||||
but may differ in detail to address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Library
|
||||
specifies a version number of this License which applies to it and
|
||||
"any later version", you have the option of following the terms and
|
||||
conditions either of that version or of any later version published by
|
||||
the Free Software Foundation. If the Library does not specify a
|
||||
license version number, you may choose any version ever published by
|
||||
the Free Software Foundation.
|
||||
|
||||
14. If you wish to incorporate parts of the Library into other free
|
||||
programs whose distribution conditions are incompatible with these,
|
||||
write to the author to ask for permission. For software which is
|
||||
copyrighted by the Free Software Foundation, write to the Free
|
||||
Software Foundation; we sometimes make exceptions for this. Our
|
||||
decision will be guided by the two goals of preserving the free status
|
||||
of all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
||||
DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Libraries
|
||||
|
||||
If you develop a new library, and you want it to be of the greatest
|
||||
possible use to the public, we recommend making it free software that
|
||||
everyone can redistribute and change. You can do so by permitting
|
||||
redistribution under these terms (or, alternatively, under the terms of the
|
||||
ordinary General Public License).
|
||||
|
||||
To apply these terms, attach the following notices to the library. It is
|
||||
safest to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least the
|
||||
"copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the library's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the library, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the
|
||||
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
|
||||
|
||||
<signature of Ty Coon>, 1 April 1990
|
||||
Ty Coon, President of Vice
|
||||
|
||||
That's all there is to it!
|
47
HOWTO_RELEASE
Normal file
47
HOWTO_RELEASE
Normal file
@ -0,0 +1,47 @@
|
||||
1. Verify that the versions currently set in Version.txt
|
||||
sense for this release.
|
||||
|
||||
- GEOS_VERSION_PATCH
|
||||
- GEOS_VERSION_MINOR
|
||||
- GEOS_VERSION_MAJOR
|
||||
|
||||
- CAPI_INTERFACE_CURRENT
|
||||
- CAPI_INTERFACE_REVISION
|
||||
- CAPI_INTERFACE_AGE
|
||||
|
||||
Always increase the revision value.
|
||||
Increase the current value whenever an interface has been added, removed or changed.
|
||||
Increase the age value only if the changes made to the ABI are backward compatible.
|
||||
|
||||
2. Run 'make distcheck', fix any problem with it.
|
||||
|
||||
3. Update the NEWS file (extract most important things from the
|
||||
repository log). Make sure to update the release date.
|
||||
|
||||
4. Commit the changes in the NEWS file.
|
||||
|
||||
5. Run 'make dist-bzip2'.
|
||||
|
||||
$ ./autogen.sh && ./configure && make dist-bzip2
|
||||
|
||||
6. Verify that you can un-pack and build the tarball.
|
||||
|
||||
- autotools: ./configure && make check
|
||||
- cmake: mkdir build && cd build && cmake .. && make && make check
|
||||
|
||||
7. Copy the tarball to upload.osgeo.org:/osgeo/download/geos
|
||||
|
||||
8. Tag the release:
|
||||
|
||||
$ git tag MAJOR.MINOR.PATCH
|
||||
$ git push origin MAJOR.MINOR.PATCH
|
||||
|
||||
9. Increment all the version numbers for the next release (described in 1 above).
|
||||
|
||||
10. Update wiki page https://trac.osgeo.org/geos/ at Download section
|
||||
|
||||
- Add latest release
|
||||
- Remove previous patch level release (if any)
|
||||
|
||||
11. Announce on geos-devel
|
||||
|
92
INSTALL
Normal file
92
INSTALL
Normal file
@ -0,0 +1,92 @@
|
||||
## Building GEOS From Source
|
||||
|
||||
### Prerequisites
|
||||
|
||||
GEOS has no external library dependencies and can be built with any C++11
|
||||
compiler.
|
||||
|
||||
### Unix
|
||||
|
||||
GEOS can be built on Unix systems using either the autotools or CMake build
|
||||
systems.
|
||||
|
||||
#### Using Autotools:
|
||||
|
||||
When building GEOS using autotools, a `configure` script must first be generated
|
||||
using the `autogen.sh` file included in the root of the repository:
|
||||
|
||||
./autogen.sh
|
||||
|
||||
An out-of-tree build can then be initiated by creating a subdirectory and
|
||||
running the generated `configure` script from that subdirectory:
|
||||
|
||||
mkdir obj && cd obj && ../configure
|
||||
|
||||
Once the `configure` script has run, GEOS can be built by running `make` and
|
||||
installed by running `make install`. The test suite can be run using `make
|
||||
check`.
|
||||
|
||||
#### Using CMake:
|
||||
|
||||
To build `GEOS` using CMake, create a build directory and run the `cmake` command
|
||||
from that location:
|
||||
|
||||
mkdir build && cd build && cmake -DCMAKE_BUILD_TYPE=Release ..
|
||||
|
||||
Setting `CMAKE_BUILD_TYPE` to `Release` is necessary to enable compiler
|
||||
optimizations.
|
||||
|
||||
Once the `cmake` tool has run, GEOS can be built by running `make` and
|
||||
installed by running `make install`.
|
||||
|
||||
The entire test suite can be run using `make check`.
|
||||
Alternatively, the `ctest` command can be used, which provides more control over test execution.
|
||||
For example, `ctest -R unit-capi -j2` uses a regular expression to run all tests
|
||||
associated with the C API, using two processes in parallel.
|
||||
A list of available tests can be obtained using `ctest -N`.
|
||||
|
||||
### Microsoft Windows
|
||||
|
||||
GEOS can be built with Microsoft Visual C++ by opening the `CMakeLists.txt` in
|
||||
the project root using `File > Open > CMake`.
|
||||
|
||||
If you prefer the command-line
|
||||
|
||||
#### Build with CMake generator for Ninja (fast)
|
||||
|
||||
In the Visual Studio 2019 command prompt, `x64 Native Tools Command Prompt for VS 2019` or `x64_x86 Cross Tools Command Prompt for VS 2019`:
|
||||
|
||||
```
|
||||
cmake -S . -B _build_vs2019_ninja -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||
cmake --build _build_vs2019_ninja -j 16 --verbose
|
||||
```
|
||||
|
||||
#### Build with CMake generator for MSBuild (default)
|
||||
|
||||
In the non-specific Command Prompt:
|
||||
|
||||
##### 64-bit
|
||||
|
||||
```
|
||||
cmake -S . -B _build_vs2019x64 -G "Visual Studio 16 2019" -A x64 -DCMAKE_GENERATOR_TOOLSET=host=x64
|
||||
cmake --build _build_vs2019x64 --config Release -j 16 --verbose
|
||||
```
|
||||
|
||||
##### 32-bit
|
||||
|
||||
```
|
||||
cmake -S . -B _build_vs2019x32 -G "Visual Studio 16 2019" -A x32 -DCMAKE_GENERATOR_TOOLSET=host=x64
|
||||
cmake --build _build_vs2019x32 --config Release -j 16 --verbose
|
||||
```
|
||||
|
||||
#### Test using CMake
|
||||
|
||||
```
|
||||
cd <build directory>
|
||||
ctest --show-only
|
||||
ctest
|
||||
ctest --output-on-failure
|
||||
ctest -V
|
||||
ctest -VV
|
||||
```
|
||||
|
77
Makefile.am
Normal file
77
Makefile.am
Normal file
@ -0,0 +1,77 @@
|
||||
#
|
||||
# This file is part of project GEOS (http://trac.osgeo.org/geos/)
|
||||
#
|
||||
# NOTE: Make sure that 'src' appears first.
|
||||
# 'capi' and 'doc' surely rely on availability of libgeos
|
||||
# which is built under 'src' and it seems that automake
|
||||
# is not able to detect required build order but blindly
|
||||
# relies on the order items in SUBDIRS appear.
|
||||
#
|
||||
|
||||
# foreign is needed to avoid enforced ChangeLog in EXTRA_DIST
|
||||
# (we'll still take care of adding it ourselves)
|
||||
AUTOMAKE_OPTIONS = foreign
|
||||
|
||||
SUBDIRS = \
|
||||
include \
|
||||
src \
|
||||
capi \
|
||||
doc \
|
||||
macros \
|
||||
swig \
|
||||
tests \
|
||||
benchmarks \
|
||||
tools
|
||||
|
||||
BUILT_SOURCES =
|
||||
|
||||
EXTRA_DIST = \
|
||||
README.md \
|
||||
acsite.m4 \
|
||||
.editorconfig \
|
||||
Version.txt \
|
||||
CMakeLists.txt \
|
||||
cmake/cmake_uninstall.cmake.in \
|
||||
cmake/geos-config.cmake \
|
||||
cmake/FindMakeDistCheck.cmake
|
||||
|
||||
ACLOCAL_AMFLAGS = -I macros
|
||||
|
||||
dist-hook: gen-ChangeLog
|
||||
|
||||
gen-ChangeLog:
|
||||
cd $(distdir) && owd=`pwd` && \
|
||||
cd ../ && cd $(srcdir) && \
|
||||
if test -d .git; then \
|
||||
git log --pretty --numstat --summary | git2cl > $${owd}/ChangeLog; \
|
||||
elif test -d .svn; then \
|
||||
svn2cl --authors=authors.svn -i -o $${owd}/ChangeLog; \
|
||||
elif test -f ChangeLog; then \
|
||||
cp ChangeLog $${owd}/ChangeLog; \
|
||||
fi
|
||||
|
||||
apidoc doxygen:
|
||||
cd doc && make $@
|
||||
|
||||
doxygen-checked:
|
||||
( set -o pipefail; \
|
||||
! make doxygen 2>&1 > /dev/null | \
|
||||
grep -v '\(not documented\|ignoring unsupported tag\)'; \
|
||||
)
|
||||
|
||||
authors.git: authors.svn
|
||||
cd $(srcdir) && sed -e 's/:/ = /' authors.svn > authors.git
|
||||
|
||||
svnrebase: authors.git
|
||||
cd $(srcdir) && git svn rebase --authors-file authors.git
|
||||
|
||||
VALGRIND = $(LIBTOOL) --mode=execute valgrind --leak-check=full --error-exitcode=1
|
||||
|
||||
valgrindcheck:
|
||||
$(VALGRIND) tests/unit/geos_unit
|
||||
|
||||
check-local:
|
||||
! find $(srcdir) -name '*.cpp' -o -name '*.h' | \
|
||||
grep -v tests/xmltester/tinyxml | \
|
||||
grep -v include/geos/algorithm/ttmath | \
|
||||
xargs grep -n '[[:space:]]$$'
|
706
NEWS
Normal file
706
NEWS
Normal file
@ -0,0 +1,706 @@
|
||||
Changes in 3.8.1
|
||||
2020-03-10
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Stack allocate line segments in OverlapUnion (Paul Ramsey)
|
||||
- Avoid returning non-empty CoordinateSequence from empty Point
|
||||
(#1001, Dan Baston)
|
||||
- Avoid assertion failure with MSVC 2017 / 2019 (#1002, Dan Baston)
|
||||
- Remove whitespace from end of GEOSversion() output (azhi)
|
||||
- Improve performance of GEOSisValid (#1008, Dan Baston)
|
||||
- Avoid changing MultiLineString component order in GEOSReverse
|
||||
(#1013, Dan Baston)
|
||||
- Fix missing vtable for LineString and CoordinateArraySequenceFactory
|
||||
(#299 and #1016, Evgen Bodunov)
|
||||
- Reduce performance regression in GEOSBuffer (#1020)
|
||||
|
||||
Changes in 3.8.0
|
||||
2019-10-10
|
||||
|
||||
- New things:
|
||||
- CAPI: GEOSBuildArea (#952, Even Rouault)
|
||||
- CAPI: GEOSMakeValid (#952, Even Rouault)
|
||||
- CAPI: GEOSPolygonize_valid (#727, Dan Baston)
|
||||
- CAPI: GEOSCoverageUnion (Dan Baston)
|
||||
- CAPI: GEOSCoordSeq_setXY, GEOSCoordSeq_setXYZ,
|
||||
GEOSCoordSeq_getXY, GEOSCoordSeq_getXYZ (Dan Baston)
|
||||
- CAPI: GEOSMinimumBoundingCircle (#735)
|
||||
- CAPI: GEOSGeom_createPointFromXY (Dan Baston)
|
||||
|
||||
- Improvements:
|
||||
- Improve overall performance by reducing of heap allocations (Dan Baston)
|
||||
- Improve performance and robustness of GEOSPointOnSurface (Martin Davis)
|
||||
- Improve performance of GEOSPolygonize for cases with many potential
|
||||
holes (#748, Dan Baston)
|
||||
- Support extended precision calculations (ttmath) and port JTS
|
||||
improvements related to extended precision (Paul Ramsey, Mateusz Loskot)
|
||||
- Improve performance of GEOSPolygonize for cases with many or complex
|
||||
shells (Dan Baston, Martin Davis)
|
||||
- Improve performance of Delaunay triangulations / Voronoi Diagrams
|
||||
(Dan Baston)
|
||||
- Improve performance of prepared geometry operations (Dan Baston)
|
||||
- Improve robustness of Delaunay triangulations (Paul Ramsey, Martin Davis)
|
||||
- Improve performance of unary union for lines (Dan Baston)
|
||||
- Improve general predicate, overlay, and buffer performance (Dan Baston, Paul Ramsey)
|
||||
- Improve cascaded union performance (Paul Ramsey, Martin Davis)
|
||||
- Allocate default GeometryFactory singleton on the stack (Sandro Mani)
|
||||
- Harmonize XML tests with JTS and harmonize cmake/autoconf
|
||||
test running (Paul Ramsey)
|
||||
- CMake modernization (Mateusz Loskot, Paul Ramsey, Dan Baston)
|
||||
- Return unique_ptr from most methods that produce a new geometry (Dan Baston)
|
||||
|
||||
- Changes:
|
||||
- Constructive geometry functions in CAPI now preserve SRID
|
||||
of input arguments in output (#896)
|
||||
|
||||
|
||||
Changes in 3.7.2
|
||||
2019-05-02
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Envelope constructor using strtod (#875 Paul Ramsey)
|
||||
- Failure in CMake for OSX Framework (#936 Paul Ramsey)
|
||||
- Polygon build failure in Overlay difference (#789 Paul Ramsey)
|
||||
- Invalid union result from valid polygon inputs (#838)
|
||||
|
||||
|
||||
Changes in 3.7.1
|
||||
2018-11-29
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Fix crash in GEOSCoordSeq_isCCW with empty coordseq
|
||||
(#927, Sergey Fedoseev)
|
||||
- Fix crash in GEOSInterpolate with empty LineString
|
||||
(#926, Sergey Fedoseev)
|
||||
- Fix crash in GEOSUnaryUnion with empty LineString
|
||||
(#928, Sergey Fedoseev)
|
||||
- Fix memory leak in SIRtree::insert (#919, Dan Baston)
|
||||
- Reduce required autoconf to 2.63
|
||||
(#56, John Harvey)
|
||||
- Fix incorrect return values on error from GEOSLength
|
||||
GEOSisValidDetail (#941, Dan Baston)
|
||||
|
||||
|
||||
Changes in 3.7.0
|
||||
2018-09-10
|
||||
|
||||
- New things:
|
||||
- CAPI: GEOSDistanceIndexed (#795, Dan Baston)
|
||||
- CAPI: GEOSCoordSeq_isCCW (#870, Dan Baston)
|
||||
- CAPI: GEOSGeom_getXMin, GEOSGeom_getXMax,
|
||||
GEOSGeom_getYMin, GEOSGeom_getYMax (#871, Dan Baston)
|
||||
- CAPI: GEOSFrechetDistance (#797, Shinichi SUGIYAMA)
|
||||
- CAPI: GEOSReverse (#872, Dan Baston)
|
||||
- CAPI: GEOSSegmentIntersection (#873, Dan Baston)
|
||||
- CAPI: GEOSGeomGetZ (#581, J Smith)
|
||||
|
||||
- Improvements
|
||||
- Interruptible snap operation (Paul Ramsey)
|
||||
- Numerous packaging, doc, and build changes
|
||||
(Debian group: Bas Couwenberg, Francesco Paolo Lovergine)
|
||||
|
||||
- C++ API changes:
|
||||
- Require defining USE_UNSTABLE_GEOS_CPP_API for use without
|
||||
warnings.
|
||||
- Make C++11 required (Mateusz Loskot)
|
||||
- Use C++11 unique_ptr, nullptr, and override constructs
|
||||
(Mateusz Loskot)
|
||||
- C++11 standard delete on noncopyable
|
||||
(#851, Vicky Vergara)
|
||||
- Fix CommonBits::getBit to correctly handle i >= 32
|
||||
(#834, Kurt Schwehr)
|
||||
|
||||
Changes in 3.7.0rc1
|
||||
2018-08-19
|
||||
Fixes / enhancements since 3.7.0beta2
|
||||
- Avoid segfault when querying empty tree (#730, framm)
|
||||
- Collection with Empty components crashes overlay (#782, Dan Baston)
|
||||
- Allow static library with C API for CMake builds (#878, Dakota Hawkins)
|
||||
|
||||
Changes in 3.7.0beta2
|
||||
2018-08-06
|
||||
Fixes since 3.7.0beta1
|
||||
- Fix infinite loop in GEOSClipByRect (#865, Dan Baston)
|
||||
- Make GEOSException inherit from std::runtime_error
|
||||
to address clang warnings (Dan Baston)
|
||||
- Add missing CMake files to tarball (#895, Regina Obe)
|
||||
|
||||
|
||||
Changes in 3.7.0beta1
|
||||
2018-06-25
|
||||
See 3.7.0 latest notes
|
||||
|
||||
Changes in 3.7.0alpha
|
||||
2018-06-14
|
||||
See 3.7.0 notes
|
||||
|
||||
Changes in 3.6.1
|
||||
2016-12-24
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Fix GEOSSTRtree_nearest_r signature and add implementation (#796)
|
||||
- Fix --static-clibs and --static-cclibs returns from geos-config
|
||||
- Fix WKB representation of empty polygon (#680).
|
||||
- Fix empty GEOSSimplify return on inner ring collapse (#741)
|
||||
|
||||
Changes in 3.6.0
|
||||
2016-10-25
|
||||
|
||||
- Important / Breaking Changes:
|
||||
- The PHP binding moved to its own repository:
|
||||
http://git.osgeo.org/gogs/geos/php-geos (#765)
|
||||
- New things:
|
||||
- CAPI: GEOSGeom_{get,set}UserData (Rashad Kanavath)
|
||||
- CAPI: GEOSGeom_{set,get}Precision (#713)
|
||||
- CAPI: GEOSMinimumRotatedRectangle and GEOSMinimumWidth
|
||||
(#729, Nyall Dawson)
|
||||
- CAPI: GEOSSTRtree_nearest (#768, Dan Baston)
|
||||
- CAPI: GEOSMinimumClearance and GEOSMinimumClearanceLine
|
||||
(#776, Dan Baston)
|
||||
- C++ API changes:
|
||||
- Automatic memory management for GeometryFactory objects
|
||||
|
||||
|
||||
Changes in 3.5.0
|
||||
2015-08-16
|
||||
|
||||
- New things:
|
||||
- Voronoi API (#627)
|
||||
- PHP: Geometry->normalize method
|
||||
- GEOS_USE_ONLY_R_API macro support (#695)
|
||||
- PHP: WKBReader->read() & WKBWriter::write() methods (Benjamin Morel)
|
||||
- GEOSClipByRect (#699, Mika Heiskanen, Sandro Santilli)
|
||||
- CAPI: thread-safe message handling API (#663, Pepijn Van Eeckhoudt)
|
||||
- Improvements:
|
||||
- Speed-up intersection and difference between geometries
|
||||
with small bounding box overlap.
|
||||
- CAPI: add MULTILINESTRING support for GEOSisClosed (Benjamin Morel)
|
||||
- C++ API changes:
|
||||
- Added no-parameter CoordinateSequenceFactory::create method (Sandro Mani)
|
||||
|
||||
Changes in 3.4.2
|
||||
2013-08-25
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Use a double for PrecisionModel scale, avoiding overflows
|
||||
should fix 32-bit regression failures (#652)
|
||||
- isnan workaround OS detection missing NetBSD, DragonFly, Sun nuance (#650)
|
||||
- Do not distribute platform.h and version.h, but install both (#601)
|
||||
- Non-standard ChangeLog file in 3.4.0 and 3.4.1 releases (#654)
|
||||
- new travis bot (#657)
|
||||
- accept multiple Nan representations (#656)
|
||||
|
||||
|
||||
Changes in 3.4.1
|
||||
2013-08-17
|
||||
|
||||
- Bug fixes / improvements
|
||||
- Assertion failure snapping line to points of rectangle
|
||||
smaller than tolerance (#649)
|
||||
- Can't build using cmake with tar ball (#644)
|
||||
|
||||
Changes in 3.4.0
|
||||
2013-08-11
|
||||
|
||||
- New things:
|
||||
- Delaunay Triangulation API (#487, #565, #570, #567)
|
||||
- Interruptibility API (C and C++)
|
||||
- CAPI: GEOSNode (#496) - PHP: Geometry->node
|
||||
- GeometryPrecisionReducer class (#496, #526)
|
||||
- BufferInputLineSimplifier header exposed (#548)
|
||||
- New Centroid class supporting mixed geometry components (#612)
|
||||
- io::Writer::reserve() method
|
||||
- CAPI: GEOSNearestPoints
|
||||
- Add --cclibs, --static-clibs and --static-cclibs to geos-config (#497)
|
||||
- Early bail out of overlay exception if input is invalid
|
||||
|
||||
- C++ API changes:
|
||||
- New noding::GeometryNoder class
|
||||
- Added BufferOp::setSingleSided
|
||||
- Signature of most functions taking a Label changed to take it
|
||||
by reference rather than pointer.
|
||||
- Signature of most functions taking an IntersectionMatrix changed
|
||||
to take it by reference rather than pointer.
|
||||
- GraphComponent::label is now a Label value (from a pointer)
|
||||
- NodedSegmentString takes ownership of CoordinateSenuence now
|
||||
- io::Writer's toString() returns by const ref, write() takes a const ref
|
||||
- Unify prototypes of WKTReader and WKBReader constructor (#310)
|
||||
- GeometryCollection::computeEnvelopInternal and
|
||||
GeometryCollection::compareToSameClass are marked virtual (#478)
|
||||
|
||||
- Bug fixes / improvements
|
||||
- A point interpolated from a line does not always intersect
|
||||
the same line (#323)
|
||||
- Port ConvexHull robustness fix from JTS-1.13 (#457)
|
||||
- Improve Overlay robustness by reducing input precision on topology
|
||||
exception and by refusing to accept unnoded output (#459)
|
||||
- Improve Buffer robustness by reducing input precision on topology
|
||||
exception (#605)
|
||||
- Mismatch segment sides in OffsetCurveBuilder (#633 )
|
||||
- Fixed Linear Referencing API to handle MultiLineStrings consistently
|
||||
by always using the lowest possible index value, and by trimming
|
||||