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

Commit

Permalink
Merge remote-tracking branch 'trac/develop' into ticket/15148
Browse files Browse the repository at this point in the history
Conflicts:
	src/sage/schemes/hyperelliptic_curves/hyperelliptic_finite_field.py
  • Loading branch information
Jean-Pierre Flori committed Mar 6, 2014
2 parents 63bf717 + ccab985 commit 8029bc6
Show file tree
Hide file tree
Showing 1,606 changed files with 154,604 additions and 79,267 deletions.
61 changes: 61 additions & 0 deletions .gitignore
Expand Up @@ -4,3 +4,64 @@
/local
/logs
/upstream

#############################
# Autotools generated files #
#############################
/aclocal.m4
/autom4te.cache/
/config/
/config.log
/config.status
/configure
/build/Makefile-auto
/build/Makefile-auto.in

###################
# Temporary Files #
###################

# Various editors
*~

# Emacs
\#*\#
.\#*

# Vim
*.s[a-w][a-z]
*.un~
.netrwhist

# PyCharm
.idea
.iml

# Eclipse
*.pydevproject
.project
.metadata
*.tmp
*.bak
*.swp
*~.nib
.classpath
.settings/
.loadpath
.externalToolBuilders/
.cproject
.buildpath

# OSX specific temporary files
.DS_Store
._*
.AppleDouble
.LSOverride
.Spotlight-V100
.Trashes

# Windows
$RECYCLE.BIN/

# SublimeText
*.sublime-workspace
2 changes: 2 additions & 0 deletions COPYING.txt
Expand Up @@ -88,6 +88,8 @@ pari GPLv2+
patch GPLv2+
pexpect Python License
pil Similar to MIT and modified BSD (see below)
pkgconf ISC License (equivalent to Simplified BSD)
pkgconfig MIT License
polybori GPLv2+
polytopes_db None (database)
ppl GPLv3+
Expand Down
31 changes: 26 additions & 5 deletions Makefile
Expand Up @@ -9,18 +9,25 @@

PIPE = build/pipestatus


all: start doc # indirectly depends on build

logs:
mkdir -p $@

build: logs
cd build && \
build: logs configure
+cd build && \
"../$(PIPE)" \
"env SAGE_PARALLEL_SPKG_BUILD='$(SAGE_PARALLEL_SPKG_BUILD)' ./install all 2>&1" \
"tee -a ../logs/install.log"
./sage -b

# Preemptively download all standard upstream source tarballs.
download:
export SAGE_ROOT=$$(pwd) && \
export PATH=$$SAGE_ROOT/src/bin:$$PATH && \
./src/bin/sage-download-upstream

# ssl: build Sage, and also install pyOpenSSL. This is necessary for
# running the secure notebook. This make target requires internet
# access. Note that this requires that your system have OpenSSL
Expand Down Expand Up @@ -76,13 +83,24 @@ bdist-clean: clean
rm -rf logs
rm -rf dist
rm -rf tmp
rm -f build/Makefile
rm -f aclocal.m4 config.log config.status confcache
rm -rf autom4te.cache
rm -f build/Makefile build/Makefile-auto
rm -f .BUILDSTART

distclean: clean doc-clean lib-clean bdist-clean
@echo "Deleting all remaining output from build system ..."
rm -rf local

# Delete all auto-generated files which are distributed as part of the
# source tarball
bootstrap-clean:
rm -rf config configure build/Makefile-auto.in

# Remove absolutely everything which isn't part of the git repo
maintainer-clean: distclean bootstrap-clean
rm -rf upstream

micro_release: bdist-clean lib-clean
@echo "Stripping binaries ..."
LC_ALL=C find local/lib local/bin -type f -exec strip '{}' ';' 2>&1 | grep -v "File format not recognized" | grep -v "File truncated" || true
Expand Down Expand Up @@ -134,6 +152,9 @@ ptestoptional: ptestall # just an alias

ptestoptionallong: ptestalllong # just an alias

configure: configure.ac src/bin/sage-version.sh \
m4/ax_c_check_flag.m4 m4/ax_gcc_option.m4 m4/ax_gcc_version.m4 m4/ax_gxx_option.m4 m4/ax_gxx_version.m4 m4/ax_prog_perl_version.m4
./bootstrap -d

install:
echo "Experimental use only!"
Expand All @@ -154,8 +175,8 @@ install:
"$(DESTDIR)"/bin/sage -c # Run sage-location


.PHONY: all build build-serial start install \
.PHONY: all build build-serial start install micro_release \
doc doc-html doc-html-jsmath doc-html-mathjax doc-pdf \
doc-clean clean lib-clean bdist-clean distclean micro_release \
doc-clean clean lib-clean bdist-clean distclean bootstrap-clean maintainer-clean \
test check testoptional testall testlong testoptionallong testallong \
ptest ptestoptional ptestall ptestlong ptestoptionallong ptestallong
23 changes: 17 additions & 6 deletions README.txt
Expand Up @@ -75,12 +75,23 @@ Installation Guide:
"Precise"), you need the dpkg-dev package.

