Commit graph

466 commits

Author SHA1 Message Date
Sandro Santilli 72fb032864 Fix 'clean' rule under loader to drop stuff under .libs
git-svn-id: http://svn.osgeo.org/postgis/trunk@8191 b70326c6-7e19-0410-871a-916f4a2858ee
2011-11-20 20:51:27 +00:00
Paul Ramsey 07f2341e38 Ensure calls to lwgeom->type use type of uint8_t
git-svn-id: http://svn.osgeo.org/postgis/trunk@8027 b70326c6-7e19-0410-871a-916f4a2858ee
2011-10-28 17:01:02 +00:00
Sandro Santilli 39d7914c30 Define SHELL (used by LIBTOOL and INSTALL) hopefully helps bug #1218
git-svn-id: http://svn.osgeo.org/postgis/trunk@7921 b70326c6-7e19-0410-871a-916f4a2858ee
2011-09-29 19:43:00 +00:00
Sandro Santilli 809ae790e4 Move LWDEBUG macros in a new lwgeom_log.h header file (see #1220)
Update all implementation files accordingly.
Fix some misuses out of liblwgeom.
Add missing copyright notices in a few files.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7907 b70326c6-7e19-0410-871a-916f4a2858ee
2011-09-28 10:05:36 +00:00
Paul Ramsey 54484e1f7a shp2pgsql gui wrong use of create spatial index (#1091)
git-svn-id: http://svn.osgeo.org/postgis/trunk@7862 b70326c6-7e19-0410-871a-916f4a2858ee
2011-09-17 19:59:41 +00:00
Sandro Santilli d7bf7ec260 Dynamically link loader and dumper to liblwgeom [RT-SIGTA]
This reduces each of the 3 installed executable sizes by 547 Kb.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7793 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-29 15:23:35 +00:00
Sandro Santilli b131652f6c Drop (u)int32 and uchar in favor of C99 standard int types [RT-SIGTA]
This commit drops PostgreSQL references in liblwgeom.h (C_H define)
and hopefully reduces the noise generated by custom symbols.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7761 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-19 09:34:58 +00:00
Sandro Santilli 3713c150e0 Don't use problematic int types for no reason...
git-svn-id: http://svn.osgeo.org/postgis/trunk@7760 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-19 09:30:21 +00:00
Sandro Santilli f3db965181 Second attempt at libtool usage. Seems better to me now.
PostGIS clients still all use the static version of the library.
Libraries are not installed by default.
[RT-SIGTA]

git-svn-id: http://svn.osgeo.org/postgis/trunk@7744 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-13 10:06:07 +00:00
Sandro Santilli 72b1c0a360 loader also includes liblwgeom.h, thus wants PROJ cpp flags
git-svn-id: http://svn.osgeo.org/postgis/trunk@7737 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-12 17:37:33 +00:00
Sandro Santilli 89bb89d9d1 Give PARSER_CHECK macros an LW_ prefix [RT-SIGTA]
git-svn-id: http://svn.osgeo.org/postgis/trunk@7725 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-11 07:51:45 +00:00
Sandro Santilli f9b94014f1 Drop REPEATED_POINTS_* and SPLICE_* defines from liblwgeom.h, move MAXFLOAT to liblwgeom_internal.h [RT-SIGTA]
git-svn-id: http://svn.osgeo.org/postgis/trunk@7716 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-09 15:12:06 +00:00
Sandro Santilli 0acdc94202 Don't include liblwgeom.h from headers if not needed, document what is it needed for in implementation files [RT-SIGTA]
git-svn-id: http://svn.osgeo.org/postgis/trunk@7713 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-09 09:51:52 +00:00
Sandro Santilli 1620279562 Clean up gui as well
git-svn-id: http://svn.osgeo.org/postgis/trunk@7712 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-09 09:50:45 +00:00
Sandro Santilli f979d106a4 Encode more deps
git-svn-id: http://svn.osgeo.org/postgis/trunk@7709 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-08 10:11:40 +00:00
Sandro Santilli 4f058f6f1b Include postgis_config.h to find POSTGIS_VERSION and stringbuffer.h when needed
git-svn-id: http://svn.osgeo.org/postgis/trunk@7705 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-06 18:42:28 +00:00
Sandro Santilli 25ae1f548b Re-drop use of libtool (more troubles than help).
Stub a rule to build and install a shared liblwgeom.
[RT-SIGTA].

git-svn-id: http://svn.osgeo.org/postgis/trunk@7701 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-06 17:48:39 +00:00
Sandro Santilli e5152c02d6 Use libtool to build liblwgeom. Still only static. [RT-SIGTA]
git-svn-id: http://svn.osgeo.org/postgis/trunk@7699 b70326c6-7e19-0410-871a-916f4a2858ee
2011-08-06 15:12:32 +00:00
Mark Cave-Ayland 67e3f3298b Fix compile warning for lwgeom_init_allocators() in loader/dumper by adding missing liblwgeom.h #include.
git-svn-id: http://svn.osgeo.org/postgis/trunk@7606 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-06 10:48:05 +00:00
Mark Cave-Ayland adf9834315 Fix for #1088: Too many columns in select crashes pgsql2shp.
Instead of a fixed length query string, dynamically allocate the memory based
upon the sum of the lengths of all of the column names.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7566 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-03 21:47:09 +00:00
Mark Cave-Ayland baeeefeb22 Update loader regression test suite to add a simple test for shp2pgsql (much as we now do for pgsql2shp).
Note that these tests aren't completely comprehensive and should be expanded, with the long term aim
of moving the loader regression tests out of the main regression harness and into CUnit instead.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7551 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-02 13:43:35 +00:00
Mark Cave-Ayland 820efdcc24 Fix up the loader unit tests so that if --with-gui is not passed to configure, the non-GUI tests will continute to run instead of failing compilation.
git-svn-id: http://svn.osgeo.org/postgis/trunk@7550 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-02 12:34:16 +00:00
Mark Cave-Ayland 9bb000bbcc Another attempt to fix #1080 on Windows - it seems that simply opening and
closing a pgsql2shp state object is a good way to find all uninitialised
variables.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7547 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-01 22:36:48 +00:00
Mark Cave-Ayland 5c705a34c8 Revised fix for #1080 based upon backtrace provided by Regina.
git-svn-id: http://svn.osgeo.org/postgis/trunk@7546 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-01 21:37:34 +00:00
Mark Cave-Ayland 1b0e73ba66 Fix #1080: cunit is crashing on test_ShpDumerDestroy().
Looks like the original code omitted to set the default config values causing
the addition of a ShpDumperDestroy() call to fall over on some platforms due
to uninitialised pointers.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7533 b70326c6-7e19-0410-871a-916f4a2858ee
2011-07-01 09:33:28 +00:00
Mark Cave-Ayland 06b5e95f83 Commit rework of #885 (pgsql2shp fields conversion from predefined list).
This patch required extra work to ensure that it was a better fit for the
new loader/dumper structure including error reporting, better use of C
coding style and altering various names/code locations as appropriate.

git-svn-id: http://svn.osgeo.org/postgis/trunk@7524 b70326c6-7e19-0410-871a-916f4a2858ee
2011-06-29 22:40:54 +00:00
Sandro Santilli 2f3f65e974 Fix libiconv linker flags
git-svn-id: http://svn.osgeo.org/postgis/trunk@7392 b70326c6-7e19-0410-871a-916f4a2858ee
2011-06-14 08:20:16 +00:00
Paul Ramsey 63cd9b8def Allow cunit tests to build and run in OS/X
git-svn-id: http://svn.osgeo.org/postgis/trunk@7388 b70326c6-7e19-0410-871a-916f4a2858ee
2011-06-13 20:20:56 +00:00
Sandro Santilli ebf3d2dc1b Do not error out if things are clean already
git-svn-id: http://svn.osgeo.org/postgis/trunk@7028 b70326c6-7e19-0410-871a-916f4a2858ee
2011-04-14 10:38:22 +00:00
Sandro Santilli 91f24b5ef0 Properly clean in loader's cunit test dir
git-svn-id: http://svn.osgeo.org/postgis/trunk@7027 b70326c6-7e19-0410-871a-916f4a2858ee
2011-04-14 10:36:08 +00:00
Mark Leslie fd7107cd38 Adding a dbf filter for file selection.
git-svn-id: http://svn.osgeo.org/postgis/trunk@7023 b70326c6-7e19-0410-871a-916f4a2858ee
2011-04-13 10:25:06 +00:00
Sandro Santilli a7c93b6306 Ticket #855 by Loic Dachary: pgsql2shp fields conversion from predefined list
git-svn-id: http://svn.osgeo.org/postgis/trunk@6996 b70326c6-7e19-0410-871a-916f4a2858ee
2011-04-03 19:19:30 +00:00
Paul Ramsey ec01ab6dc8 Jeff Adams: Changed variables we are storing getopt result in from char to int, since int is the return type from the getopt function. (#663)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6935 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-18 19:43:25 +00:00
Paul Ramsey 9b394f152f Jeff Adams: Added regression test for LATIN1 encoding, fixed failure to convert to UTF8. (#808)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6932 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-18 19:13:26 +00:00
Paul Ramsey 8647121289 Jeff Adams: Per suggestion on #857, corrected output to indicate table name is optional.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6927 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-18 16:54:18 +00:00
Paul Ramsey 359ab99a41 Jeff Adams: Increasing precision due to tests failing in automatic build.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6925 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-18 16:24:33 +00:00
Paul Ramsey a2c725a6fb Fixes the following shp2pgsql issues:
#229: A new "-r" command line parameter to specify a "from" SRID for reprojecting (the existing -s is the "to").
#779: -S now works for points, and -w is documented.
#864: MULTIPOINT shapefiles with single-vertex points now correctly load with all MULTIPOINTs.
#865: no longer crashes when both -g and -G are used.



git-svn-id: http://svn.osgeo.org/postgis/trunk@6922 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-18 15:40:31 +00:00
Paul Ramsey 2db8d4de0e Jeff Adams patch to add command line flag to not use a transaction. (#110)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6909 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-16 17:16:47 +00:00
Paul Ramsey eea9d3470a Jeff Adams patch to support tablespaces (#67)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6905 b70326c6-7e19-0410-871a-916f4a2858ee
2011-03-16 13:02:43 +00:00
Regina Obe 4ca2f6a08d start getting rid of deprecated calls
git-svn-id: http://svn.osgeo.org/postgis/trunk@6524 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-28 18:22:37 +00:00
Sandro Santilli 67ea552e1b Only run unit tests when building GUI (See http://postgis.refractions.net/pipermail/postgis-devel/2010-December/011014.html)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6414 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-16 14:35:22 +00:00
Paul Ramsey 26398241e2 Minor usage changes. (#604)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6374 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-14 05:01:51 +00:00
Paul Ramsey 639ab205d8 Return value of snprintf not correctly checked (#556)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6360 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-13 20:40:48 +00:00
Paul Ramsey 2a22e258a6 Change default shp2pgsql column to "geom" (#352)
git-svn-id: http://svn.osgeo.org/postgis/trunk@6358 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-13 20:09:26 +00:00
Paul Ramsey 1ae5b8f68b ptarray_free now frees the serialized_ptlist, unless FLAGS_GET_READONLY is set.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6340 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-11 00:28:57 +00:00
Paul Ramsey 892caa698a Remove many instances of lwgeom_getType used on PG_LWGEOM
git-svn-id: http://svn.osgeo.org/postgis/trunk@6309 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-08 22:31:28 +00:00
Paul Ramsey b05eea79c6 Rename lwgeom_from_wkt to lwgeom_parse_wkt to note the use of the parser object.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6294 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-08 00:02:31 +00:00
Paul Ramsey 77b08404a5 Start flipping over references to srid = -1 to srid = SRID_UNKNOWN
git-svn-id: http://svn.osgeo.org/postgis/trunk@6293 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-07 21:59:54 +00:00
Paul Ramsey 4cc4123357 Replace the old WKB/WKT parser and emitters with the new ones.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6291 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-07 21:08:05 +00:00
Paul Ramsey a907649647 Change i18n instructions to use shp2pgsql_LANG.po as format for po file names.
git-svn-id: http://svn.osgeo.org/postgis/trunk@6267 b70326c6-7e19-0410-871a-916f4a2858ee
2010-12-02 20:38:06 +00:00