desktop/transmission-qt/PKGBUILD

111 lines
3.7 KiB
Bash
Raw Normal View History

#
# Apps Packages for Chakra, part of chakra-project.org
#
2012-04-11 07:25:25 +08:00
# maintainer abveritas@chakra-project.org
# contributor : Stephen McIntosh <stephenmac7@gmail.com>
pkgbase=transmission
pkgname=('transmission-cli' 'transmission-qt' 'transmission-qt5')
2013-09-15 01:01:21 +08:00
pkgver=2.82
pkgrel=4
2012-12-14 00:21:00 +08:00
arch=('x86_64')
url="http://www.transmissionbt.com/"
license=('MIT')
makedepends=('intltool' 'curl' 'pkgconfig' 'desktop-file-utils' 'qt' 'libevent' 'gettext' 'qt5-base' 'miniupnpc')
2012-07-25 05:25:24 +08:00
source=("http://mirrors.m0k.org/transmission/files/${pkgbase}-${pkgver}.tar.xz"
'transmission.tmpfiles'
'build-against-qt-4-and-5.patch')
2013-09-15 01:01:21 +08:00
md5sums=('a5ef870c0410b12d10449c2d36fa4661'
'23f2320361ad54373c3a4551ef634fe8'
'd747baff383df78e6544d5a0a5106268')
prepare() {
cp -r "${srcdir}/${pkgbase}-${pkgver}/qt" "${srcdir}/${pkgbase}-${pkgver}/qt5"
cd "${srcdir}/${pkgbase}-${pkgver}/qt"
patch -Np0 -i "$srcdir/build-against-qt-4-and-5.patch"
}
build() {
cd "${srcdir}/${pkgbase}-${pkgver}"
autoreconf -fi
export CFLAGS="$CFLAGS -fno-strict-aliasing"
./configure --prefix=/usr \
--enable-nls \
--enable-static=no \
--localedir=/usr/share/transmission/i18n
make
cd "${srcdir}/${pkgbase}-${pkgver}/qt"
qmake qtr.pro
make
cd "${srcdir}/${pkgbase}-${pkgver}/qt5"
/usr/lib/qt5/bin/qmake qtr.pro
make
}
package_transmission-cli() {
pkgdesc="Fast, easy, and free BitTorrent client (CLI tools, daemon and web client)"
depends=('curl' 'libevent')
categories=('network')
backup=('etc/conf.d/transmissiond')
install=transmission-cli.install
cd "${srcdir}/${pkgbase}-${pkgver}"
for dir in daemon cli web utils
do
make -C "${dir}" DESTDIR="${pkgdir}" install
done
install -D -m644 "${srcdir}/${pkgbase}-${pkgver}/daemon/transmission-daemon.service" "$pkgdir/usr/lib/systemd/system/transmission-daemon.service"
install -D -m644 "$srcdir/transmission.tmpfiles" "$pkgdir/usr/lib/tmpfiles.d/transmission.conf"
install -D -m644 COPYING "${pkgdir}/usr/share/licenses/transmission-cli/COPYING"
}
package_transmission-qt() {
pkgdesc="Fast, easy, and free BitTorrent client (Qt GUI)"
depends=('curl' 'qt' 'libevent')
optdepends=('transmission-cli: daemon and web support')
categories=('network')
2012-07-25 05:25:24 +08:00
screenshot=('http://www.transmissionbt.com/images/screenshots/Qt-Large.jpg')
provides=("${pkgbase}")
conflicts=("${pkgbase}")
replaces=("${pkgbase}")
install=transmission-qt.install
cd "${srcdir}/${pkgbase}-${pkgver}"
make -C qt INSTALL_ROOT="${pkgdir}"/usr install
install -D -m644 COPYING "${pkgdir}/usr/share/licenses/transmission-qt/COPYING"
install -D -m644 qt/icons/transmission.png "${pkgdir}/usr/share/pixmaps/transmission-qt.png"
install -D -m644 qt/transmission-qt.desktop "${pkgdir}/usr/share/applications/transmission-qt.desktop"
install -dm755 ${pkgdir}/usr/share/icons/hicolor
cp -r qt/icons/hicolor/* ${pkgdir}/usr/share/icons/hicolor/
}
package_transmission-qt5() {
pkgdesc="Fast, easy, and free BitTorrent client (Qt5 GUI)"
depends=('curl' 'qt5-base' 'libevent' 'miniupnpc')
optdepends=('transmission-cli: daemon and web support')
categories=('network')
provides=("${pkgbase}")
conflicts=("${pkgbase}")
replaces=("${pkgbase}")
screenshot=('http://www.transmissionbt.com/images/screenshots/Qt-Large.jpg')
install=transmission-qt.install
cd "${srcdir}/${pkgbase}-${pkgver}"
make -C qt5 INSTALL_ROOT="${pkgdir}"/usr install
install -D -m644 COPYING "${pkgdir}/usr/share/licenses/transmission-qt/COPYING"
install -D -m644 qt5/icons/transmission.png "${pkgdir}/usr/share/pixmaps/transmission-qt.png"
install -D -m644 qt5/transmission-qt.desktop "${pkgdir}/usr/share/applications/transmission-qt.desktop"
install -dm755 ${pkgdir}/usr/share/icons/hicolor
cp -r qt/icons/hicolor/* ${pkgdir}/usr/share/icons/hicolor/
}