summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO43
-rw-r--r--PKGBUILD78
-rw-r--r--dynamic-compilation.patch13
-rw-r--r--ghc_8.2.patch13
4 files changed, 147 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..5d8dba7ee169
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,43 @@
+# Generated by mksrcinfo v8
+# Sat Jan 27 20:28:18 UTC 2018
+pkgbase = taffybar
+ pkgdesc = A desktop bar similar to xmobar, but with more GUI
+ pkgver = 0.4.6
+ pkgrel = 1
+ url = http://github.com/travitch/taffybar
+ arch = i686
+ arch = x86_64
+ license = BSD3
+ depends = ghc
+ depends = haskell-hstringtemplate
+ depends = haskell-http
+ depends = haskell-x11
+ depends = haskell-cairo
+ depends = haskell-dbus
+ depends = haskell-dyre
+ depends = haskell-enclosed-exceptions
+ depends = haskell-gtk
+ depends = haskell-gtk-traymanager
+ depends = haskell-mtl
+ depends = haskell-network
+ depends = haskell-network-uri
+ depends = haskell-old-locale
+ depends = haskell-parsec
+ depends = haskell-safe
+ depends = haskell-split
+ depends = haskell-stm
+ depends = haskell-text
+ depends = haskell-time-locale-compat
+ depends = haskell-utf8-string
+ depends = haskell-xdg-basedir
+ depends = xmonad
+ depends = xmonad-contrib
+ source = http://hackage.haskell.org/packages/archive/taffybar/0.4.6/taffybar-0.4.6.tar.gz
+ source = dynamic-compilation.patch
+ source = ghc_8.2.patch
+ sha256sums = 620918469d79d33067808114bdf8d4d6f5a5ae6d77ff672a37ea04ecc5e0caf5
+ sha256sums = ab4f83891b764938d4750e7a1835761028b3c8761f7f6089053b3696325851d3
+ sha256sums = 127746e08c91035adb38c9e6f046bd7a5377d95c9cb61d81a186e3e20f5dd808
+
+pkgname = taffybar
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..5e7ce02ed498
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,78 @@
+# Maintainer: Leif Warner <abimelech@gmail.com>
+pkgname=taffybar
+pkgver=0.4.6
+pkgrel=1
+license=('BSD3')
+pkgdesc="A desktop bar similar to xmobar, but with more GUI"
+url="http://github.com/travitch/taffybar"
+arch=('i686' 'x86_64')
+depends=("ghc"
+ "haskell-hstringtemplate"
+ "haskell-http"
+ "haskell-x11"
+ "haskell-cairo"
+ "haskell-dbus"
+ "haskell-dyre"
+ "haskell-enclosed-exceptions"
+ "haskell-gtk"
+ "haskell-gtk-traymanager"
+ "haskell-mtl"
+ "haskell-network"
+ "haskell-network-uri"
+ "haskell-old-locale"
+ "haskell-parsec"
+ "haskell-safe"
+ "haskell-split"
+ "haskell-stm"
+ "haskell-text"
+ "haskell-time-locale-compat"
+ "haskell-utf8-string"
+ "haskell-xdg-basedir"
+ "xmonad"
+ "xmonad-contrib")
+source=("http://hackage.haskell.org/packages/archive/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz"
+ "dynamic-compilation.patch"
+ "ghc_8.2.patch")
+
+sha256sums=('620918469d79d33067808114bdf8d4d6f5a5ae6d77ff672a37ea04ecc5e0caf5'
+ 'ab4f83891b764938d4750e7a1835761028b3c8761f7f6089053b3696325851d3'
+ '127746e08c91035adb38c9e6f046bd7a5377d95c9cb61d81a186e3e20f5dd808')
+
+# PKGBUILD functions
+
+prepare() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # Submitted upstream: https://github.com/travitch/taffybar/pull/247
+ patch -p1 -i ../ghc_8.2.patch
+ #sed -i -e "s/time >= 1.4 && < 1.7/time >= 1.4 \&\& < 1.9/" taffybar.cabal
+ # See https://github.com/willdonnelly/dyre/issues/5
+ patch -p1 -i ../dynamic-compilation.patch
+ #sed -i -e 's/Dyre.ghcOpts = ["-threaded", "-rtsopts"]/Dyre.ghcOpts = \["-threaded", "-rtsopts", "-dynamic"\]/' src/System/Taffybar.hs
+}
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ runhaskell Setup configure -O --enable-shared --disable-library-vanilla \
+ --enable-executable-dynamic \
+ --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+ --libsubdir=\$compiler/site-local/\$pkgid \
+ -fnetwork-uri
+ runhaskell Setup build
+ runhaskell Setup register --gen-script
+ runhaskell Setup unregister --gen-script
+ sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh
+ sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ install -Dm 744 register.sh "${pkgdir}/usr/share/haskell/register/${pkgname}.sh"
+ install -Dm 744 unregister.sh "${pkgdir}/usr/share/haskell/unregister/${pkgname}.sh"
+
+ runhaskell Setup copy --destdir="${pkgdir}"
+ install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+ rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE"
+}
diff --git a/dynamic-compilation.patch b/dynamic-compilation.patch
new file mode 100644
index 000000000000..db6e37f5e372
--- /dev/null
+++ b/dynamic-compilation.patch
@@ -0,0 +1,13 @@
+Index: taffybar-0.4.6/src/System/Taffybar.hs
+===================================================================
+--- taffybar-0.4.6.orig/src/System/Taffybar.hs
++++ taffybar-0.4.6/src/System/Taffybar.hs
+@@ -195,7 +195,7 @@ defaultParams :: Dyre.Params TaffybarCon
+ defaultParams = Dyre.defaultParams { Dyre.projectName = "taffybar"
+ , Dyre.realMain = realMain
+ , Dyre.showError = showError
+- , Dyre.ghcOpts = ["-threaded", "-rtsopts"]
++ , Dyre.ghcOpts = ["-threaded", "-rtsopts", "-dynamic"]
+ , Dyre.rtsOptsHandling = Dyre.RTSAppend ["-I0", "-V0"]
+ }
+
diff --git a/ghc_8.2.patch b/ghc_8.2.patch
new file mode 100644
index 000000000000..6b02033e96ca
--- /dev/null
+++ b/ghc_8.2.patch
@@ -0,0 +1,13 @@
+Index: taffybar-0.4.6/taffybar.cabal
+===================================================================
+--- taffybar-0.4.6.orig/taffybar.cabal
++++ taffybar-0.4.6/taffybar.cabal
+@@ -27,7 +27,7 @@ flag network-uri
+ library
+ default-language: Haskell2010
+ build-depends: base > 3 && < 5,
+- time >= 1.4 && < 1.7,
++ time >= 1.4 && < 1.9,
+ time-locale-compat >= 0.1 && < 0.2,
+ old-locale,
+ containers,