GIS Offline

We can run a GIS fully offline using the integrated MapServer configuration 'module'.

Here are the notes for getting this working on the Portable Apps version:

Create an updated release

cvs -z3 -d:pserver:anonymous@sahana.cvs.sourceforge.net:/cvsroot/sahana co -P sahana-ext
cd sahana-ext/release
mkdir portable-package
cp -r portable-skel/* portable-package/
mv sahana-phase2 portable-package/PortableApps/SahanaPortable/udrive/www
cd portable-package
zip -r ../release-portable-app.zip *
rm -rf portable-package

Add PHP Curl, GetText & ZIP support

Download http://museum.php.net/php5/php-5.2.3-Win32.zip

From here, extract php_curl.dll, php_gettext.dll & php_zip.dll to \PortableApps\SahanaPortable\udrive\usr\local\php\extensions

Add these to \PortableApps\SahanaPortable\udrive\usr\local\php\php.ini

Add PHP MapScript

Download http://maptools.org/dl/ms4w/ms4w_2.2.9.zip

From here, extract php_mapscript.dll to \PortableApps\SahanaPortable\udrive\usr\local\php\extensions

Add this to \PortableApps\SahanaPortable\udrive\usr\local\php\php.ini

Also extract these DLLs to \PortableApps\SahanaPortable\udrive\usr\local\php:

cfitsio.dll
fribidi.dll
gdal15.dll
geos_c.dll
geotiff.dll
hdf5dll.dll
iconv.dll
jbig1.dll
libcurl.dll
libeay32.dll
libecwj2.dll
libexpat.dll
libfcgi.dll
libmap.dll
libpq.dll
libtiff.dll
libxml2.dll
lti_dsdk_dll.dll
netcdf.dll
pdflib.dll
proj.dll
sqlite3.dll
ssleay32.dll
szlibdll.dll
xerces-c_2_7.dll
zlib1.dll

Also extract mapserv.exe to \PortableApps\SahanaPortable\udrive\cgi-bin, along with the same DLLs & also libmysql.dll

Add Proj

Unzip the proj folder from ms4w_2.2.9.zip to \PortableApps\SahanaPortable\udrive

Add these lines to \PortableApps\SahanaPortable\Sahana_Start.bat

set PATH=\proj\bin;%PATH%
set PROJ_LIB=\proj\nad

Add this line to \PortableApps\SahanaPortable\udrive\usr\local\apache2\conf\httpd.conf

(just before section2)

SetEnv PROJ_LIB "w:/proj/nad"

This is the error that comes otherwise:

msProcessProjection(): Projection library error. Permission denied 

Add support for Google Projection

Edit \PortableApps\SahanaPortable\udrive\proj\nad\epsg

Add these lines to the top:

# Google
<900913> +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs

Create folder:

\PortableApps\SahanaPortable\udrive\www\sahana\www\res\OpenLayers\files

Add PostGIS

Download http://downloads.thehumanjourney.net/USBGIS_12.zip

extract the pgsql folder to \PortableApps

tbc


Navigation
QR Code
QR Code dev:gis_offline (generated for current page)