Changeset: b6e64c8adf1d for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b6e64c8adf1d
Added Files:
        debian/libmonetdb5-server-lidar.install
Modified Files:
        MonetDB.spec
        configure.ag
        debian/control
        debian/monetdb5-server.install
        gdk/gdk_bbp.c
        geom/monetdb5/geom.c
        geom/sql/conformance/Tests/T13.stable.out
        geom/sql/conformance/Tests/T14.stable.out
        geom/sql/conformance/Tests/T17.stable.out
        geom/sql/conformance/Tests/T18.stable.out
        geom/sql/conformance/Tests/T23.stable.out
        geom/sql/conformance/Tests/T24.stable.out
        geom/sql/conformance/Tests/T27.stable.out
        geom/sql/conformance/Tests/T29.stable.out
        geom/sql/conformance/Tests/T31.stable.out
        geom/sql/conformance/Tests/T34.stable.out
        geom/sql/conformance/Tests/T47.stable.out
        geom/sql/conformance/Tests/T48.stable.out
        geom/sql/conformance/Tests/T49.stable.out
        geom/sql/conformance/Tests/T50.stable.out
        geom/sql/conformance/Tests/T52.stable.out
        geom/sql/conformance/Tests/T8.stable.out
        geom/sql/functions/Tests/ST_AsEWKT.stable.out
        geom/sql/functions/Tests/ST_AsText.stable.out
        geom/sql/functions/Tests/ST_NumPoints.stable.err
        geom/sql/pg_regression/Tests/boundary.stable.out
        geom/sql/pg_regression/Tests/delaunaytriangles.stable.out
        monetdb5/mal/mal_profiler.c
        rpm.mk.in
        sql/backends/monet5/sql_upgrades.c
        sql/backends/monet5/vaults/lidar/Makefile.ag
        sql/server/rel_updates.c
        sql/test/BugTracker-2014/Tests/querylog.Bug-3607.sql
        sql/test/BugTracker-2014/Tests/querylog.Bug-3607.stable.out
        sql/test/BugTracker-2016/Tests/All
        
sql/test/BugTracker-2016/Tests/DISTINCT_with_correlated_scalar_subquery_crashes_mserver.Bug-3920.sql
        
sql/test/BugTracker-2016/Tests/DISTINCT_with_correlated_scalar_subquery_crashes_mserver.Bug-3920.stable.out
        sql/test/Dependencies/Tests/All
        sql/test/Tests/All
        sql/test/pg_regress/Tests/box.stable.err
        sql/test/pg_regress/Tests/box.stable.out
        sql/test/pg_regress/Tests/path.stable.out
        sql/test/pg_regress/Tests/point.stable.out
        sql/test/pg_regress/Tests/polygon.stable.out
        sql/test/testdb-upgrade-chain-hge/Tests/upgrade.stable.out
        sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out
        sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out.int128
        sql/test/testdb-upgrade-hge/Tests/upgrade.stable.out
        sql/test/testdb-upgrade/Tests/upgrade.stable.out
        sql/test/testdb-upgrade/Tests/upgrade.stable.out.int128
Branch: embedded
Log Message:

merge with default


diffs (truncated from 6651 to 300 lines):

diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -50,10 +50,23 @@
 %define with_geos 1
 %endif
 
+# On Fedora, the liblas library is available, and so we can require it
+# and build the lidar modules.  On RedHat Enterprise Linux and
+# derivatives (CentOS, Scientific Linux), the liblas library is not
+# available, even with EPEL available.
 %if %{?rhel:0}%{!?rhel:1}
-# If the _without_samtools macro is set, the MonetDB-bam-MonetDB5 RPM
-# will be created.  The macro can be set when using mock by passing it
-# the flag --without=samtools.
+# If the _without_lidar macro is not set, the MonetDB-lidar RPM will
+# be created.  The macro can be set when using mock by passing it the
+# flag --without=lidar.
+%if %{?_without_lidar:0}%{!?_without_lidar:1}
+%define with_lidar 1
+%endif
+%endif
+
+%if %{?rhel:0}%{!?rhel:1}
+# If the _without_samtools macro is not set, the MonetDB-bam-MonetDB5
+# RPM will be created.  The macro can be set when using mock by
+# passing it the flag --without=samtools.
 # Note that the samtools-devel RPM is not available on RedHat
 # Enterprise Linux and derivatives, even with EPEL availabe.
 # (Actually, at the moment of writing, samtools-devel is available in
@@ -102,6 +115,11 @@ BuildRequires: cfitsio-devel
 BuildRequires: geos-devel >= 3.0.0
 %endif
 BuildRequires: gsl-devel
+%if %{?with_lidar:1}%{!?with_lidar:0}
+BuildRequires: liblas-devel gdal-devel libgeotiff-devel
+# Fedora 22 libas-devel does not depend on liblas:
+BuildRequires: liblas
+%endif
 BuildRequires: libatomic_ops-devel
 BuildRequires: libcurl-devel
 # BuildRequires: libmicrohttpd-devel
@@ -473,6 +491,28 @@ extensions for %{name}-SQL-server5.
 %{_libdir}/monetdb5/lib_geom.so
 %endif
 
+%if %{?with_lidar:1}%{!?with_lidar:0}
+%package lidar
+Summary: MonetDB5 SQL support for working with LiDAR data
+Group: Applications/Databases
+Requires: MonetDB5-server%{?_isa} = %{version}-%{release}
+
+%description lidar
+MonetDB is a database management system that is developed from a
+main-memory perspective with use of a fully decomposed storage model,
+automatic index management, extensibility of data types and search
+accelerators.  It also has an SQL frontend.
+
+This package contains support for reading and writing LiDAR data.
+
+%files lidar
+%defattr(-,root,root)
+%{_libdir}/monetdb5/autoload/*_lidar.mal
+%{_libdir}/monetdb5/createdb/*_lidar.sql
+%{_libdir}/monetdb5/lidar.mal
+%{_libdir}/monetdb5/lib_lidar.so
+%endif
+
 %package gsl-MonetDB5
 Summary: MonetDB5 SQL interface to the gsl library
 Group: Applications/Databases
@@ -628,6 +668,9 @@ fi
 %exclude %{_libdir}/monetdb5/geom.mal
 %endif
 %exclude %{_libdir}/monetdb5/gsl.mal
+%if %{?with_lidar:1}%{!?with_lidar:0}
+%exclude %{_libdir}/monetdb5/lidar.mal
+%endif
 %if %{?with_rintegration:1}%{!?with_rintegration:0}
 %exclude %{_libdir}/monetdb5/rapi.mal
 %endif
@@ -641,6 +684,9 @@ fi
 %exclude %{_libdir}/monetdb5/autoload/*_geom.mal
 %endif
 %exclude %{_libdir}/monetdb5/autoload/*_gsl.mal
+%if %{?with_lidar:1}%{!?with_lidar:0}
+%exclude %{_libdir}/monetdb5/autoload/*_lidar.mal
+%endif
 %if %{?with_rintegration:1}%{!?with_rintegration:0}
 %exclude %{_libdir}/monetdb5/autoload/*_rapi.mal
 %endif
@@ -650,6 +696,9 @@ fi
 %exclude %{_libdir}/monetdb5/lib_geom.so
 %endif
 %exclude %{_libdir}/monetdb5/lib_gsl.so
+%if %{?with_lidar:1}%{!?with_lidar:0}
+%exclude %{_libdir}/monetdb5/lib_lidar.so
+%endif
 %if %{?with_rintegration:1}%{!?with_rintegration:0}
 %exclude %{_libdir}/monetdb5/lib_rapi.so
 %endif
@@ -763,6 +812,9 @@ systemd-tmpfiles --create %{_sysconfdir}
 %exclude %{_libdir}/monetdb5/createdb/*_geom.sql
 %endif
 %exclude %{_libdir}/monetdb5/createdb/*_gsl.sql
+%if %{?with_lidar:1}%{!?with_lidar:0}
+%exclude %{_libdir}/monetdb5/createdb/*_lidar.sql
+%endif
 %if %{?with_samtools:1}%{!?with_samtools:0}
 %exclude %{_libdir}/monetdb5/createdb/*_bam.sql
 %endif
@@ -913,6 +965,7 @@ developer, but if you do want to test, t
        --enable-gsl=yes \
        --enable-instrument=no \
        --enable-jdbc=no \
+       --enable-lidar=%{?with_lidar:yes}%{!?with_lidar:no} \
        --enable-merocontrol=no \
        --enable-microhttpd=no \
        --enable-monetdb5=yes \
@@ -928,6 +981,7 @@ developer, but if you do want to test, t
        --with-bz2=yes \
        --with-geos=%{?with_geos:yes}%{!?with_geos:no} \
        --with-java=no \
+       --with-liblas=%{?with_lidar:yes}%{!?with_lidar:no} \
        --with-perl=yes \
        --with-perl-libdir=lib/perl5 \
        --with-pthread=yes \
diff --git a/configure.ag b/configure.ag
--- a/configure.ag
+++ b/configure.ag
@@ -2707,6 +2707,13 @@ no)
        why_have_liblas="(lidar module is disabled)"
        ;;
 esac
+case "$enable_lidar" in
+no)    LIBLAS_RPM=without;;
+*)     LIBLAS_RPM=with;;
+esac
+# this is only used in rpm.mk.in to maybe avoid building MonetDB-lidar
+AC_SUBST(LIBLAS_RPM)
+
 AC_SUBST(LIBLAS_INCS)
 AC_SUBST(LIBLAS_LIBS)
 AC_MSG_CHECKING(['enable lidar: $enable_lidar'])
diff --git a/debian/control b/debian/control
--- a/debian/control
+++ b/debian/control
@@ -11,7 +11,8 @@ Build-Depends: debhelper (>= 5), autotoo
  libbam-dev, libbz2-dev, libcurl4-gnutls-dev, libgeos-dev (>= 3.0.0),
  libgsl0-dev, libpcre3-dev, libreadline-gplv2-dev | libreadline-dev,
  libssl-dev, libxml2-dev, perl, pkg-config, python, python3, ruby,
- rubygems | libyaml-0-2, unixodbc-dev, uuid-dev, zlib1g-dev
+ rubygems | libyaml-0-2, unixodbc-dev, uuid-dev, zlib1g-dev,
+ liblas-c-dev
 Standards-Version: 3.8.0
 X-Python-Version: >= 2.6
 X-Python3-Version: >= 3.0
@@ -193,6 +194,18 @@ Description: MonetDB5 SQL GIS support mo
  This package contains the GIS (Geographic Information System)
  extensions for MonetDB-SQL-server5.
 
+Package: libmonetdb5-server-lidar
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, monetdb5-sql
+Description: MonetDB5 SQL GIS support module
+ MonetDB is a database management system that is developed from a
+ main-memory perspective with use of a fully decomposed storage model,
+ automatic index management, extensibility of data types and search
+ accelerators.  It also has an SQL frontend.
+ .
+ This package contains support for reading and writing LiDAR data.
+
 Package: libmonetdb5-server-gsl
 Section: libs
 Architecture: any
diff --git a/debian/libmonetdb5-server-lidar.install 
b/debian/libmonetdb5-server-lidar.install
new file mode 100644
--- /dev/null
+++ b/debian/libmonetdb5-server-lidar.install
@@ -0,0 +1,4 @@
+debian/tmp/usr/lib/monetdb5/autoload/*_lidar.mal usr/lib/monetdb5/autoload
+debian/tmp/usr/lib/monetdb5/createdb/*_lidar.sql usr/lib/monetdb5/createdb
+debian/tmp/usr/lib/monetdb5/lidar.mal usr/lib/monetdb5
+debian/tmp/usr/lib/monetdb5/lib_lidar.so usr/lib/monetdb5
diff --git a/debian/monetdb5-server.install b/debian/monetdb5-server.install
--- a/debian/monetdb5-server.install
+++ b/debian/monetdb5-server.install
@@ -1,24 +1,25 @@
 debian/tmp/usr/bin/mserver5 usr/bin
 debian/tmp/usr/lib/libmonetdb5.so.* usr/lib
 
-# usr/lib/monetdb5/lib_*.so EXCEPT: lib_{bam,geom,gsl,sql}.so
+# usr/lib/monetdb5/lib_*.so EXCEPT: lib_{bam,geom,gsl,lidar,sql}.so
 debian/tmp/usr/lib/monetdb5/lib_generator.so usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/lib_lsst.so usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/lib_opt_sql_append.so usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/lib_udf.so usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/lib_vault.so usr/lib/monetdb5
 
-# usr/lib/monetdb5/*.mal EXCEPT: bam.mal, geom.mal, gsl.mal, sql*.mal *_hge.mal
-debian/tmp/usr/lib/monetdb5/[!bgsu]*.mal usr/lib/monetdb5
+# usr/lib/monetdb5/*.mal EXCEPT: {bam,geom,gsl,lidar,sql*,*_hge}.mal
+debian/tmp/usr/lib/monetdb5/[!bglsu]*.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/ba[!m]*.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/b[!a]*.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/generator.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/g[!es]*.mal usr/lib/monetdb5
+debian/tmp/usr/lib/monetdb5/l[!i]*.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/s[!q]*.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/udf.mal usr/lib/monetdb5
 debian/tmp/usr/lib/monetdb5/u[!d]*.mal usr/lib/monetdb5
 
-# usr/lib/monetdb5/autoload/*.mal EXCEPT: *_bam.mal, *_geom.mal, *_gsl.mal, 
*_hge.mal *_sql.mal
+# usr/lib/monetdb5/autoload/*.mal EXCEPT: *_{bam,geom,gsl,hge,lidar,sql}.mal
 debian/tmp/usr/lib/monetdb5/autoload/??_batcalc.mal usr/lib/monetdb5/autoload
 debian/tmp/usr/lib/monetdb5/autoload/??_calc.mal usr/lib/monetdb5/autoload
 debian/tmp/usr/lib/monetdb5/autoload/??_generator.mal usr/lib/monetdb5/autoload
diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c
--- a/gdk/gdk_bbp.c
+++ b/gdk/gdk_bbp.c
@@ -1192,7 +1192,8 @@ BBPheader(FILE *fp, oid *BBPoid, int *OI
        }
        if (bbpversion != GDKLIBRARY &&
            bbpversion != GDKLIBRARY_SORTEDPOS &&
-           bbpversion != GDKLIBRARY_64_BIT_INT) {
+           bbpversion != GDKLIBRARY_64_BIT_INT &&
+           bbpversion != GDKLIBRARY_OLDWKB) {
                GDKfatal("BBPinit: incompatible BBP version: expected 0%o, got 
0%o.", GDKLIBRARY, bbpversion);
        }
        if (fgets(buf, sizeof(buf), fp) == NULL) {
diff --git a/geom/monetdb5/geom.c b/geom/monetdb5/geom.c
--- a/geom/monetdb5/geom.c
+++ b/geom/monetdb5/geom.c
@@ -4922,6 +4922,7 @@ int wkbTOSTR(char **geomWKT, int* len, w
                //set the number of dimensions in the writer so that it can
                //read correctly the geometry coordinates
                GEOSWKTWriter_setOutputDimension(WKT_wr, 
GEOSGeom_getCoordinateDimension(geosGeometry));
+               GEOSWKTWriter_setTrim(WKT_wr, 1);
                wkt = GEOSWKTWriter_write(WKT_wr, geosGeometry);
                l = strlen(wkt);
                assert(l < GDK_int_max);
diff --git a/geom/sql/conformance/Tests/T13.stable.out 
b/geom/sql/conformance/Tests/T13.stable.out
--- a/geom/sql/conformance/Tests/T13.stable.out
+++ b/geom/sql/conformance/Tests/T13.stable.out
@@ -29,8 +29,8 @@ Ready.
 % sys.L # table_name
 % st_boundary_boundary # name
 % clob # type
-% 218 # length
-[ "\"LINESTRING (67.0000000000000000 13.0000000000000000, 67.0000000000000000 
18.0000000000000000, 59.0000000000000000 18.0000000000000000, 
59.0000000000000000 13.0000000000000000, 67.0000000000000000 
13.0000000000000000)\""       ]
+% 48 # length
+[ "\"LINESTRING (67 13, 67 18, 59 18, 59 13, 67 13)\"" ]
 
 # 14:23:22 >  
 # 14:23:22 >  "Done."
diff --git a/geom/sql/conformance/Tests/T14.stable.out 
b/geom/sql/conformance/Tests/T14.stable.out
--- a/geom/sql/conformance/Tests/T14.stable.out
+++ b/geom/sql/conformance/Tests/T14.stable.out
@@ -29,8 +29,8 @@ Ready.
 % sys.L # table_name
 % st_envelope_boundary # name
 % clob # type
-% 217 # length
-[ "\"POLYGON ((59.0000000000000000 13.0000000000000000, 67.0000000000000000 
13.0000000000000000, 67.0000000000000000 18.0000000000000000, 
59.0000000000000000 18.0000000000000000, 59.0000000000000000 
13.0000000000000000))\""        ]
+% 47 # length
+[ "\"POLYGON ((59 13, 67 13, 67 18, 59 18, 59 13))\""  ]
 
 # 14:23:22 >  
 # 14:23:22 >  "Done."
diff --git a/geom/sql/conformance/Tests/T17.stable.out 
b/geom/sql/conformance/Tests/T17.stable.out
--- a/geom/sql/conformance/Tests/T17.stable.out
+++ b/geom/sql/conformance/Tests/T17.stable.out
@@ -29,8 +29,8 @@ Ready.
 % sys.L # table_name
 % st_startpoint_centerline # name
 % clob # type
-% 48 # length
-[ "\"POINT (0.0000000000000000 18.0000000000000000)\"" ]
+% 14 # length
+[ "\"POINT (0 18)\""   ]
 
 # 14:23:23 >  
 # 14:23:23 >  "Done."
diff --git a/geom/sql/conformance/Tests/T18.stable.out 
b/geom/sql/conformance/Tests/T18.stable.out
--- a/geom/sql/conformance/Tests/T18.stable.out
+++ b/geom/sql/conformance/Tests/T18.stable.out
@@ -29,8 +29,8 @@ Ready.
 % sys.L # table_name
 % st_endpoint_centerline # name
 % clob # type
-% 49 # length
-[ "\"POINT (44.0000000000000000 31.0000000000000000)\""        ]
+% 15 # length
+[ "\"POINT (44 31)\""  ]
 
 # 14:23:23 >  
 # 14:23:23 >  "Done."
diff --git a/geom/sql/conformance/Tests/T23.stable.out 
b/geom/sql/conformance/Tests/T23.stable.out
--- a/geom/sql/conformance/Tests/T23.stable.out
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to