Menu

Question about pel in sphixTrain

Help
forsubhi
2012-02-29
2012-09-22
  • forsubhi

    forsubhi - 2012-02-29

    I added perl code to eclipse with epic and I do the configure and make then I
    had the following error SphinxTrain:util not found
    is there util folder in sphinx train and how do we make it if it isn't ?

     
  • Nickolay V. Shmyrev

    is there util folder in sphinx train

    The SphinxTrain::Util module is in the folder

    sphinxtrain/scripts_pl/lib/util
    
     
  • forsubhi

    forsubhi - 2012-02-29

    ok .. do you know how could I fix the above error

     
  • Nickolay V. Shmyrev

    do you know how could I fix the above error

    Yes, I do

     
  • forsubhi

    forsubhi - 2012-03-05

    I am not good in English but do you find my question wrong or not obvious or
    silly ?

     
  • Nickolay V. Shmyrev

    I am not good in English but do you find my question wrong or not obvious or
    silly ?

    Sorry, I didn't mean anything about your quesiton, I just answered it. If you
    were looking for another answer you need to ask another question.

     
  • forsubhi

    forsubhi - 2012-03-06

    what is the meaning of
    use sphinxTrain:: Util and why there is error next to it .

     
  • Nickolay V. Shmyrev

    what is the meaning of
    use sphinxTrain:: Util

    It says to plug in perl module SphinxTrain::Util which is located in the file
    Util.pm

    and why there is error next to it .

    This module is located in a custom folder. So it's not found by default. You
    need to configure Eclipse to look for the modules in a proper folder and it
    will find it.

    You can read
    http://perldoc.perl.org/perlmod.html
    for details on modules. As for Eclipse configuration, it must be in project
    properties, but I'm not sure which perl plugin are you using so can't tell you
    where is it exactly.

     
  • forsubhi

    forsubhi - 2012-03-07

    thank you for reply

    my plugin for eclipse is epic www.epic-ide.org

    if you know ide better than if to use with sphinx please tell me

    and this is snapshot on my project properies

    please tell my how to configure eclipse to include this module

    thanks

     
  • Nickolay V. Shmyrev

    In EPIC perl include path is configured in a project properties

    http://www.epic-ide.org/guide/ch03s02.php

     
  • forsubhi

    forsubhi - 2012-03-11

    First , thank you for you reply
    But I have additional Problem
    I add ${resource_loc:/myperl/lib/SphinxTrain} to Include Path where myperl is
    name of my database that I want to train
    so the
    use sphinxTrain:: Util work with no error
    but the same error appear next to
    use Pod::Usage;
    how can I sove this problem ?

     
  • Nickolay V. Shmyrev

    but the same error appear next to use Pod::Usage; how can I sove this
    problem ?

    Turn on your brains and you will find a solution

     
  • forsubhi

    forsubhi - 2012-03-12

    the folder
    digit/scripts_pl/lib/SphinxTrain/
    contains Config.pm and Util.pm
    I don't understand whey eclipse find the first and reduse the another , you
    say it is in custom folder
    I try to understand this but I fail ,I need a hint !

     
  • forsubhi

    forsubhi - 2012-03-12

    sorry
    I don't understand whey eclipse find the first and refuse the another , you
    say it is in custom folder

     
  • forsubhi

    forsubhi - 2012-03-12

    this error may be usefull to solve essue

     
  • Nickolay V. Shmyrev

    I don't understand whey eclipse find the first and reduse the another , you
    say it is in custom folder

    It's not another. Pod::Usage module is usually located in system folder. You
    can try to find it with the command

    locate Pod/Usage.pm
    

    You need to add Pod folder to include path too

     
  • forsubhi

    forsubhi - 2012-03-12

    it's very strange error , I add the path and the error still exist

    and this is output of the command

    subhi@subhi-pc:~$ locate Pod/Usage.pm
    /usr/share/perl/5.12.4/Pod/Usage.pm
    
     
  • Nickolay V. Shmyrev

    Not strange, you added the wrong folder. You need to add
    /usr/share/perl/5.12.4/, not /usr/share/perl/5.12.4/Pod

     
  • forsubhi

    forsubhi - 2012-03-13

    all modules error solved ,and use Pod:Usage works well , unless this

    use SphinxTrain::Util ;   // Compilation failed in require
    

    please help me .. man

    note there is no folder sphinxtrain/scripts_pl/lib/util in sphinxtrain but
    there is file sphinxtrain/scripts_pl/lib/util.pm

     
  • forsubhi

    forsubhi - 2012-03-15

    Do you need more information ,
    the error still exist and I don't know what is the problem ?
    give me refrence to fix this error cos I want to complete my studying soon cos
    I have project

     
  • forsubhi

    forsubhi - 2012-03-16

    problem solved ^__^
    in line 55 of Util.pm I add #

    die "Configuration (e.g. etc/sphinx_train.cfg) not defined\n" unless defined

    ($ST::CFG_DONE);

    then the error disappear

     

Log in to post a comment.