Skip to content

Commit 340cf1e

Browse files
author
Release Manager
committed
gh-36839: Remove most `spkg-legacy-uninstall` scripts <!-- ^^^^^ Please provide a concise, informative and self-explanatory title. Don't put issue numbers in there, do this in the PR body below. For example, instead of "Fixes #1234" use "Introduce new method to calculate 1+1" --> <!-- Describe your changes here in detail --> Most normal SPKGs are installed by staging in `DESTDIR`. When copying to the final install location in `SAGE_LOCAL`, an installation record is created, which is used later in package uninstallation. However, when SPKG installation was switched to using staging in `DESTDIR` (Meta-ticket #24024), the parts of `spkg-install` scripts that used to be responsible for removing an old version of the installed package were either kept in place or moved to `spkg-legacy-uninstall` scripts. This was done to enable incremental builds from older installations. By passage of time, this is no longer needed. Some of the removals are a partial cherry-pick from #25140 by @embray. We also switch `frobby` to `DESTDIR` staging and *add* an `spkg-legacy- uninstall` script. Resolves #25140. Resolves #30480. <!-- Why is this change required? What problem does it solve? --> <!-- If this PR resolves an open issue, please link to it here. For example "Fixes #12345". --> <!-- If your change requires a documentation PR, please link it appropriately. --> ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> <!-- If your change requires a documentation PR, please link it appropriately --> <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> <!-- Feel free to remove irrelevant items. --> - [x] The title is concise, informative, and self-explanatory. - [x] The description explains in detail what this PR is about. - [x] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation accordingly. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on - #12345: short description why this is a dependency - #34567: ... --> - Depends on #36778 (merged here to resolve merge conflict) <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> URL: #36839 Reported by: Matthias Köppe Reviewer(s): Dima Pasechnik
2 parents 4adecd8 + d8dd0ec commit 340cf1e

37 files changed

+6
-245
lines changed

build/pkgs/boost_cropped/spkg-legacy-uninstall

Lines changed: 0 additions & 2 deletions
This file was deleted.

build/pkgs/brial/spkg-legacy-uninstall

Lines changed: 0 additions & 5 deletions
This file was deleted.

build/pkgs/cvxopt/spkg-install.in

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,6 @@ sdh_pip_install .
8282

8383
if [ "x$SAGE_SPKG_INSTALL_DOCS" = xyes ] ; then
8484
cd doc
85-
# checking to see if there is previously installed documentation.
86-
if [ -d $SAGE_LOCAL/share/doc/cvxopt/html ] ; then
87-
rm -rf $SAGE_LOCAL/share/doc/cvxopt/html
88-
fi
8985
mkdir -p "${SAGE_DESTDIR}${SAGE_LOCAL}/share/doc/cvxopt/html"
9086
cp -r html/* "${SAGE_DESTDIR}${SAGE_LOCAL}/share/doc/cvxopt/html/"
9187
fi

build/pkgs/ecl/spkg-legacy-uninstall

Lines changed: 0 additions & 6 deletions
This file was deleted.

build/pkgs/eclib/spkg-install.in

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,6 @@ CXXFLAGS="$CXXFLAGS_O3_NON_NATIVE"
33

44
export CFLAGS CXXFLAGS
55

6-
7-
echo "Deleting old versions of eclib libraries, which"
8-
echo "would interfere with new builds..."
9-
# Delete any pre-autotools libraries:
10-
rm -f "$SAGE_LOCAL"/lib/lib{curvesntl,g0nntl,jcntl,rankntl,mwrank}.*
11-
# Delete autotools libraries:
12-
rm -f "$SAGE_LOCAL"/lib/lib{e,j}c.*
13-
echo "Deleting old include directory..."
14-
rm -rf "$SAGE_LOCAL"/include/eclib/
15-
16-
176
cd src/
187

198
#############################################################

build/pkgs/ecm/spkg-install.in

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -232,17 +232,6 @@ sdh_configure $SAGE_CONFIGURE_GMP $ECM_CONFIGURE
232232

233233
sdh_make
234234

235-
###############################################################################
236-
# Remove old executable/header/libraries/manpage:
237-
###############################################################################
238-
239-
echo
240-
echo "Build succeeded. Now removing old binary, header file, manual page and libraries..."
241-
rm -f "$SAGE_LOCAL"/bin/ecm
242-
rm -f "$SAGE_LOCAL"/lib/libecm.*
243-
rm -f "$SAGE_LOCAL"/include/ecm.h
244-
rm -f "$SAGE_LOCAL"/share/man/man1/ecm.1
245-
246235
###############################################################################
247236
# Now install ECM:
248237
###############################################################################

build/pkgs/fplll/spkg-install.in

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,3 @@ export CXX="$CXX"
2222
sdh_configure $CONFIGUREFLAGS
2323
sdh_make
2424
sdh_make_install
25-
26-
# Pretend that the "libfplll" package is not installed. This is needed to
27-
# support renaming libfplll -> fplll done on Trac #24042
28-
rm -f "$SAGE_SPKG_INST/"libfplll-*

build/pkgs/freetype/spkg-install.in

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,3 @@ cd src
44
GNUMAKE=${MAKE} sdh_configure --enable-freetype-config $FREETYPE_CONFIGURE
55
sdh_make
66
sdh_make_install
7-
8-
# The following file may be present from old builds of freetype, and
9-
# its presence can break the matplotlib build. So remove it. (The
10-
# current version is $SAGE_LOCAL/include/freetype2/ftbuild.h.)
11-
12-
rm -f "$SAGE_LOCAL/include/ft2build.h"

build/pkgs/frobby/spkg-install.in

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
rm -rf "$SAGE_LOCAL/bin/frobby"
21

32
GMP_INC_DIR="$SAGE_LOCAL/include"; export GMP_INC_DIR
43
ldflags="-Wl,-rpath,$SAGE_LOCAL/lib -L$SAGE_LOCAL/lib/ -lgmpxx -lgmp"; export ldflags
@@ -12,14 +11,4 @@ if [ $? -ne 0 ]; then
1211
exit 1
1312
fi
1413

15-
if [ ! -f bin/release/frobby ]; then
16-
echo "Frobby executable not found."
17-
exit 1
18-
fi
19-
20-
$CP bin/release/frobby "$SAGE_LOCAL/bin/"
21-
22-
if [ ! -f "$SAGE_LOCAL/bin/frobby" ]; then
23-
echo "Frobby executable not copied."
24-
exit 1
25-
fi
14+
sdh_install bin/release/frobby "$SAGE_LOCAL/bin"
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/usr/bin/env bash
2+
rm -f "$SAGE_LOCAL/bin/frobby"

0 commit comments

Comments
 (0)