aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
authorEmil Velikov <emil.l.velikov@gmail.com>2024-09-22 16:21:44 +0100
committerMario Limonciello <superm1@gmail.com>2024-10-10 14:33:32 +0000
commitee8c336ab3ab434908866c9a5e6dbbc555a80f39 (patch)
tree41839fd454d9f650002ef758eb013cf0f974ffad /Makefile
parentcc4c1fccb0d8f5ac675e16d89a1ab756da671961 (diff)
copy-firmware.sh: flesh out and fix dedup-firmware.sh
Flesh out the de-duplication logic in separate script. The copy-firmware.sh is already complex enough and de-duplication doesn't really fit in there. In the process we migrate away from the open-coded `ln --relative`. We also avoid touching symlinks, which are not created by rdfind. Otherwise we end up "fixing" the folder to folder symlinks (created earlier in the process) and things explode. As result we also get a few bonuses: - the COPYOPTS shell injection is gone - the variable was never used - people can dedup as separate step if/when they choose to do so Aside: based on the noise in git log and around distros ... I'm wondering if having the de-duplication as opt-in, would have been better. Is it too late to change or the ship has sailed? Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 5 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index ac43c97f..216dd488 100644
--- a/Makefile
+++ b/Makefile
@@ -26,21 +26,22 @@ deb:
rpm:
./build_packages.py --rpm
-install:
- install -d $(DESTDIR)$(FIRMWAREDIR)
- ./copy-firmware.sh $(COPYOPTS) $(DESTDIR)$(FIRMWAREDIR)
+install: install-nodedup
+ ./dedup-firmware.sh $(DESTDIR)$(FIRMWAREDIR)
install-nodedup:
install -d $(DESTDIR)$(FIRMWAREDIR)
- ./copy-firmware.sh --ignore-duplicates $(DESTDIR)$(FIRMWAREDIR)
+ ./copy-firmware.sh $(DESTDIR)$(FIRMWAREDIR)
install-xz:
install -d $(DESTDIR)$(FIRMWAREDIR)
./copy-firmware.sh --xz $(DESTDIR)$(FIRMWAREDIR)
+ ./dedup-firmware.sh $(DESTDIR)$(FIRMWAREDIR)
install-zst:
install -d $(DESTDIR)$(FIRMWAREDIR)
./copy-firmware.sh --zstd $(DESTDIR)$(FIRMWAREDIR)
+ ./dedup-firmware.sh $(DESTDIR)$(FIRMWAREDIR)
clean:
rm -rf release dist