Changeset 28 for trunk


Ignore:
Timestamp:
Sep 24, 2010, 3:27:52 PM (14 years ago)
Author:
david
Message:

-modification des options de compilation pour le support perl et php

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/zoo-kernel/configure.ac

    r15 r28  
    182182
    183183AC_ARG_WITH([php],
    184         [AS_HELP_STRING([--with-php=PATH], [specify an alternative directory for php installation or --with-php=no  to disable php support])],
    185         [PHP_PATH="$withval"], [PHP_PATH=""])
    186 if test "$PHP_PATH" != "no";
    187 then
     184        [AS_HELP_STRING([--with-php=PATH], [To enabled php support or specify an alternative directory for php installation,  disabled by default])],
     185        [PHP_PATH="$withval"; PHP_ENABLED="-DUSE_PHP"], [PHP_ENABLED=""])
     186
     187
     188if test -z "$PHP_ENABLED"
     189then
     190        PHP_FILE=""
     191else
    188192        PHPCONFIG="$PHP_PATH/bin/php-config"
    189         PHP_ENABLED="-DUSE_PHP"
    190193        PHP_FILE="service_internal_php.o"
    191         if test "x$PHPCONFIG" = "x";
    192         then
    193         # PHP was not specified, so search within the current path
    194         AC_PATH_PROG([PHPCONFIG], [php-config])
    195 
    196         # If we couldn't find php-config, display a warning
    197         if test "x$PHPCONFIG" = "x";
    198         then
    199                 AC_MSG_ERROR([could not find php-config from libphp within the current path. You may need to try re-running configure with a --with-php parameter.])
    200         fi
    201         else
    202                 # PHP was specified; display a message to the user
    203                 if test "x$PHP" = "xyes";
    204                 then
    205                         AC_MSG_ERROR([you must specify a parameter to --with-php, e.g. --with-php=/path/to/php])
    206                 else
    207                         if test -f $PHPCONFIG;
    208                         then
    209                                 AC_MSG_RESULT([Using user-specified php-config file: $PHPCONFIG])
    210                         else
    211                                 AC_MSG_ERROR([the user-specified php-config file $PHPCONFIG does not exist])
    212                         fi     
    213                 fi
    214         fi
     194        if test  "$PHP_PATH" = "yes"
     195        then
     196                # PHP was not specified, so search within the current path
     197                AC_PATH_PROG([PHPCONFIG], [php-config])
     198        else
     199                PHPCONFIG="$PHP_PATH/bin/php-config"
     200        fi
     201
    215202        # Extract the linker and include flags
    216203        PHP_LDFLAGS="-L/`$PHPCONFIG --prefix`/lib -lphp5"
     
    230217        AC_SUBST([PHP_CPPFLAGS])
    231218        AC_SUBST([PHP_LDFLAGS])
    232 else
    233         PHP_ENABLED=""
    234         PHP_FILE=""
    235219fi
    236220
     
    244228
    245229
    246 
    247 
    248230AC_ARG_WITH([perl],
    249         [AS_HELP_STRING([--with-perl=PATH], [specify an alternative directory for perl installation or --with-perl=no  to disable perl support])],
    250         [PERL_PATH="$withval"], [PERL_PATH=""])
    251 if test "$PERL_PATH" != "no";
    252 then
    253         if test "x$PERL_PATH" = "xyes";
    254         then
     231        [AS_HELP_STRING([--with-perl=PATH], [To enabled perl support or specify an alternative directory for perl installation,  disabled by default])],
     232        [PERL_PATH="$withval"; PERL_ENABLED="-DUSE_PERL"], [PERL_ENABLED=""])
     233
     234
     235if test -z "$PERL_ENABLED"
     236then
     237        PERL_FILE=""
     238else
     239        PERLCONFIG="$PERL_PATH/bin/perl"
     240        PHP_FILE="service_internal_perl.o"
     241        if test  "$PERL_PATH" = "yes"
     242        then
     243                # PHP was not specified, so search within the current path
    255244                AC_PATH_PROG([PERLCONFIG], [perl])
    256245        else
     
    258247        fi
    259248
    260         if test -f $PERLCONFIG;
    261         then
    262                 AC_MSG_RESULT([Using user-specified perl file: $PERLCONFIG])
    263         else
    264                 AC_MSG_ERROR([the user-specified perl file $PERLCONFIG does not exist])
    265         fi
    266 
    267         PERL_ENABLED="-DUSE_PERL"
    268         PERL_FILE="service_internal_perl.o"
    269        
    270249        # Extract the linker and include flags
    271250        PERL_LDFLAGS=`$PERLCONFIG -MExtUtils::Embed -e ldopts`
     
    280259        AC_SUBST([PERL_CPPFLAGS])
    281260        AC_SUBST([PERL_LDFLAGS])
    282 else
    283         PERL_ENABLED=""
    284         PERL_FILE=""
    285261fi
    286262
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