Skip to content

Commit

Permalink
Merge pull request #7 from ghorn/master
Browse files Browse the repository at this point in the history
fix getFlagValues in Setup.hs
  • Loading branch information
albertov committed Oct 24, 2017
2 parents aecc2fc + d2cc1db commit b33b49c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Setup.hs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,11 @@ parseLibraries = concatMap go
Nothing -> []

getFlagValues f s = map (\(_:_:v) -> v) filtered
where filtered = filter (\(_:f':_) -> f==f') (words . init $ s)
where filtered = filter (\(_:f':_) -> f==f') (words . rstrip $ s)
rstrip = reverse . rlstrip . reverse
rlstrip ('\n':'\r':x) = x
rlstrip ('\n':x) = x
rlstrip x = x

staticLibNameAndPath :: FilePath -> Maybe (String, FilePath)
staticLibNameAndPath p
Expand Down

0 comments on commit b33b49c

Please sign in to comment.