feat: further improvement of the build and compress script

This commit is contained in:
2025-09-08 12:20:41 +02:00
parent dbca360da2
commit a2ba43fe79

View File

@@ -1,7 +1,12 @@
#!/bin/bash #!/bin/bash
cd build cd build
cmake --build . cmake --build .
echo "dd bs=1 skip=61<\$0|unlzma>/tmp/C;chmod +x /tmp/C;/tmp/C;exit" > two CMD="#!/bin/bash
dd bs=1 skip=%s<\$0|unlzma>/tmp/C;chmod +x /tmp/C;trap '' HUP;/tmp/C&"
COUNT=$(printf "$CMD" | wc -c)
EXTRA=$(printf "$COUNT" | wc -c)
COUNT=$((COUNT + EXTRA + 1))
echo "$CMD" | sed 's/%s/'"$COUNT"'/' > two
chmod +x two chmod +x two
sstrip one sstrip one
lzma -9 one lzma -9 one