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

Commit

Permalink
sage-sdist: don't require sage to be built
Browse files Browse the repository at this point in the history
  • Loading branch information
ohanar committed Dec 30, 2013
1 parent 68ac77f commit 43b696f
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
6 changes: 4 additions & 2 deletions build/deps
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,9 @@ $(INST)/sage: \
$(INST)/$(SYMMETRICA) \
$(INST)/$(ZNPOLY) \
$(INST)/csage
if [ -z "$$SAGE_INSTALL_FETCH_ONLY" ]; then \
if [ -n "$$SAGE_CLONE_TARGET" ]; then \
$(SAGE_SRC)/bin/sage-clone-source "$(SAGE_ROOT)" "$$SAGE_CLONE_TARGET"; \
else \
cd $(SAGE_SRC) && source bin/sage-env && \
$(PIPE) 'time python setup.py install 2>&1' 'tee -a $(SAGE_LOGS)/sage-$(SAGE_VERSION).log' && \
touch $@; \
Expand All @@ -471,7 +473,7 @@ $(INST)/csage: $(INST)/$(SCONS) \
$(INST)/$(POLYBORI) \
$(INST)/$(PYNAC) \
$(INST)/$(PYTHON)
if [ -z "$$SAGE_INSTALL_FETCH_ONLY" ]; then \
if [ -z "$$SAGE_CLONE_TARGET" ]; then \
cd $(SAGE_SRC) && source bin/sage-env && cd c_lib && \
$(PIPE) 'time scons -Q install 2>&1' 'tee -a $(SAGE_LOGS)/csage-$(SAGE_VERSION).log' && \
touch $@; \
Expand Down
8 changes: 8 additions & 0 deletions build/install
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,14 @@ mkdir -p "$SAGE_LOCAL/lib"
mkdir -p "$SAGE_SPKG_INST"
mkdir -p "$SAGE_SHARE"

#######################################################################
# Setup cloning variables if SAGE_CLONE_TARGET is set
#######################################################################

if [ -n "$SAGE_CLONE_TARGET" -a -z "$SAGE_SPKG_COPY_UPSTREAM" ]; then
export SAGE_SPKG_COPY_UPSTREAM="$SAGE_CLONE_TARGET/upstream"
fi

###############################################################################
# Determine whether to install GCC (gcc, g++, gfortran).
###############################################################################
Expand Down
3 changes: 1 addition & 2 deletions src/bin/sage-sdist
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,11 @@ source "$SAGE_SRC/bin/sage-version.sh"
echo "Sage version $SAGE_VERSION, release date $SAGE_RELEASE_DATE"

TARGET="sage-$SAGE_VERSION"
sage-clone-source "$SAGE_ROOT" "$TMP_DIR/$TARGET"

# Download and copy all upstream tarballs (the -B option to make forces
# all targets to be built unconditionally)
cd "$SAGE_ROOT/build"
SAGE_INSTALL_GCC=yes SAGE_SPKG_OPTS="-f -d" SAGE_SPKG_COPY_UPSTREAM="$TMP_DIR/$TARGET/upstream" ./install -B all
SAGE_INSTALL_GCC=yes SAGE_SPKG_OPTS="-f -d" SAGE_CLONE_TARGET="$TMP_DIR/$TARGET" ./install -B all

# Create source .tar.gz
cd "$TMP_DIR"
Expand Down

0 comments on commit 43b696f

Please sign in to comment.