Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
Merge tag '7.3' into t/20278/ticket/20278
Browse files Browse the repository at this point in the history
SageMath version 7.3
  • Loading branch information
mkoeppe committed Aug 12, 2016
2 parents 990f3f7 + b630b41 commit 0d449b9
Show file tree
Hide file tree
Showing 1,670 changed files with 54,017 additions and 18,268 deletions.
2 changes: 1 addition & 1 deletion Makefile
Expand Up @@ -15,7 +15,7 @@ build: all-build
%::
@if [ -x relocate-once.py ]; then ./relocate-once.py; fi
$(MAKE) build/make/Makefile
+build/bin/sage-logger -p \
+build/bin/sage-logger \
"cd build/make && ./install '$@'" logs/install.log

# If configure was run before, rerun it with the old arguments.
Expand Down
15 changes: 10 additions & 5 deletions README.md
Expand Up @@ -3,7 +3,7 @@
> "Creating a Viable Open Source Alternative to
> Magma, Maple, Mathematica, and MATLAB"
> Copyright (C) 2005-2014 The Sage Development Team
> Copyright (C) 2005-2016 The Sage Development Team
http://www.sagemath.org

Expand Down Expand Up @@ -67,7 +67,7 @@ source. More detailed instructions, including how to build faster on
multicore machines, are contained later in this README and in the
Installation Guide:

http://www.sagemath.org/doc/installation
http://doc.sagemath.org/html/en/installation

__1. Make sure you have the dependencies and 5 GB of free disk space.__

Expand Down Expand Up @@ -110,14 +110,19 @@ __3. cd into the Sage directory and type make:__
should work fine on all fully supported platforms. If it does not, we
want to know!

If you'd like to contribute to Sage, be sure to read the
Developer's Guide:

http://doc.sagemath.org/html/en/developer/index.html


Environment Variables
---------------------

There are a lot of environment variables which control the install
process of Sage, see:

http://sagemath.org/doc/installation/source.html#environment-variables
http://doc.sagemath.org/html/en/installation/source.html#environment-variables


