Hi,

Am Sonntag, den 16.08.2015, 12:05 +0200 schrieb Joachim Breitner:
> I am debugging this by passing +RTS -M300M to "Setup configure", to
> make it abort when it starts eating too much memory. The problem seems
> to be in Cabal, namely mappend and simplifyCondTree in
> Distribution.PackageDescription.Configuration. See the attached heap
> profile and profile file.

I think I got it: Cabal tries to infer what feature are supported by
looking at the dependencies, and their flags, and mumble mumble complex
search space. So while it works fine with all dependencies installed,
it works less well with some missing (as on my machine, or on mips),
and Cabal runs wild in the search space.

The solution would be to explicitly tell Cabal what features are
supported. So for example on amd64, you want
$  ./Setup configure -fcryptonite -fdatabase -fnetwork-uri  -f-ekg 
-f-asciiprogress -f-torrentparser -fdesktopnotify -ftahoe -fquvi -ffeed -ftdfa 
-ftestsuite -f-androidsplice -f-android -fproduction -fdns -fxmpp -fpairing 
webapp--fsecure -fwebapp -fassistant -fdbus -finotify -fwebdav -fs3

You can obtain that list from a successful run if you pass "-v" to
configure, and translate this summary into the above format (prefix -f
for =True, -f- for =False)

Flags chosen: cryptonite=True, database=True, network-uri=True, ekg=False,
asciiprogress=False, torrentparser=False, desktopnotify=True, tahoe=True,
quvi=True, feed=True, tdfa=True, testsuite=True, androidsplice=False,
android=False, production=True, dns=True, xmpp=True, pairing=True,
webapp-secure=True, webapp=True, assistant=True, dbus=True, inotify=True,
webdav=True, s3=True

This means on mips, you (Richard) have to manually set some of them to
false. You can probably guess which ones, e.g. webapp.

It is all a bit more manual, but also more explicit: You will not
accidentally lose a feature because a dependency has the wrong version
or is missing, but rather the build will fail. Which is a good thing.
And the error message will hopefully point you at which flag assignment
is wrong.

Potentially, it helps to just set one or two flags on mips, but
guessing which ones are enough to avoid the problem is maybe more work
than simply setting all of them.

Let me know if that solves the problem on mips.

Greetings,
Joachim




-- 
Joachim "nomeata" Breitner
Debian Developer
  nome...@debian.org | ICQ# 74513189 | GPG-Keyid: F0FBF51F
  JID: nome...@joachim-breitner.de | http://people.debian.org/~nomeata

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to