09/05/23 11:47, Duncan Roe <[email protected]>: > On Mon, May 08, 2023 at 08:02:42AM +0200, Didier Spaier wrote: > > Le 08/05/2023 à 06:29, Franzen via SlackBuilds-users a écrit : > > > The find -L ... on this sources takes forever on my old hardware, and > > > spits > > > thousand > > > "chmod: cannot operate on dangling symlink > > > './links/22/actions/fileview-preview.svg" > > > I changed it to > > > chmod -R u+w,go-w,a+rX-st . > > > and it's ready under one second. > > > > > > There are also some duplicate files(not much, but anyway), to replace > > > them by > > > symlinks i added: > > > LASTSIZE=x > > > find $PKG -type f -printf '%s %p\n' | sort -n | > > > while read -r SIZE FILE; do > > > # symlinks alse need some bytes, don't link under 10 bytes > > > if [ "$SIZE" -gt 10 -a "$SIZE" == "$LASTSIZE" ]; then > > > if [ "$(sha512sum $FILE | cut -d' ' -f1)" \ > > > == "$(sha512sum $LASTFILE | cut -d' ' -f1)" ] ; then > > > ln -srf $FILE $LASTFILE > > > fi > > > fi > > > LASTSIZE="$SIZE"; LASTFILE="$FILE" > > > done > > > > Thanks Johannes, I will take your changes. > > > > As an aside, I included this package in Slint so users be able to add > > XFCE-4.18 > > as packaged by George Vlahavas in > > http://slackware.uk/salix/x86_64/xfce4.18-15.0/ (with the same look) trying > > just > > this command: > > slapt-get --install-set xfce > > > > Cheers, > > Didier > > > I'm a little concerned by the comment > > "symlinks alse need some bytes, don't link under 10 bytes" > > Files occupy a multiple of 4K bytes. So replacing a 1-byte file with a symlink > will usually save 4KB. Occasionally it will bump the directory size by 4KB so > there is no saving. > > I suggest symlinking should be unconditional. > > Cheers ... Duncan.
Isn't this is more about source code that contain symlinks with non-existent endpoints and file system loops? In our case, when we changed modes and ownership of files in a directory it really makes no difference to follow a symlink to a file/directory that the find command will eventually come to anyway (if the target is inside the source tarball). I can't see a problem with leaving out the -L myself, but perhaps I'm missing something? Dave -- sbo-maintainer-tools (sbolint, sbopkglint): https://slackbuilds.org/repository/15.0/system/sbo-maintainer-tools/ SBo templates: https://slackbuilds.org/templates/ How to format github downloads: https://slackbuilds.org/GITHUB_URLs.txt _______________________________________________ SlackBuilds-users mailing list [email protected] https://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users Archives - https://lists.slackbuilds.org/pipermail/slackbuilds-users/ FAQ - https://slackbuilds.org/faq/
