aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorCountStarlight2018-01-04 12:14:15 +0800
committerCountStarlight2018-01-04 12:14:15 +0800
commita56e0c1dde775623d1c190b9fc476db5b1aa6fe5 (patch)
tree0bfd3f6d413f1facba2e7e93f110ef2572f905e3
downloadaur-a56e0c1dde775623d1c190b9fc476db5b1aa6fe5.tar.gz
init
Signed-off-by: CountStarlight <countstarlight@gmail.com>
-rw-r--r--.SRCINFO23
-rw-r--r--.gitignore6
-rw-r--r--.travis.yml16
-rw-r--r--PKGBUILD40
-rw-r--r--README.md28
-rwxr-xr-xclean.sh2
-rw-r--r--deepin-wine-thunderspeed.install4
-rwxr-xr-xgen.sh2
-rwxr-xr-xrun.sh95
9 files changed, 216 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..b042297a9fd0
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = deepin-wine-thunderspeed
+ pkgdesc = Thunderspeed(Xun Lei) on Deepin Wine For Archlinux(Don't need deepin-wine package)
+ pkgver = 7.10.35.366deepin17
+ pkgrel = 0
+ url = http://dl.xunlei.com/
+ install = deepin-wine-thunderspeed.install
+ arch = x86_64
+ license = custom
+ depends = p7zip
+ depends = wine
+ depends = wine-mono
+ depends = wine_gecko
+ depends = xorg-xwininfo
+ depends = wqy-microhei
+ depends = adobe-source-han-sans-cn-fonts
+ conflicts = deepin.com.thunderspeed
+ source = https://mirrors.ustc.edu.cn/deepin/pool/non-free/d/deepin.com.thunderspeed/deepin.com.thunderspeed_7.10.35.366deepin17_i386.deb
+ source = run.sh
+ md5sums = f57d11655311c11e109847b3eb6eedd7
+ md5sums = 94a6bd45f579622b0799d664a9d65964
+
+pkgname = deepin-wine-thunderspeed
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..abff1a66b3ce
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,6 @@
+.directory
+TIM*
+deepin.com.th*
+deepin-wine-thunderspeed-*
+pkg/
+src/
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 000000000000..fde212efd683
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,16 @@
+sudo: required
+
+arch:
+ packages:
+ - p7zip
+ - wine
+ - wine-mono
+ - wine_gecko
+ - xorg-xwininfo
+ - wqy-microhei
+ - adobe-source-han-sans-cn-fonts
+ script:
+ - "makepkg"
+
+script:
+ - "curl -s https://raw.githubusercontent.com/mikkeloscar/arch-travis/master/arch-travis.sh | bash"
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..f5396a97d3c0
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,40 @@
+# Maintainer: CountStarlight <countstarlight@gmail.com>
+
+pkgname=deepin-wine-thunderspeed
+pkgver=7.10.35.366deepin17
+pkgrel=0
+pkgdesc="Thunderspeed(Xun Lei) on Deepin Wine For Archlinux(Don't need deepin-wine package)"
+arch=("x86_64")
+url="http://dl.xunlei.com/"
+license=('custom')
+depends=('p7zip' 'wine' 'wine-mono' 'wine_gecko' 'xorg-xwininfo' 'wqy-microhei' 'adobe-source-han-sans-cn-fonts')
+conflicts=('deepin.com.thunderspeed')
+install="deepin-wine-thunderspeed.install"
+_mirror="https://mirrors.ustc.edu.cn/deepin"
+source=("$_mirror/pool/non-free/d/deepin.com.thunderspeed/deepin.com.thunderspeed_${pkgver}_i386.deb"
+ "run.sh")
+md5sums=('f57d11655311c11e109847b3eb6eedd7'
+ '94a6bd45f579622b0799d664a9d65964')
+
+build() {
+ msg "Extracting DPKG package ..."
+ mkdir -p "${srcdir}/dpkgdir"
+ tar -xvf data.tar.xz -C "${srcdir}/dpkgdir"
+ sed "s/\(Categories.*$\)/\1Network;/" -i "${srcdir}/dpkgdir/usr/local/share/applications/deepin.com.thunderspeed.desktop"
+ msg "Extracting Deepin Wine Thunderspeed archive ..."
+ 7z x -aoa "${srcdir}/dpkgdir/opt/deepinwine/apps/Deepin-ThunderSpeed/files.7z" -o"${srcdir}/deepinqqdir"
+ ln -sf "/usr/share/fonts/wenquanyi/wqy-microhei/wqy-microhei.ttc" "${srcdir}/deepinqqdir/drive_c/windows/Fonts/wqy-microhei.ttc"
+ ln -sf "/usr/share/fonts/adobe-source-han-sans/SourceHanSansCN-Medium.otf" "${srcdir}/deepinqqdir/drive_c/windows/Fonts/SourceHanSansCN-Medium.otf"
+ msg "Repackaging app archive ..."
+ 7z a -t7z -r "${srcdir}/files.7z" "${srcdir}/deepinqqdir/*"
+}
+
+package() {
+ msg "Preparing icons ..."
+ install -d "${pkgdir}/usr/share"
+ cp -a ${srcdir}/dpkgdir/usr/local/share/* "${pkgdir}/usr/share/"
+ msg "Copying ThunderSpeed to /opt/deepinwine/apps/Deepin-ThunderSpeed ..."
+ install -d "${pkgdir}/opt/deepinwine/apps/Deepin-ThunderSpeed"
+ install -m644 "${srcdir}/files.7z" "${pkgdir}/opt/deepinwine/apps/Deepin-ThunderSpeed/"
+ install -m755 "${srcdir}/run.sh" "${pkgdir}/opt/deepinwine/apps/Deepin-ThunderSpeed/"
+}
diff --git a/README.md b/README.md
new file mode 100644
index 000000000000..a76a22b9969e
--- /dev/null
+++ b/README.md
@@ -0,0 +1,28 @@
+# 在Archlinux及其衍生发行版上运行迅雷急速版
+
+把deepin的迅雷急速版移植到Archlinux
+
+构建状态: ![https://github.com/countstarlight/deepin-wine-thunderspeed-arch](https://travis-ci.org/countstarlight/deepin-wine-thunderspeed-arch.svg?branch=master)
+
+## 安装
+* 1.已添加到AUR [deepin-wine-thunderspeed](https://aur.archlinux.org/packages/deepin-wine-thunderspeed/),可直接安装:
+```shell
+yaourt deepin-wine-thunderspeed
+```
+
+* 2.手动安装
+
+```shell
+ git clone https://github.com/countstarlight/deepin-wine-thunderspeed-arch.git
+
+ cd deepin-wine-thunderspeed-arch
+
+ makepkg -si
+```
+
+* 安装完可直接启动
+* 默认使用文泉驿微米黑(`wqy-microhei`)字体,要使用其他字体,如 微软雅黑或者微软宋体放进`~/.deepinwine/Deepin-ThunderSpeed/drive_c/windows/Fonts`中。
+## 常见问题
+* 1.解决在 2k/4k 屏幕下字体和图标都非常小, 参见[issue1](https://github.com/countstarlight/deepin-wine-tim-arch/issues/1)
+## 更新日志
+* 2018-1-4 deepin.com.thunderspeed_7.10.35.366deepin17
diff --git a/clean.sh b/clean.sh
new file mode 100755
index 000000000000..eed5376fa004
--- /dev/null
+++ b/clean.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+git clean -xfd
diff --git a/deepin-wine-thunderspeed.install b/deepin-wine-thunderspeed.install
new file mode 100644
index 000000000000..f4393a0d835c
--- /dev/null
+++ b/deepin-wine-thunderspeed.install
@@ -0,0 +1,4 @@
+pre_remove() {
+ echo "deleting the ThunderSpeed bottle..."
+ find /home -maxdepth 2 -name ".deepinwine" -exec rm -rf \{\}/Deepin-ThunderSpeed/ \;
+}
diff --git a/gen.sh b/gen.sh
new file mode 100755
index 000000000000..8c19586bb6e4
--- /dev/null
+++ b/gen.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+makepkg --printsrcinfo > .SRCINFO
diff --git a/run.sh b/run.sh
new file mode 100755
index 000000000000..0c0e6b181efb
--- /dev/null
+++ b/run.sh
@@ -0,0 +1,95 @@
+#!/bin/sh
+
+# Copyright (C) 2016 Deepin, Inc.
+#
+# Author: Li LongYu <lilongyu@linuxdeepin.com>
+# Peng Hao <penghao@linuxdeepin.com>
+
+WINEPREFIX="$HOME/.deepinwine/Deepin-ThunderSpeed"
+APPDIR="/opt/deepinwine/apps/Deepin-ThunderSpeed"
+APPVER="7.10.35.366deepin17"
+APPTAR="files.7z"
+PACKAGENAME="deepin.com.thunderspeed"
+
+HelpApp()
+{
+ echo " Extra Commands:"
+ echo " -r/--reset Reset app to fix errors"
+ echo " -e/--remove Remove deployed app files"
+ echo " -h/--help Show program help info"
+}
+CallApp()
+{
+ bash "$WINEPREFIX/drive_c/deepin/EnvInit.sh"
+}
+ExtractApp()
+{
+ mkdir -p "$1"
+ 7z x "$APPDIR/$APPTAR" -o"$1"
+ mv "$1/drive_c/users/@current_user@" "$1/drive_c/users/$USER"
+ sed -i "s#@current_user@#$USER#" $1/*.reg
+ sed -i "s/deepin-wine/wine/" $1/drive_c/deepin/EnvInit.sh
+}
+DeployApp()
+{
+ ExtractApp "$WINEPREFIX"
+ echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
+}
+RemoveApp()
+{
+ rm -rf "$WINEPREFIX"
+}
+ResetApp()
+{
+ echo "Reset $PACKAGENAME....."
+ read -p "* Are you sure?(Y/N)" ANSWER
+ if [ "$ANSWER" = "Y" -o "$ANSWER" = "y" -o -z "$ANSWER" ]; then
+ EvacuateApp
+ DeployApp
+ CallApp
+ fi
+}
+UpdateApp()
+{
+ if [ -f "$WINEPREFIX/PACKAGE_VERSION" ] && [ "$(cat "$WINEPREFIX/PACKAGE_VERSION")" = "$APPVER" ]; then
+ return
+ fi
+ if [ -d "${WINEPREFIX}.tmpdir" ]; then
+ rm -rf "${WINEPREFIX}.tmpdir"
+ fi
+ ExtractApp "${WINEPREFIX}.tmpdir"
+ /opt/deepinwine/tools/updater -s "${WINEPREFIX}.tmpdir" -c "${WINEPREFIX}" -v
+ rm -rf "${WINEPREFIX}.tmpdir"
+ echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
+}
+RunApp()
+{
+ if [ -d "$WINEPREFIX" ]; then
+ UpdateApp
+ else
+ DeployApp
+ fi
+ CallApp
+}
+
+if [ -z $1 ]; then
+ RunApp
+ exit 0
+fi
+case $1 in
+ "-r" | "--reset")
+ ResetApp
+ ;;
+ "-e" | "--remove")
+ RemoveApp
+ ;;
+ "-h" | "--help")
+ HelpApp
+ ;;
+ *)
+ echo "Invalid option: $1"
+ echo "Use -h|--help to get help"
+ exit 1
+ ;;
+esac
+exit 0