[mapserver-dev] Oracle Plugin - Does it work (linux)?
Michael Smith
michael.smith.erdc at gmail.com
Sat Apr 9 07:04:53 PDT 2022
from CMake
[ 98%] Linking CXX shared library libmapserver.so
[ 98%] Built target mapserver
[100%] Building C object CMakeFiles/msplugin_oracle.dir/maporaclespatial.c.o
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:
In function 'msOracleSpatialLayerWhichShapes':
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:2141:18:
warning: assignment discards 'const' qualifier from pointer target type
[-Wdiscarded-qualifiers]
2141 | bind_value = msLookupHashTable(&layer->bindvals, bind_key);
| ^
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:
In function 'msOracleSpatialLayerGetAutoProjection':
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:2766:31:
warning: variable 'dthand' set but not used [-Wunused-but-set-variable]
2766 | msOracleSpatialDataHandler *dthand = NULL;
| ^~~~~~
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:
In function 'msOracleSpatialLayerGetItems':
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:2983:31:
warning: variable 'dthand' set but not used [-Wunused-but-set-variable]
2983 | msOracleSpatialDataHandler *dthand = NULL;
| ^~~~~~
At top level:
/home/ec2-user/miniconda3/conda-bld/mapserverplugins_1649503981733/work/maporaclespatial.c:1078:13:
warning: 'osConvexHullGetExtent' defined but not used [-Wunused-function]
1078 | static void osConvexHullGetExtent(layerObj *layer, char *query_str,
size_t size, char *geom_column_name, char *table_name)
| ^~~~~~~~~~~~~~~~~~~~~
[100%] Linking C shared module libmsplugin_oracle.so
In case this helps
On Sat, Apr 9, 2022 at 9:42 AM Michael Smith <michael.smith.erdc at gmail.com>
wrote:
> In changing over our build configs to conda, I want to start using the
> very nice mapserver packages at conda-forge. However to do that, I need to
> build the mapserver oracle plugin.
>
>
>
> I’m using cmake with -DWITH_ORACLE_PLUGIN=1 and then
>
> make msplugin_oracle
>
>
>
> I’ve been able to do this successfully in gdal and building an oracle
> plugin for gdal but, while the mapserver oracle plugin builds, and using
> ldd I can see that the plugin is properly linked, I cannot get the plugin
> to work in a mapfile.
>
>
>
> If I set an incorrect path to the plugin, I see an error
>
> [Sat Apr 9 13:33:11 2022].731407 msGetSymbol(): General error message.
> Dynamic loading failed: /opt2/conda/lib/libmsplugin_oracle.so: cannot open
> shared object file: No such file or directory
>
> [Sat Apr 9 13:33:11 2022].731455 loadCustomLayerDLL: General error
> message. Failed to load dynamic Layer LIB:
> /opt2/conda/lib/libmsplugin_oracle.so
>
>
>
> When the plugin is set I get
>
> [Sat Apr 9 13:35:15 2022].17089 msDrawMap(): rendering using outputformat
> named png (AGG/PNG).
>
> [Sat Apr 9 13:35:15 2022].17135 msDrawMap(): WMS/WFS set-up and query,
> 0.000s
>
> [Sat Apr 9 13:35:15 2022].55543 msOracleSpatialLayerOpen(): OracleSpatial
> error. OracleSpatial is not supported
>
> [Sat Apr 9 13:35:15 2022].56576 msDrawMap(): Layer 1 (basins), 0.039s
>
> [Sat Apr 9 13:35:15 2022].56614 msDrawMap(): Drawing Label Cache, 0.000s
>
> [Sat Apr 9 13:35:15 2022].56623 msDrawMap() total time: 0.041s
>
> [Sat Apr 9 13:35:15 2022].70250 msSaveImage(stdout) total time: 0.014s
>
> [Sat Apr 9 13:35:15 2022].70413 mapserv request processing time
> (msLoadMap not incl.): 0.054s
>
> [Sat Apr 9 13:35:15 2022].70426 msFreeMap(): freeing map at
> 0x5604a1a50be0.
>
>
>
>
>
> Layer is defined as:
>
> LAYER
>
> NAME basins
>
> DEBUG 5
>
> CONNECTIONTYPE plugin
>
> PLUGIN "/opt/conda lib/libmsplugin_oracle.so"
>
> INCLUDE "include/connection.inc"
>
> DATA "shape from WORLD_BASINS using srid 4326"
>
> PROCESSING "CLOSE_CONNECTION=DEFER"
>
> PROJECTION
>
> "init=epsg:4326"
>
> END
>
> …
>
> END
>
>
>
> Any idea anyone? I may have to do this via OGR connection but I have had
> faster performance in the past with the native oracle spatial driver. So I
> would prefer to use that, just as a plugin.
>
>
>
> If I get this working, I’ll certainly be adding some doc tickets about
> this.
>
>
>
> Mike
>
>
>
>
>
> --
>
> Michael Smith
>
> US Army Corps / Remote Sensing GIS Center
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20220409/497f5b2c/attachment-0001.html>
More information about the MapServer-dev
mailing list