DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦1da16ab0b⟧ TextFile

    Length: 20040 (0x4e48)
    Types: TextFile
    Notes: R1k Text-file segment

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦5a81ac88f⟧ »Space Info Vol 1« 
        └─⟦ac46c2277⟧ 
            └─⟦this⟧ 

TextFile

INSTALL_CUSTOMIZATION => (
    Do_Step
       (Step => "AUTHORIZATION_CHECK,
                 RELEASE_RESTORE,
                 INSTALL_PRODUCT,
                 REGISTER_TARGET,
                 RECORD_INSTALLATION",
        Step_File =>
           "!MACHINE.RELEASE.ARCHIVE.RCF_RS6000_AIX_IBM.RELEASE1_0_2.COMMAND_DATA.STEPS");
)

AUTHORIZATION_CHECK => (
declare
    subtype Bogus is Natural range 0 .. 1;
    package Pp is new Parameter_Parser (Bogus);
    Iter : Pp.Iterator :=
       Pp.Parse ("CMVC, CMVC.Source_Control, RCF");
    Error : Natural := 0;

    function Product_Name (Iter : Pp.Iterator) return String is
    begin
        if String_Utilities.Equal (Pp.Name (Iter), "NAME") then
            return Pp.Get_Image (Iter);
        else
            return Pp.Name (Iter);
        end if;
    end Product_Name;

begin
    while not Pp.Done (Iter) loop
        declare
            Name : constant String := Product_Name (Iter);
        begin  
            if "!Implementation".Product_Authorization.Is_Registered (Name) then
                Log.Put_Line (Name & " is authorized", Profile.Note_Msg);
            else
                Log.Put_Line ("Need to Authorize " & Name, Profile.Error_Msg);
                Error := Error + 1;
            end if;
        end;
        Pp.Next (Iter);
    end loop;
    if Error /= 0 then
        Log.Put_Line
           ("Do not proceed until all these products have been authorized",
            Profile.Error_Msg);
        Do_Step ("PROMPT=AUTHORIZE_PRODUCT");
    elsif Get_Site /= "" then
        declare
            Limit, Current, Buy_Out : Natural;
        begin
            "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Command_Data".
               Token_Information ("RCF", Limit, Buy_Out, Current);
            if Limit = 0 then
                Log.Put_Line
                   ("No tokens (sessions) for RCF have been authorized.  Do not proceed until you have authorized tokens for RCF",
                    Profile.Error_Msg);
                Do_Step ("PROMPT=AUTHORIZE_TOKEN");
            elsif (Buy_Out /= Current) and Current = Limit then
                Log.Put_Line
                   ("Tokens (Sessions) have been authorized for RCF, but all are in use",
                    Profile.Error_Msg);
                Log.Put_Line
                   ("Have users which are using the RCF tokens log off (and then back on) before continuing",
                    Profile.Error_Msg);
                Show_Tokens (Product_Filter => "RCF");
            end if;
        end;
    else
        Log.Put_Line ("Machine has not been configured with product tokens");
    end if;
end;
)

AUTHORIZE_TOKEN => (
    Accept_Tokens (Product => [STRING-expression],
                   Donation => [POSITIVE-expression],
                   Resulting_Count => [POSITIVE-expression],
                   Code => [STRING-expression],
                   Response => "<PROFILE>");
)

AUTHORIZE_PRODUCT => (
    "!Implementation".Product_Authorization.Register
            (Product_Name => ">>Product Name<<",
             Authorization_Code => ">> Code <<");
)

RELEASE_RESTORE => (
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Release_Log");
    Archive.Restore (Options => "promote, replace",
                     Device => "Release");
    if Directory_Tools.Object.Is_Ok (The_Objects =>
                                        Directory_Tools.Naming.Resolution
                                           ("Release_Notes.[Data,Index]")) then
        Archive.Restore (Options => "promote, replace",
                         Device => "Release_Notes");

    end if;
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Release_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Release_Log_Summary",
        Auxiliaries => False,
        Warnings => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Release_Log_Summary");
)

