Commit 9d2f69d2 authored by Ivan Ivlev's avatar Ivan Ivlev

winetricks: redo opensymbol download, remove w_try_ar (eterbug #17726)

Signed-off-by: Ivan Ivlev's avatarIvan Ivlev <iviv@etersoft.ru>
parent b7ae3b80
From 0daa793971fd8bcbe5c80b58ee7e88539073a0d8 Mon Sep 17 00:00:00 2001
From: Ivan Ivlev <iviv@etersoft.ru>
Date: Mon, 30 Sep 2024 19:17:25 +0300
Subject: [PATCH] redo opensymbol download, remove w_try_ar function (eterbug
#17726)
Signed-off-by: Ivan Ivlev <iviv@etersoft.ru>
---
winetricks/src/winetricks | 38 +++++++-------------------------------
1 file changed, 7 insertions(+), 31 deletions(-)
diff --git a/winetricks/src/winetricks b/winetricks/src/winetricks
index 05b6683..ea6b24e 100755
--- a/winetricks/src/winetricks
+++ b/winetricks/src/winetricks
@@ -26,7 +26,7 @@ WINETRICKS_VERSION=20240105-next
#
# Uses the following non-POSIX system tools:
# - wine is used to execute Win32 apps except on Cygwin.
-# - ar, cabextract, unrar, unzip, and 7z are needed by some verbs.
+# - cabextract, unrar, unzip, and 7z are needed by some verbs.
# - aria2c, wget, curl, or fetch is needed for downloading.
# - fuseiso, archivemount (Linux), or hdiutil (macOS) is used to mount .iso images.
# - perl is used for displaying download progress for wget when using zenity
@@ -709,27 +709,6 @@ w_try_7z()
fi
}
-w_try_ar()
-{
- # $1 - ar file (.deb) to extract (keeping internal paths, in cwd)
- # $2 - file to extract (optional)
-
- # Not always installed, use Windows 7-zip as a fallback:
- if [ -z "${WINETRICKS_FORCE_WIN_7Z}" ] && [ -x "$(command -v ar 2>/dev/null)" ]; then
- w_try ar x "$@"
- else
- w_warn "Cannot find ar. Using Windows 7-zip instead. (You can avoid this by installing binutils, e.g. 'sudo apt install binutils' or 'sudo yum install binutils')."
- WINETRICKS_OPT_SHAREDPREFIX=1 w_call 7zip
-
- # w_call above will wipe $W_TMP; if that's the CWD, things will break. So forcefully reset the directory:
- w_try_cd "${PWD}"
-
- # -t* prevents 7-zip from decompressing .tar.xz to .tar, see
- # https://sourceforge.net/p/sevenzip/discussion/45798/thread/8cd16946/?limit=25
- w_try "${WINE}" "${W_PROGRAMS_X86_WIN}\\7-Zip\\7z.exe" -t* x "$(w_pathconv -w "$1")"
- fi
-}
-
w_try_cabextract()
{
# Not always installed, but shouldn't be fatal unless it's being used
@@ -15082,19 +15061,16 @@ w_metadata opensymbol fonts \
publisher="libreoffice.org" \
year="2022" \
media="download" \
- file1="fonts-opensymbol_102.12+LibO7.6.4~rc1-1~bpo12+1_all.deb" \
+ file1="opens___.ttf" \
installed_file1="${W_FONTSDIR_WIN}/opens___.ttf"
load_opensymbol()
{
- # The OpenSymbol fonts are a replacement for the Windows Wingdings font from OpenOffice.org.
- # Need to w_download Debian since I can't find a standalone download from OpenOffice
- # Note: The source download package on debian is for _all_ of OpenOffice, which is 266 MB.
- w_download http://ftp.us.debian.org/debian/pool/main/libr/libreoffice/fonts-opensymbol_102.12+LibO7.6.4~rc1-1~bpo12+1_all.deb e35e57a0a703fe656230a30c7675a5c5c4772a11c6f650634765234d1f0fa35f
- w_try_cd "${W_TMP}"
- w_try_ar "${W_CACHE}/${W_PACKAGE}/${file1}" data.tar.xz
- w_try tar -Jxf "${W_TMP}/data.tar.xz" ./usr/share/fonts/truetype/libreoffice/opens___.ttf
- w_try_cp_font_files "usr/share/fonts/truetype/libreoffice" "${W_FONTSDIR_UNIX}"
+ # w_download http://ftp.us.debian.org/debian/pool/main/libr/libreoffice/fonts-opensymbol_102.12+LibO7.6.4~rc1-1~bpo12+1_all.deb e35e57a0a703fe656230a30c7675a5c5c4772a11c6f650634765234d1f0fa35f
+
+ # 30.09.2024 download file directly from git repo instead of downloading entire deb package
+ w_download "https://raw.githubusercontent.com/apache/openoffice/5f13fa00702a0abe48858d443bc306f5c5ba26d8/main/extras/source/truetype/symbol/opens___.ttf" 86f6a40ca61adfc5942fb4d2fc360ffba9abd972a7e21c1ee91e494299ff0cbc
+ w_try_cp_font_files "${W_CACHE}/${W_PACKAGE}/" "${W_FONTSDIR_UNIX}"
w_register_font opens___.ttf "OpenSymbol"
}
--
2.42.1
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment