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

Commit

Permalink
Merge branch 't/21203/sequences/k-regular' into t/21318/sequences/rec…
Browse files Browse the repository at this point in the history
…-basic-arith

* t/21203/sequences/k-regular: (1892 commits)
  fix building of docs (no idea why it failed)
  fix doctests (experimental warning)
  doctesting all parameters in coefficient_of_word
  Updated SageMath version to 7.4.beta1
  Dots removed.
  Minor changes.
  More cleanup
  Add sphinx plots and cleanup
  Fix doctests and minor cleanup
  Corrections, changes etc.
  Trac #21181: Yet a few more formatting fixes in docstrings of sage/combinat/words/finite_word.py
  Trac #21181 (previously #21178): Change to imperative form in docstrings of sage/combinat/words/finite_word.py, part II
  Trac #21181 (previously #21178): Change to imperative form in docstrings of sage/combinat/words/finite_word.py
  Trac #21178: A few more markup/formatting fixes in docstrings of sage/combinat/words/finite_word.py
  Trac #21178: Fix typos and a lot of markup/formatting in docstrings of sage/combinat/words/finite_word.py
  py3: no longer use file(name, kind)
  21137: minor doc change
  sqome more typos
  trac 21241 details
  Fix formatting
  ...
  • Loading branch information
dkrenn committed Aug 25, 2016
2 parents b76bf4e + 143ea73 commit 6247a7f
Show file tree
Hide file tree
Showing 2,357 changed files with 92,880 additions and 44,719 deletions.
22 changes: 6 additions & 16 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -130,22 +130,12 @@ configure: configure.ac src/bin/sage-version.sh m4/*.m4
./bootstrap -d

install:
echo "Experimental use only!"
if [ "$(DESTDIR)" = "" ]; then \
echo >&2 "Set the environment variable DESTDIR to the install path."; \
exit 1; \
fi
# Make sure we remove only an existing directory. If $(DESTDIR)/sage is
# a file instead of a directory then the mkdir statement later will fail
if [ -d "$(DESTDIR)"/sage ]; then \
rm -rf "$(DESTDIR)"/sage; \
fi
mkdir -p "$(DESTDIR)"/sage
mkdir -p "$(DESTDIR)"/bin
cp -Rp * "$(DESTDIR)"/sage
rm -f "$(DESTDIR)"/bin/sage
ln -s ../sage/sage "$(DESTDIR)"/bin/sage
"$(DESTDIR)"/bin/sage -c # Run sage-location
@echo "******************************************************************"
@echo "The '$@' target is no longer supported:"
@echo "either build SageMath in-place or use the binary packaging scripts"
@echo "from https://github.com/sagemath/binary-pkg"
@echo "******************************************************************"
@exit 1


.PHONY: default build install micro_release \
Expand Down
15 changes: 10 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
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
Original file line number Diff line number Diff line change
@@ -1 +1 @@
SageMath version 7.2, Release Date: 2016-05-15
SageMath version 7.4.beta1, Release Date: 2016-08-17
4 changes: 2 additions & 2 deletions build/bin/sage-download-file
Original file line number Diff line number Diff line change
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()
33 changes: 31 additions & 2 deletions build/bin/sage-logger
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#!/usr/bin/env bash
#
# sage-logger COMMAND LOGFILE
# sage-logger [-p] COMMAND LOGFILE
#
# Evaluate shell command COMMAND while logging stdout and stderr to
# LOGFILE. If either the command or the logging failed, return a
# non-zero exit status.
#
# If the -p argument is given, each line printed to stdout is prefixed
# with the name of the log file.
#
# AUTHOR:
#
# - Jeroen Demeyer (2015-07-26): initial version based on old pipestatus
Expand All @@ -20,16 +23,42 @@
# http://www.gnu.org/licenses/
#*****************************************************************************

use_prefix=false

if [[ "$1" = -p ]]; then
use_prefix=true
shift
fi

cmd="$1"
logfile="$2"
logname="$(basename $logfile .log)"
logdir=`dirname "$logfile"`

if [[ $use_prefix = true ]]; then
prefix="[${logname}] "
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" )
( 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
Original file line number Diff line number Diff line change
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
Original file line number Diff line number Diff line change
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
62 changes: 19 additions & 43 deletions build/bin/sage-uncompress-spkg
Original file line number Diff line number Diff line change
@@ -1,47 +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.)
# 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

import sys
import tarfile
import zipfile

if __name__ == '__main__':
filename = sys.argv[1]
if tarfile.is_tarfile(filename):
# tar file, possibly compressed:
archive = tarfile.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)
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()
12 changes: 6 additions & 6 deletions build/make/deps
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ sagelib: \
$(EXTCODE)
if [ -z "$$SAGE_INSTALL_FETCH_ONLY" ]; then \
cd $(SAGE_SRC) && source bin/sage-env && \
sage-logger 'time $(MAKE) sage' '$(SAGE_LOGS)/sagelib-$(SAGE_VERSION).log'; \
sage-logger -p 'time $(MAKE) sage' '$(SAGE_LOGS)/sagelib-$(SAGE_VERSION).log'; \
fi


Expand Down Expand Up @@ -192,28 +192,28 @@ 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

doc-html: $(DOC_DEPENDENCIES)
cd ../.. && sage-logger './sage --docbuild --no-pdf-links all html $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log
cd ../.. && sage-logger -p './sage --docbuild --no-pdf-links all html $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log

# 'doc-html-no-plot': build docs without building the graphics coming
# from the '.. plot' directive, in case you want to save a few
# megabytes of disk space. 'doc-clean' is a prerequisite because the
# presence of graphics is cached in src/doc/output.
doc-html-no-plot: doc-clean $(DOC_DEPENDENCIES)
cd ../.. && sage-logger './sage --docbuild --no-pdf-links --no-plot all html $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log
cd ../.. && sage-logger -p './sage --docbuild --no-pdf-links --no-plot all html $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log

doc-html-mathjax: $(DOC_DEPENDENCIES)
cd ../.. && sage-logger './sage --docbuild --no-pdf-links all html -j $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log
cd ../.. && sage-logger -p './sage --docbuild --no-pdf-links all html -j $(SAGE_DOCBUILD_OPTS)' logs/dochtml.log

# Keep target 'doc-html-jsmath' for backwards compatibility.
doc-html-jsmath: doc-html-mathjax

doc-pdf: $(DOC_DEPENDENCIES)
cd ../.. && sage-logger './sage --docbuild all pdf $(SAGE_DOCBUILD_OPTS)' logs/docpdf.log
cd ../.. && sage-logger -p './sage --docbuild all pdf $(SAGE_DOCBUILD_OPTS)' logs/docpdf.log

doc-clean: doc-src-clean doc-output-clean

Expand Down
5 changes: 5 additions & 0 deletions build/pkgs/4ti2/dependencies
Original file line number Diff line number Diff line change
@@ -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.
6 changes: 3 additions & 3 deletions build/pkgs/alabaster/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
tarball=alabaster-VERSION.tar.gz
sha1=ff3e575ee7eb4ba1721f17d91ec5a54b16283603
md5=957c665d7126dea8121f98038debcba7
cksum=738605178
sha1=c80dedaf4a1906410e53b653de059fe9d8b17c68
md5=346a71e8a6d51dff2e02086fdd9c5ffe
cksum=2849350596
2 changes: 1 addition & 1 deletion build/pkgs/alabaster/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.7.7
0.7.8
4 changes: 2 additions & 2 deletions build/pkgs/atlas/patches/Makefile.patch
Original file line number Diff line number Diff line change
@@ -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
Loading

0 comments on commit 6247a7f

Please sign in to comment.