Question Regarding Perl Mapscript
Lowell.Filak
lfilak at MEDINACO.ORG
Wed Sep 13 05:52:27 PDT 2006
Gabriel A Weaver writes:
> Hi all,
>
> I am trying to install mapscript for perl and run into the following
> error:
>
> [terminal: ]$ perl -e 'use lib "/web/cgi-bin/Progs/lib/5.6.0/i386-linux";
> use mapscript; my $map = new mapObj("DBs/MapData/world.map"); if ($map ==
> null) { print "UTOH!";} else { print "IT WORKS!";}'
>
> Unfortunately, I keep getting "UTOH", indicating I have a null pointer
> instead of a mapObj object.
>
> So far I have: a) verified that the world.map file is in the proper
> location
> b) checked permissions
> c) rebuilt mapscript.pm after re-swigging.
>
> Note, I am building with an older version of MapServer, a version from
> 1999, because I heard that MapServer 4 maps may not be fully compatible
> with mapserver 3 data. Any help you could provide would be much
> appreciated.
Gabe,
Here is a sample for 3.6.1:
perl -we 'use lib "/web/cgi-bin/Progs/lib/5.6.0/i386-linux"; use mapscript;
my $map = new mapObj("DBs/MapData/world.map") or die("UTOH!"); print "IT
WORKS!";
HTH
Lowell
More information about the MapServer-users
mailing list