Implementation
Expand Down Expand Up @@ -325,7 +330,7 @@ SAGE_ROOT Root directory (sage-x.y.z in Sage tarball)
```
For more details, see:

http://sagemath.org/doc/developer/coding_basics.html#files-and-directory-structure
http://doc.sagemath.org/html/en/developer/coding_basics.html#files-and-directory-structure


Relocation
Expand All @@ -343,7 +348,7 @@ Sage as root at least once prior to using the system-wide Sage as a
normal user. See the Installation Guide for further information on
performing a system-wide installation:

http://www.sagemath.org/doc/installation/source.html#installation-in-a-multiuser-environment
http://doc.sagemath.org/html/en/installation/source.html#installation-in-a-multiuser-environment

If you find anything that doesn't work correctly after you moved the
directory, please email the sage-support mailing list.
Expand Down
2 changes: 1 addition & 1 deletion VERSION.txt
@@ -1 +1 @@
SageMath version 7.3.beta2, Release Date: 2016-05-28
SageMath version 7.3, Release Date: 2016-08-04
4 changes: 2 additions & 2 deletions build/bin/sage-download-file
Expand Up @@ -24,5 +24,5 @@ except ImportError:
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))
import sage_bootstrap

from sage_bootstrap.cmdline import SageDownloadFileApplication
SageDownloadFileApplication().run()
from sage_bootstrap.download.cmdline import run_safe
run_safe()
15 changes: 13 additions & 2 deletions build/bin/sage-logger
Expand Up @@ -41,13 +41,24 @@ else
prefix=""
fi

# Use sed option to reduce buffering, to make the output appear more
# smoothly. For GNU sed, this is the --unbuffered option.
# For BSD sed (which is also on OS X), this is the -l option.
if sed </dev/null 2>/dev/null --unbuffered ""; then
SED="sed --unbuffered"
elif sed </dev/null 2>/dev/null -l ""; then
SED="sed -l"
else
SED="sed"
fi

mkdir -p "$logdir"

# Redirect stdout and stderr to a subprocess running tee.
# We trap SIGINT such that SIGINT interrupts the main process being
# run, not the logging.
( exec 2>&1; eval "$cmd" ) | ( trap '' SIGINT; tee -a "$logfile" ) | \
(while read line; do echo "${prefix}${line}"; done)
( exec 2>&1; eval "$cmd" ) | \
( trap '' SIGINT; tee -a "$logfile" | $SED "s/^/$prefix/" )

pipestatus=(${PIPESTATUS[*]})

Expand Down
4 changes: 2 additions & 2 deletions build/bin/sage-package
Expand Up @@ -38,5 +38,5 @@ except ImportError:
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))
import sage_bootstrap

from sage_bootstrap.cmdline import SagePkgApplication
SagePkgApplication().run()
from sage_bootstrap.cmdline import run
run()
49 changes: 22 additions & 27 deletions build/bin/sage-spkg
Expand Up @@ -272,7 +272,8 @@ elif [ -z "$PKG_HAS_PATH" ]; then
echo "that it will build correctly, or behave as expected."
echo "Use at your own risk!"
echo "==============================================================="
read -p "Are you sure you want to continue [Y/n]? " answer
echo "Are you sure you want to continue [Y/n]?"
read -p "Answer: " answer
case "$answer" in
n*|N*) exit 0;;
esac
Expand Down Expand Up @@ -365,7 +366,8 @@ if [ ! -f "$PKG_SRC" ]; then
echo "For more information about making Sage packages, see"
echo "http://doc.sagemath.org/html/en/developer/packaging.html"
echo "=========================================================================="
read -p "Are you sure you want to continue [Y/n]? " answer
echo "Are you sure you want to continue [Y/n]?"
read -p "Answer: " answer
case "$answer" in
n*|N*) exit 0;;
esac
Expand All @@ -381,7 +383,8 @@ if [ ! -f "$PKG_SRC" ]; then
echo "http://doc.sagemath.org/html/en/developer/packaging.html"
echo "=========================================================================="
echo
read -t 30 -p "Are you sure (automatically continuing in 30 seconds) [Y/n]? " answer
echo "Are you sure (automatically continuing in 30 seconds) [Y/n]?"
read -t 30 -p "Answer: " answer
case "$answer" in
n*|N*) exit 0;;
esac
Expand Down Expand Up @@ -520,44 +523,36 @@ fi
##################################################################

if [ "$USE_LOCAL_SCRIPTS" = yes ]; then
# New-style package
echo "Setting up build directory for $PKG_NAME"
cp -Rp "$PKG_SCRIPTS" "$PKG_NAME"
cd "$PKG_NAME" || exit $?

sage-uncompress-spkg -d src "$PKG_SRC"
if [ $? -ne 0 ]; then
echo >&2 "Error: failed to extract $PKG_SRC"
exit 1
fi
else
# Old-style package (deprecated)
echo "Extracting package $PKG_SRC"
ls -l "$PKG_SRC"
fi

sage-uncompress-spkg "$PKG_SRC"
if [ $? -ne 0 ]; then
echo >&2 "Error: failed to extract $PKG_SRC"
exit 1
fi

if [ "$USE_LOCAL_SCRIPTS" = yes ]; then
shopt -s nocaseglob # see trac:16415
# Strip file extension from the archive file and hope (as per
# automake standards) that this is the same as the directory name
# inside; move the directory to "src". (This goes wrong for
# upstream package archives that have been renamed to appease some
# other Sage script, such as "latte-int", whose archive is renamed
# to "latte_int".)
mv "$(echo "$PKG_NAME_UPSTREAM" | sed 's/\.zip$//g;s/\.tgz$//g;s/\.tar\.gz$//g;s/\.tar\.xz$//g;s/\.tar\.lz$//g;s/\.tar\.bz2$//g;s/\.tar$//g')"* src
# Do not check for errors here; the "mv" fails in the situation
# mentioned above, and the package-specific script needs to do
# this work itself.
shopt -u nocaseglob
echo "Finished set up"
else
echo "Finished extraction"
sage-uncompress-spkg "$PKG_SRC"
if [ $? -ne 0 ]; then
echo >&2 "Error: failed to extract $PKG_SRC"
exit 1
fi

cd "$PKG_NAME"
if [ $? -ne 0 ]; then
echo >&2 "Error: after extracting, the directory $PKG_NAME does not exist"
echo >&2 "Error: after extracting, the directory '$PKG_NAME' does not exist"
exit 1
fi
fi

echo "Finished extraction"

##################################################################
# The package has been extracted, prepare for installation
##################################################################
Expand Down
93 changes: 21 additions & 72 deletions build/bin/sage-uncompress-spkg
@@ -1,74 +1,23 @@
#!/usr/bin/env python

# USAGE:
#
# sage-uncompress-spkg PKG [FILE]
#
# With a single argument, unpack the file PKG to the current directory.
#
# If FILE is specified, extract FILE from PKG and send it to
# stdout. (This option is present only for backwards compatibility:
# printing the SPKG.txt file from an old-style spkg.)

import copy
import os
import sys
import tarfile
import zipfile


class UmaskExtractTarFile(tarfile.TarFile):
"""
Sage as tarfile.TarFile, but applies the user's current umask to the
permissions of al extracted files and directories.
This mimics the default behavior of the ``tar`` utility.
See http://trac.sagemath.org/ticket/20218#comment:16 for more background.
"""

def __init__(self, *args, **kwargs):
super(UmaskExtractTarFile, self).__init__(*args, **kwargs)

# Unfortunately the only way to get the current umask is to set it
# and then restore it
self.umask = os.umask(0777)
os.umask(self.umask)

def chmod(self, tarinfo, target):
tarinfo = copy.copy(tarinfo)
tarinfo.mode &= ~self.umask
return super(UmaskExtractTarFile, self).chmod(tarinfo, target)


if __name__ == '__main__':
filename = sys.argv[1]
if tarfile.is_tarfile(filename):
# tar file, possibly compressed:
archive = UmaskExtractTarFile.open(filename, 'r:*')
if len(sys.argv) == 2:
archive.extractall()
else:
member = sys.argv[2]
if member in archive.getnames():
SPKG_TXT = archive.extractfile(member)
sys.stdout.write(SPKG_TXT.read())
exit(1)
archive.close()
exit(0)
if zipfile.is_zipfile(filename):
# zip file:
archive = zipfile.ZipFile(filename, 'r')
if len(sys.argv) == 2:
archive.extractall()
else:
member = sys.argv[2]
if member in archive.namelist():
sys.stdout.write(archive.read(member))
else:
exit(1)
archive.close()
exit(0)
else:
print ('Error: Unknown file type: {}'.format(filename))
exit(1)
# usage: sage-uncompress-spkg [-h] [-d DIR] PKG [FILE]
#
# positional arguments:
# PKG the archive to extract
# FILE (deprecated) print the contents of the given archive member to
# stdout
#
# optional arguments:
# -h, --help show this help message and exit
# -d DIR directory to extract archive contents into


try:
import sage_bootstrap
except ImportError:
import os, sys
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))
import sage_bootstrap

from sage_bootstrap.uncompress.cmdline import run
run()
2 changes: 1 addition & 1 deletion build/make/deps
Expand Up @@ -192,7 +192,7 @@ DOC_DEPENDENCIES = sagelib $(inst_sphinx) $(inst_sagenb) \
| $(SAGERUNTIME) $(inst_maxima) $(inst_networkx) $(inst_scipy) \
$(inst_matplotlib) $(inst_pillow) $(inst_mathjax) $(inst_mpmath) \
$(inst_ipykernel) $(inst_jupyter_client) $(inst_conway_polynomials) \
$(inst_tachyon)
$(inst_tachyon) $(inst_jmol)

doc: doc-html

Expand Down
5 changes: 5 additions & 0 deletions build/pkgs/4ti2/dependencies
@@ -0,0 +1,5 @@
zlib $(MP_LIBRARY) glpk

----------
All lines of this file are ignored except the first.
It is copied by SAGE_ROOT/build/make/install into SAGE_ROOT/build/make/Makefile.
4 changes: 2 additions & 2 deletions build/pkgs/atlas/patches/Makefile.patch
@@ -1,5 +1,5 @@
--- src/CONFIG/src/Makefile 2012-06-23 17:27:27.000000000 +0100
+++ new/CONFIG/src/Makefile 2012-06-24 03:05:52.043151077 +0100
--- src/ATLAS/CONFIG/src/Makefile 2012-06-23 17:27:27.000000000 +0100
+++ new/ATLAS/CONFIG/src/Makefile 2012-06-24 03:05:52.043151077 +0100
@@ -580,6 +580,6 @@
confclean: $(CLEANdep)
rm -f *core* *.o config?.out
Expand Down
6 changes: 3 additions & 3 deletions build/pkgs/atlas/patches/arm_hard_floats.patch
@@ -1,6 +1,6 @@
diff -druN ATLAS.detect/CONFIG/src/atlcomp.txt ATLAS/CONFIG/src/atlcomp.txt
--- ATLAS.detect/CONFIG/src/atlcomp.txt 2013-01-08 10:15:42.000000000 -0800
+++ ATLAS/CONFIG/src/atlcomp.txt 2014-02-10 04:36:26.113011794 -0800
diff -druN ATLAS.detect/ATLAS/CONFIG/src/atlcomp.txt ATLAS/ATLAS/CONFIG/src/atlcomp.txt
--- ATLAS.detect/ATLAS/CONFIG/src/atlcomp.txt 2013-01-08 10:15:42.000000000 -0800
+++ ATLAS/ATLAS/CONFIG/src/atlcomp.txt 2014-02-10 04:36:26.113011794 -0800
@@ -255,13 +255,13 @@
# ARM defaults
#
Expand Down
6 changes: 3 additions & 3 deletions build/pkgs/atlas/patches/cygwin_threads.patch
@@ -1,7 +1,7 @@
Let ATLAS use Cygwin thread functions on Cygwin64.
diff -druN ATLAS.orig/src/threads/ATL_thread_start.c ATLAS.new/src/threads/ATL_thread_start.c
--- ATLAS.orig/src/threads/ATL_thread_start.c 2014-07-10 09:22:06.000000000 -0700
+++ ATLAS.new/src/threads/ATL_thread_start.c 2014-11-18 07:17:39.207997205 -0800
diff -druN ATLAS.orig/ATLAS/src/threads/ATL_thread_start.c ATLAS.new/ATLAS/src/threads/ATL_thread_start.c
--- ATLAS.orig/ATLAS/src/threads/ATL_thread_start.c 2014-07-10 09:22:06.000000000 -0700
+++ ATLAS.new/ATLAS/src/threads/ATL_thread_start.c 2014-11-18 07:17:39.207997205 -0800
@@ -14,14 +14,14 @@
*/
{
Expand Down
6 changes: 3 additions & 3 deletions build/pkgs/atlas/patches/detect.patch
@@ -1,6 +1,6 @@
diff -druN ATLAS.orig/CONFIG/include/atlconf.h ATLAS/CONFIG/include/atlconf.h
--- ATLAS.orig/CONFIG/include/atlconf.h 2013-01-08 10:15:42.000000000 -0800
+++ ATLAS/CONFIG/include/atlconf.h 2014-02-10 04:31:19.992981182 -0800
diff -druN ATLAS.orig/ATLAS/CONFIG/include/atlconf.h ATLAS/ATLAS/CONFIG/include/atlconf.h
--- ATLAS.orig/ATLAS/CONFIG/include/atlconf.h 2013-01-08 10:15:42.000000000 -0800
+++ ATLAS/ATLAS/CONFIG/include/atlconf.h 2014-02-10 04:31:19.992981182 -0800
@@ -18,7 +18,7 @@
enum ARCHFAM {AFOther=0, AFPPC, AFSPARC, AFALPHA, AFX86, AFIA64, AFMIPS,
AFARM, AFS390};
Expand Down
6 changes: 3 additions & 3 deletions build/pkgs/atlas/patches/do_not_force_mutex.patch
@@ -1,10 +1,10 @@
Always use assembly over mutex since the mutex version fails to build
a shared library. See #15045 for details.

diff --git a/tune/threads/tune_count.c b/tune/threads/tune_count.c
diff --git a/ATLAS/tune/threads/tune_count.c b/ATLAS/tune/threads/tune_count.c
index f09717f..4dc3fde 100644
--- a/tune/threads/tune_count.c
+++ b/tune/threads/tune_count.c
--- a/ATLAS/tune/threads/tune_count.c
+++ b/ATLAS/tune/threads/tune_count.c
@@ -241,8 +241,8 @@ int main(int nargs, char **args)
*/
if (tmut < tldec*1.02)
Expand Down
4 changes: 2 additions & 2 deletions build/pkgs/atlas/patches/glibc_scanf_workaround.patch
@@ -1,8 +1,8 @@
Bug in glibc-2.18: https://sourceware.org/bugzilla/show_bug.cgi?id=15917


--- a/tune/sysinfo/masrch.c
+++ b/tune/sysinfo/masrch.c
--- a/ATLAS/tune/sysinfo/masrch.c
+++ b/ATLAS/tune/sysinfo/masrch.c
@@ -1,6 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
Expand Down

0 comments on commit 0d449b9

Please sign in to comment.