OS X: Xcode. Make sure you have installed the most recent version
of Xcode. For pre-Lion versions of OS X, you can download Xcode
from http://developer.apple.com/downloads/. For OS X Lion, you can
install it using the App Store. With Xcode 4.3 or later, you need
to install the "Command Line Tools": from the File menu, choose
"Preferences", then the "Downloads" tab, and then "Install" the
Command Line Tools.
of Xcode. With recent versions of OS X (OS X Lion or later), you
can install Xcode for free from the App Store. For pre-Lion
versions of OS X, you can download Xcode from
http://developer.apple.com/downloads/.

With OS X, you also need to install the "command line tools". When
using OS X Mavericks, after installing Xcode, run this command from
a terminal window:

xcode-select --install

Then click "Install" in the pop-up window.

When using OS X Mountain Lion or earlier, you need to install the
command line tools from Xcode: run Xcode; then from the File
menu, choose "Preferences", then the "Downloads" tab, and then
"Install" the Command Line Tools.

Other platforms: See detailed instructions below.

Expand Down
2 changes: 1 addition & 1 deletion VERSION.txt
@@ -1 +1 @@
Sage version 5.12.beta5, released 2013-09-06
Sage version 6.2.beta3, released 2014-03-03
133 changes: 133 additions & 0 deletions bootstrap
@@ -0,0 +1,133 @@
#!/usr/bin/env bash

########################################################################
# Regenerate auto-generated files (e.g. configure)
#
# If the -s option is given, save the autogenerated scripts in
# $SAGE_ROOT/upstream/configure-$CONFVERSION.tar.gz where CONFVERSION
# is the version number stored in
# build/pkgs/configure/package-version.txt
#
# If optional argument -i is given, then automatically increment the
# version number.
#
# If optional argument -d is given and bootstrapping failed, instead
# extract the files from a local configure tarball, downloading it if
# needed. If -D is given, don't try to bootstrap and always extract or
# donwload.
########################################################################

# Either run this script from SAGE_ROOT or make sure that SAGE_ROOT
# is set
test -z "$SAGE_ROOT" || cd "$SAGE_ROOT"

PKG=build/pkgs/configure
MAKE="${MAKE:-make}"
CONFVERSION=`cat $PKG/package-version.txt`

bootstrap () {
aclocal -I m4 && \
automake --add-missing --copy build/Makefile-auto && \
autoconf

st=$?
case $st in
0) true;; # Success

63|127) # Autotools not installed or version too old
if [ $DOWNLOAD = yes ]; then
echo >&2 "Bootstrap failed, downloading required files instead."
bootstrap-download || exit $?
else
if [ $st -eq 127 ]; then
verb="install"
else
verb="upgrade"
fi
echo >&2 "Bootstrap failed. Either $verb autotools or run bootstrap with"
echo >&2 "the -d option to download the auto-generated files instead."
exit $st
fi;;

*) exit $st;; # Failure
esac
}

# Bootstrap by downloading the auto-generated files
bootstrap-download () {
source src/bin/sage-env

mkdir upstream 2>/dev/null
if [ ! -f $CONFBALL ]; then
sage-download-file $SAGE_UPSTREAM/configure/configure-$CONFVERSION.tar.gz >$CONFBALL
if [ $? -ne 0 ]; then
rm -f "$CONFBALL"
echo >&2 "Error: downloading configure-$CONFVERSION.tar.gz failed"
exit 1
fi
fi

# The "m" option to tar ensures that timestamps are set to the
# current time, not taken from the tarball.
# We need these files to be more recent than the input files
# like configure.ac, otherwise "make" gets confused.
tar xzmf $CONFBALL || exit $?
}

save () {
set -e

# Create configure tarball
echo "Creating $CONFBALL..."
mkdir -p upstream
tar zcf "$CONFBALL" configure config/* build/Makefile-auto.in

# Update version number
echo "$CONFVERSION" >$PKG/package-version.txt

# Compute checksum
SAGE_ROOT=. src/bin/sage-fix-pkg-checksums "$CONFBALL"
}


usage () {
echo >&2 "Usage: $0 [-d|-D|-s] [-i] [-h]"
}


# Parse options
SAVE=no
DOWNLOAD=no
ALWAYSDOWNLOAD=no
while getopts "Ddsih" OPTION
do
case "$OPTION" in
D) ALWAYSDOWNLOAD=yes; DOWNLOAD=yes;;
d) DOWNLOAD=yes;;
s) SAVE=yes;;
i) CONFVERSION=$(( CONFVERSION + 1 ));;
h) usage; exit 0;;
?) usage; exit 2;;
esac
done
CONFBALL="upstream/configure-$CONFVERSION.tar.gz"

if [ $DOWNLOAD$SAVE = yesyes ]; then
echo >&2 "$0: refusing to download and save."
usage
exit 2
fi

# Start cleanly (it's not a problem if this fails)
$MAKE bootstrap-clean 2>/dev/null
mkdir config 2>/dev/null

if [ $ALWAYSDOWNLOAD = yes ]; then
bootstrap-download || exit $?
else
bootstrap
fi

if [ $SAVE = yes ]; then
save
fi
2 changes: 2 additions & 0 deletions build/Makefile-auto.am
@@ -0,0 +1,2 @@
# Currently, this file is unused. However, it needs to exist to coerce
# automake into thinking that this is an Automake project.

0 comments on commit 8029bc6

Please sign in to comment.