summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorPrem Kumar2018-10-24 18:01:02 +0530
committerPrem Kumar2018-10-24 18:01:57 +0530
commit86bbe1ac73dea56e31ffa34fdc3d370a282a4258 (patch)
tree8bcc6ebecb8ee2847ce49abeeed3bbc93e2bf536
parent54b8b821b9e33e01eebce0c7ee5b779cba6e54f4 (diff)
downloadaur-86bbe1ac73dea56e31ffa34fdc3d370a282a4258.tar.gz
modified PKGBUILD to build the package instead of using the provided binary
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD31
2 files changed, 28 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f495328ca6e..0bfcf088635 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -5,8 +5,10 @@ pkgbase = auryo
url = http://auryo.com
arch = x86_64
license = GPL3
- source = https://github.com/Superjo149/auryo/releases/download/v2.1.2/Auryo-2.1.2.pacman
- md5sums = 3382424c498f798802bea7a3bf99dc5e
+ conflicts = auryo
+ conflicts = auryo-git
+ source = https://github.com/Superjo149/auryo/archive/v2.1.2.tar.gz
+ md5sums = 24fe79995200821f2fee80cac6e9c60a
pkgname = auryo
diff --git a/PKGBUILD b/PKGBUILD
index cc8029f06d0..d93c2b94f7d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,23 +5,40 @@ pkgname="auryo"
_desktopname="auryo"
_fullpkgname="Auryo"
pkgver=2.1.2
-pkgrel=1
+pkgrel=2
pkgdesc="A SoundCloud client for your desktop."
arch=("x86_64")
url="http://auryo.com"
license=("GPL3")
-source=("https://github.com/Superjo149/auryo/releases/download/v${pkgver}/${_fullpkgname}-${pkgver}.pacman")
-md5sums=('3382424c498f798802bea7a3bf99dc5e')
+conflicts=('auryo' 'auryo-git')
+source=("https://github.com/Superjo149/auryo/archive/v${pkgver}.tar.gz")
+md5sums=('24fe79995200821f2fee80cac6e9c60a')
_replace_str="\/opt\/${_fullpkgname}\/${_fullpkgname}"
+prepare() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ sed -i 's/"deb",//' package.json
+ sed -i 's/"rpm",//' package.json
+ sed -i 's/"AppImage",//' package.json
+}
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ yarn install -g --user root --prefix auryo/usr
+ yarn build
+ yarn run package:linux
+}
+
package() {
- cd "${srcdir}/"
+ mkdir "${srcdir}/${pkgver}"
+ tar -xvf ${srcdir}/${pkgname}-${pkgver}/release/${pkgname}-${pkgver}.pacman -C ${srcdir}/${pkgver}
+ cd "${srcdir}/${pkgver}"
install -dm755 "${pkgdir}/opt/"
install -dm755 "${pkgdir}/usr/share/applications/"
install -dm755 "${pkgdir}/usr/share/icons/"
- cp -r "${srcdir}/opt/${_fullpkgname}" "${pkgdir}/opt/"
- cp -r "${srcdir}/usr/share/applications/${_desktopname}.desktop" "${pkgdir}/usr/share/applications/"
- cp -r "${srcdir}/usr/share/icons" "${pkgdir}/usr/share/"
+ cp -r "${srcdir}/${pkgver}/opt/${_fullpkgname}" "${pkgdir}/opt/"
+ cp -r "${srcdir}/${pkgver}/usr/share/applications/${_desktopname}.desktop" "${pkgdir}/usr/share/applications/"
+ cp -r "${srcdir}/${pkgver}/usr/share/icons" "${pkgdir}/usr/share/"
mkdir -p "${pkgdir}/usr/bin"
ln -s "/opt/${_fullpkgname}/${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
sed -i "s/${_replace_str}/${pkgname}/g" "${pkgdir}/usr/share/applications/${_desktopname}.desktop"