Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to devel-sobukus-protection sorcery by Thomas Orgis (382d44ed11f8c8c17ebe61f7235c032ebc331161)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Thomas Orgis <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to devel-sobukus-protection sorcery by Thomas Orgis (382d44ed11f8c8c17ebe61f7235c032ebc331161)
  • Date: Fri, 26 Feb 2021 10:25:29 +0000

GIT changes to devel-sobukus-protection sorcery by Thomas Orgis
<sobukus AT sourcemage.org>:

var/lib/sorcery/modules/libmisc | 13 +++----------
1 file changed, 3 insertions(+), 10 deletions(-)

New commits:
commit 784a08be310d9a3fce44d1268d6fc46f174ce159
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

protected: also /bin/login, got bitten by failed shadow install

commit 74ed077db053356600153abbf7c45468881710ef
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libdepengine: more avoidance of casts after failures

commit c6f61b20e1b009fdfe1da4aee8693318aea53e99
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libgrimoire: half of RAM as default size of TMPFS source directories

commit 66ea29759e0c1334957726148fcdcc6cb2a83864
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

protected: egrep is needed in sorcery itself, even, but also installs

commit c52445632ca1b83d97321fb1ba2e505b2b51cf7d
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libdepengine: add short cut for grey dependency loops

The repeated dive into the same branches of the dependency tree
can be very wasteful. Lots of calls to recurse_depends can be
avoided when it is already known that a spell recursion will
turn up aborted because of a dependency loop (grey dependency).

This assumes that the situation only possibly changes when a spell
is actually cast.

I am not sure if my analysis is correct. I had the rather fatal
situation of a sorcery rebuild spinning for hours in a rendering
of dependency hell trying to decide what to build next after some
successful initial casts. This patch avoids that situation at least.

I also for some time whitnessed an immense delay on removing dependees
of a failed spell. I am not sure if this is now gone or could still
reappear. The whole dependency engine needs an overhaul in all its
wastefulness.

commit 05a3dfd2476691b32c9dcffe887484cb1d0ed61d
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libdepengine: more debugging

commit b8ecf56135e4eaff52d14e36c8dbbf0f88a0884d
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libmisc: more robust debugging of parallel work

This prints out the whole debugging line on one go to reduce interference
of printouts from multiple sorcery processes (subshells for cast passes).
Debugging is a nightmare when data within a line is already interleaved!
This is still not proper, but we don't want to bring things to a crawl by
i/o locking. An alternative might be to write output to per-process files.
But then, we also should implement timestamps in the output. Pro-tip: use
ts from moreutils in a tail -f | ts configuration to put them on closely
after the fact.

Also, to actually tell the differing subshells of the cast process apart,
the variable $$ is not enough. Bash offers an alternative. This is used
with $$ as fallback now. We may want to check what to do for other shells
that we want to be able to run sorcery properly.

commit 23c1c2d3fcae3654c2c771f73ca4b8f071992e47
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

cast: more debugging, tell differing subshells apart

commit 61a40fb20a2112cea8b9caa5dfc9c3aef92c5966
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

Revert "libmisc: Implement one-shot specfile selection"

This reverts commit 615b00c28da7e62b0b31098b0229b0f9a04de0d2.

This broke things by not setting specdir appropriately, causing
later attempts to fix that. Those attempts break for differing
arch selections as they are not all in the same path depth.

We shall never guess specdir after the fact. Use the values
we know!

commit 8337a25a5a7620b5703077bca9fb3019382c23d0
Author: Thomas Orgis <sobukus AT sourcemage.org>
Commit: Thomas Orgis <sobukus AT sourcemage.org>

libdispel, dispel, resurrect: optionally protect files

This is the first proof of concept of preserving library files from
old spell versions. The current case for me is gcc being broken after
isl update, and hence full stop on any magic.

This only works for manual invocation of dispel/resurrect right now. The
idea is to add a variable PROTECT_FILES to DETAILS that triggers
the protection.

diff --git a/var/lib/sorcery/modules/libmisc b/var/lib/sorcery/modules/libmisc
index 2157ecc..cbc09cd 100755
--- a/var/lib/sorcery/modules/libmisc
+++ b/var/lib/sorcery/modules/libmisc
@@ -1499,16 +1499,9 @@ set_architecture() {
fi
debug "libmisc" "set_architecture: SPECFILE=$SPECFILE"

- # turn the path into an array, removing the spec dir prefix
- SMGL_COMPAT_ARCHS=($(awk -F/ -vdirs="^${ARCH_SPECS[*]}/" -vf="$SPECFILE" '
- BEGIN {
- sub(/[/]* +/, "/|^", dirs) # convert to regex
- match(f, dirs)
- f = substr(f, RLENGTH) # remove prefix
- gsub(/[/]+/, " ", f) # split
- print f
- }'))
- debug "libmisc" "set_architecture:
SMGL_COMPAT_ARCHS[${#SMGL_COMPAT_ARCHS[@]}]=(${SMGL_COMPAT_ARCHS[*]})"
+ # turn the path into an array, but remove $specdir from the start first
+ unset SMGL_COMPAT_ARCHS
+ explode "${SPECFILE#$specdir/}" '/' SMGL_COMPAT_ARCHS

# Reverse the array so that the most specific arch is first
ARCHITECTURE=($(awk 'BEGIN { while (--ARGC > 0) print ARGV[ARGC] }' \



  • [SM-Commit] GIT changes to devel-sobukus-protection sorcery by Thomas Orgis (382d44ed11f8c8c17ebe61f7235c032ebc331161), Thomas Orgis, 02/26/2021

Archive powered by MHonArc 2.6.24.

Top of Page