summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2011-08-04 21:04:18 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2011-08-04 21:04:18 +0000
commit83b5477fd4f51966ff4b87126e531ffe9758ec13 (patch)
treead6a4983d518608b5070d5af73c3e5c3134522dd /dev-vcs/darcs
parentdev-vcs/darcs: version bump (and it's minimal depends) (diff)
downloadgentoo-2-83b5477fd4f51966ff4b87126e531ffe9758ec13.tar.gz
gentoo-2-83b5477fd4f51966ff4b87126e531ffe9758ec13.tar.bz2
gentoo-2-83b5477fd4f51966ff4b87126e531ffe9758ec13.zip
dev-vcs/darcs: version bump (and it's minimal depends)
(Portage version: 2.1.10.10/cvs/Linux x86_64)
Diffstat (limited to 'dev-vcs/darcs')
-rw-r--r--dev-vcs/darcs/ChangeLog11
-rw-r--r--dev-vcs/darcs/darcs-2.5.2.ebuild123
-rw-r--r--dev-vcs/darcs/files/darcs-2.5.2-ghc-7.2.patch142
-rw-r--r--dev-vcs/darcs/files/darcs-2.5.2-relax-regex-libs-deps.patch69
-rw-r--r--dev-vcs/darcs/files/darcs-2.5.2-tests-ghc-7.2.patch26
5 files changed, 370 insertions, 1 deletions
diff --git a/dev-vcs/darcs/ChangeLog b/dev-vcs/darcs/ChangeLog
index c55a4a1b133e..9601e449bfd5 100644
--- a/dev-vcs/darcs/ChangeLog
+++ b/dev-vcs/darcs/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for dev-vcs/darcs
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-vcs/darcs/ChangeLog,v 1.21 2011/06/05 12:10:57 slyfox Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-vcs/darcs/ChangeLog,v 1.22 2011/08/04 21:04:18 slyfox Exp $
+
+*darcs-2.5.2 (04 Aug 2011)
+
+ 04 Aug 2011; Sergei Trofimovich <slyfox@gentoo.org> +darcs-2.5.2.ebuild,
+ +files/darcs-2.5.2-ghc-7.2.patch,
+ +files/darcs-2.5.2-relax-regex-libs-deps.patch,
+ +files/darcs-2.5.2-tests-ghc-7.2.patch:
+ Version bump (ghc-7 support). Dropped ~alpha/~ia64/~ppc/~ppc64/~sparc
+ keywords until deps are keyworded.
05 Jun 2011; Sergei Trofimovich <slyfox@gentoo.org> darcs-2.4.4-r1.ebuild:
restored lost ~x86-freebsd ~amd64-linux ~x86-linux ~x86-solaris
diff --git a/dev-vcs/darcs/darcs-2.5.2.ebuild b/dev-vcs/darcs/darcs-2.5.2.ebuild
new file mode 100644
index 000000000000..2c76b746341c
--- /dev/null
+++ b/dev-vcs/darcs/darcs-2.5.2.ebuild
@@ -0,0 +1,123 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-vcs/darcs/darcs-2.5.2.ebuild,v 1.1 2011/08/04 21:04:18 slyfox Exp $
+
+EAPI="3"
+CABAL_FEATURES="bin lib profile haddock hscolour"
+inherit haskell-cabal bash-completion
+
+DESCRIPTION="a distributed, interactive, smart revision control system"
+HOMEPAGE="http://darcs.net/"
+SRC_URI="http://hackage.haskell.org/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
+IUSE="doc test"
+
+RDEPEND="=dev-haskell/hashed-storage-0.5*
+ =dev-haskell/haskeline-0.6*
+ =dev-haskell/html-1.0*
+ <dev-haskell/http-4000.2
+ =dev-haskell/mmap-0.5*
+ <dev-haskell/mtl-2.1
+ >=dev-haskell/network-2.2
+ <dev-haskell/parsec-3.2
+ <dev-haskell/regex-compat-0.96
+ =dev-haskell/tar-0.3*
+ =dev-haskell/terminfo-0.3*
+ =dev-haskell/text-0.11*
+ <dev-haskell/zlib-0.6.0.0
+ >=dev-lang/ghc-6.10.1
+ net-misc/curl
+ virtual/mta"
+
+# darcs also has a library version; we thus need $DEPEND
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.8
+ doc? ( virtual/latex-base
+ || ( dev-tex/latex2html[png]
+ dev-tex/latex2html[gif]
+ )
+ )
+ test? ( dev-haskell/test-framework
+ dev-haskell/test-framework-hunit
+ dev-haskell/test-framework-quickcheck2
+ )
+ "
+
+src_prepare() {
+ cd "${S}/contrib"
+ epatch "${FILESDIR}/${PN}-1.0.9-bashcomp.patch"
+ cd ..
+
+ epatch "${FILESDIR}/${PN}-2.5.2-relax-regex-libs-deps.patch"
+ epatch "${FILESDIR}/${PN}-2.5.2-ghc-7.2.patch"
+ epatch "${FILESDIR}/${PN}-2.5.2-tests-ghc-7.2.patch"
+
+ # hlint tests tend to break on every newly released hlint
+ rm "${S}/tests/haskell_policy.sh"
+
+ # use a more recent API, and thus depend on a more recent package
+ sed -i -e "s/findBy/find/" "${S}/src/Darcs/Test/Patch/Info.hs" || die "sed s/findBy/find/ not necessary"
+}
+
+src_configure() {
+ # checking whether ghc supports -threaded flag
+ # Beware: http://www.haskell.org/ghc/docs/latest/html/users_guide/options-phases.html#options-linker
+ # contains: 'The ability to make a foreign call that does not block all other Haskell threads.'
+ # It might have interactivity impact.
+
+ threaded_flag=""
+ if $(ghc-getghc) --info | grep "Support SMP" | grep -q "YES"; then
+ threaded_flag="--flags=threaded"
+ einfo "$P will be built with threads support"
+ else
+ threaded_flag="--flags=-threaded"
+ einfo "$P will be built without threads support"
+ fi
+
+ # Use curl for net stuff to avoid strict version dep on HTTP and network
+ cabal_src_configure \
+ --flags=curl \
+ --flags=-http \
+ --flags=curl-pipelining \
+ --flags=color \
+ --flags=terminfo \
+ --flags=mmap \
+ $threaded_flag \
+ $(cabal_flag test)
+}
+
+src_test() {
+ # run cabal test from haskell-cabal
+ haskell-cabal_src_test || die "cabal test failed"
+
+ # run the unit tests (not part of cabal test for some reason...)
+ # breaks the cabal abstraction a bit...
+ "${S}/dist/build/unit/unit" || die "unit tests failed"
+}
+
+src_install() {
+ cabal_src_install
+ dobashcompletion "${S}/contrib/darcs_completion" "${PN}"
+
+ rm "${ED}/usr/bin/unit" 2> /dev/null
+
+ # fixup perms in such an an awkward way
+ mv "${ED}/usr/share/man/man1/darcs.1" "${S}/darcs.1" || die "darcs.1 not found"
+ doman "${S}/darcs.1" || die "failed to register darcs.1 as a manpage"
+
+ # if tests were enabled, make sure the unit test driver is deleted
+ rm -rf "${ED}/usr/bin/unit"
+}
+
+pkg_postinst() {
+ ghc-package_pkg_postinst
+ bash-completion_pkg_postinst
+
+ ewarn "NOTE: in order for the darcs send command to work properly,"
+ ewarn "you must properly configure your mail transport agent to relay"
+ ewarn "outgoing mail. For example, if you are using ssmtp, please edit"
+ ewarn "${EPREFIX}/etc/ssmtp/ssmtp.conf with appropriate values for your site."
+}
diff --git a/dev-vcs/darcs/files/darcs-2.5.2-ghc-7.2.patch b/dev-vcs/darcs/files/darcs-2.5.2-ghc-7.2.patch
new file mode 100644
index 000000000000..22dfea864e33
--- /dev/null
+++ b/dev-vcs/darcs/files/darcs-2.5.2-ghc-7.2.patch
@@ -0,0 +1,142 @@
+diff --git a/Distribution/ShellHarness.hs b/Distribution/ShellHarness.hs
+index 78a8a9b..949b752 100644
+--- a/Distribution/ShellHarness.hs
++++ b/Distribution/ShellHarness.hs
+@@ -12,10 +12,9 @@ import System.Environment ( getEnv, getEnvironment )
+ import System.Exit ( ExitCode (..) )
+ import System.FilePath
+ import System.IO
+-import System( system )
+ import System.Process ( ProcessHandle,
+ runInteractiveProcess, waitForProcess,
+- getProcessExitCode )
++ getProcessExitCode, system )
+ import Data.Maybe
+ import Data.List ( isInfixOf, isPrefixOf, (\\), nubBy, isSuffixOf )
+ import Control.Concurrent
+diff --git a/darcs.cabal b/darcs.cabal
+index 887a27b..56e36fa 100644
+--- a/darcs.cabal
++++ b/darcs.cabal
+@@ -124,7 +124,7 @@ Executable witnesses
+ else
+ buildable: True
+
+- build-tools: ghc >= 6.10 && < 7.2
++ build-tools: ghc >= 6.10 && < 7.4
+
+ hs-source-dirs: src
+ include-dirs: src
+@@ -182,7 +182,7 @@ Executable witnesses
+ text == 0.11.*,
+ old-time == 1.0.*,
+ directory >= 1.0.0.0 && < 1.2.0.0,
+- process == 1.0.*,
++ process >= 1.0 && < 1.2,
+ containers >= 0.1 && < 0.5,
+ array >= 0.1 && < 0.4,
+ random == 1.0.*,
+@@ -192,7 +192,7 @@ Executable witnesses
+ test-framework >= 0.2.2,
+ test-framework-quickcheck2 >= 0.2.2
+ if !os(windows)
+- build-depends: unix >= 1.0 && < 2.5
++ build-depends: unix >= 1.0 && < 2.6
+ if flag(http)
+ build-depends: network >= 2.2 && < 2.4,
+ HTTP >= 3000.0 && < 4000.2
+@@ -208,7 +208,7 @@ Library
+ else
+ buildable: True
+
+- build-tools: ghc >= 6.10 && < 7.2
++ build-tools: ghc >= 6.10 && < 7.4
+
+ hs-source-dirs: src
+ include-dirs: src
+@@ -385,14 +385,14 @@ Library
+ tar == 0.3.*
+
+ if !os(windows)
+- build-depends: unix >= 1.0 && < 2.5
++ build-depends: unix >= 1.0 && < 2.6
+
+ build-depends: base >= 3,
+ bytestring >= 0.9.0 && < 0.10,
+ text == 0.11.*,
+ old-time == 1.0.*,
+ directory >= 1.0.0.0 && < 1.2.0.0,
+- process == 1.0.*,
++ process >= 1.0 && < 1.2,
+ containers >= 0.1 && < 0.5,
+ array >= 0.1 && < 0.4,
+ random == 1.0.*
+@@ -483,7 +483,7 @@ Executable darcs
+ src/umask.c
+ src/Crypt/sha2.c
+
+- build-tools: ghc >= 6.10 && < 7.2
++ build-tools: ghc >= 6.10 && < 7.4
+
+ -- We need optimizations, regardless of what Hackage says
+ -- Note: "if true" works around a cabal bug with order of flag composition
+@@ -533,14 +533,14 @@ Executable darcs
+ tar == 0.3.*
+
+ if !os(windows)
+- build-depends: unix >= 1.0 && < 2.5
++ build-depends: unix >= 1.0 && < 2.6
+
+ build-depends: base >= 3,
+ bytestring >= 0.9.0 && < 0.10,
+ text == 0.11.*,
+ old-time == 1.0.*,
+ directory >= 1.0.0.0 && < 1.2.0.0,
+- process == 1.0.*,
++ process >= 1.0 && < 1.2,
+ containers >= 0.1 && < 0.5,
+ array >= 0.1 && < 0.4,
+ random == 1.0.*
+@@ -615,7 +615,7 @@ Executable unit
+ else
+ buildable: True
+
+- build-tools: ghc >= 6.10 && < 7.2
++ build-tools: ghc >= 6.10 && < 7.4
+
+ build-depends: base < 5,
+ extensible-exceptions >= 0.1 && < 0.2,
+@@ -678,7 +678,7 @@ Executable unit
+ cc-options: -DHAVE_SIGINFO_H
+
+ if !os(windows)
+- build-depends: unix >= 1.0 && < 2.5
++ build-depends: unix >= 1.0 && < 2.6
+
+ build-depends: base >= 3,
+ bytestring >= 0.9.0 && < 0.10,
+@@ -686,7 +686,7 @@ Executable unit
+ text == 0.11.*,
+ old-time == 1.0.*,
+ directory >= 1.0.0.0 && < 1.2.0.0,
+- process == 1.0.*,
++ process >= 1.0 && < 1.2,
+ containers >= 0.1 && < 0.5,
+ array >= 0.1 && < 0.4,
+ hashed-storage >= 0.5.2 && < 0.6,
+diff --git a/src/Darcs/RepoPath.hs b/src/Darcs/RepoPath.hs
+index aa00156..8c5432b 100644
+--- a/src/Darcs/RepoPath.hs
++++ b/src/Darcs/RepoPath.hs
+@@ -60,11 +60,9 @@ import qualified Darcs.Patch.FileName as PatchFileName ( FileName, fp2fn, fn2fp
+ #include "impossible.h"
+
+ class FilePathOrURL a where
+- {-# INLINE toPath #-}
+ toPath :: a -> String
+
+ class FilePathOrURL a => FilePathLike a where
+- {-# INLINE toFilePath #-}
+ toFilePath :: a -> FilePath
+
+ -- | Paths which are relative to the local darcs repository and normalized.
diff --git a/dev-vcs/darcs/files/darcs-2.5.2-relax-regex-libs-deps.patch b/dev-vcs/darcs/files/darcs-2.5.2-relax-regex-libs-deps.patch
new file mode 100644
index 000000000000..1b6a37d75d37
--- /dev/null
+++ b/dev-vcs/darcs/files/darcs-2.5.2-relax-regex-libs-deps.patch
@@ -0,0 +1,69 @@
+diff -rN -u old-darcs-2.5.2/darcs.cabal new-darcs-2.5.2/darcs.cabal
+--- old-darcs-2.5.2/darcs.cabal 2011-06-03 20:24:32.079482374 +0200
++++ new-darcs-2.5.2/darcs.cabal 2011-06-03 20:24:32.080482374 +0200
+@@ -166,11 +166,11 @@
+ cpp-options: -DWIN32
+ c-sources: src/win32/send_email.c
+ build-depends: unix-compat >= 0.1.2,
+- regex-posix >= 0.94.4 && < 0.95
++ regex-posix >= 0.94.4 && < 0.96
+
+ build-depends: base < 5,
+ extensible-exceptions >= 0.1 && < 0.2,
+- regex-compat >= 0.71 && < 0.94,
++ regex-compat >= 0.71 && < 0.96,
+ mtl >= 1.0 && < 2.1,
+ parsec >= 2.0 && < 3.2,
+ html == 1.0.*,
+@@ -368,14 +368,14 @@
+ cpp-options: -DWIN32
+ c-sources: src/win32/send_email.c
+ build-depends: unix-compat >= 0.1.2,
+- regex-posix >= 0.94.4 && < 0.95
++ regex-posix >= 0.94.4 && < 0.96
+
+ if os(solaris)
+ cc-options: -DHAVE_SIGINFO_H
+
+ build-depends: base < 5,
+ extensible-exceptions >= 0.1 && < 0.2,
+- regex-compat >= 0.71 && < 0.94,
++ regex-compat >= 0.71 && < 0.96,
+ mtl >= 1.0 && < 2.1,
+ parsec >= 2.0 && < 3.2,
+ html == 1.0.*,
+@@ -516,14 +516,14 @@
+ cpp-options: -DWIN32
+ c-sources: src/win32/send_email.c
+ build-depends: unix-compat >= 0.1.2,
+- regex-posix >= 0.94.4 && < 0.95
++ regex-posix >= 0.94.4 && < 0.96
+
+ if os(solaris)
+ cc-options: -DHAVE_SIGINFO_H
+
+ build-depends: base < 5,
+ extensible-exceptions >= 0.1 && < 0.2,
+- regex-compat >= 0.71 && < 0.94,
++ regex-compat >= 0.71 && < 0.96,
+ mtl >= 1.0 && < 2.1,
+ parsec >= 2.0 && < 3.2,
+ html == 1.0.*,
+@@ -619,7 +619,7 @@
+
+ build-depends: base < 5,
+ extensible-exceptions >= 0.1 && < 0.2,
+- regex-compat >= 0.71 && < 0.94,
++ regex-compat >= 0.71 && < 0.96,
+ mtl >= 1.0 && < 2.1,
+ parsec >= 2.0 && < 3.2,
+ html == 1.0.*,
+@@ -672,7 +672,7 @@
+ cpp-options: -DWIN32
+ c-sources: src/win32/send_email.c
+ build-depends: unix-compat >= 0.1.2,
+- regex-posix >= 0.94.4 && < 0.95
++ regex-posix >= 0.94.4 && < 0.96
+
+ if os(solaris)
+ cc-options: -DHAVE_SIGINFO_H
diff --git a/dev-vcs/darcs/files/darcs-2.5.2-tests-ghc-7.2.patch b/dev-vcs/darcs/files/darcs-2.5.2-tests-ghc-7.2.patch
new file mode 100644
index 000000000000..c43df9a9328a
--- /dev/null
+++ b/dev-vcs/darcs/files/darcs-2.5.2-tests-ghc-7.2.patch
@@ -0,0 +1,26 @@
+diff --git a/tests/hspwd.hs b/tests/hspwd.hs
+index b93a7d5..f6fe2dd 100644
+--- a/tests/hspwd.hs
++++ b/tests/hspwd.hs
+@@ -1,5 +1,5 @@
+ module Main where
+
+-import Directory ( getCurrentDirectory )
++import System.Directory ( getCurrentDirectory )
+
+ main = getCurrentDirectory >>= putStr
+diff --git a/tests/trackdown-bisect-helper.hs b/tests/trackdown-bisect-helper.hs
+index 5c325c4..7fcb4a4 100644
+--- a/tests/trackdown-bisect-helper.hs
++++ b/tests/trackdown-bisect-helper.hs
+@@ -15,8 +15,9 @@ patches with the linear implementation.
+
+
+ import Control.Monad
++import System.Environment
+ import System.IO
+-import System
++import System.Process
+ import System.Random
+ import Data.List
+ import Control.Exception