INSTALL_PRODUCT => (
declare
    Found : Boolean := False;
    function Rcf_Target_File return String is
        use Directory_Tools;
    begin
        if Object.Is_Ok (The_Object =>
                            Naming.Resolution
                               ("!Machine.Initialization.Rational")) then
            return "!Machine.Initialization.Site.RCF_Configuration";
        else
            return "!Machine.RCF_Targets";
        end if;
    end Rcf_Target_File;
begin
    Io.Set_Output ("!Machine.Temporary.RCF_Targets");
    Io.Set_Input (Rcf_Target_File);
    while not Io.End_Of_File loop
        declare
            Name : constant String := String_Utilities.Strip (Io.Get_Line);
        begin
            if not String_Utilities.Equal (Name, "RS6000_IBM") then
                Io.Put_Line (Name);
            end if;
            Found := Found or String_Utilities.Equal (Name, "RS6000_AIX_IBM");
        end;
    end loop;
    if not Found then
        Io.Put_Line ("RS6000_AIX_IBM");
    end if;
    Io.Reset_Output;
    Io.Reset_Input;
    Lib.Move (From => "!Machine.Temporary.RCF_Targets",
              To => Rcf_Target_File,
              Response => "<ERRORS>");
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Install_Product_Log");
    Library.Context (To_Be =>
                        "!Targets.Implementation.Release_Rs6000_AIX_IBM_1_0_2");
    System_Utilities.Set_Page_Limit (16_000);
    "!Targets.Implementation.Release_Rs6000_AIX_IBM_1_0_2".Install_Customization
       ("RS6000_AIX_IBM");
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Install_Product_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Install_Product_Log_Summary",
        Warnings => False,
        Auxiliaries => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Install_Product_Log_Summary");

end;
)

REGISTER_TARGET => (
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Register_Target_Log");
    Rs6000_Aix_Ibm.Register;
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Register_Target_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Register_Target_Log_Summary",
        Warnings => False,
        Auxiliaries => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Register_Target_Log_Summary");
)

ACTIVITY_UPDATE => (
declare
    Temp_Activity : constant String := "!Machine.Temporary.Activity";
begin
    Log.Put_Line ("Updating System Activity to <unknown>");
    Activity.Create (The_Activity => Temp_Activity,
                     Source => Activity.Nil,
                     Mode => Activity.Exact_Copy,
                     Response => "<ERRORS>");
    Activity.Add (Subsystem => "!<subsystem>",
                  Load_Value => "<load_view>",
                  Spec_Value => "<spec_view>",
                  The_Activity => Temp_Activity,
                  Mode => Activity.Exact_Copy,
                  Response => "<ERRORS>");
    Activity.Merge (Source => Temp_Activity,
                    Subsystem => "?",
                    Spec_View => "?",
                    Load_View => "?",
                    Mode => Activity.Exact_Copy,
                    Target => "!Machine.Release.Current.Activity",
                    Response => "<ERRORS>");
    Lib.Delete (Existing => "!Machine.Temporary.Activity",
                Limit => "<DIRECTORIES>",
                Response => "<ERRORS>");

end;
)

RESTORE_NOTES => (
    Archive.Restore (Device => "Release_Notes");
)


