# HG changeset patch
# User Jeroen Demeyer <jdemeyer@cage.ugent.be>
# Date 1318867571 -7200
# Node ID ac14bac95dbc141c384d2699c8257a5ef2a9ca90
# Parent a9011e45347e8cd8c3cd3b7e37c8b8b3d91dd180
Run sage_setup before testing Sage
diff --git a/spkg/bin/sage b/spkg/bin/sage
a
|
b
|
|
285 | 285 | cat "$SAGE_LOCAL/bin/sage-banner" |
286 | 286 | fi |
287 | 287 | |
288 | | # Check to see if the whole Sage install tree has moved. |
289 | | # If so, change various hardcoded paths. |
290 | | sage-location || exit $? |
| 288 | # Check to see if the whole Sage install tree has moved. If so, |
| 289 | # change various hardcoded paths. Skip this if we don't have write |
| 290 | # access to $SAGE_LOCAL (e.g. when running as a different user). |
| 291 | if [ -w "$SAGE_LOCAL" ]; then |
| 292 | sage-location || exit $? |
| 293 | fi |
291 | 294 | |
292 | 295 | export IPYTHONDIR="$DOT_SAGE/ipython" |
293 | 296 | export IPYTHONRC="ipythonrc" |
… |
… |
|
782 | 785 | touch "$DOT_SAGE"/init.sage |
783 | 786 | fi |
784 | 787 | shift |
| 788 | SAGE_BANNER="no" |
| 789 | sage_setup |
785 | 790 | sage-test "$@" |
786 | 791 | exit $? |
787 | 792 | fi |
… |
… |
|
795 | 800 | touch "$DOT_SAGE"/init.sage |
796 | 801 | fi |
797 | 802 | shift |
| 803 | SAGE_BANNER="no" |
| 804 | sage_setup |
798 | 805 | sage-ptest "$@" |
799 | 806 | exit $? |
800 | 807 | fi |
… |
… |
|
804 | 811 | build_sage |
805 | 812 | fi |
806 | 813 | shift |
| 814 | SAGE_BANNER="no" |
| 815 | sage_setup |
807 | 816 | sage-test-new "$@" |
808 | 817 | exit $? |
809 | 818 | fi |
810 | 819 | |
811 | 820 | if [ "$1" = '-testall' -o "$1" = "--testall" ]; then |
812 | 821 | shift |
| 822 | SAGE_BANNER="no" |
| 823 | sage_setup |
813 | 824 | sage-maketest "$@" |
814 | 825 | exit $? |
815 | 826 | fi |
… |
… |
|
906 | 917 | |
907 | 918 | if [ "$1" = '-info' -o "$1" = '--info' ]; then |
908 | 919 | shift |
909 | | # If there are no further arguments, simply list all installed |
910 | | # packages. |
911 | | if [ $# -eq 0 ]; then |
912 | | exec sage-spkg |
913 | | fi |
914 | | install --info "$@" |
| 920 | for PKG in "$@" |
| 921 | do |
| 922 | sage-spkg --info "$PKG" || exit $? |
| 923 | done |
| 924 | exit 0 |
915 | 925 | fi |
916 | 926 | |
917 | 927 | if [ "$1" = '-pkg' -o "$1" = '-spkg' -o "$1" = "--pkg" -o "$1" = "--spkg" ]; then |
… |
… |
|
972 | 982 | # People often move the Sage install right before doing the upgrade, so it's |
973 | 983 | # important to fix any path hardcoding issues first, or certain library |
974 | 984 | # links will fail. |
975 | | sage-location |
| 985 | sage-location || exit $? |
976 | 986 | |
977 | 987 | # Run sage-upgrade twice since when installing sage-scripts and a |
978 | 988 | # running script changes, it gets confused and exits with an error. |