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

Commit

Permalink
build/pkgs/sagelib/spkg-install: Use helper function sdh_pip_editable…
Browse files Browse the repository at this point in the history
…_install
  • Loading branch information
mkoeppe committed Sep 26, 2022
1 parent 4541564 commit 07f5cde
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion build/pkgs/sagelib/spkg-install
@@ -1,4 +1,15 @@
#!/usr/bin/env bash
# From sage-spkg.
# For type=script packages, the build rule in build/make/Makefile sources
# sage-env but not sage-dist-helpers.
lib="$SAGE_ROOT/build/bin/sage-dist-helpers"
source "$lib"
if [ $? -ne 0 ]; then
echo >&2 "Error: failed to source $lib"
echo >&2 "Is $SAGE_ROOT the correct SAGE_ROOT?"
exit 1
fi

if [ "$SAGE_EDITABLE" = yes ]; then
cd "$SAGE_SRC"
else
Expand Down Expand Up @@ -52,7 +63,7 @@ if [ "$SAGE_EDITABLE" = yes ]; then
# and renamed the distribution to "sagemath-standard"). There is no clean way to uninstall
# them, so we just use rm.
(cd "$SITEPACKAGESDIR" && rm -rf sage sage_setup sage-[1-9]*.egg-info sage-[1-9]*.dist-info)
time python3 -m pip install --verbose --no-deps --no-index --no-build-isolation --isolated --editable . || exit 1
time sdh_pip_editable_install .
else
# Make sure that an installed old version of sagelib in which sage is an ordinary package
# does not shadow the namespace package sage during the build.
Expand Down

0 comments on commit 07f5cde

Please sign in to comment.