Skip to content

Commit

Permalink
Trac #30947: src/doc/bootstrap: Simplify by using new options of "sag…
Browse files Browse the repository at this point in the history
…e -package list"

URL: https://trac.sagemath.org/30947
Reported by: mkoeppe
Ticket author(s): Matthias Koeppe
Reviewer(s): Sébastien Labbé
  • Loading branch information
Release Manager committed Dec 14, 2020
2 parents 831e4e2 + 084fbf6 commit 2fc350e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 22 deletions.
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=9630148997eadc90f50a99bc8902d9759cd63d4d
md5=c73af26d82eac1af9725ca780e650ebb
cksum=78369567
sha1=8ecca12a12bf8706ec8409cfbc732f028ac80b9d
md5=b96290622ae27430c92385b38a20c172
cksum=3364064440
2 changes: 1 addition & 1 deletion build/pkgs/configure/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3290413be62de2cc4b8568c058ffe33b05acca0b
032dca1061966a9ebcc4950d4b9d5aad0862b52b
24 changes: 6 additions & 18 deletions src/doc/bootstrap
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,10 @@ for SYSTEM in arch debian fedora cygwin homebrew conda; do
SAGELIB_SYSTEM_PACKAGES=
SAGELIB_OPTIONAL_SYSTEM_PACKAGES=
RECOMMENDED_SYSTEM_PACKAGES=
for PKG_SCRIPTS in build/pkgs/*; do
if [ -d $PKG_SCRIPTS ]; then
PKG_BASE=$(basename $PKG_SCRIPTS)
SYSTEM_PACKAGES_FILE=$PKG_SCRIPTS/distros/$SYSTEM.txt
if [ ! -f $PKG_SCRIPTS/type ]; then
echo >&2 "Warning: $PKG_SCRIPTS/type is missing."
continue
fi
PKG_TYPE=$(cat $PKG_SCRIPTS/type)
if [ -f $SYSTEM_PACKAGES_FILE ]; then
for PKG_BASE in $(./sage --package list --has-file distros/$SYSTEM.txt); do
PKG_SCRIPTS=build/pkgs/$PKG_BASE
SYSTEM_PACKAGES_FILE=$PKG_SCRIPTS/distros/$SYSTEM.txt
PKG_TYPE=$(cat $PKG_SCRIPTS/type)
PKG_SYSTEM_PACKAGES=$(echo $(${STRIP_COMMENTS} $SYSTEM_PACKAGES_FILE))
if [ -n "PKG_SYSTEM_PACKAGES" ]; then
if [ -f $PKG_SCRIPTS/spkg-configure.m4 ]; then
Expand All @@ -66,8 +60,6 @@ for SYSTEM in arch debian fedora cygwin homebrew conda; do
esac
fi
fi
fi
fi
done
if [ "${SYSTEM}" = "conda" ]; then
if [ "${BOOTSTRAP_QUIET}" = "no" ]; then
Expand Down Expand Up @@ -120,16 +112,12 @@ External Packages
:maxdepth: 1
EOF
for PKG_SCRIPTS in build/pkgs/*; do
if [ -d "$PKG_SCRIPTS" ]; then
PKG_BASE=$(basename "$PKG_SCRIPTS")
if [ -f "$PKG_SCRIPTS"/SPKG.rst ]; then
for PKG_BASE in $(./sage --package list --has-file SPKG.rst); do
PKG_SCRIPTS=build/pkgs/$PKG_BASE
# Instead of just copying, we may want to call
# a version of sage-spkg-info to format extra information.
cp "$PKG_SCRIPTS"/SPKG.rst "$OUTPUT_DIR"/$PKG_BASE.rst
echo >> "$OUTPUT_INDEX" " $PKG_BASE"
fi
fi
done
cat >> "$OUTPUT_INDEX" <<EOF
.. include:: ../footer.txt
Expand Down

0 comments on commit 2fc350e

Please sign in to comment.