package Cpanel::Easy::PHP5::Mhash;

# cpanel - Cpanel/Easy/PHP5/Mhash.pm              Copyright(c) 2011 cPanel, Inc.
#                                                           All rights Reserved.
# copyright@cpanel.net                                         http://cpanel.net
# This code is subject to the cPanel license. Unauthorized copying is prohibited

our $easyconfig = {
    'name'   => 'Mhash',
    'url'    => 'http://www.php.net/manual/en/ref.mhash.php',
    'dryrun' => {
        '0' => {
            'name'    => 'Find mhash path for PHP 5',
            'command' => sub {
                my ($self) = @_;
                my ( $path, @text ) = $self->get_path_installed('Cpanel::Easy::OptLib::mhash');

                if ($path) {
                    $self->{'__'}{'MhashPath'} = $path;
                    return ( 1, 'Ok' );
                }
                else {
                    return $path, @text;
                }
            },
        },
    },
    'step' => {
        '0' => {
            'name'    => 'to config options',
            'command' => sub {
                my ($self) = @_;
                $self->add_to_configure( { '--with-mhash' => $self->{'__'}{'MhashPath'} } );
                return ( 1, 'Ok' );
            },
        },
    },
};

1;
