[gdal-dev] Compile GDAL/OGR with SOSI support

SBL Stefan.Blumentrath at nina.no
Wed Apr 10 01:26:17 PDT 2013


HiSome updates on this issue:Thomas Hirsch updated the source of the FYBA
library:https://github.com/kartverket/fyba/commit/a9cd3e740e78f319f73b74348ac71876805d7a5aFollowing
the instructions there, libfyba can be build on Ubuntu 12.04.So, now I have
the fyba library in /usr/local/libAs a next step I edited some of the GDAL
makefiles analog to the builds hints  for windows:In GDALmake.opt.in I added
in the list of libs (line 42):
$(SOSI_LIBS)
Further down I added a section for SOSI-support:
## SOSI#SOSI_INC_DIR = -I/usr/local/include/fybaSOSI_LIBS =
/usr/local/lib/libfyba.a \	/usr/local/lib/libfygm.a \
/usr/local/lib/libfyut.aHAVE_SOSI = YES
In ogr/ogrsf_frmts/GNUmakefile I added 
sosi
to the SUBDIRS anda line 
SUBDIRS-$(HAVE_SOSI)	+= sosi
Finally I added in ogr/ogrsf_frmts/generic/GNUmakefile a line
-DSOSI_ENABLED \
In the list of BASEFORMATS.Now also 'make' runs, but 'make install' throws
an error:
make -C sosimake[3]: Entering directory
`/data/home/stefan/src/gdal_1_8/gdal/ogr/ogrsf_frmts/sosi'make[3]: *** No
targets specified and no makefile found.  Stop.make[3]: Leaving directory
`/data/home/stefan/src/gdal_1_8/gdal/ogr/ogrsf_frmts/sosi'make[2]: ***
[sosi-target] Error 2make[2]: Leaving directory
`/data/home/stefan/src/gdal_1_8/gdal/ogr/ogrsf_frmts'make[1]: *** [sublibs]
Error 2make[1]: Leaving directory
`/data/home/stefan/src/gdal_1_8/gdal/ogr'make: *** [ogr-target] Error 2
So I added a makefile in the sosi subdir containing:
include ../../../GDALmake.optOBJ	=	ogrsosidriver.o ogrsosidatasource.o
ogrsosilayer.o fyba_melding.o \EXTRAFLAGS =	-I.. -I..\..
-I$(SOSI_INC_DIR)GDAL_ROOT	=	..\..\..default:	$(OBJ)clean:	rm -f $(OBJ)
Compiled without libtool (because I got a libtool error on make or make
install) I get the following error messages:
In file included from ogr_sosi.h:34:0,                 from
ogrsosidatasource.cpp:30:/usr/local/include/fyba/fyba.h:88:24: fatal error:
../GM/fygm.h: No such file or directorycompilation terminated.In file
included from ogr_sosi.h:34:0,                 from
ogrsosidriver.cpp:30:/usr/local/include/fyba/fyba.h:88:24: fatal error:
../GM/fygm.h: No such file or directorycompilation terminated.In file
included from ogr_sosi.h:34:0,                 from
ogrsosilayer.cpp:30:/usr/local/include/fyba/fyba.h:88:24: fatal error:
../GM/fygm.h: No such file or directorycompilation
terminated.fyba_melding.cpp:30:21: fatal error: windows.h: No such file or
directorycompilation terminated.make[3]: *** [ogrsosidriver.o] Error
1make[3]: *** Waiting for unfinished jobs....make[3]: *** [ogrsosilayer.o]
Error 1make[3]: *** [ogrsosidatasource.o] Error 1make[3]: ***
[fyba_melding.o] Error 1make[2]: *** [sosi-target] Error 2make[2]: ***
Waiting for unfinished jobs....
Now it seems some paths in ogr_sosi.h and fyba.h are in the disorder...Maybe
something to be fixed in the FYBA lib?CheersStefanP.S.: Sorry for the long
post...



--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Compile-GDAL-OGR-with-SOSI-support-tp5045207p5045729.html
Sent from the GDAL - Dev mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20130410/c3e754ba/attachment.html>


More information about the gdal-dev mailing list