Permalink
Browse files

Distribution/Gentoo/Packages.hs: handle EAPI=5 SLOT=slot_part/subslot…

…_part

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
  • Loading branch information...
1 parent 6863fbc commit 3f5fea0206c7c16329fdb0752d8daed6ace7de2d @trofi trofi committed Oct 18, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 Distribution/Gentoo/Packages.hs
@@ -87,9 +87,11 @@ getSlot cp = do ex <- doesFileExist sFile
else return Nothing
where
sFile = pkgPath cp </> "SLOT"
+ -- EAPI=5 defines subslots
+ split_slot_subslot = break (== '/')
parse = do fl <- readFile sFile
-- Don't want the trailing newline
- return $ listToMaybe $ lines fl
+ return $ listToMaybe $ map (fst . split_slot_subslot) $ lines fl
-- | Remove the version information from the package name.
stripVersion :: VerPkg -> Pkg

0 comments on commit 3f5fea0

Please sign in to comment.