diff --git a/deepin-wine-easy-packager.py b/deepin-wine-easy-packager.py index d3d053c..36f2118 100755 --- a/deepin-wine-easy-packager.py +++ b/deepin-wine-easy-packager.py @@ -589,7 +589,7 @@ class RunThread(QtCore.QThread): self.RunCommand(f"rm -fv '{bottlePath}/drive_c/users/@current_user@/Downloads'") self.RunCommand(f"rm -fv '{bottlePath}/drive_c/users/@current_user@/Templates'") ########### 打包容器 - self.RunCommand(f"7z a '{bottlePackagePath}' '{bottlePath}/'*") + self.RunCommand(f"7z a -snh -snl '{bottlePackagePath}' '{bottlePath}/'*") ########### 生成文件内容 buildProgramSize = getFileFolderSize(debBuildPath) / 1000 replaceMap = [ diff --git a/deepin-wine-packager.py b/deepin-wine-packager.py index e7e7227..4ac69e7 100755 --- a/deepin-wine-packager.py +++ b/deepin-wine-packager.py @@ -215,9 +215,9 @@ def Build7z(b, self, debInformation, debPackagePath): os.system(f"cp -rv '{b}' '{debPackagePath}/opt/cxoffice/support/{e5_text.text()}'") return if debPackagePath[-3: ] == ".7z": - self.run_command("7z a '{}' '{}/'*".format(debPackagePath, b)) + self.run_command("7z a -snh -snl '{}' '{}/'*".format(debPackagePath, b)) else: - self.run_command("7z a {}/opt/apps/{}/files/files.7z '{}/'*".format(debPackagePath, e1_text.text(), b)) + self.run_command("7z a -snh -snl {}/opt/apps/{}/files/files.7z '{}/'*".format(debPackagePath, e1_text.text(), b)) def Build7zButton_Clicked(): @@ -1514,7 +1514,7 @@ fi # 都有了为什么要打包呢? shutil.copy(wine[wineVersion.currentText()], f"{debPackagePath}/opt/apps/{e1_text.text()}/files/wine_archive.7z") else: - self.run_command(f"7z a '{debPackagePath}/opt/apps/{e1_text.text()}/files/wine_archive.7z' '{wine[wineVersion.currentText()]}/*'") + self.run_command(f"7z a -snh -snl '{debPackagePath}/opt/apps/{e1_text.text()}/files/wine_archive.7z' '{wine[wineVersion.currentText()]}/*'") ############### # 复制文件 ############### diff --git a/package-script/script-packager.sh b/package-script/script-packager.sh index 8ec58a7..301b24d 100755 --- a/package-script/script-packager.sh +++ b/package-script/script-packager.sh @@ -150,10 +150,10 @@ checkWineDepends() cp /usr/lib/i386-linux-gnu/deepin-wine/gtkGetFileNameDlg "$outfiles" - 7z a -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/wine_archive.7z" /usr/lib/i386-linux-gnu/deepin-wine5-stable/* + 7z a -snh -snl -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/wine_archive.7z" /usr/lib/i386-linux-gnu/deepin-wine5-stable/* echo "$WINELIBVER" > "$outfiles/wine_archive.md5sum" - 7z a -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/helper_archive.7z" /opt/deepinwine/tools/* + 7z a -snh -snl -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/helper_archive.7z" /opt/deepinwine/tools/* echo "$WINEHELPERVER" > "$outfiles/helper_archive.md5sum" } @@ -279,7 +279,7 @@ else ls -l "$stgdir/winx/extensions.so" fi - 7z a -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/files.7z" "$stgdir/*" + 7z a -snh -snl -t7z -mx=9 -ms=on -mmt=on -m0=BCJ2 -m1=LZMA2:d=64m:fb=273 "$outfiles/files.7z" "$stgdir/*" fi md5sum "$outfiles/files.7z" | awk '{print $1}' > "$outfiles/files.md5sum"