Ticket #5852: 5852_doc.patch

File 5852_doc.patch, 8.9 KB (added by jdemeyer, 10 years ago)
  • doc/en/installation/binary.rst

    # HG changeset patch
    # User Jeroen Demeyer <jdemeyer@cage.ugent.be>
    # Date 1321607336 -3600
    # Node ID a0ed53dabbe1dce658c6ebfdff9fe63f9f05b8b7
    # Parent  34b00237e846827599803897e455c95e047747a4
    Recommend using a symbolic link from /usr/local/bin/sage to $SAGE_ROOT/sage
    
    diff --git a/doc/en/installation/binary.rst b/doc/en/installation/binary.rst
    a b  
    1414
    1515Assumptions: You have a computer with at least 2 GB of free
    1616disk space and the operating system is Linux (32-bit or 64-bit) or
    17 OS X (10.5.x).
     17OS X (10.4 or later).
    1818
    1919Highly Recommended: It is highly recommended that you have LaTeX
    2020installed.  If you want to view animations, you should install either
     
    2222displaying some LaTeX output in the Sage notebook.
    2323
    2424Download the latest binary tarball from
    25 http://www.sagemath.org/download.html . For example, it might be
     25http://www.sagemath.org/download.html. For example, it might be
    2626called ``sage-x.y.z-x86_64-Linux.tgz``. Unpack it on your computer
    27 in a directory which you have permission to read and write:
     27in a directory which you have permission to read and write::
     28
     29    tar zxvf sage-x.y.z-x86_64-Linux.tgz
     30
     31You can move the resulting directory ``sage-x.y.z-x86_64-Linux``
     32anywhere and still run ``./sage`` from it, as long as the full path name
     33has **no spaces** in it.  You can also copy the file ``sage`` from
     34that directory and put it anywhere, e.g., ``/usr/local/bin/``, but
     35then you have to edit the ``#SAGE_ROOT=/path/to/sage-version`` line
     36at the top of the copied file ``/usr/local/bin/sage``
     37(you should not edit the original ``sage`` executable).
     38The variable ``SAGE_ROOT`` should point to the directory
     39``sage-x.y.z-x86_64-Linux`` of the extracted Sage tarball.
     40As long as ``/usr/local/bin`` is in your
     41``$PATH``, you can then type ``sage`` from the command line to run
     42Sage.  Another approach is to create a symbolic link, say
     43``/usr/local/bin/sage``, pointing to ``sage-x.y.z-x86_64-Linux`` ::
     44
     45    ln -s /path/to/sage-x.y.z-x86_64-Linux/sage /usr/local/bin/sage
     46
     47With this approach, there is no need to edit ``/usr/local/bin/sage``,
     48the ``SAGE_ROOT`` path will be discovered automatically thanks to the
     49symbolic link.
     50When you want to install a new version of Sage, just delete the old
     51link and create a new one.
     52
     53Any time you move the Sage directory, you may see a message like
    2854
    2955::
    3056
    31         tar zxvf sage-x.y.z-x86_64-Linux.tgz
    32 
    33 You can move the resulting directory ``sage-x.y.z-x86_64-Linux``
    34 anywhere and still run ``sage`` from it, as long as the full path name
    35 has **no spaces** in it.  You can also copy the file ``sage`` from
    36 that directory and put it anywhere, e.g., ``/usr/local/bin/``, but
    37 then you have to edit the ``SAGE_ROOT="....."`` line at the top of
    38 that file, replacing the dots with the path to the Sage directory
    39 ``sage-x.y.z-x86_64-Linux``.  As long as ``/usr/local/bin`` is in your
    40 ``$PATH``, you can then type ``sage`` from the command line to run
    41 Sage.  Another approach is to create a symbolic link, say
    42 ``/usr/local/share/sage``, pointing to ``sage-x.y.z-x86_64-Linux`` ::
    43 
    44     ln -s /.../path_to/.../sage-x.y.z-x86_64-Linux /usr/local/share/sage
    45 
    46 Then put ``/usr/local/share/sage`` in your ``$PATH``.  If you do this,
    47 you can type ``sage`` from the command line to run Sage.  Also, if you
    48 install a different version of Sage, you just have to delete the old
    49 link and create one from the new directory to
    50 ``/usr/local/share/sage``.
    51 
    52 Finally, you can also combine these two approaches, copying ``sage``
    53 to ``/usr/local/bin/``, creating a link ``/usr/local/share/sage``
    54 pointing to ``sage-x.y.z-x86_64-Linux``, and editing
    55 the file ``/usr/local/bin/sage``: change the line ::
    56 
    57   SAGE_ROOT="....."
    58 
    59 to ::
    60 
    61   SAGE_ROOT="/usr/local/share/sage"
    62 
    63 When you want to install a new version of Sage, just delete the old
    64 link and create a new one; you shouldn't have to replace or modify the
    65 file ``/usr/local/bin/sage``.
    66 
    67 The first time you run Sage, and any time you move the Sage directory
    68 or create a link as above, you may see a message saying
    69 
    70 ::
    71 
    72    The Sage install tree may have moved.
    73    Regenerating Python.pyo and .pyc files that hardcode the install PATH
    74    (please wait at most a few minutes)...
    75    Do not interrupt this.
     57    The Sage installation tree may have moved
     58    (from /foo to /bar).
     59    Changing various hardcoded paths...
     60    (Please wait at most a few minutes.)
     61    DO NOT INTERRUPT THIS.
    7662
    7763We currently distribute ``.dmg`` files for OS X 10.4.x and 10.5.x. But
    7864we would like to make Sage more of a native application. Work for that
  • doc/en/installation/source.rst

    diff --git a/doc/en/installation/source.rst b/doc/en/installation/source.rst
    a b  
    3333for these systems. You will also find details about `ports <http://en.wikipedia.org/wiki/Computer_port_%28software%29>`_
    3434to other operating systems or processors which may be taking place.
    3535
    36 Assumptions: You have a computer with about 2.5 GB of free
     36Assumptions: You have a computer with at least 3 GB of free
    3737disk space running one of the supported version of an
    3838operating system listed at
    3939http://wiki.sagemath.org/SupportedPlatforms
     
    268268there are spaces in the path.  Running Sage from a directory with
    269269spaces in its name will also fail.
    270270
    271 #. Go to http://www.sagemath.org/download-source.html , select a mirror,
    272    and download the file sage-\*.tar.
     271#. Go to http://www.sagemath.org/download-source.html, select a mirror,
     272   and download the file ``sage-x.y.z.tar``.
    273273
    274274   This tarfile contains the source code for Sage and the source for
    275275   all programs on which Sage depends. Download it into a subdirectory
     
    345345
    346346   ::
    347347
    348             grep -li "An error" spkg/logs/*
     348            grep -li "^Error installing" spkg/logs/*
    349349 
    350350   Then paste the contents of the log file(s) with errors to the Sage
    351351   support newsgroup http://groups.google.com/group/sage-support
     
    479479#. Optional: Different possibilities to make using Sage a little
    480480   easier:
    481481
     482   - Make a symbolic link from ``/usr/local/bin/sage`` (or another
     483     directory in your :envvar:`PATH`) to ``$SAGE_ROOT/sage``::
    482484
    483    -  Copy ``$SAGE_ROOT/sage`` to a location in your ``PATH``. If you do
    484       this, make sure you edit the line with the ``....``'s at the top of
    485       the ``sage`` script.
     485         ln -s /path/to/sage-x.y.z/sage /usr/local/bin/sage
     486
     487     Now simply typing ``sage`` should be sufficient to run Sage.
     488
     489   - Copy ``$SAGE_ROOT/sage`` to a location in your ``PATH``. If you do
     490     this, make sure you edit the line ``#SAGE_ROOT=/path/to/sage-version``
     491     at the top of the copied ``sage`` script. It is best to edit only
     492     the copy, not the original.
    486493
    487494   -  For KDE users, create a bash script {sage} containing the lines
    488495
     
    497504      the Application tab of the Properties of the icon, which you get my
    498505      right clicking the mouse on the icon).
    499506
    500    -  For bash shell users, type ``echo $PATH`` and
    501       ``cp sage <your-path-dir>`` into one of these directories, or else
    502       add this ``bin`` directory to your ``PATH`` variable, e.g., if you use
    503       the bash shell, add the line
    504 
    505       ::
    506 
    507           PATH="<sage-home-dir>/bin":$PATH
    508           export PATH
    509 
    510       in your .bashrc file (if it exists; if not, make one). After doing
    511       this and logging out and in again, typing ``sage`` at a shell prompt
    512       should start Sage.
    513 
    514507   - On Linux and OS X systems, you can make an alias to ``$SAGE_ROOT/sage``.
    515508     For example, put something similar to the following line in your
    516      ``.bashrc`` file:
     509     ``.bashrc`` file::
    517510
    518      ::
    519 
    520          alias 'sage'='/home/username/sage-3.1.2/sage'
     511         alias 'sage'='/home/username/sage-4.8/sage'
    521512
    522513     Having done so, quit your terminal emulator and restart it again.
    523514     Now typing ``sage`` within your terminal emulator should start
     
    881872   locations will get updated.  For this reason, it might be easier to
    882873   simply build Sage in its final location.
    883874
    884 #. Make a copy of the ``sage`` script in ``/usr/local/bin``::
     875#. Make a symbolic link to the ``sage`` script in ``/usr/local/bin``::
    885876
    886        cp /usr/local/sage-4.8/sage /usr/local/bin/
     877       ln -s /path/to/sage-x.y.z/sage /usr/local/bin/sage
    887878
     879   Alternatively, copy the Sage script::
     880
     881       cp /path/to/sage-x.y.z/sage /usr/local/bin/sage
     882   
    888883   and edit the file ``/usr/local/bin/sage``: ``SAGE_ROOT`` should be
    889    set to the directory where Sage is installed, for example
    890    ``/usr/local/sage-4.8``. It is recommended not to edit the original
    891    file ``/usr/local/sage-4.8/sage``, only the copy.
     884   set to the directory ``/path/to/sage-x.y.z/`` where Sage is
     885   installed.  It is recommended not to edit the original ``sage``
     886   script, only the copy in ``/usr/local/bin/sage``.
    892887
    893888#. Make sure that all files in the Sage tree are readable by all::
    894889