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

Commit

Permalink
Trac #30266: Merge branch 'develop' into t/30266/immutability_for_sca…
Browse files Browse the repository at this point in the history
…lar_fields
  • Loading branch information
Michael Jung committed Aug 2, 2020
2 parents 8ca8b75 + 83caa4b commit 0bf9f36
Show file tree
Hide file tree
Showing 252 changed files with 5,931 additions and 4,797 deletions.
4 changes: 4 additions & 0 deletions .ci/push-dockerhub.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,8 @@ if [ -z "$DOCKER_USER" -o -z "$SECRET_DOCKER_PASS" ]; then
else
cat "$SECRET_DOCKER_PASS" | docker login -u $DOCKER_USER --password-stdin
docker push ${DOCKER_NAMESPACE:-sagemath}/$1:$DOCKER_TAG

# For historical reasons, we also provide a -py3 tag. It's identical to the non-py3 tag.
docker tag ${DOCKER_NAMESPACE:-sagemath}/$1:$DOCKER_TAG ${DOCKER_NAMESPACE:-sagemath}/$1:$DOCKER_TAG-py3
docker push ${DOCKER_NAMESPACE:-sagemath}/$1:$DOCKER_TAG-py3
fi
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,4 @@ gitlab-build-docker.log

/.tox
/prefix
worktree*
40 changes: 0 additions & 40 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -193,43 +193,3 @@ push-dockerhub-dev:
script:
- . .ci/pull-gitlab.sh sagemath-dev
- sh .ci/push-dockerhub.sh sagemath-dev

.py3:
variables:
WITH_PYTHON: 3
DEFAULT_ARTIFACT_BASE: sagemath/sagemath-dev:develop-py3

build-from-latest-py3:
extends:
- build-from-latest
- .py3

build-from-clean-py3:
extends:
- build-from-clean
- .py3

test-dev-py3:
extends:
- test-dev
- .py3

test-cli-py3:
extends:
- test-cli
- .py3

test-jupyter-py3:
extends:
- test-jupyter
- .py3

push-dockerhub-py3:
extends:
- push-dockerhub
- .py3

push-dockerhub-dev-py3:
extends:
- push-dockerhub-dev
- .py3
1 change: 0 additions & 1 deletion COPYING.txt
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ sage_scripts GPLv2+
sagenb GPLv3
sagetex GPLv2+ (CC BY-SA 3.0 for included documentation)
scipy Modified BSD
scons MIT License
setuptools Python License
singular GPLv2 or GPLv3 (see below)
six MIT License
Expand Down
2 changes: 1 addition & 1 deletion VERSION.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
SageMath version 9.2.beta6, Release Date: 2020-07-25
SageMath version 9.2.beta7, Release Date: 2020-08-02
1 change: 0 additions & 1 deletion bootstrap
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,6 @@ fi
$MAKE bootstrap-clean 2>/dev/null
mkdir config 2>/dev/null

# Get autotools from our own package into PATH (Trac #21214).
# If Sage has not been built yet, this will fail due to a missing
# sage-env-config. We just ignore that error.
source src/bin/sage-env-config 2>/dev/null
Expand Down
2 changes: 1 addition & 1 deletion build/bin/sage-get-system-packages
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#! /usr/bin/env bash
#!/bin/sh
SYSTEM=$1
if [ -z "$SYSTEM" ]; then
echo >&2 "usage: $0 {debian|arch|conda|...} SPKGS..."
Expand Down
2 changes: 1 addition & 1 deletion build/bin/sage-guess-package-system
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash
#!/bin/sh
#
# First test for user-installable package systems, then system package systems
if conda --version > /dev/null 2>&1; then
Expand Down
2 changes: 1 addition & 1 deletion build/bin/sage-python23
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash
#!/bin/sh


# Run the Python interpreter that we are currently building Sage with
Expand Down
2 changes: 1 addition & 1 deletion build/bin/sage-spkg-info
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash
#!/bin/sh
#
# sage-spkg-info SPKG
# Format information about a Sage package
Expand Down
2 changes: 1 addition & 1 deletion build/bin/sage-starts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash
#!/bin/sh

# Run this test from SAGE_ROOT.
# If SAGE_ROOT is not defined (this will be the case when called from
Expand Down
4 changes: 2 additions & 2 deletions build/bin/sage-system-python
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash
#!/bin/sh

