Re: [cciug] Error Creating view from within Script

From: Marilyn Sander (Marilyn.Sander@Sun.COM)
Date: Mon Jul 23 2001 - 17:47:24 EDT


Well, usually in the system command you use quotes, not backticks.
The system command does not return stdout, it gives back an
exit status.

If you actually want stdout returned, use

$exitStatus = `$ct mkview -tag $release_view $view_storage/$release_view.vws`;

But if you want the exit status from the command, use

$exitStatus = system ("$ct mkview -tag $release_view $view_storage/$release_view.vws");

If you need both stdout and the exit status, use the backticks, and the
special variable $? or $CHILD_ERROR. Be sure to look those up in the Perl
book, as it won't be the simple exit status you're used to getting from
a shell.

--Marilyn Sander

> From: "Abner, Daniel" <DAbner@sjm.com>
> To: "ClearCase User Group (E-mail)" <cciug@rational.com>
> Subject: [cciug] Error Creating view from within Script
> MIME-Version: 1.0
> X-Majordomo-Taboo: cciug
>
>
> OS: SunOS 5.5.1
> CC: 3.2.1
> Patches: 4,9,12,20,21
> Perl: 5.005_3
>
> I'm using the following code in a perl script to create a view:
>
> $exitStatus = system (`$ct mkview -tag $release_view
> $view_storage/$release_view.vws`);
>
> and I receive the following error:
>
> "ld.so.1: cleartool: fatal: relocation error: file
> /user/atria/shlib/libatriaks.so: symbol tmps_floor: referenced symbol not
> found"
>
> I've captured the output of the command in backticks and executed it on a
> command line with success.
>
> Any ideas on what I may be experiencing or any suggestions for resolutions?
>
> Thanks,
> Dan.
>
>
> ____________________________
> Daniel Abner
> St. Jude Medical CRMD
> Sylmar, CA
>
>
>
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
>

 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



This archive was generated by hypermail 2b29 : Tue Jul 31 2001 - 22:03:59 EDT