dpatel has asked for the wisdom of the Perl Monks concerning the following question:

hi

I am working on automation of clearcase, in which- my perl scripts should automatically set a view, start the view, set the label and version according to user's choice and retrive the source codes and copy it to remote location. but when I try to run command in my perl scripts:

system ("/usr/atria/bin/cleartool setview <view_name>");

and it doesn't come out of the program until i enter exit. and then rest of the program gets executed. I can see that this is occuring due to the cleartool command which spawns a subshell.

So i tried using cleartool::CtCmd and other clearcse perl modules. but the problem is now that I am working on linux server and i don't have permission to install new perl modules. so i install my new version of perl locally and i tried installing perl modules locally. i am able to install some modules successfully and also able to work with them. but I am not able to install clearcase-perl moduels and even if i'm successful in installing them locally, my program is not able to use the locally installed modules. i even add local modules directory path to @INC array. but it's still not working. I can see my installed modules in the same directoy. what may be wrong here?

and the modules i am not able to install i.e. ClearCase::CtCmd, what may be the issue? i even set all the environment variable values,but i think i am still misssing something. please help me. I can not proceed with my further work without solving this issue.

or show me the other way where i can set clearcase view automatically and copy the source code to remote location or some local directory.

  • Comment on problem while installing the perl modules for clearcase

Replies are listed 'Best First'.
Re: problem while installing the perl modules for clearcase
by marto (Cardinal) on Mar 11, 2010 at 09:35 UTC

    "but I am not able to install clearcase-perl moduels and even if i'm successful in installing them locally, my program is not able to use the locally installed modules."

    I don't understand what you mean by this, see I know what I mean. Why don't you?.

    "but the problem is now that I am working on linux server and i don't have permission to install new perl modules."

    See Yes, even you can use CPAN. I assume you read the ClearCase::CtCmd INSTALL file. For further reading on the subject of installing modules see Installing Modules from the tutorials section.

      all I meant to say is, some of the modules are not being installed. I am installing them using their source codes, so whenever i tried to run commmand "make" or "make install" , it gives me error. and some of them i installed correctly in my home directory locally, i am not able to use it even if i add the line in my scripts "use lib <local module path>".

        'i am not able to use it even if i add the line in my scripts "use lib <local module path>".'

        Did you read Re: problem while installing the perl modules for clearcase?

        'I am installing them using their source codes, so whenever i tried to run commmand "make" or "make install" , it gives me error.'

        Which modules? What errors occured? Part of the problem with your question and the replies is that you don't tell us enough information to advise. There is no point in telling us 'it gives me error' unless you tell us what 'it' is and what the error was. You could post the command you're using to install a module, along with the output. Read and understand How do I post a question effectively?.

Re: problem while installing the perl modules for clearcase
by cdarke (Prior) on Mar 11, 2010 at 10:36 UTC
    i even add local modules directory path to @INC array

    How are you trying to do that? Modules are (usually) read at compile-time, so adding them to @INC at run-time will have no effect. use lib instead. See lib