[Mapserver-users] mapscript seems to be fubar

Joe Bussell joe at otsys.com
Fri Jan 24 10:43:26 PST 2003


Greetings,
    I ran into this as well, but in truth it turns out to be good news 
(in a twisted sort of way).  They are using a more up-to-date version of 
swig which is apparently enforcing the perl namespace.  In my perl 
mapscript files I must refer to mapscript::<any object under mapscript>.
    The problem is that the scripts which are included in the package do 
not actually make use of this.  For a quick test of this add mapscript:: 
to any object that is called via new from the mapscript package in the 
dump.pl file.
    You will have to modify your code to make use of the mapscript 
namespace.
    The beauty is that you will not have to hand hack mapscript_wrap.c

Cordially,

Joe Bussell
On Time Systems
www.trafficdodger.com


pkishor_98  wrote:
> Steve L, Lowell, others,
> 
> I seem to have fubar-ed my perfectly working copy of mapscript, and
> can't figure out how to set it right.
> 
> I rebuilt mapserver 3.6.4. Straight, no frills --
> 
> 
> 
> ./configure --with-jpeg --with-gd=../gd-1.8.4 --with-png=/usr/local/lib
> 
> 
> 
> 
> 
> 
> Got the usualy slew of messages and warnings and what-not, and then
> mapserv is built just fine --
> 
> 
> 
> [lucknow:~/Projects/mapserver/mapserver-3.6.4] pkishor% ./mapserv -v
> MapServer version 3.6.4 OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
> SUPPORTS=TTF INPUT=TIFF INPUT=EPPL7 INPUT=JPEG INPUT=SHAPEFILE
> 
> 
> 
> 
> Then I do the perl Makefile.PL, make, sudo make install dance, and
> mapscript.pm  gets built and installed in its correct place. But
> nothing works with perl. Trying out the simplest dump.pl, I get
> 
> 
> 
> [lucknow:mapscript/perl/examples] pkishor% ./dump.pl -file=~/dap.shp
> Can't locate object method "new" via package "shapefileObj" at
> ./dump.pl line 18.
> 
> 
> 
> and so on. When I turn diagnostics on, I get --
> 
> 
> 
> [lucknow:mapscript/perl/examples] pkishor% ./dump.pl
> -file=~/Sites/palatine/data/dap.shp
> Can't locate object method "new" via package "shapefileObj" at
> ./dump.pl line
>         19 (#1)
>     
>     (F) You said to do (or require, or use) a file that couldn't be
>     found. Perl looks for the file in all the locations mentioned in @INC,
>     unless the file name included the full path to the file.  Perhaps
> you need
>     to set the PERL5LIB or PERL5OPT environment variable to say where
> the extra
>     library is, or maybe the script needs to add the library name to
> @INC.  Or
>     maybe you just misspelled the name of the file.  See perlfunc/require
>     and lib.
>     
> Uncaught exception from user code:
>         Can't locate object method "new" via package "shapefileObj" at
> ./dump.pl line 19.
> 
> 
> 
> 
> I know that mapscript.pm is in my @INC which is -- 
> 
> /System/Library/Perl/darwin
> /System/Library/Perl
> /Library/Perl/darwin
> /Library/Perl
> /Library/Perl
> /Network/Library/Perl/darwin
> /Network/Library/Perl
> /Network/Library/Perl
> 
> 
> 
> because make install put it there --
> 
> [lucknow:mapserver-3.6.4/mapscript/perl] pkishor% sudo make install
> Password:
> Installing /Library/Perl/darwin/auto/mapscript/mapscript.bs
> Installing /Library/Perl/darwin/auto/mapscript/mapscript.bundle
> Files found in blib/arch: installing files in blib/lib into
> architecture dependent library tree
> Installing /Library/Perl/darwin/mapscript.pm
> Writing /Library/Perl/darwin/auto/mapscript/.packlist
> Appending installation info to /System/Library/Perl/darwin/perllocal.pod
> 
> I am at a dead end. Any suggestions as to where I should begin looking 
> 
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> 





More information about the MapServer-users mailing list