Hello community,

here is the log from the commit of package ghc-shake-language-c for 
openSUSE:Factory checked in at 2017-04-11 09:43:37
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-shake-language-c (Old)
 and      /work/SRC/openSUSE:Factory/.ghc-shake-language-c.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc-shake-language-c"

Tue Apr 11 09:43:37 2017 rev:2 rq:485160 version:0.10.1

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/ghc-shake-language-c/ghc-shake-language-c.changes    
    2017-03-24 02:05:51.462189676 +0100
+++ 
/work/SRC/openSUSE:Factory/.ghc-shake-language-c.new/ghc-shake-language-c.changes
   2017-04-11 09:43:40.757658184 +0200
@@ -1,0 +2,10 @@
+Mon Mar 27 12:40:44 UTC 2017 - [email protected]
+
+- Update to version 0.10.1 with cabal2obs.
+
+-------------------------------------------------------------------
+Thu Sep 15 06:51:14 UTC 2016 - [email protected]
+
+- Update to version 0.10.0 revision 0 with cabal2obs.
+
+-------------------------------------------------------------------

Old:
----
  shake-language-c-0.9.1.tar.gz

New:
----
  shake-language-c-0.10.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc-shake-language-c.spec ++++++
--- /var/tmp/diff_new_pack.88VsyA/_old  2017-04-11 09:43:41.809509595 +0200
+++ /var/tmp/diff_new_pack.88VsyA/_new  2017-04-11 09:43:41.809509595 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package ghc-shake-language-c
 #
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -19,7 +19,7 @@
 %global pkg_name shake-language-c
 %bcond_with tests
 Name:           ghc-%{pkg_name}
-Version:        0.9.1
+Version:        0.10.1
 Release:        0
 Summary:        Utilities for cross-compiling with Shake
 License:        Apache-2.0

++++++ shake-language-c-0.9.1.tar.gz -> shake-language-c-0.10.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/shake-language-c-0.9.1/CHANGELOG.md 
new/shake-language-c-0.10.1/CHANGELOG.md
--- old/shake-language-c-0.9.1/CHANGELOG.md     2016-04-13 22:53:18.000000000 
+0200
+++ new/shake-language-c-0.10.1/CHANGELOG.md    2017-03-14 14:52:22.000000000 
+0100
@@ -1,5 +1,13 @@
 # Changelog for shake-language-c
 
+## v0.10.1
+
+* Add support for Linux ARMv7
+
+## v0.10.0
+
+* Add mkConfig function that caches dependencies
+
 ## v0.9.1
 
 * Fix host architecture detection on Windows 10
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/shake-language-c-0.9.1/shake-language-c.cabal 
new/shake-language-c-0.10.1/shake-language-c.cabal
--- old/shake-language-c-0.9.1/shake-language-c.cabal   2016-04-13 
22:53:18.000000000 +0200
+++ new/shake-language-c-0.10.1/shake-language-c.cabal  2017-03-14 
14:52:22.000000000 +0100
@@ -13,7 +13,7 @@
 -- limitations under the License.
 
 Name:         shake-language-c
-Version:      0.9.1
+Version:      0.10.1
 Synopsis:     Utilities for cross-compiling with Shake
 Description:  This library provides <http://hackage.haskell.org/package/shake 
Shake> utilities for cross-compiling @C@, @C++@ and @ObjC@ code for various 
target platforms. Currently supported target platforms are Android, iOS, Linux, 
MacOS X, Windows\/MinGW and Google Portable Native Client (PNaCl). Supported 
host platforms are MacOS X, Linux and Windows.
 Category:     Development
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/shake-language-c-0.9.1/src/Development/Shake/Language/C/Config.hs 
new/shake-language-c-0.10.1/src/Development/Shake/Language/C/Config.hs
--- old/shake-language-c-0.9.1/src/Development/Shake/Language/C/Config.hs       
2016-04-13 22:53:18.000000000 +0200
+++ new/shake-language-c-0.10.1/src/Development/Shake/Language/C/Config.hs      
2017-03-14 14:52:22.000000000 +0100
@@ -8,6 +8,7 @@
 -}
 module Development.Shake.Language.C.Config(
     withConfig
+  , mkConfig
   , parsePaths
   , getPaths
 ) where
@@ -19,7 +20,7 @@
 import Development.Shake.Config (readConfigFileWithEnv)
 import Development.Shake.Language.C.Util (words')
 
-newtype Config = Config ([(String, String)], FilePath, String) deriving 
(Show,Typeable,Eq,Hashable,Binary,NFData)
+newtype Config = Config ([FilePath], FilePath, [(String, String)], String) 
deriving (Show,Typeable,Eq,Hashable,Binary,NFData)
 
 {- | Given a list of dependencies, return a function that takes an environment
 of variable bindings, a configuration file path and a configuration variable
@@ -42,11 +43,38 @@
                      -> String
                      -> Action (Maybe String))
 withConfig deps = do
-  fileCache <- newCache $ \(env, file) -> do
+  fileCache <- newCache $ \(file, env) -> do
     need deps
     liftIO $ readConfigFileWithEnv env file
-  query <- addOracle $ \(Config (env, file, key)) -> Map.lookup key <$> 
fileCache (env, file)
-  return $ \env file key -> query (Config (env, file, key))
+  query <- addOracle $ \(Config (_, file, env, key)) -> Map.lookup key <$> 
fileCache (file, env)
+  return $ \env file key -> query (Config ([], file, env, key))
+
+{- | Return a function that takes a list of dependencies, a configuration file
+path, an environment of variable bindings and a configuration variable and
+returns the corresponding configuration value.
+
+This function is more flexible than `Development.Shake.Config.usingConfigFile`.
+It allows the use of multiple configuration files as well as specifying default
+variable bindings.
+
+Typical usage would be something like this:
+
+> -- In the Rules monad
+> getConfig <- mkConfig
+> -- Then in an Action
+> ... value <- getConfig ["some_generated_config.cfg"] [("variable", "default 
value")] "config.cfg" "variable"
+-}
+mkConfig :: Rules (     [FilePath]
+                     -> FilePath
+                     -> [(String,String)]
+                     -> String
+                     -> Action (Maybe String))
+mkConfig = do
+  fileCache <- newCache $ \(deps, file, env) -> do
+    need deps
+    liftIO $ readConfigFileWithEnv env file
+  query <- addOracle $ \(Config (deps, file, env, key)) -> Map.lookup key <$> 
fileCache (deps, file, env)
+  return $ \deps file env key -> query (Config (deps, file, env, key))
 
 -- | Parse a list of space separated paths from an input string. Spaces can be 
escaped by @\\@ characters.
 --
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/shake-language-c-0.9.1/src/Development/Shake/Language/C/Host/Linux.hs 
new/shake-language-c-0.10.1/src/Development/Shake/Language/C/Host/Linux.hs
--- old/shake-language-c-0.9.1/src/Development/Shake/Language/C/Host/Linux.hs   
2016-04-13 22:53:18.000000000 +0200
+++ new/shake-language-c-0.10.1/src/Development/Shake/Language/C/Host/Linux.hs  
2017-03-14 14:52:22.000000000 +0100
@@ -30,6 +30,7 @@
         "i386" -> X86 I386
         "i686" -> X86 I686
         "x86_64" -> X86 X86_64
+        "armv7l" -> Arm Armv7
         _ -> error $ "Unknown host architecture " ++ arch
 
 -- | Get host toolchain.


Reply via email to