TEST_RELEASE => (
declare

    type Ptr_String is access String;
    Username, Password, Machine, Directory_Name : Ptr_String;
    function Get_Line
                (Prompt : String; Min_Length : Natural := 1) return String is
        S : String (1 .. 80);
        Last : Natural := 0;
    begin
        loop
            Io.Put (Prompt);
            Io.Get_Line (S, Last);
            exit when Last >= Min_Length;
            Io.Put_Line ("ERROR: Must enter a value with" &
                         Natural'Image (Min_Length) & " characters");
        end loop;
        return (S (1 .. Last));
    end Get_Line;
begin
    Machine := new String'(Get_Line ("Enter Remote Machine Name : ", 1));
    Io.Put_Line ("Resolved " &
                 Transport_Name.Host_Id_To_Host
                    (Transport_Name.Host_To_Host_Id (Machine.all)) &
                 " successfully.");
    Username := new String'(Get_Line ("Enter Remote Username : ", 0));
    Password := new String'(Get_Line ("Enter Remote Password : ", 0));
    Directory_Name :=
       new String'
              (Get_Line
                  ("Enter Remote USER Directory pathname (eg: /u/smp) : ", 1) &
               "/RS6000_AIX_IBM1_0_2");
    Switches.Set (Spec => "Session_Ftp.Username:=""" & Username.all &
                             """;Session_FTP.Password:=""" &
                             Password.all & """",
                  File => "<SESSION>",
                  Response => "<ERRORS>");
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Tests_Log");
    Archive.Restore (Options => "Promote,Replace", Device => "Tests");
    Library.Context
       (To_Be =>
           "!TESTS.STAGING.INSTALL_VERIFICATIONS.RCF_RS6000_AIX_IBM.TEST_SUBSYSTEM",
        Response => "<PROFILE>");
    Rcf_Cmvc.Make_Path
       (From_Path => "R1000_Working",
        New_Path_Name => "RS6000_AIX_IBM",
        Remote_Machine => Machine.all,
        Remote_Directory => Directory_Name.all,
        View_To_Import => "",
        Model => "!Model.RS6000_AIX_IBM",
        Goal => Compilation.Coded,
        Response => "<PROFILE>");
    Library.Context (To_Be => "RS6000_AIX_IBM_Working.Units", Response => "<PROFILE>");
    Rcf.Link (Main_Unit => "hello",
              Make_Uncoded_Units => False,
              Executable_Name => "",
              Response => "~---,<PROGRESS>");
    Rcf.Execute_Remote_Command (Remote_Command => "./hello.exe");
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Tests_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Tests_Log_Summary",
        Auxiliaries => False,
        Warnings => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Restore_Tests_Log_Summary");
exception
    when Transport_Name.Undefined =>
        Log.Put_Line
           ("Cannot resolve the machine name, please enter this into the Transport_Name_Map and rerun this step",
            Profile.Error_Msg);
end;
)

LINK_TEST => (
    Library.Context
       (To_Be =>
           "!TESTS.STAGING.INSTALL_VERIFICATIONS.RCF_RS6000_AIX_IBM.RELEASE3_2_0.Rs6000_Aix_Ibm_Working.Units",
        Response => "<ERRORS>");
    Rcf.Link (Main_Unit => "hello",
              Make_Uncoded_Units => False,
              Executable_Name => "",
              Response => "~---,<PROGRESS>");
)

CONVERT_RCF_VIEWS => (
declare

    Count : Natural := 0;
    
    Abort_Execution : Exception;

    procedure Kill_Job (Job_Name : String) is
    begin
        for J in System_Utilities.Job_Id loop
            begin
                if String_Utilities.Equal
                      (System_Utilities.Job_Name (J), Job_Name) then
                    Log.Put_Line ("Killing job " & Job_Name,
                                  Profile.Positive_Msg);
                    Job.Kill (J);
                end if;
            exception
                when others =>
                    null;
            end;
        end loop;
    end Kill_Job;
    
    function Job_Running (Job_Name : String) return Boolean is
    begin
        for J in System_Utilities.Job_Id loop
            begin
                if String_Utilities.Equal
                      (System_Utilities.Job_Name (J), Job_Name) then
                    return True;
                end if;
            exception
                when others =>
                    null;
            end;
        end loop;
        return False;
    end Job_Running;
begin
    if Directory_Tools.Naming.Full_Name
          ("!TARGETS.IMPLEMENTATION.RCF_RELEASE1_1_0.INSTALL_ACTIVITY") =
       "" then
        Log.Put_Line
           ("Cannot locate Release1_1_0 activity, you will need to manually start the 1_1_0 RCF and do the conversion",
            Profile.Error_Msg);
        raise Abort_Execution;
    end if;
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log");
    Log.Put_Line ("Killing RCF and library extensions");
    "!TARGETS.IMPLEMENTATION.RCF_USER_INTERFACE.REV3_2_SPEC.UNITS".
       Kill_Rcf_Main;
    Log.Put_Line ("Starting RS6000 RCF for Release 1_1_0");
    Program.Run_Job
       (S =>
           """!Targets.Implementation.Rs6000_Ibm'Spec_View.Units"".START_RS6000_RCF;",
        Context => "!Machine.Error_Logs",
        Response =>
           "Activity=!TARGETS.IMPLEMENTATION.RCF_RELEASE1_1_0.INSTALL_ACTIVITY, <PROFILE>");
    while not Job_Running ("RCF_Rs6000_Compiler") loop
        Count := Count + 1;
        if Count > 20 then
            Log.Put_Line ("Failed to get RCF_Rs6000_Compiler started",
                          Profile.Error_Msg);
            raise Abort_Execution;
        end if;
        delay 3.0;
    end loop;

    Log.Put_Line ("Registering RS6000 target key");
    Program.Run
       (S =>
           """!Targets.Implementation.Rcf_Library_Integration.Rev1_0_2.Units"".Register;",
        Context => "!Machine.Error_Logs",
        Response =>
           "Activity=!TARGETS.IMPLEMENTATION.RCF_RELEASE1_1_0.INSTALL_ACTIVITY, <PROFILE>");
    Count := 0;
    while not Job_Running ("Rs6000_Library_Extension") loop
        Count := Count + 1;
        if Count > 20 then
            Log.Put_Line ("Failed to get RS6000_Library_Extension started",
                          Profile.Error_Msg);
            raise Abort_Execution;
        end if;
        delay 3.0;
    end loop;
    Log.Put_Line ("Calling Convert_RCF_Views_Main");
    "!TARGETS.IMPLEMENTATION.RCF_USER_INTERFACE.REV3_2_SPEC.UNITS".
       Convert_Rcf_Views_Main (From_Key => "RS6000",
                               To_Key => "RS6000_AIX_IBM",
                               Restore_Object_State => True);
    Kill_Job ("Rs6000_Library_Extension");
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log_Summary",
        Auxiliaries => False,
        Warnings => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log_Summary");

exception
    when Abort_Execution =>
        Log.Put_Line ("Aborting execution", Profile.Negative_Msg);
        Io.Reset_Output;
        Log.Filter_Errors
           (Log_File =>
               "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log",
            Destination =>
               "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log_Summary",
            Auxiliaries => False,
            Warnings => False,
            Exceptions => True);
        Common.Definition
           ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Convert_Views_Log_Summary");
end;
)

RECORD_INSTALLATION => (
declare
    Product : constant String := Directory_Tools.Naming.Simple_Name
                                    (Directory_Tools.Naming.Full_Name ("^"));
    Release : constant String := Directory_Tools.Naming.Simple_Name
                                    (Directory_Tools.Naming.Full_Name ("$"));
    Product_Info : constant String :=
       "(RELEASE => " & Release & ", DATE => (" &
          Time_Utilities.Image (Time_Utilities.Get_Time,
                                Time_Utilities.Year_Month_Day) &
          "), USER => " & System_Utilities.User_Name &
          '.' & System_Utilities.Session_Name & ")";
    Product_Filename : constant String := "!Machine.Release.Current.Products";
    F : Io.File_Type;
begin
    Io.Append (F, Name => Product_Filename);
    Io.Put_Line (F, Product & " => " & Product_Info);
    Io.Close (F);
    Log.Put_Line ("Recording product " & Product &
                  " current release as " & Release,
                  Profile.Positive_Msg);
end;
)

DESTROY_OLD_RELEASES => (
    Io.Set_Output
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Destroy_Old_Releases_Log");
    Cmvc.Destroy_View
       (What_View =>
           "!Targets.Implementation.Release_Rs6000_Aix_Ibm_1_0_2.[[_install_activity]$$^.@'C(Spec_View,Load_View),~[_install_activity]]",
        Demote_Clients => False,
        Destroy_Configuration_Also => True,
        Comments => "",
        Work_Order => "<DEFAULT>",
        Response => "<PROFILE>");
    Compilation.Destroy
       (Unit => "!Targets.Implementation.[Release_Rs6000_Aix_IBM@,~Release_Rs6000_Aix_IBM_1_0_2]",
        Threshold => 999,
        Limit => "<ALL_WORLDS>",
        Response => "<PROFILE>");
    Io.Reset_Output;
    Log.Filter_Errors
       (Log_File =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Destroy_Old_Releases_Log",
        Destination =>
           "!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Destroy_Old_Releases_Log_Summary",
        Auxiliaries => False,
        Warnings => False,
        Exceptions => True);
    Common.Definition
       ("!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2.Logs.Destroy_Old_Releases_Log_Summary");
)




CLEANUP => (
    Library.Context
       (To_Be =>
           "!Tests.Staging.Install_Verifications.Rcf_Rs6000_Aix_Ibm.Test_Subsystem",
        Response => "<ERRORS>");
    Cmvc.Destroy_View (What_View => "R1000_Working",
                       Demote_Clients => False,
                       Destroy_Configuration_Also => False,
                       Comments => "",
                       Work_Order => "<DEFAULT>",
                       Response => "<ERRORS>");
    Rcf_Cmvc.Destroy_View (What_View => "RS6000_AIX_IBM_Working",
                           Demote_Clients => True,
                           Destroy_Configuration_Also => False,
                           Destroy_Remote_Library => True,
                           Comments => "",
                           Work_Order => "<DEFAULT>",
                           Response => "<ERRORS>");
    Library.Context
       (To_Be =>
           "!Tests.Staging.Install_Verifications.Rcf_Rs6000_Aix_Ibm",
        Response => "<ERRORS>");
    Cmvc.Destroy_Subsystem (What_Subsystem => "Test_Subsystem",
                            Comments => "",
                            Work_Order => "<DEFAULT>",
                            Response => "<ERRORS>");
    Compilation.Destroy
       (Unit =>
           "[!Machine.Release.Archive.RCF_RS6000_AIX_IBM.Release1_0_2" &
              ",!Targets.Implementation.Release_Rs6000_Aix_Ibm_1_0_2.[@,~Install_Activity]]",
        Threshold => 999,
        Limit => "<ALL_WORLDS>",
        Response => "<ERRORS>");
    Switches.Set (Spec =>
                     "Session_Ftp.Username:="""";Session_FTP.Password:=""""",
                  File => "<SESSION>",
                  Response => "<ERRORS>");