Commit e240ba3c authored by Boris Yumankulov's avatar Boris Yumankulov Committed by Vitaly Lipatov

epm play wpsoffice: separate to cn and global version (eterbug #17812)

parent e1c42ac9
#!/bin/sh
PKGNAME=wpsoffice
SUPPORTEDARCHES="x86_64"
VERSION="$2"
DESCRIPTION="WPS Office for Linux from the official site (Chinese version)"
URL="https://www.wps.cn/product/wpslinux"
TIPS="Run epm play wpsoffice=<version> to install some specific version"
. $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then
VERSION=$(eget -O- https://archive2.kylinos.cn/DEB/KYLIN_DEB/pool/main/deb/wpsoffice/ | grep -oP '[^/]+_\K[\d.]+(?=_amd64\.deb)' | sort -V | tail -n1)
fi
PKGURL="https://archive2.kylinos.cn/DEB/KYLIN_DEB/pool/main/deb/wpsoffice/wpsoffice_${VERSION}_amd64.deb"
install_pkgurl
#!/bin/sh
PKGNAME=wpsoffice
PKGNAME=wps-office
SUPPORTEDARCHES="x86_64"
VERSION="$2"
DESCRIPTION="WPS Office for Linux from the official site"
URL="https://www.wps.cn/product/wpslinux"
TIPS="Run epm play wpsoffice=<version> to install some specific version"
if epm installed wps-office ; then
PKGNAME=wps-office
fi
if echo "$VERSION" | grep -q "^11" ; then
PKGNAME=wps-office
fi
. $(dirname $0)/common.sh
if [ "$VERSION" = "*" ] ; then
VERSION=$(eget -O- https://archive2.kylinos.cn/DEB/KYLIN_DEB/pool/main/deb/wpsoffice/ | grep -oP '[^/]+_\K[\d.]+(?=_amd64\.deb)' | sort -V | tail -n1)
fi
PKGURL="https://archive2.kylinos.cn/DEB/KYLIN_DEB/pool/main/deb/wpsoffice/wpsoffice_${VERSION}_amd64.deb"
# wps-office 12 need GLIBCXX_3.4.30
#is_stdcpp_enough "12.1" || VERSION="11.1.0.11723.XA"
if echo "$VERSION" | grep -q "^11" ; then
mversion=$(echo "$VERSION" | sed -e 's|\.XA$||' -e 's|.*\.||')
pkgtype=$(epm print info -p)
case $pkgtype in
rpm)
PKGURL="https://wdl1.pcfg.cache.wpscdn.com/wpsdl/wpsoffice/download/linux/$mversion/wps-office-${VERSION}-1.x86_64.rpm"
;;
*)
PKGURL="https://wdl1.pcfg.cache.wpscdn.com/wpsdl/wpsoffice/download/linux/$mversion/wps-office_${VERSION}_amd64.deb"
;;
esac
fi
mversion=$(echo "$VERSION" | sed -e 's|\.XA$||' -e 's|.*\.||')
pkgtype=$(epm print info -p)
case $pkgtype in
rpm)
PKGURL="https://wdl1.pcfg.cache.wpscdn.com/wpsdl/wpsoffice/download/linux/$mversion/wps-office-${VERSION}-1.x86_64.rpm"
;;
*)
PKGURL="https://wdl1.pcfg.cache.wpscdn.com/wpsdl/wpsoffice/download/linux/$mversion/wps-office_${VERSION}_amd64.deb"
;;
esac
install_pkgurl
......@@ -626,6 +626,17 @@ get_desktop_value()
cat "$DESKTOPFILE" | grep "^$FIELD=" | head -n1 | sed -e 's|^'"$FIELD"'=||' -e 's| .*||'
}
# copied from epm play common
# arg: minimal require of libstdc++ version
# return true is we have such version
is_stdcpp_enough()
{
local needed="$1"
local STDCPKG="libstdc++"
epm status --installed $STDCPKG || STDCPKG="libstdc++6"
is_pkg_enough $STDCPKG $needed
}
[ -d "$BUILDROOT" ] || fatal "Run me only via epm repack <package>"
......
......@@ -23,13 +23,13 @@ remove_file $PRODUCTDIR/office6/wpscloudsvr
# linked with missed libkappessframework.so()(64bit)
remove_file $PRODUCTDIR/office6/addons/pdfbatchcompression/libpdfbatchcompressionapp.so
# https://bugs.etersoft.ru/show_bug.cgi?id=17812
# Fix for icu>=71.1
#remove_file $PRODUCTDIR/office6/libstdc++.so*
# https://github.com/NixOS/nixpkgs/commit/da74ad3a905aa45ee6e4f8b4b69b56930195adcb
# Use system libjpeg
remove_file $PRODUCTDIR/office6/libjpeg.so*
# Fix theme system on WPS Office 11
is_stdcpp_enough "12.1" && remove_file $PRODUCTDIR/office6/libstdc++.so*
# hack to fix bug somewhere in linking
ignore_lib_requires "libc++.so"
......
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