From 0c9d48df9c77b58f6a88792d8d3f4da48e4a787a Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Sun, 16 Jun 2019 01:17:49 -0400 Subject: ob-buildopk: Make archive member ordering deterministic --- diff --git a/src/ob-buildopk.sh b/src/ob-buildopk.sh index da111ef..11a16d9 100644 --- a/src/ob-buildopk.sh +++ b/src/ob-buildopk.sh @@ -32,8 +32,10 @@ build_opk() "${binary}_${version}_${arch}_${plat}.opk" find "${binary}.control" "${binary}.data" | xargs touch -d "${date}" - (cd -- "${binary}.control" && tar -czf '../control.tar.gz' '.') - (cd -- "${binary}.data" && tar -czf '../data.tar.gz' '.') + (cd -- "${binary}.control" && find '.' \! -type d | LC_ALL=C sort -r | \ + tar -czf '../control.tar.gz' -T -) + (cd -- "${binary}.data" && find '.' \! -type d | LC_ALL=C sort -r | \ + tar -czf '../data.tar.gz' -T -) touch -d "${date}" 'control.tar.gz' 'data.tar.gz' tar -czf "../../${binary}_${version}_${arch}_${plat}.opk" \ -- cgit v0.9.1