-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
Something is busted in CabalBundler.OpenBSD
:
# This reports nothing
% cabal-bundler --openbsd stack-2.7.1 2>&1 | grep cmdargs
# This correctly lists cmdargs
% cabal-bundler --curl stack-2.7.1 2>&1 | grep cmdargs
f7d8ea5c4e6af368d9b5d2eb994fc29235406fbe91916a6dc63bd883025eca75 cmdargs-0.10.21.tar.gz
curl --silent --location --output cmdargs-0.10.21.tar.gz 'http://hackage.haskell.org/package/cmdargs-0.10.21/cmdargs-0.10.21.tar.gz'
More specifically, its bfs
function seems to be to blame. Given this patch:
@@ -34,9 +35,12 @@ generateOpenBSD tracer packageName exeName' plan meta = do
let units :: Map P.UnitId P.Unit
units = P.pjUnits plan
+ flip traverse_ (M.keys units) $ \u -> putDebug tracer (show u)
case findExe packageName exeName units of
[(uid0, pkgId0)] -> do
usedUnits <- bfs tracer units uid0
+ putDebug tracer "Used units"
+ flip traverse_ usedUnits $ \u -> putDebug tracer (show u)
deps <- unitsToDeps meta usedUnits
case partition ((pkgId0 == ) . depPkgId) deps of
(mainPackage : _, depUnits) -> do
I see that units
contains cmdargs and usedUnits
does not.
[ 14.51226] debug: UnitId "cmdargs-0.10.21-4a200e2c22dceb11fcfc14a75b5ccfc97e5beabff692ce78854608622c5379d6"
@phadej if you happen to spot the bug, I'll happily skip the hunt. Otherwise I'll figure it out.
Metadata
Metadata
Assignees
Labels
No labels