Ignore:
Timestamp:
04/22/02 11:28:38 (23 years ago)
Author:
tbretz
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/macros/rootlogon.C

    r1058 r1283  
    2323\* ======================================================================== */
    2424
     25Bool_t isloaded()
     26{
     27    TString str = gSystem->GetLibraries("*/mars.so");
    2528
    26 void rootlogon()
     29    return !str.IsNull();
     30}
     31
     32void unload()
    2733{
    28     cout << endl;
     34    if (!isloaded())
     35        return;
     36
     37    cout << "Unloading 'mars.so'... " << flush;
     38    if (gSystem->Unload("mars.so"))
     39        cout << "error." << endl;
     40    else
     41        cout << "done." << endl << endl;
     42}
     43
     44void load()
     45{
     46    if (isloaded())
     47        return;
    2948
    3049    cout << "Loading 'mars.so'... " << flush;
     
    4059
    4160    cout << endl;
     61}
     62
     63void make()
     64{
     65    unload();
     66
     67    if (gSystem->Exec("make"))
     68    {
     69        cout << "Error calling make..." << endl;
     70        return;
     71    }
     72
     73    load();
     74}
     75
     76void rootlogon()
     77{
     78    cout << endl;
     79
     80    load();
    4281
    4382    cout << "Welcome to the Mars Root environment." << endl;
     
    4584    cout << endl;
    4685}
    47 
Note: See TracChangeset for help on using the changeset viewer.