1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 # ebuild generated by hackport 0.4.6.9999
7 #hackport: flags: -generatemanpage,-testing
9 CABAL_FEATURES="bin lib profile haddock hoogle hscolour test-suite"
12 DESCRIPTION="A tiling window manager"
13 HOMEPAGE="https://xmonad.org/"
14 SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz"
18 KEYWORDS="~amd64 ~ppc64 ~x86"
19 IUSE="+default-term no-autorepeat-keys"
21 RESTRICT=test # fails test on ghc-8 (assert has different text of exception)
23 RDEPEND="dev-haskell/data-default:=[profile?]
24 dev-haskell/extensible-exceptions:=[profile?]
25 dev-haskell/mtl:=[profile?]
26 dev-haskell/setlocale:=[profile?]
27 >=dev-haskell/utf8-string-0.3:=[profile?] <dev-haskell/utf8-string-1.1:=[profile?]
28 >=dev-haskell/x11-1.5:=[profile?] <dev-haskell/x11-1.7:=[profile?]
29 >=dev-lang/ghc-7.4.1:=
32 >=dev-haskell/cabal-1.8
33 test? ( >=dev-haskell/quickcheck-2 )
35 PDEPEND="default-term? ( x11-terms/xterm )
39 SAMPLE_CONFIG="xmonad.hs"
40 SAMPLE_CONFIG_LOC="man"
43 use no-autorepeat-keys && epatch "$FILESDIR"/${PN}-0.12-check-repeat.patch
50 haskell-cabal_src_configure \
51 --flag=-generatemanpage \
58 echo -e "#!/bin/sh\n/usr/bin/xmonad" > "${T}/${PN}"
59 exeinto /etc/X11/Sessions
62 insinto /usr/share/xsessions
63 doins "${FILESDIR}/${PN}.desktop"
66 dohtml man/xmonad.1.html
68 dodoc CONFIG README.md CHANGES.md
72 haskell-cabal_pkg_postinst
74 elog "A sample ${SAMPLE_CONFIG} configuration file can be found here:"
75 elog " /usr/share/${PF}/ghc-$(ghc-version)/${SAMPLE_CONFIG_LOC}/${SAMPLE_CONFIG}"
76 elog "The parameters in this file are the defaults used by xmonad."
77 elog "To customize xmonad, copy this file to:"
78 elog " ~/.xmonad/${SAMPLE_CONFIG}"
79 elog "After editing, use 'mod-q' to dynamically restart xmonad "
80 elog "(where the 'mod' key defaults to 'Alt')."
82 elog "Read the README or man page for more information, and to see "
83 elog "other possible configurations go to:"
84 elog " http://haskell.org/haskellwiki/Xmonad/Config_archive"
85 elog "Please note that many of these configurations will require the "
86 elog "x11-wm/xmonad-contrib package to be installed."