summaryrefslogtreecommitdiff
path: root/standalone/android/haskell-patches
diff options
context:
space:
mode:
authorGravatar androidbuilder <androidbuilder@example.com>2015-08-02 19:48:36 +0000
committerGravatar androidbuilder <androidbuilder@example.com>2015-08-02 19:48:36 +0000
commitd03dd472b7f987695489f01d52cedb8b16e5b6c1 (patch)
treec5f5d0bd8a6a68476fc4cc6616170e8545d51791 /standalone/android/haskell-patches
parentf37922856e7ac2ad535f8da11dc291f485e22b98 (diff)
reverted updates to new lib versions that broke android build
I ran into several evilsplicer problems with the new lib versions, most notably including a problem with encoding of embedded binary files
Diffstat (limited to 'standalone/android/haskell-patches')
-rw-r--r--standalone/android/haskell-patches/crypto-numbers_build-fix.patch227
-rw-r--r--standalone/android/haskell-patches/dns_use-android-net.dns1-command-instead-of-resolv.conf.patch38
-rw-r--r--standalone/android/haskell-patches/entropy_cross-build.patch27
-rw-r--r--standalone/android/haskell-patches/gnuidn_fix-build-with-new-base.patch50
-rw-r--r--standalone/android/haskell-patches/iproute_1.2.11_0001-build-without-IPv6-stuff.patch24
-rw-r--r--standalone/android/haskell-patches/network_2.4.1.0_0002-remove-Network.BSD-symbols-not-available-in-bionic.patch50
-rw-r--r--standalone/android/haskell-patches/network_2.4.1.0_0003-configure-misdetects-accept4.patch16
-rw-r--r--standalone/android/haskell-patches/network_2.4.1.0_0006-build-fixes.patch24
-rw-r--r--standalone/android/haskell-patches/optparse-applicative_remove-ANN.patch33
-rw-r--r--standalone/android/haskell-patches/profunctors_3.3-0001-fix-cross-build.patch26
-rw-r--r--standalone/android/haskell-patches/shakespeare-text_remove-TH.patch153
-rw-r--r--standalone/android/haskell-patches/skein_hardcode_little-endian.patch26
-rw-r--r--standalone/android/haskell-patches/unix-time_hack-for-Bionic.patch24
-rw-r--r--standalone/android/haskell-patches/uuid_build-without-v1-uuid-which-needs-network-info.patch59
-rw-r--r--standalone/android/haskell-patches/vector_cross-build.patch24
-rw-r--r--standalone/android/haskell-patches/warp_avoid-ipv6-for-android.patch39
16 files changed, 541 insertions, 299 deletions
diff --git a/standalone/android/haskell-patches/crypto-numbers_build-fix.patch b/standalone/android/haskell-patches/crypto-numbers_build-fix.patch
new file mode 100644
index 000000000..5c0693a31
--- /dev/null
+++ b/standalone/android/haskell-patches/crypto-numbers_build-fix.patch
@@ -0,0 +1,227 @@
+From 0cfdb30120976290068f4bcbebbf236b960afbb6 Mon Sep 17 00:00:00 2001
+From: dummy <dummy@example.com>
+Date: Thu, 26 Dec 2013 20:01:30 -0400
+Subject: [PATCH] hack to build
+
+---
+ Crypto/Number/Basic.hs | 14 --------------
+ Crypto/Number/ModArithmetic.hs | 29 -----------------------------
+ Crypto/Number/Prime.hs | 18 ------------------
+ crypto-numbers.cabal | 2 +-
+ 4 files changed, 1 insertion(+), 62 deletions(-)
+
+diff --git a/Crypto/Number/Basic.hs b/Crypto/Number/Basic.hs
+index 65c14b3..eaee853 100644
+--- a/Crypto/Number/Basic.hs
++++ b/Crypto/Number/Basic.hs
+@@ -20,11 +20,7 @@ module Crypto.Number.Basic
+ , areEven
+ ) where
+
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-import GHC.Integer.GMP.Internals
+-#else
+ import Data.Bits
+-#endif
+
+ -- | sqrti returns two integer (l,b) so that l <= sqrt i <= b
+ -- the implementation is quite naive, use an approximation for the first number
+@@ -63,25 +59,16 @@ sqrti i
+ -- gcde 'a' 'b' find (x,y,gcd(a,b)) where ax + by = d
+ --
+ gcde :: Integer -> Integer -> (Integer, Integer, Integer)
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-gcde a b = (s, t, g)
+- where (# g, s #) = gcdExtInteger a b
+- t = (g - s * a) `div` b
+-#else
+ gcde a b = if d < 0 then (-x,-y,-d) else (x,y,d) where
+ (d, x, y) = f (a,1,0) (b,0,1)
+ f t (0, _, _) = t
+ f (a', sa, ta) t@(b', sb, tb) =
+ let (q, r) = a' `divMod` b' in
+ f t (r, sa - (q * sb), ta - (q * tb))
+-#endif
+
+ -- | get the extended GCD of two integer using the extended binary algorithm (HAC 14.61)
+ -- get (x,y,d) where d = gcd(a,b) and x,y satisfying ax + by = d
+ gcde_binary :: Integer -> Integer -> (Integer, Integer, Integer)
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-gcde_binary = gcde
+-#else
+ gcde_binary a' b'
+ | b' == 0 = (1,0,a')
+ | a' >= b' = compute a' b'
+@@ -105,7 +92,6 @@ gcde_binary a' b'
+ in if u2 >= v2
+ then loop g x y (u2 - v2) v2 (a2 - c2) (b2 - d2) c2 d2
+ else loop g x y u2 (v2 - u2) a2 b2 (c2 - a2) (d2 - b2)
+-#endif
+
+ -- | check if a list of integer are all even
+ areEven :: [Integer] -> Bool
+diff --git a/Crypto/Number/ModArithmetic.hs b/Crypto/Number/ModArithmetic.hs
+index 942c12f..f8cfc32 100644
+--- a/Crypto/Number/ModArithmetic.hs
++++ b/Crypto/Number/ModArithmetic.hs
+@@ -29,12 +29,8 @@ module Crypto.Number.ModArithmetic
+ import Control.Exception (throw, Exception)
+ import Data.Typeable
+
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-import GHC.Integer.GMP.Internals
+-#else
+ import Crypto.Number.Basic (gcde_binary)
+ import Data.Bits
+-#endif
+
+ -- | Raised when two numbers are supposed to be coprimes but are not.
+ data CoprimesAssertionError = CoprimesAssertionError
+@@ -55,13 +51,7 @@ expSafe :: Integer -- ^ base
+ -> Integer -- ^ exponant
+ -> Integer -- ^ modulo
+ -> Integer -- ^ result
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-expSafe b e m
+- | odd m = powModSecInteger b e m
+- | otherwise = powModInteger b e m
+-#else
+ expSafe = exponentiation
+-#endif
+
+ -- | Compute the modular exponentiation of base^exponant using
+ -- the fastest algorithm without any consideration for
+@@ -74,11 +64,7 @@ expFast :: Integer -- ^ base
+ -> Integer -- ^ modulo
+ -> Integer -- ^ result
+ expFast =
+-#if MIN_VERSION_integer_gmp(0,5,1)
+- powModInteger
+-#else
+ exponentiation
+-#endif
+
+ -- note on exponentiation: 0^0 is treated as 1 for mimicking the standard library;
+ -- the mathematic debate is still open on whether or not this is true, but pratically
+@@ -87,22 +73,15 @@ expFast =
+ -- | exponentiation_rtl_binary computes modular exponentiation as b^e mod m
+ -- using the right-to-left binary exponentiation algorithm (HAC 14.79)
+ exponentiation_rtl_binary :: Integer -> Integer -> Integer -> Integer
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-exponentiation_rtl_binary = expSafe
+-#else
+ exponentiation_rtl_binary 0 0 m = 1 `mod` m
+ exponentiation_rtl_binary b e m = loop e b 1
+ where sq x = (x * x) `mod` m
+ loop !0 _ !a = a `mod` m
+ loop !i !s !a = loop (i `shiftR` 1) (sq s) (if odd i then a * s else a)
+-#endif
+
+ -- | exponentiation computes modular exponentiation as b^e mod m
+ -- using repetitive squaring.
+ exponentiation :: Integer -> Integer -> Integer -> Integer
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-exponentiation = expSafe
+-#else
+ exponentiation b e m
+ | b == 1 = b
+ | e == 0 = 1
+@@ -110,7 +89,6 @@ exponentiation b e m
+ | even e = let p = (exponentiation b (e `div` 2) m) `mod` m
+ in (p^(2::Integer)) `mod` m
+ | otherwise = (b * exponentiation b (e-1) m) `mod` m
+-#endif
+
+ --{-# DEPRECATED exponantiation_rtl_binary "typo in API name it's called exponentiation_rtl_binary #-}
+ exponantiation_rtl_binary :: Integer -> Integer -> Integer -> Integer
+@@ -122,17 +100,10 @@ exponantiation = exponentiation
+
+ -- | inverse computes the modular inverse as in g^(-1) mod m
+ inverse :: Integer -> Integer -> Maybe Integer
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-inverse g m
+- | r == 0 = Nothing
+- | otherwise = Just r
+- where r = recipModInteger g m
+-#else
+ inverse g m
+ | d > 1 = Nothing
+ | otherwise = Just (x `mod` m)
+ where (x,_,d) = gcde_binary g m
+-#endif
+
+ -- | Compute the modular inverse of 2 coprime numbers.
+ -- This is equivalent to inverse except that the result
+diff --git a/Crypto/Number/Prime.hs b/Crypto/Number/Prime.hs
+index 0cea9da..458c94d 100644
+--- a/Crypto/Number/Prime.hs
++++ b/Crypto/Number/Prime.hs
+@@ -3,9 +3,7 @@
+ #ifndef MIN_VERSION_integer_gmp
+ #define MIN_VERSION_integer_gmp(a,b,c) 0
+ #endif
+-#if MIN_VERSION_integer_gmp(0,5,1)
+ {-# LANGUAGE MagicHash #-}
+-#endif
+ -- |
+ -- Module : Crypto.Number.Prime
+ -- License : BSD-style
+@@ -30,12 +28,7 @@ import Crypto.Number.Generate
+ import Crypto.Number.Basic (sqrti, gcde_binary)
+ import Crypto.Number.ModArithmetic (exponantiation)
+
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-import GHC.Integer.GMP.Internals
+-import GHC.Base
+-#else
+ import Data.Bits
+-#endif
+
+ -- | returns if the number is probably prime.
+ -- first a list of small primes are implicitely tested for divisibility,
+@@ -78,21 +71,11 @@ findPrimeFromWith rng prop !n
+ -- | find a prime from a starting point with no specific property.
+ findPrimeFrom :: CPRG g => g -> Integer -> (Integer, g)
+ findPrimeFrom rng n =
+-#if MIN_VERSION_integer_gmp(0,5,1)
+- (nextPrimeInteger n, rng)
+-#else
+ findPrimeFromWith rng (\g _ -> (True, g)) n
+-#endif
+
+ -- | Miller Rabin algorithm return if the number is probably prime or composite.
+ -- the tries parameter is the number of recursion, that determines the accuracy of the test.
+ primalityTestMillerRabin :: CPRG g => g -> Int -> Integer -> (Bool, g)
+-#if MIN_VERSION_integer_gmp(0,5,1)
+-primalityTestMillerRabin rng (I# tries) !n =
+- case testPrimeInteger n tries of
+- 0# -> (False, rng)
+- _ -> (True, rng)
+-#else
+ primalityTestMillerRabin rng tries !n
+ | n <= 3 = error "Miller-Rabin requires tested value to be > 3"
+ | even n = (False, rng)
+@@ -129,7 +112,6 @@ primalityTestMillerRabin rng tries !n
+ | x2 == 1 = False
+ | x2 /= nm1 = loop' ws ((x2*x2) `mod` n) (r+1)
+ | otherwise = loop ws
+-#endif
+
+ {-
+ n < z -> witness to test
+diff --git a/crypto-numbers.cabal b/crypto-numbers.cabal
+index 9610e34..6669d78 100644
+--- a/crypto-numbers.cabal
++++ b/crypto-numbers.cabal
+@@ -15,7 +15,7 @@ Extra-Source-Files: Tests/*.hs
+
+ Flag integer-gmp
+ Description: Are we using integer-gmp?
+- Default: True
++ Default: False
+
+ Library
+ Build-Depends: base >= 4 && < 5
+--
+1.7.10.4
+
diff --git a/standalone/android/haskell-patches/dns_use-android-net.dns1-command-instead-of-resolv.conf.patch b/standalone/android/haskell-patches/dns_use-android-net.dns1-command-instead-of-resolv.conf.patch
index 2b23c6d24..962a64207 100644
--- a/standalone/android/haskell-patches/dns_use-android-net.dns1-command-instead-of-resolv.conf.patch
+++ b/standalone/android/haskell-patches/dns_use-android-net.dns1-command-instead-of-resolv.conf.patch
@@ -1,6 +1,6 @@
-From e5072d9b721cc25fa1017df97d71bf926a78d4e5 Mon Sep 17 00:00:00 2001
+From 087f1ae5e17f0e6d7c9f6b4092a5bb5bb6f5bf60 Mon Sep 17 00:00:00 2001
From: dummy <dummy@example.com>
-Date: Fri, 3 Jul 2015 02:24:19 +0000
+Date: Thu, 16 Oct 2014 02:59:11 +0000
Subject: [PATCH] port
---
@@ -9,48 +9,48 @@ Subject: [PATCH] port
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/Network/DNS/Resolver.hs b/Network/DNS/Resolver.hs
-index 31f6373..6487c7b 100644
+index 5721e03..c4400d1 100644
--- a/Network/DNS/Resolver.hs
+++ b/Network/DNS/Resolver.hs
-@@ -18,7 +18,7 @@ module Network.DNS.Resolver (
- , fromDNSFormat
+@@ -19,7 +19,7 @@ module Network.DNS.Resolver (
) where
+ import Control.Applicative ((<$>), (<*>), pure)
-import Control.Exception (bracket)
+import Control.Exception (bracket, catch, IOException)
+ import qualified Data.ByteString.Char8 as BS
import Data.Char (isSpace)
import Data.List (isPrefixOf)
- import Data.Maybe (fromMaybe)
-@@ -32,6 +32,7 @@ import Network.Socket (AddrInfoFlag(..), AddrInfo(..), SockAddr(..), PortNumber(
+@@ -32,6 +32,7 @@ import Network.Socket (AddrInfoFlag(..), AddrInfo(..), defaultHints, getAddrInfo
import Prelude hiding (lookup)
import System.Random (getStdRandom, randomR)
import System.Timeout (timeout)
+import System.Process
- #if __GLASGOW_HASKELL__ < 709
- import Control.Applicative ((<$>), (<*>), pure)
-@@ -136,10 +137,12 @@ makeResolvSeed conf = ResolvSeed <$> addr
+ #if mingw32_HOST_OS == 1
+ import Network.Socket (send)
+@@ -130,10 +131,12 @@ makeResolvSeed conf = ResolvSeed <$> addr
+ where
addr = case resolvInfo conf of
- RCHostName numhost -> makeAddrInfo numhost Nothing
- RCHostPort numhost mport -> makeAddrInfo numhost $ Just mport
-- RCFilePath file -> toAddr <$> readFile file >>= \i -> makeAddrInfo i Nothing
+ RCHostName numhost -> makeAddrInfo numhost
+- RCFilePath file -> toAddr <$> readFile file >>= makeAddrInfo
- toAddr cs = let l:_ = filter ("nameserver" `isPrefixOf`) $ lines cs
- in extract l
- extract = reverse . dropWhile isSpace . reverse . dropWhile isSpace . drop 11
+ RCFilePath file -> do
+ -- Android has no /etc/resolv.conf; use getprop command.
+ ls <- catch (lines <$> readProcess "getprop" ["net.dns1"] []) (const (return []) :: IOException -> IO [String])
-+ flip makeAddrInfo Nothing $ case ls of
++ makeAddrInfo $ case ls of
+ [] -> "8.8.8.8" -- google public dns as a fallback only
+ (l:_) -> l
- makeAddrInfo :: HostName -> Maybe PortNumber -> IO AddrInfo
- makeAddrInfo addr mport = do
+ makeAddrInfo :: HostName -> IO AddrInfo
+ makeAddrInfo addr = do
diff --git a/dns.cabal b/dns.cabal
-index 0745754..8cf4b67 100644
+index ceaf5f4..cd15e61 100644
--- a/dns.cabal
+++ b/dns.cabal
-@@ -39,6 +39,7 @@ Library
+@@ -37,6 +37,7 @@ Library
, network >= 2.3
, random
, resourcet
@@ -59,5 +59,5 @@ index 0745754..8cf4b67 100644
Build-Depends: base >= 4 && < 5
, attoparsec
--
-2.1.4
+2.1.1
diff --git a/standalone/android/haskell-patches/entropy_cross-build.patch b/standalone/android/haskell-patches/entropy_cross-build.patch
deleted file mode 100644
index 4c27ac479..000000000
--- a/standalone/android/haskell-patches/entropy_cross-build.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 8e942c1f661b30e5477607b78528634e6d345ae8 Mon Sep 17 00:00:00 2001
-From: androidbuilder <androidbuilder@example.com>
-Date: Thu, 2 Jul 2015 21:16:15 +0000
-Subject: [PATCH] cross build
-
----
- entropy.cabal | 5 +----
- 1 file changed, 1 insertion(+), 4 deletions(-)
-
-diff --git a/entropy.cabal b/entropy.cabal
-index e4fb436..e26896c 100644
---- a/entropy.cabal
-+++ b/entropy.cabal
-@@ -14,10 +14,7 @@ category: Data, Cryptography
- homepage: https://github.com/TomMD/entropy
- bug-reports: https://github.com/TomMD/entropy/issues
- stability: stable
---- build-type: Simple
---- ^^ Used for HaLVM
--build-type: Custom
---- ^^ Test for RDRAND support using 'ghc'
-+build-type: Simple
- cabal-version: >=1.10
- tested-with: GHC == 7.8.2
- -- data-files:
---
-2.1.4
diff --git a/standalone/android/haskell-patches/gnuidn_fix-build-with-new-base.patch b/standalone/android/haskell-patches/gnuidn_fix-build-with-new-base.patch
new file mode 100644
index 000000000..ff9d8f245
--- /dev/null
+++ b/standalone/android/haskell-patches/gnuidn_fix-build-with-new-base.patch
@@ -0,0 +1,50 @@
+From afdec6c9e66211a0ac8419fffe191b059d1fd00c Mon Sep 17 00:00:00 2001
+From: foo <foo@bar>
+Date: Sun, 22 Sep 2013 17:24:33 +0000
+Subject: [PATCH] fix build with new base
+
+---
+ Data/Text/IDN/IDNA.chs | 1 +
+ Data/Text/IDN/Punycode.chs | 1 +
+ Data/Text/IDN/StringPrep.chs | 1 +
+ 3 files changed, 3 insertions(+)
+
+diff --git a/Data/Text/IDN/IDNA.chs b/Data/Text/IDN/IDNA.chs
+index ed29ee4..dbb4ba5 100644
+--- a/Data/Text/IDN/IDNA.chs
++++ b/Data/Text/IDN/IDNA.chs
+@@ -31,6 +31,7 @@ import Foreign
+ import Foreign.C
+
+ import Data.Text.IDN.Internal
++import System.IO.Unsafe
+
+ #include <idna.h>
+ #include <idn-free.h>
+diff --git a/Data/Text/IDN/Punycode.chs b/Data/Text/IDN/Punycode.chs
+index 24b5fa6..4e62555 100644
+--- a/Data/Text/IDN/Punycode.chs
++++ b/Data/Text/IDN/Punycode.chs
+@@ -32,6 +32,7 @@ import Data.List (unfoldr)
+ import qualified Data.ByteString as B
+ import qualified Data.Text as T
+
++import System.IO.Unsafe
+ import Foreign
+ import Foreign.C
+
+diff --git a/Data/Text/IDN/StringPrep.chs b/Data/Text/IDN/StringPrep.chs
+index 752dc9e..5e9fd84 100644
+--- a/Data/Text/IDN/StringPrep.chs
++++ b/Data/Text/IDN/StringPrep.chs
+@@ -39,6 +39,7 @@ import qualified Data.ByteString as B
+ import qualified Data.Text as T
+ import qualified Data.Text.Encoding as TE
+
++import System.IO.Unsafe
+ import Foreign
+ import Foreign.C
+
+--
+1.7.10.4
+
diff --git a/standalone/android/haskell-patches/iproute_1.2.11_0001-build-without-IPv6-stuff.patch b/standalone/android/haskell-patches/iproute_1.2.11_0001-build-without-IPv6-stuff.patch
index 13cfbd232..bb9caec77 100644
--- a/standalone/android/haskell-patches/iproute_1.2.11_0001-build-without-IPv6-stuff.patch
+++ b/standalone/android/haskell-patches/iproute_1.2.11_0001-build-without-IPv6-stuff.patch
@@ -1,31 +1,31 @@
-From b2b88224426fe6c7c72ebdec2946fd1ddbacbfaf Mon Sep 17 00:00:00 2001
-From: dummy <dummy@example.com>
-Date: Thu, 2 Jul 2015 20:42:50 +0000
+From 7beec2e707d59f9573aa2dc7c57bd2a62f16b480 Mon Sep 17 00:00:00 2001
+From: Joey Hess <joey@kitenet.net>
+Date: Wed, 15 May 2013 19:06:03 -0400
Subject: [PATCH] build without IPv6 stuff
---
- Data/IP.hs | 2 +-
- Data/IP/Addr.hs | 3 +++
+ Data/IP.hs | 2 +-
+ Data/IP/Addr.hs | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/Data/IP.hs b/Data/IP.hs
-index 306a488..e3f252e 100644
+index cffef93..ea486c9 100644
--- a/Data/IP.hs
+++ b/Data/IP.hs
@@ -6,7 +6,7 @@ module Data.IP (
-- ** IP data
IP (..)
, IPv4, toIPv4, fromIPv4, fromHostAddress, toHostAddress
-- , IPv6, toIPv6, toIPv6b, fromIPv6, fromIPv6b, fromHostAddress6, toHostAddress6
-+ , IPv6, toIPv6, toIPv6b, fromIPv6, fromIPv6b -- , fromHostAddress6, toHostAddress6
+- , IPv6, toIPv6, fromIPv6, fromHostAddress6, toHostAddress6
++ , IPv6, toIPv6, fromIPv6 -- , fromHostAddress6, toHostAddress6
-- ** IP range data
, IPRange (..)
, AddrRange (addr, mask, mlen)
diff --git a/Data/IP/Addr.hs b/Data/IP/Addr.hs
-index 8d4131e..868a572 100644
+index faaf0c7..5b556fb 100644
--- a/Data/IP/Addr.hs
+++ b/Data/IP/Addr.hs
-@@ -376,6 +376,7 @@ toHostAddress (IP4 addr4)
+@@ -312,6 +312,7 @@ toHostAddress (IP4 addr4)
| byteOrder == LittleEndian = fixByteOrder addr4
| otherwise = addr4
@@ -33,7 +33,7 @@ index 8d4131e..868a572 100644
-- | The 'fromHostAddress6' function converts 'HostAddress6' to 'IPv6'.
fromHostAddress6 :: HostAddress6 -> IPv6
fromHostAddress6 = IP6
-@@ -384,6 +385,8 @@ fromHostAddress6 = IP6
+@@ -320,6 +321,8 @@ fromHostAddress6 = IP6
toHostAddress6 :: IPv6 -> HostAddress6
toHostAddress6 (IP6 addr6) = addr6
@@ -43,5 +43,5 @@ index 8d4131e..868a572 100644
fixByteOrder s = d1 .|. d2 .|. d3 .|. d4
where
--
-2.1.4
+1.7.10.4
diff --git a/standalone/android/haskell-patches/network_2.4.1.0_0002-remove-Network.BSD-symbols-not-available-in-bionic.patch b/standalone/android/haskell-patches/network_2.4.1.0_0002-remove-Network.BSD-symbols-not-available-in-bionic.patch
index e4ebc3ef4..5b07f233b 100644
--- a/standalone/android/haskell-patches/network_2.4.1.0_0002-remove-Network.BSD-symbols-not-available-in-bionic.patch
+++ b/standalone/android/haskell-patches/network_2.4.1.0_0002-remove-Network.BSD-symbols-not-available-in-bionic.patch
@@ -1,17 +1,17 @@
-From 508b4701c1610d9772564b97a74b5fa01dab48e2 Mon Sep 17 00:00:00 2001
-From: dummy <dummy@example.com>
-Date: Thu, 2 Jul 2015 20:12:59 +0000
+From 7861b133bb269b50fcf709291449cb0473818902 Mon Sep 17 00:00:00 2001
+From: Joey Hess <joey@kitenet.net>
+Date: Sun, 29 Dec 2013 21:29:23 +0000
Subject: [PATCH] remove Network.BSD symbols not available in bionic
---
- Network/BSD.hsc | 100 --------------------------------------------------------
- 1 file changed, 100 deletions(-)
+ Network/BSD.hsc | 98 -------------------------------------------------------
+ 1 file changed, 98 deletions(-)
diff --git a/Network/BSD.hsc b/Network/BSD.hsc
-index b5e9a26..f085f2a 100644
+index d6dae85..27910f4 100644
--- a/Network/BSD.hsc
+++ b/Network/BSD.hsc
-@@ -27,15 +27,6 @@ module Network.BSD
+@@ -30,15 +30,6 @@ module Network.BSD
, getHostByAddr
, hostAddress
@@ -27,7 +27,7 @@ index b5e9a26..f085f2a 100644
-- * Service names
, ServiceEntry(..)
, ServiceName
-@@ -61,14 +52,6 @@ module Network.BSD
+@@ -64,14 +55,6 @@ module Network.BSD
, getProtocolNumber
, defaultProtocol
@@ -42,7 +42,7 @@ index b5e9a26..f085f2a 100644
-- * Port numbers
, PortNumber
-@@ -80,11 +63,7 @@ module Network.BSD
+@@ -83,11 +66,7 @@ module Network.BSD
#if !defined(cygwin32_HOST_OS) && !defined(mingw32_HOST_OS) && !defined(_WIN32)
, getNetworkByName
, getNetworkByAddr
@@ -52,9 +52,9 @@ index b5e9a26..f085f2a 100644
- , getNetworkEntry
- , endNetworkEntry
#endif
+ ) where
- #if defined(HAVE_IF_NAMETOINDEX)
-@@ -298,31 +277,6 @@ getProtocolNumber proto = do
+@@ -303,31 +282,6 @@ getProtocolNumber proto = do
(ProtocolEntry _ _ num) <- getProtocolByName proto
return num
@@ -62,18 +62,18 @@ index b5e9a26..f085f2a 100644
-getProtocolEntry :: IO ProtocolEntry -- Next Protocol Entry from DB
-getProtocolEntry = withLock $ do
- ent <- throwNoSuchThingIfNull "getProtocolEntry" "no such protocol entry"
-- $ c_getprotoent
+- $ trySysCall c_getprotoent
- peek ent
-
-foreign import ccall unsafe "getprotoent" c_getprotoent :: IO (Ptr ProtocolEntry)
-
-setProtocolEntry :: Bool -> IO () -- Keep DB Open ?
--setProtocolEntry flg = withLock $ c_setprotoent (fromBool flg)
+-setProtocolEntry flg = withLock $ trySysCall $ c_setprotoent (fromBool flg)
-
-foreign import ccall unsafe "setprotoent" c_setprotoent :: CInt -> IO ()
-
-endProtocolEntry :: IO ()
--endProtocolEntry = withLock $ c_endprotoent
+-endProtocolEntry = withLock $ trySysCall $ c_endprotoent
-
-foreign import ccall unsafe "endprotoent" c_endprotoent :: IO ()
-
@@ -86,7 +86,7 @@ index b5e9a26..f085f2a 100644
-- ---------------------------------------------------------------------------
-- Host lookups
-@@ -397,31 +351,6 @@ getHostByAddr family addr = do
+@@ -402,31 +356,6 @@ getHostByAddr family addr = do
foreign import CALLCONV safe "gethostbyaddr"
c_gethostbyaddr :: Ptr HostAddress -> CInt -> CInt -> IO (Ptr HostEntry)
@@ -94,13 +94,13 @@ index b5e9a26..f085f2a 100644
-getHostEntry :: IO HostEntry
-getHostEntry = withLock $ do
- throwNoSuchThingIfNull "getHostEntry" "unable to retrieve host entry"
-- $ c_gethostent
+- $ trySysCall $ c_gethostent
- >>= peek
-
-foreign import ccall unsafe "gethostent" c_gethostent :: IO (Ptr HostEntry)
-
-setHostEntry :: Bool -> IO ()
--setHostEntry flg = withLock $ c_sethostent (fromBool flg)
+-setHostEntry flg = withLock $ trySysCall $ c_sethostent (fromBool flg)
-
-foreign import ccall unsafe "sethostent" c_sethostent :: CInt -> IO ()
-
@@ -118,14 +118,14 @@ index b5e9a26..f085f2a 100644
-- ---------------------------------------------------------------------------
-- Accessing network information
-@@ -483,35 +412,6 @@ getNetworkByAddr addr family = withLock $ do
+@@ -488,33 +417,6 @@ getNetworkByAddr addr family = withLock $ do
foreign import ccall unsafe "getnetbyaddr"
c_getnetbyaddr :: NetworkAddr -> CInt -> IO (Ptr NetworkEntry)
-getNetworkEntry :: IO NetworkEntry
-getNetworkEntry = withLock $ do
- throwNoSuchThingIfNull "getNetworkEntry" "no more network entries"
-- $ c_getnetent
+- $ trySysCall $ c_getnetent
- >>= peek
-
-foreign import ccall unsafe "getnetent" c_getnetent :: IO (Ptr NetworkEntry)
@@ -134,13 +134,13 @@ index b5e9a26..f085f2a 100644
--- whether a connection is maintained open between various
--- networkEntry calls
-setNetworkEntry :: Bool -> IO ()
--setNetworkEntry flg = withLock $ c_setnetent (fromBool flg)
+-setNetworkEntry flg = withLock $ trySysCall $ c_setnetent (fromBool flg)
-
-foreign import ccall unsafe "setnetent" c_setnetent :: CInt -> IO ()
-
--- | Close the connection to the network name database.
-endNetworkEntry :: IO ()
--endNetworkEntry = withLock $ c_endnetent
+-endNetworkEntry = withLock $ trySysCall $ c_endnetent
-
-foreign import ccall unsafe "endnetent" c_endnetent :: IO ()
-
@@ -149,11 +149,9 @@ index b5e9a26..f085f2a 100644
-getNetworkEntries stayOpen = do
- setNetworkEntry stayOpen
- getEntries (getNetworkEntry) (endNetworkEntry)
--#endif
--
- -- ---------------------------------------------------------------------------
- -- Interface names
+ #endif
+ -- Mutex for name service lockdown
--
-2.1.4
+1.7.10.4
diff --git a/standalone/android/haskell-patches/network_2.4.1.0_0003-configure-misdetects-accept4.patch b/standalone/android/haskell-patches/network_2.4.1.0_0003-configure-misdetects-accept4.patch
index 932bfe3da..084d355ba 100644
--- a/standalone/android/haskell-patches/network_2.4.1.0_0003-configure-misdetects-accept4.patch
+++ b/standalone/android/haskell-patches/network_2.4.1.0_0003-configure-misdetects-accept4.patch
@@ -1,6 +1,6 @@
-From 21af25e922b00171c07f951a235ff7d7edbbd2be Mon Sep 17 00:00:00 2001
+From 478fc7ae42030c1345e75727e54e1f8f895d3e22 Mon Sep 17 00:00:00 2001
From: dummy <dummy@example.com>
-Date: Thu, 2 Jul 2015 20:14:40 +0000
+Date: Wed, 15 Oct 2014 15:16:21 +0000
Subject: [PATCH] avoid accept4
---
@@ -8,19 +8,19 @@ Subject: [PATCH] avoid accept4
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Network/Socket.hsc b/Network/Socket.hsc
-index 6553bfc..802a7e9 100644
+index 2fe62ee..94db7a4 100644
--- a/Network/Socket.hsc
+++ b/Network/Socket.hsc
-@@ -489,7 +489,7 @@ accept sock@(MkSocket s family stype protocol status) = do
- return new_sock
+@@ -511,7 +511,7 @@ accept sock@(MkSocket s family stype protocol status) = do
#else
with (fromIntegral sz) $ \ ptr_len -> do
+ new_sock <-
-# ifdef HAVE_ACCEPT4
+#if 0
- new_sock <- throwSocketErrorIfMinus1RetryMayBlock "accept"
+ throwSocketErrorIfMinus1RetryMayBlock "accept"
(threadWaitRead (fromIntegral s))
(c_accept4 s sockaddr ptr_len (#const SOCK_NONBLOCK))
-@@ -1565,7 +1565,7 @@ foreign import CALLCONV SAFE_ON_WIN "connect"
+@@ -1602,7 +1602,7 @@ foreign import CALLCONV SAFE_ON_WIN "connect"
c_connect :: CInt -> Ptr SockAddr -> CInt{-CSockLen???-} -> IO CInt
foreign import CALLCONV unsafe "accept"
c_accept :: CInt -> Ptr SockAddr -> Ptr CInt{-CSockLen???-} -> IO CInt
@@ -30,5 +30,5 @@ index 6553bfc..802a7e9 100644
c_accept4 :: CInt -> Ptr SockAddr -> Ptr CInt{-CSockLen???-} -> CInt -> IO CInt
#endif
--
-2.1.4
+2.1.1
diff --git a/standalone/android/haskell-patches/network_2.4.1.0_0006-build-fixes.patch b/standalone/android/haskell-patches/network_2.4.1.0_0006-build-fixes.patch
deleted file mode 100644
index f7cf7c747..000000000
--- a/standalone/android/haskell-patches/network_2.4.1.0_0006-build-fixes.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From cf110acc7f5863bb80ba835a009a7f59d3453239 Mon Sep 17 00:00:00 2001
-From: dummy <dummy@example.com>
-Date: Thu, 2 Jul 2015 20:19:14 +0000
-Subject: [PATCH] fix build
-
----
- Network/BSD.hsc | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/Network/BSD.hsc b/Network/BSD.hsc
-index e11ac71..039d0f1 100644
---- a/Network/BSD.hsc
-+++ b/Network/BSD.hsc
-@@ -396,7 +396,6 @@ instance Storable NetworkEntry where
- poke _p = error "Storable.poke(BSD.NetEntry) not implemented"
-
-
--#if !defined(cygwin32_HOST_OS) && !defined(mingw32_HOST_OS) && !defined(_WIN32)
- getNetworkByName :: NetworkName -> IO NetworkEntry
- getNetworkByName name = withLock $ do
- withCString name $ \ name_cstr -> do
---
-2.1.4
-
diff --git a/standalone/android/haskell-patches/optparse-applicative_remove-ANN.patch b/standalone/android/haskell-patches/optparse-applicative_remove-ANN.patch
deleted file mode 100644
index 1bb843524..000000000
--- a/standalone/android/haskell-patches/optparse-applicative_remove-ANN.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From b128590966d4946219e45e2efd88acf7a354abc2 Mon Sep 17 00:00:00 2001
-From: androidbuilder <androidbuilder@example.com>
-Date: Tue, 14 Oct 2014 02:28:02 +0000
-Subject: [PATCH] remove ANN
-
----
- Options/Applicative.hs | 2 --
- Options/Applicative/Help/Core.hs | 2 --
- 2 files changed, 4 deletions(-)
-
-diff --git a/Options/Applicative.hs b/Options/Applicative.hs
-index bd4129d..f412062 100644
---- a/Options/Applicative.hs
-+++ b/Options/Applicative.hs
-@@ -34,5 +34,3 @@ import Options.Applicative.Common
- import Options.Applicative.Builder
- import Options.Applicative.Builder.Completer
- import Options.Applicative.Extra
--
--{-# ANN module "HLint: ignore Use import/export shortcut" #-}
-diff --git a/Options/Applicative/Help/Core.hs b/Options/Applicative/Help/Core.hs
-index 0a79169..3f1ce3f 100644
---- a/Options/Applicative/Help/Core.hs
-+++ b/Options/Applicative/Help/Core.hs
-@@ -139,5 +139,3 @@ parserUsage pprefs p progn = hsep
- [ string "Usage:"
- , string progn
- , align (extractChunk (briefDesc pprefs p)) ]
--
--{-# ANN footerHelp "HLint: ignore Eta reduce" #-}
---
-1.7.10.4
-
diff --git a/standalone/android/haskell-patches/profunctors_3.3-0001-fix-cross-build.patch b/standalone/android/haskell-patches/profunctors_3.3-0001-fix-cross-build.patch
deleted file mode 100644
index 45397f3e5..000000000
--- a/standalone/android/haskell-patches/profunctors_3.3-0001-fix-cross-build.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 392602f5ff14c0b5a801397d075ddcbcd890aa83 Mon Sep 17 00:00:00 2001
-From: Joey Hess <joey@kitenet.net>
-Date: Thu, 18 Apr 2013 17:50:59 -0400
-Subject: [PATCH] fix cross build
-
----
- src/Data/Profunctor/Unsafe.hs | 3 ---
- 1 file changed, 3 deletions(-)
-
-diff --git a/src/Data/Profunctor/Unsafe.hs b/src/Data/Profunctor/Unsafe.hs
-index 025c7c4..0249274 100644
---- a/src/Data/Profunctor/Unsafe.hs
-+++ b/src/Data/Profunctor/Unsafe.hs
-@@ -40,9 +40,6 @@ import Data.Tagged
- import Prelude hiding (id,(.),sequence)
- import Unsafe.Coerce
-
--{-# ANN module "Hlint: ignore Redundant lambda" #-}
--{-# ANN module "Hlint: ignore Collapse lambdas" #-}
--
- infixr 9 #.
- infixl 8 .#
-
---
-1.8.2.rc3
-
diff --git a/standalone/android/haskell-patches/shakespeare-text_remove-TH.patch b/standalone/android/haskell-patches/shakespeare-text_remove-TH.patch
new file mode 100644
index 000000000..ece906f4b
--- /dev/null
+++ b/standalone/android/haskell-patches/shakespeare-text_remove-TH.patch
@@ -0,0 +1,153 @@
+From dca2a30ca06865bf66cd25cc14b06f5d28190231 Mon Sep 17 00:00:00 2001
+From: dummy <dummy@example.com>
+Date: Thu, 16 Oct 2014 02:46:57 +0000
+Subject: [PATCH] remove TH
+
+---
+ Text/Shakespeare/Text.hs | 125 +++++------------------------------------------
+ 1 file changed, 11 insertions(+), 114 deletions(-)
+
+diff --git a/Text/Shakespeare/Text.hs b/Text/Shakespeare/Text.hs
+index 6865a5a..e25a8be 100644
+--- a/Text/Shakespeare/Text.hs
++++ b/Text/Shakespeare/Text.hs
+@@ -7,18 +7,18 @@ module Text.Shakespeare.Text
+ ( TextUrl
+ , ToText (..)
+ , renderTextUrl
+- , stext
+- , text
+- , textFile
+- , textFileDebug
+- , textFileReload
+- , st -- | strict text
+- , lt -- | lazy text, same as stext :)
++ --, stext
++ --, text
++ --, textFile
++ --, textFileDebug
++ --, textFileReload
++ --, st -- | strict text
++ --, lt -- | lazy text, same as stext :)
+ -- * Yesod code generation
+- , codegen
+- , codegenSt
+- , codegenFile
+- , codegenFileReload
++ --, codegen
++ --, codegenSt
++ --, codegenFile
++ --, codegenFileReload
+ ) where
+
+ import Language.Haskell.TH.Quote (QuasiQuoter (..))
+@@ -45,106 +45,3 @@ instance ToText Int32 where toText = toText . show
+ instance ToText Int64 where toText = toText . show
+ instance ToText Int where toText = toText . show
+
+-settings :: Q ShakespeareSettings
+-settings = do
+- toTExp <- [|toText|]
+- wrapExp <- [|id|]
+- unWrapExp <- [|id|]
+- return $ defaultShakespeareSettings { toBuilder = toTExp
+- , wrap = wrapExp
+- , unwrap = unWrapExp
+- }
+-
+-
+-stext, lt, st, text :: QuasiQuoter
+-stext =
+- QuasiQuoter { quoteExp = \s -> do
+- rs <- settings
+- render <- [|toLazyText|]
+- rendered <- shakespeareFromString rs { justVarInterpolation = True } s
+- return (render `AppE` rendered)
+- }
+-lt = stext
+-
+-st =
+- QuasiQuoter { quoteExp = \s -> do
+- rs <- settings
+- render <- [|TL.toStrict . toLazyText|]
+- rendered <- shakespeareFromString rs { justVarInterpolation = True } s
+- return (render `AppE` rendered)
+- }
+-
+-text = QuasiQuoter { quoteExp = \s -> do
+- rs <- settings
+- quoteExp (shakespeare rs) $ filter (/='\r') s
+- }
+-
+-
+-textFile :: FilePath -> Q Exp
+-textFile fp = do
+- rs <- settings
+- shakespeareFile rs fp
+-
+-
+-textFileDebug :: FilePath -> Q Exp
+-textFileDebug = textFileReload
+-{-# DEPRECATED textFileDebug "Please use textFileReload instead" #-}
+-
+-textFileReload :: FilePath -> Q Exp
+-textFileReload fp = do
+- rs <- settings
+- shakespeareFileReload rs fp
+-
+--- | codegen is designed for generating Yesod code, including templates
+--- So it uses different interpolation characters that won't clash with templates.
+-codegenSettings :: Q ShakespeareSettings
+-codegenSettings = do
+- toTExp <- [|toText|]
+- wrapExp <- [|id|]
+- unWrapExp <- [|id|]
+- return $ defaultShakespeareSettings { toBuilder = toTExp
+- , wrap = wrapExp
+- , unwrap = unWrapExp
+- , varChar = '~'
+- , urlChar = '*'
+- , intChar = '&'
+- , justVarInterpolation = True -- always!
+- }
+-
+--- | codegen is designed for generating Yesod code, including templates
+--- So it uses different interpolation characters that won't clash with templates.
+--- You can use the normal text quasiquoters to generate code
+-codegen :: QuasiQuoter
+-codegen =
+- QuasiQuoter { quoteExp = \s -> do
+- rs <- codegenSettings
+- render <- [|toLazyText|]
+- rendered <- shakespeareFromString rs { justVarInterpolation = True } s
+- return (render `AppE` rendered)
+- }
+-
+--- | Generates strict Text
+--- codegen is designed for generating Yesod code, including templates
+--- So it uses different interpolation characters that won't clash with templates.
+-codegenSt :: QuasiQuoter
+-codegenSt =
+- QuasiQuoter { quoteExp = \s -> do
+- rs <- codegenSettings
+- render <- [|TL.toStrict . toLazyText|]
+- rendered <- shakespeareFromString rs { justVarInterpolation = True } s
+- return (render `AppE` rendered)
+- }
+-
+-codegenFileReload :: FilePath -> Q Exp
+-codegenFileReload fp = do
+- rs <- codegenSettings
+- render <- [|TL.toStrict . toLazyText|]
+- rendered <- shakespeareFileReload rs{ justVarInterpolation = True } fp
+- return (render `AppE` rendered)
+-
+-codegenFile :: FilePath -> Q Exp
+-codegenFile fp = do
+- rs <- codegenSettings
+- render <- [|TL.toStrict . toLazyText|]
+- rendered <- shakespeareFile rs{ justVarInterpolation = True } fp
+- return (render `AppE` rendered)
+--
+2.1.1
+
diff --git a/standalone/android/haskell-patches/skein_hardcode_little-endian.patch b/standalone/android/haskell-patches/skein_hardcode_little-endian.patch
deleted file mode 100644
index 7333742b0..000000000
--- a/standalone/android/haskell-patches/skein_hardcode_little-endian.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 3a04b41ffce4e4e87b0fedd3a1e3434a3f06cc76 Mon Sep 17 00:00:00 2001
-From: foo <foo@bar>
-Date: Sun, 22 Sep 2013 00:18:12 +0000
-Subject: [PATCH] hardcode little endian
-
-This is the same as building with a cabal flag.
-
----
- c_impl/optimized/skein_port.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/c_impl/optimized/skein_port.h b/c_impl/optimized/skein_port.h
-index a2d0fc2..6929bb0 100644
---- a/c_impl/optimized/skein_port.h
-+++ b/c_impl/optimized/skein_port.h
-@@ -45,6 +45,7 @@ typedef uint64_t u64b_t; /* 64-bit unsigned integer */
- * platform-specific code instead (e.g., for big-endian CPUs).
- *
- */
-+#define SKEIN_NEED_SWAP (0)
- #ifndef SKEIN_NEED_SWAP /* compile-time "override" for endianness? */
-
- #include "brg_endian.h" /* get endianness selection */
---
-1.7.10.4
-
diff --git a/standalone/android/haskell-patches/unix-time_hack-for-Bionic.patch b/standalone/android/haskell-patches/unix-time_hack-for-Bionic.patch
index 3f7d2aae7..16c4f92a2 100644
--- a/standalone/android/haskell-patches/unix-time_hack-for-Bionic.patch
+++ b/standalone/android/haskell-patches/unix-time_hack-for-Bionic.patch
@@ -1,6 +1,6 @@
-From da127aa3b2c6cbf679950eb593eb8c88384cc26b Mon Sep 17 00:00:00 2001
+From db9eb179885874af342bb2c3adef7185496ba1f1 Mon Sep 17 00:00:00 2001
From: dummy <dummy@example.com>
-Date: Thu, 2 Jul 2015 20:34:05 +0000
+Date: Wed, 15 Oct 2014 16:37:32 +0000
Subject: [PATCH] hack for bionic
---
@@ -9,10 +9,10 @@ Subject: [PATCH] hack for bionic
2 files changed, 1 insertion(+), 13 deletions(-)
diff --git a/Data/UnixTime/Types.hsc b/Data/UnixTime/Types.hsc
-index 6253b27..fb5b3fa 100644
+index d30f39b..ec7ca4c 100644
--- a/Data/UnixTime/Types.hsc
+++ b/Data/UnixTime/Types.hsc
-@@ -12,8 +12,6 @@ import Data.Binary
+@@ -9,8 +9,6 @@ import Foreign.Storable
#include <sys/time.h>
@@ -20,8 +20,8 @@ index 6253b27..fb5b3fa 100644
-
-- |
-- Data structure for Unix time.
- --
-@@ -33,16 +31,6 @@ data UnixTime = UnixTime {
+ data UnixTime = UnixTime {
+@@ -20,16 +18,6 @@ data UnixTime = UnixTime {
, utMicroSeconds :: {-# UNPACK #-} !Int32
} deriving (Eq,Ord,Show)
@@ -35,14 +35,14 @@ index 6253b27..fb5b3fa 100644
- (#poke struct timeval, tv_sec) ptr (utSeconds ut)
- (#poke struct timeval, tv_usec) ptr (utMicroSeconds ut)
-
- #if __GLASGOW_HASKELL__ >= 704
- instance Binary UnixTime where
- put (UnixTime (CTime sec) msec) = do
+ -- |
+ -- Format of the strptime()/strftime() style.
+ type Format = ByteString
diff --git a/cbits/conv.c b/cbits/conv.c
-index 669cfda..8fa5f9a 100644
+index ec31fef..b7bc0f9 100644
--- a/cbits/conv.c
+++ b/cbits/conv.c
-@@ -98,7 +98,7 @@ time_t c_parse_unix_time_gmt(char *fmt, char *src) {
+@@ -96,7 +96,7 @@ time_t c_parse_unix_time_gmt(char *fmt, char *src) {
#else
strptime(src, fmt, &dst);
#endif
@@ -52,5 +52,5 @@ index 669cfda..8fa5f9a 100644
size_t c_format_unix_time(char *fmt, time_t src, char* dst, int siz) {
--
-2.1.4
+2.1.1
diff --git a/standalone/android/haskell-patches/uuid_build-without-v1-uuid-which-needs-network-info.patch b/standalone/android/haskell-patches/uuid_build-without-v1-uuid-which-needs-network-info.patch
index 048a87fab..12cb2a922 100644
--- a/standalone/android/haskell-patches/uuid_build-without-v1-uuid-which-needs-network-info.patch
+++ b/standalone/android/haskell-patches/uuid_build-without-v1-uuid-which-needs-network-info.patch
@@ -1,15 +1,16 @@
-From 04a1230cf4d740d37ab427165eef4b4db2a3898f Mon Sep 17 00:00:00 2001
-From: dummy <dummy@example.com>
-Date: Fri, 3 Jul 2015 02:20:42 +0000
-Subject: [PATCH] build without v1 uuid which needs network-info
+From 87283f9b6f992a7f0e36c7b1bafc288bf2bf106a Mon Sep 17 00:00:00 2001
+From: androidbuilder <androidbuilder@example.com>
+Date: Mon, 11 Nov 2013 02:46:27 +0000
+Subject: [PATCH] build without v1 uuid which needs network-ino
---
- Data/UUID/Util.hs | 11 -----------
- uuid.cabal | 2 --
- 2 files changed, 13 deletions(-)
+ Data/UUID/Util.hs | 11 -----------
+ Data/UUID/V1.hs | 2 --
+ uuid.cabal | 2 --
+ 3 files changed, 15 deletions(-)
diff --git a/Data/UUID/Util.hs b/Data/UUID/Util.hs
-index 8817f51..0d43b01 100644
+index 581391a..399e508 100644
--- a/Data/UUID/Util.hs
+++ b/Data/UUID/Util.hs
@@ -3,7 +3,6 @@ module Data.UUID.Util (
@@ -23,37 +24,49 @@ index 8817f51..0d43b01 100644
@@ -13,7 +12,6 @@ import Data.Word
import Data.Word.Util
import Data.Bits
- import Data.UUID.Types.Internal
+ import Data.UUID.Internal
-import Network.Info
import Data.Int (Int64)
version :: UUID -> Int
-@@ -42,12 +40,3 @@ extractTime uuid =
-
+@@ -43,12 +41,3 @@ extractTime uuid =
timeAndVersionToTime :: Word16 -> Word16
timeAndVersionToTime tv = tv .&. 0x0FFF
--
+
-extractMac :: UUID -> Maybe MAC
--extractMac uuid =
+-extractMac uuid =
- if version uuid == 1
-- then Just $
+- then Just $
- MAC (node_0 unpacked) (node_1 unpacked) (node_2 unpacked) (node_3 unpacked) (node_4 unpacked) (node_5 unpacked)
- else Nothing
- where
- unpacked = unpack uuid
+-
+diff --git a/Data/UUID/V1.hs b/Data/UUID/V1.hs
+index 067e729..ca4c235 100644
+--- a/Data/UUID/V1.hs
++++ b/Data/UUID/V1.hs
+@@ -37,8 +37,6 @@ import System.IO.Unsafe
+
+ import qualified System.Random as R
+
+-import Network.Info
+-
+ import Data.UUID.Builder
+ import Data.UUID.Internal
+
diff --git a/uuid.cabal b/uuid.cabal
-index 2fa548b..9d86fd2 100644
+index 0a53059..57b1b86 100644
--- a/uuid.cabal
+++ b/uuid.cabal
-@@ -30,7 +30,6 @@ Library
- binary >= 0.4 && < 0.8,
- bytestring >= 0.9 && < 0.11,
+@@ -32,14 +32,12 @@ Library
cryptohash >= 0.7 && < 0.12,
+ deepseq == 1.3.*,
+ hashable (>= 1.1.1.0 && < 1.2.0) || (>= 1.2.1 && < 1.3),
- network-info == 0.2.*,
- random >= 1.0.1 && < 1.2,
- time >= 1.1 && < 1.6,
- uuid-types >= 1.0 && < 2
-@@ -38,7 +37,6 @@ Library
+ random >= 1.0.1 && < 1.1,
+ time >= 1.1 && < 1.5
+
Exposed-Modules:
Data.UUID
Data.UUID.Util
@@ -62,5 +75,5 @@ index 2fa548b..9d86fd2 100644
Data.UUID.V4
Data.UUID.V5
--
-2.1.4
+1.7.10.4
diff --git a/standalone/android/haskell-patches/vector_cross-build.patch b/standalone/android/haskell-patches/vector_cross-build.patch
deleted file mode 100644
index 2abc30599..000000000
--- a/standalone/android/haskell-patches/vector_cross-build.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From 6ffd4fcb7d27ec6df709d80a40a262406446a259 Mon Sep 17 00:00:00 2001
-From: dummy <dummy@example.com>
-Date: Wed, 15 Oct 2014 17:00:56 +0000
-Subject: [PATCH] cross build
-
----
- Data/Vector/Fusion/Stream/Monadic.hs | 1 -
- 2 files changed, 14 deletions(-)
-
-diff --git a/Data/Vector/Fusion/Stream/Monadic.hs b/Data/Vector/Fusion/Stream/Monadic.hs
-index 51fec75..b089b3d 100644
---- a/Data/Vector/Fusion/Stream/Monadic.hs
-+++ b/Data/Vector/Fusion/Stream/Monadic.hs
-@@ -101,7 +101,6 @@ import GHC.Exts ( SpecConstrAnnotation(..) )
-
- data SPEC = SPEC | SPEC2
- #if __GLASGOW_HASKELL__ >= 700
--{-# ANN type SPEC ForceSpecConstr #-}
- #endif
-
- emptyStream :: String
---
-2.1.1
-
diff --git a/standalone/android/haskell-patches/warp_avoid-ipv6-for-android.patch b/standalone/android/haskell-patches/warp_avoid-ipv6-for-android.patch
deleted file mode 100644
index 6144aa0fa..000000000
--- a/standalone/android/haskell-patches/warp_avoid-ipv6-for-android.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From a33437e3150fb33d2fd22d29ff196be28a81c747 Mon Sep 17 00:00:00 2001
-From: androidbuilder <androidbuilder@example.com>
-Date: Thu, 2 Jul 2015 21:48:18 +0000
-Subject: [PATCH] avoid ipv6 for android
-
----
- Network/Wai/Handler/Warp/Run.hs | 9 +--------
- 1 file changed, 1 insertion(+), 8 deletions(-)
-
-diff --git a/Network/Wai/Handler/Warp/Run.hs b/Network/Wai/Handler/Warp/Run.hs
-index 34ae455..ea7475c 100644
---- a/Network/Wai/Handler/Warp/Run.hs
-+++ b/Network/Wai/Handler/Warp/Run.hs
-@@ -14,7 +14,7 @@ import Control.Monad (when, unless, void)
- import Data.ByteString (ByteString)
- import qualified Data.ByteString as S
- import Data.Char (chr)
--import Data.IP (toHostAddress, toHostAddress6)
-+import Data.IP (toHostAddress)
- import Data.IORef (IORef, newIORef, readIORef, writeIORef)
- import Data.Streaming.Network (bindPortTCP)
- import Network (sClose, Socket)
-@@ -323,13 +323,6 @@ serveConnection conn ii origAddr transport settings app = do
- [a] -> Just (SockAddrInet (readInt clientPort)
- (toHostAddress a))
- _ -> Nothing
-- ["PROXY","TCP6",clientAddr,_,clientPort,_] ->
-- case [x | (x, t) <- reads (decodeAscii clientAddr), null t] of
-- [a] -> Just (SockAddrInet6 (readInt clientPort)
-- 0
-- (toHostAddress6 a)
-- 0)
-- _ -> Nothing
- ("PROXY":"UNKNOWN":_) ->
- Just origAddr
- _ ->
---
-2.1.4
-