Changes in / [1:3]


Ignore:
Location:
/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • /trunk/zoo-api/js/ZOO-proj4js.js

    r1 r3  
    1 /**
    2  * Author : René-Luc D'Hont
    3  *
    4  * Copyright 2010 3liz SARL. All rights reserved.
    5  *
    6  * Permission is hereby granted, free of charge, to any person obtaining a copy
    7  * of this software and associated documentation files (the "Software"), to deal
    8  * in the Software without restriction, including without limitation the rights
    9  * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
    10  * copies of the Software, and to permit persons to whom the Software is
    11  * furnished to do so, subject to the following conditions:
    12  *
    13  * The above copyright notice and this permission notice shall be included in
    14  * all copies or substantial portions of the Software.
    15  *
    16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    17  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    18  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
    19  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    20  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    21  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
    22  * THE SOFTWARE.
    23  */
     1/*
     2  proj4js.js -- Javascript reprojection library.
     3 
     4  Authors:      Mike Adair madairATdmsolutions.ca
     5                Richard Greenwood richATgreenwoodmap.com
     6                Didier Richard didier.richardATign.fr
     7                Stephen Irons
     8  License:      LGPL as per: http://www.gnu.org/copyleft/lesser.html
     9                Note: This program is an almost direct port of the C library
     10                Proj4.
     11*/
    2412Proj4js={defaultDatum:'WGS84',transform:function(source,dest,point){if(!source.readyToUse||!dest.readyToUse){this.reportError("Proj4js initialization for "+source.srsCode+" not yet complete");return point;}
    2513if((source.srsProjNumber=="900913"&&dest.datumCode!="WGS84")||(dest.srsProjNumber=="900913"&&source.datumCode!="WGS84")){var wgs84=Proj4js.WGS84;this.transform(source,wgs84,point);source=wgs84;}
  • /trunk/zoo-kernel/configure.ac

    r1 r3  
    169169# Shouldn't we get python here rather than python2.6 :) ??
    170170PY_LIB=`$PYTHONCONFIG --libs | sed -e 's/^.*\(python2\..\)$/\1/'`
    171 echo $PY_LIB
    172171AC_CHECK_LIB([$PY_LIB], [PyObject_CallObject], [], [AC_MSG_ERROR([could not find libpython])], [])
    173172
     
    321320
    322321AC_ARG_WITH([js],
    323         [AS_HELP_STRING([--with-js=PATH], [specify an alternative directory for spidermonkey installation or --with-js=no to disabled js support])],
     322        [AS_HELP_STRING([--with-js=PATH], [specify --with-js to enabled js support or --with-js=path-to-js js support is disabled by default ])],
    324323        [JSHOME="$withval"], [JSHOME=""])
    325 if test "$JSHOME" != "no";
     324
     325JS_ENABLED=""
     326JS_FILE=""
     327
     328
     329if test "$JSHOME" = "yes"
    326330then
    327         JS_ENABLED="-DUSE_JS"
     331        JS_ENABLED="-DUSE_JS"
    328332        JS_FILE="service_internal_js.o"
    329333
    330         #if test "x$JSHOME" = "x"; then
    331         #       # JS was not specified, so search within the current path
    332 #               # AC_PATH_PROG([JSCONFIG], [js-config])
    333 #       
    334 #               # If we couldn't find js-config, display a warning
    335 #               if test "x$JSHOME" = "x"; then
    336 #                       AC_MSG_ERROR([could not find js-config from libpython within the current path. You may need to try re-running configure with a --with-js parameter.])
    337 #               fi
    338 #       else
    339 #               # JS was specified; display a message to the user
    340 #               if test "x$JSHOME" = "xyes"; then
    341 #                       AC_MSG_ERROR([you must specify a parameter to --with-js, e.g. --with-js=/path/to/js])
    342 #               else
    343 #                       if test -f $JSHOME; then
    344 #                       AC_MSG_RESULT([Using user-specified js-config file: $JSCONFIG])
    345 #                       else
    346 #                               AC_MSG_ERROR([the user-specified js-config file $JSCONFIG does not exist])
    347 #                       fi     
    348 #               fi
    349 #       fi
    350 
    351 
    352         # Extract the linker and include flags
    353         JS_CPPFLAGS="-I$JSHOME/include"
    354         JS_LDFLAGS="-L$JSHOME/lib -ljs -lm"
    355         # Check headers file
     334        #on teste si on est sous debian like
     335        if test -f "/usr/bin/dpkg"
     336        then
     337                if test -n "`dpkg -l | grep libmozjs-dev`"
     338                then
     339                        JS_CPPFLAGS="-I/usr/include/mozjs/"
     340                        JS_LDFLAGS="-L/usr/lib -lmozjs -lm"
     341                        JS_LIB="mozjs"
     342                else
     343                        AC_MSG_ERROR([You must install libmozjs-dev or specify your custom install of libjs])
     344                fi
     345        else
     346                JS_LIB="js"
     347        fi
     348       
     349
    356350        CPPFLAGS_SAVE="$CPPFLAGS"
    357         CPPFLAGS="$JS_CPPFLAGS"
    358         #AC_CHECK_HEADERS([jsapi.h],
    359         #                [], [AC_MSG_ERROR([could not find headers include related to libjs])])
    360 
    361         # Ensure we can link against libjs
    362         LIBS_SAVE="$LIBS"
    363         LIBS="$JS_LDFLAGS"
    364        
    365         AC_CHECK_LIB([js], [JS_CallFunctionName], [], [AC_MSG_ERROR([could not find libjs])], [])
    366 
    367         AC_SUBST([JS_CPPFLAGS])
    368         AC_SUBST([JS_LDFLAGS])
    369 
    370 else
    371         JS_ENABLED=""
    372         JS_FILE=""
    373 fi
    374 
     351        CPPFLAGS="$JS_CPPFLAGS"
     352        #AC_CHECK_HEADERS([jsapi.h],
     353        #                [], [AC_MSG_ERROR([could not find headers include related to libjs])])
     354
     355        # Ensure we can link against libjs
     356        LIBS_SAVE="$LIBS"
     357        LIBS="$JS_LDFLAGS"
     358
     359        AC_CHECK_LIB([$JS_LIB], [JS_CallFunctionName], [], [AC_MSG_ERROR([could not find $JS_LIB])], [])
     360
     361        AC_SUBST([JS_CPPFLAGS])
     362        AC_SUBST([JS_LDFLAGS])
     363
     364
     365else if test  "$JSHOME" != ""
     366        then
     367                JS_ENABLED="-DUSE_JS"
     368                JS_FILE="service_internal_js.o"
     369                JS_CPPFLAGS="-I$JSHOME/include"
     370                JS_LDFLAGS="-L$JSHOME/lib -ljs -lm"
     371                JS_LIB="js"
     372
     373                CPPFLAGS_SAVE="$CPPFLAGS"
     374                CPPFLAGS="$JS_CPPFLAGS"
     375                #AC_CHECK_HEADERS([jsapi.h],
     376                #                [], [AC_MSG_ERROR([could not find headers include related to libjs])])
     377
     378                # Ensure we can link against libjs
     379                LIBS_SAVE="$LIBS"
     380                LIBS="$JS_LDFLAGS"
     381
     382                AC_CHECK_LIB([$JS_LIB], [JS_CallFunctionName], [], [AC_MSG_ERROR([could not find $JS_LIB])], [])
     383
     384                AC_SUBST([JS_CPPFLAGS])
     385                AC_SUBST([JS_LDFLAGS])
     386        fi
     387fi
    375388AC_SUBST([JS_ENABLED])
    376389AC_SUBST([JS_FILE])
  • /trunk/zoo-kernel/zoo_service_loader.c

    r1 r3  
    13921392          charxxxToMaps((char***)&outputs[0],&request_output_real_format);
    13931393        }else{
     1394#ifdef WIN32
    13941395          errstr = GetLastError();
    13951396#ifdef DEBUG
    13961397          fprintf(stderr,"Function %s failed to load because of %d\n",r_inputs->value,errstr);
     1398#endif
    13971399#endif
    13981400          r_inputs=getMap(request_inputs,"Identifier");
Note: See TracChangeset for help on using the changeset viewer.

Search

Context Navigation

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png