# Run the system python.
#
Expand All @@ -25,7 +25,7 @@ fi
PYTHONS="python python3 python3.8 python3.7 python2.7 python3.6 python2"
for PY in $PYTHONS; do
PYTHON="$(PATH="$SAGE_ORIG_PATH" command -v $PY)"
if [[ -n "$PYTHON" ]]; then
if [ -n "$PYTHON" ]; then
if "$PYTHON" -c 'import urllib'; then
exec "$PYTHON" "$@"
fi
Expand Down
6 changes: 3 additions & 3 deletions build/bin/sage-venv
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Adapted from examples in https://docs.python.org/3/library/venv.html

import venv
import os
import sys
import argparse

parser = argparse.ArgumentParser(prog=__name__,
Expand Down Expand Up @@ -37,8 +37,8 @@ options = parser.parse_args()
if options.upgrade and options.clear:
raise ValueError('you cannot supply --upgrade and --clear together.')

if os.name == 'nt':
# default for Windows
if sys.platform == 'cygwin':
# default for Cygwin; see https://trac.sagemath.org/ticket/30149
use_symlinks = False
else:
# default for posix
Expand Down
11 changes: 6 additions & 5 deletions build/bin/write-dockerfile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,8 @@ ADD src/doc/bootstrap src/doc/bootstrap
ADD src/bin src/bin
ADD m4 ./m4
ADD build ./build
$RUN ./bootstrap
ARG BOOTSTRAP=./bootstrap
$RUN sh -x -c "\${BOOTSTRAP}"
FROM bootstrapped as configured
#:configuring:
Expand All @@ -191,7 +192,7 @@ ARG NUMPROC=8
ENV MAKE="make -j\${NUMPROC}"
ARG USE_MAKEFLAGS="-k V=0"
ENV SAGE_CHECK=warn
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake"
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake,!networkx,!symengine_py"
#:toolchain:
$RUN make \${USE_MAKEFLAGS} base-toolchain
Expand All @@ -200,7 +201,7 @@ ARG NUMPROC=8
ENV MAKE="make -j\${NUMPROC}"
ARG USE_MAKEFLAGS="-k V=0"
ENV SAGE_CHECK=warn
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake"
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake,!networkx,!symengine_py"
#:make:
ARG TARGETS_PRE="sagelib-build-deps"
$RUN make SAGE_SPKG="sage-spkg -y -o" \${USE_MAKEFLAGS} \${TARGETS_PRE}
Expand All @@ -210,7 +211,7 @@ ARG NUMPROC=8
ENV MAKE="make -j\${NUMPROC}"
ARG USE_MAKEFLAGS="-k V=0"
ENV SAGE_CHECK=warn
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake"
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake,!networkx,!symengine_py"
ADD src src
ARG TARGETS="build"
$RUN make SAGE_SPKG="sage-spkg -y -o" \${USE_MAKEFLAGS} \${TARGETS}
Expand All @@ -220,7 +221,7 @@ ARG NUMPROC=8
ENV MAKE="make -j\${NUMPROC}"
ARG USE_MAKEFLAGS="-k V=0"
ENV SAGE_CHECK=warn
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake"
ENV SAGE_CHECK_PACKAGES="!cython,!r,!python3,!python2,!nose,!pathpy,!gap,!cysignals,!linbox,!git,!ppl,!cmake,!networkx,!symengine_py"
ARG TARGETS_OPTIONAL="ptest"
$RUN make SAGE_SPKG="sage-spkg -y -o" \${USE_MAKEFLAGS} \${TARGETS_OPTIONAL} || echo "(error ignored)"
Expand Down
62 changes: 39 additions & 23 deletions build/make/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ SCRIPT_PACKAGES = @SAGE_SCRIPT_PACKAGES@
#
# For example:
#
# inst_python2 = $(INST)/python2-$(vers_python2)
# inst_python3 = $(INST)/python3-$(vers_python3)
#
# inst_git = $(INST)/.dummy

Expand Down Expand Up @@ -360,11 +360,11 @@ _clean-broken-gcc:
# Define a function for generating the list of a package's dependencies
# as $(inst_<pkgname>) variables. For example, takes:
#
# deps_cysignals = python2 cython pari | pip
# deps_cysignals = python3 cython pari | pip
#
# to:
#
# $(inst_python2) $(inst_cython) $(inst_pari) | $(inst_pip)
# $(inst_python3) $(inst_cython) $(inst_pari) | $(inst_pip)
#
# If some value in the dependencies list is not a package name (e.g. it is
# the name of some arbitrary file, or it is the '|' symbol) then it is just
Expand All @@ -382,25 +382,35 @@ pkg_deps = \

# ============================= normal packages ==============================
# Generate build rules for 'normal' packages; this template is used to generate
# three rules in the form:
# rules in the form:
#
# $(INST)/<pkgname>-<pkgvers>: <dependencies>
# +$(AM_V_at)sage-logger -p '$(SAGE_SPKG) <pkgname>-<pkgvers>' '$(SAGE_LOGS)/<pkgname>-<pkgvers>.log'
# $(MAKE) $(1)-no-deps
#
# <pkgname>: $(INST)/<pkgname>-<pkgvers>
#
# <pkgname>-build-deps: <dependencies>
#
# <pkgname>-no-deps:
# +$(AM_V_at)sage-logger -p '$(SAGE_SPKG) <pkgname>-<pkgvers>' '$(SAGE_LOGS)/<pkgname>-<pkgvers>.log'
#
# <pkgname>-clean:
# sage-spkg-uninstall <pkgname> '$(SAGE_LOCAL)'
#
# For example, for python2 this will expand to:
# So <pkgname>-build-deps installs just the dependencies, while
# <pkgname>-no-deps tries to install the package without its
# dependencies. This is currently used in SAGE_SRC/bin/sage when
# running 'sage -b' to build the Sage library.
#
# $(INST)/python2-2.7.14: $(inst_zlib) $(inst_readline) $(inst_sqlite) $(inst_libpng) $(inst_bzip2)
# +$(AM_V_at)sage-logger -p '$(SAGE_SPKG) python2-2.7.14' '$(SAGE_LOGS)/python2-2.7.14.log'
# For example, for python3 this will expand to:
#
# python2: $(INST)/python2-2.7.14
# $(INST)/python3-3.7.3: $(inst_zlib) $(inst_readline) $(inst_sqlite) $(inst_libpng) $(inst_bzip2) $(inst_xz) $(inst_libffi)
# +$(AM_V_at)sage-logger -p '$(SAGE_SPKG) python3-3.7.3' '$(SAGE_LOGS)/python3-3.7.3.log'
#
# python2-clean:
# sage-spkg-uninstall python2 '$(SAGE_LOCAL)'
# python3: $(INST)/python3-3.7.3
#
# python3-clean:
# sage-spkg-uninstall python3 '$(SAGE_LOCAL)'
#
# Note: In these rules the $(INST)/<pkgname>-<pkgvers> target is used
# explicitly, rather than expanding the $(inst_<pkgname>) variable, since
Expand Down Expand Up @@ -428,17 +438,20 @@ SAGE_CHECK_$(1) := $(SAGE_CHECK)
$(1)-build-deps: $(3)

$$(INST)/$(1)-$(2): $(3)
$(MAKE) $(1)-no-deps

$(1): $$(INST)/$(1)-$(2)

$(1)-no-deps:
+$(AM_V_at)sage-logger -p 'SAGE_CHECK=$$(SAGE_CHECK_$(1)) $$(SAGE_SPKG) $$(SAGE_SPKG_OPTIONS) \
$(if $(filter $(1),$(TOOLCHAIN_DEPS)),--keep-existing) \
$(1)-$(2)' '$$(SAGE_LOGS)/$(1)-$(2).log'

$(1): $$(INST)/$(1)-$(2)

$(1)-clean:
sage-spkg-uninstall $(if $(filter $(1),$(TOOLCHAIN_DEPS)),--keep-files) \
$(1) '$(SAGE_LOCAL)'

.PHONY: $(1) $(1)-clean $(1)-build-deps
.PHONY: $(1) $(1)-clean $(1)-build-deps $(1)-no-deps
endef #################################################################

$(foreach pkgname, $(NORMAL_PACKAGES),\
Expand Down Expand Up @@ -494,12 +507,15 @@ define PIP_PACKAGE_templ
$(1)-build-deps: $(2)

$(1): $(2)
$(MAKE) $(1)-no-deps

$(1)-no-deps:
$(AM_V_at)sage-logger -p 'sage --pip install -r "$$(SAGE_ROOT)/build/pkgs/$(1)/requirements.txt"' '$$(SAGE_LOGS)/$(1).log'

$(1)-clean:
-sage --pip uninstall -y -r '$$(SAGE_ROOT)/build/pkgs/$(1)/requirements.txt'

.PHONY: $(1) $(1)-clean $(1)-build-deps
.PHONY: $(1) $(1)-clean $(1)-build-deps $(1)-no-deps
endef

$(foreach pkgname,$(PIP_PACKAGES),\
Expand Down Expand Up @@ -537,14 +553,17 @@ define SCRIPT_PACKAGE_templ
$(1)-build-deps: $(3)

$$(INST)/$(1)-$(2): $(3)
$(MAKE) $(1)-no-deps

$(1): $$(INST)/$(1)-$(2)

$(1)-no-deps:
$(AM_V_at)cd '$$(SAGE_ROOT)/build/pkgs/$(1)' && \
. '$$(SAGE_ROOT)/src/bin/sage-env-config' && \
. '$$(SAGE_ROOT)/src/bin/sage-env' && \
. '$$(SAGE_ROOT)/build/bin/sage-build-env-config' && \
sage-logger -p '$$(SAGE_ROOT)/build/pkgs/$(1)/spkg-install' '$$(SAGE_LOGS)/$(1)-$(2).log'
touch "$$@"

$(1): $$(INST)/$(1)-$(2)
touch "$$(INST)/$(1)-$(2)"

$(1)-uninstall:
-$(AM_V_at)cd '$$(SAGE_ROOT)/build/pkgs/$(1)' && \
Expand All @@ -554,7 +573,7 @@ $(1)-uninstall:
'$$(SAGE_ROOT)/build/pkgs/$(1)/spkg-uninstall'
-rm -f "$$(INST)/$(1)-$(2)"

.PHONY: $(1) $(1)-uninstall $(1)-build-deps
.PHONY: $(1) $(1)-uninstall $(1)-build-deps $(1)-no-deps $(1)-clean
endef

$(foreach pkgname,$(SCRIPT_PACKAGES),\
Expand All @@ -577,7 +596,4 @@ list:
done


.PHONY: $(NORMAL_PACKAGES) $(addsuffix -clean,$(NORMAL_PACKAGES)) \
$(PIP_PACKAGES) $(addsuffix -clean,$(PIP_PACKAGES)) \
$(SCRIPT_PACKAGES) $(addsuffix -clean,$(SCRIPT_PACKAGES)) \
list
.PHONY: list
15 changes: 15 additions & 0 deletions build/pkgs/cffi/SPKG.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
= cffi =

== Description ==

development website: https://foss.heptapod.net/pypy/cffi
documentation website: https://cffi.readthedocs.io/en/latest/
PyPI page: https://pypi.org/project/cffi/

== License ==

* MIT

== Upstream Contact ==

* https://foss.heptapod.net/pypy/cffi
5 changes: 5 additions & 0 deletions build/pkgs/cffi/checksums.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
tarball=cffi-VERSION.tar.gz
sha1=2a8f05a7d51d77ef1e641cb359a54e4d8fa019cb
md5=74845f8d2b7b583dd9a3574f402edf39
cksum=1594930691
upstream_url=https://pypi.io/packages/source/c/cffi/cffi-VERSION.tar.gz
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
$(PYTHON)
$(PYTHON) | $(PYTHON_TOOLCHAIN)

----------
All lines of this file are ignored except the first.
Expand Down
1 change: 1 addition & 0 deletions build/pkgs/cffi/package-version.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.14.0
1 change: 1 addition & 0 deletions build/pkgs/cffi/spkg-install.in
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
cd src && sdh_pip_install .
1 change: 1 addition & 0 deletions build/pkgs/cffi/type
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
standard
6 changes: 3 additions & 3 deletions build/pkgs/configure/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
tarball=configure-VERSION.tar.gz
sha1=eac827f97c1258cf6524a81084172a43bf7c4680
md5=bf07fb027bc4c586edf10132298fa363
cksum=546608769
sha1=450767d58fcd094130bcc0bae6a17340adde685f
md5=fc57202cf758c74e29dcf906e0287859
cksum=4241511310
2 changes: 1 addition & 1 deletion build/pkgs/configure/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
e41d396f5d30996ae515399b28675a60e97a1996
acf026331eeef4295aebdf3cdef0a0f5c2bdd19e
Loading

0 comments on commit 0bf9f36

Please sign in to comment.