Advertisement
Guest User

Untitled

a guest
Nov 22nd, 2019
981
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 3.35 KB | None | 0 0
  1. # Maintainer: Alex Taber <aft dot pokemon at gmail dot com>
  2.  
  3. pkgname=teamviewer
  4. pkgver=15.0.8397
  5. pkgrel=1
  6. pkgdesc='All-In-One Software for Remote Support and Online Meetings'
  7. arch=('i686' 'x86_64' 'armv7h')
  8. url='http://www.teamviewer.com'
  9. license=('custom')
  10. options=('!strip')
  11. provides=('teamviewer')
  12. conflicts=('teamviewer-beta')
  13. # /opt/teamviewer/tv_bin/script/teamviewer_setup checklibs can check deps for each TV component:
  14. # TV_DMN, TV_DESK, TV_GUI
  15. depends=(
  16.     'hicolor-icon-theme'
  17.     'qt5-webkit'
  18.     'qt5-x11extras'
  19.     'qt5-quickcontrols' # Doesn't appear in namcap, won't display UI without it.
  20. )
  21. #depends_x86_64=(
  22. # libdepends:
  23. #   'lib32-libxtst'
  24. #   'lib32-libxinerama'
  25. #   'lib32-libxrandr'
  26. #   'lib32-libxdamage'
  27. #   'lib32-fontconfig'
  28. #   'lib32-libsm')
  29. #depends_i686=()
  30. #depends_armv7h=()
  31. install=teamviewer.install
  32. source_x86_64=("https://dl.tvcdn.de/download/linux/version_${pkgver%%.*}x/teamviewer_${pkgver}_amd64.deb")
  33. source_i686=("https://dl.tvcdn.de/download/linux/version_${pkgver%%.*}x/teamviewer_${pkgver}_i386.deb")
  34. source_armv7h=("https://dl.tvcdn.de/download/linux/version_${pkgver%%.*}x/teamviewer-host_${pkgver}_armhf.deb")
  35. #source_armv7h=("https://dl.tvcdn.de/download/linux/version_${pkgver%%.*}x/teamviewer-host_13.2.13582_armhf.deb")
  36. # Old ones
  37. #sha256sums_i686=('d7d8cf4e5a3a9273c7b00c4d9be057e243643a0d1fc116ffd7c97e2859c4e97c')
  38. #sha256sums_x86_64=('1c2a70a6ad16c2c1b4da20b3ed7715ab59f5dac55ee99a945c9fd1cdf13ac748')
  39. #sha256sums_armv7h=('cc68e495598ea27a41e2d56bd01709468eec65777486fb1fb8aae58abc0acfb1')
  40. # New ones
  41. sha256sums_i686=('8a6cd9e685c18487d3238fd307042f5b551c71797af4353443d7a90ff4801390')
  42. sha256sums_x86_64=('da98c868256613b082a4fa126cdd83088cbb11a85ab90f5852ebe27f29a72d2e')
  43. #sha256sums_armv7h=('cc68e495598ea27a41e2d56bd01709468eec65777486fb1fb8aae58abc0acfb1')
  44.  
  45.  
  46. prepare() {
  47.     warning "If the install fails, you need to uninstall previous major version of Teamviewer"
  48.     [ -d data ] && rm -rf data
  49.     mkdir data
  50.     cd data
  51.     for datatar in ../data.tar.*; do
  52.         msg2 "Unpacking $datatar"
  53.         tar -xf $datatar
  54.     done
  55.     sed -i '/function CheckQtQuickControls()/{N;a ls /usr/lib/qt/qml/QtQuick/Controls/qmldir &>/dev/null && return # ArchLinux
  56. }' ./opt/teamviewer/tv_bin/script/teamviewer_setup || msg2 "Patching CheckQtQuickControls failed! Contact maintainer"
  57.     msg2 "Running teamviewer_setup checklibs"
  58.     ./opt/teamviewer/tv_bin/script/teamviewer_setup checklibs \
  59.     || msg2 "teamviewer_setup checklibs failed, contact maintainer with /tmp/teamviewerTARLibCheck/DependencyCheck.log" # Currently it always exits 0
  60. }
  61.  
  62. package() {
  63.     # Install
  64.     warning "If the install fails, you need to uninstall previous major version of Teamviewer"
  65.     cp -dr --no-preserve=ownership ./data/{etc,opt,usr,var} "${pkgdir}"/
  66.  
  67.     # Additional files
  68.     rm "${pkgdir}"/opt/teamviewer/tv_bin/xdg-utils/xdg-email
  69.     rm -rf "${pkgdir}"/etc/apt
  70.     install -D -m0644 "${pkgdir}"/opt/teamviewer/tv_bin/script/teamviewerd.service \
  71.         "${pkgdir}"/usr/lib/systemd/system/teamviewerd.service
  72.     install -d -m0755 "${pkgdir}"/usr/{share/applications,share/licenses/teamviewer}
  73.     ln -s /opt/teamviewer/License.txt \
  74.         "${pkgdir}"/usr/share/licenses/teamviewer/LICENSE
  75.     if [ "$CARCH" = "x86_64" ] && [ -f "${pkgdir}/opt/teamviewer/tv_bin/script/libdepend" ]; then
  76.         msg2 "Removing libdepend to ditch lib32 dependencies"
  77.         rm "${pkgdir}/opt/teamviewer/tv_bin/script/libdepend"
  78.     fi
  79. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement