Commit 8e21d5fb authored by Duncan Coutts's avatar Duncan Coutts
Browse files

Simplify previous pkg-config fix

parent aa3bcf99
......@@ -583,12 +583,12 @@ configurePkgconfigPackages verbosity pkg_descr conf
return exe { buildInfo = buildInfo exe `mappend` bi }
pkgconfigBuildInfo :: [Dependency] -> IO BuildInfo
pkgconfigBuildInfo pkgdeps | null pkgs = return mempty
| otherwise = do
pkgconfigBuildInfo [] = return mempty
pkgconfigBuildInfo pkgdeps = do
let pkgs = nub [ display pkg | Dependency pkg _ <- pkgdeps ]
ccflags <- pkgconfig ("--cflags" : pkgs)
ldflags <- pkgconfig ("--libs" : pkgs)
return (ccLdOptionsBuildInfo (words ccflags) (words ldflags))
where pkgs = nub [ display pkg | Dependency pkg _ <- pkgdeps ]
-- | Makes a 'BuildInfo' from C compiler and linker flags.
--
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment