Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED]ghc fails to emerge while xmonad installation
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Wed Nov 09, 2016 6:49 pm    Post subject: [SOLVED]ghc fails to emerge while xmonad installation Reply with quote

Hello all,

i tired to install xmonad on my machine, but everytime it stops at the emerge of dev-lang/ghc-7.10.3.

Here is the output of emerge --info
[spoiler]
Code:
emerge --info '=dev-lang/ghc-7.10.3::gentoo'
--- Invalid atom in /etc/portage/package.use: dev-lang/python-2.7.10-r1:2.7
Portage 2.3.0 (python 2.7.10-final-0, default/linux/amd64/13.0/desktop, gcc-4.9.3, glibc-2.22-r4, 4.4.26-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.4.26-gentoo-x86_64-Intel-R-_Core-TM-_i5-4460_CPU_@_3.20GHz-with-gentoo-2.2
KiB Mem:     8099760 total,   2448712 free
KiB Swap:     524284 total,    524284 free
Timestamp of repository gentoo: Tue, 08 Nov 2016 18:00:01 +0000
sh bash 4.3_p48
ld GNU ld (Gentoo 2.25.1 p1.1) 2.25.1
app-shells/bash:          4.3_p48::gentoo
dev-lang/perl:            5.22.2::gentoo
dev-lang/python:          2.7.10-r1::gentoo, 3.4.3-r1::gentoo
dev-util/cmake:           3.5.2-r1::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.21.7::gentoo
sys-apps/sandbox:         2.10-r1::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69::gentoo
sys-devel/automake:       1.11.6-r1::gentoo, 1.14.1::gentoo, 1.15::gentoo
sys-devel/binutils:       2.25.1-r1::gentoo
sys-devel/gcc:            4.9.3::gentoo
sys-devel/gcc-config:     1.7.3::gentoo
sys-devel/libtool:        2.4.6::gentoo
sys-devel/make:           4.1-r1::gentoo
sys-kernel/linux-headers: 4.3::gentoo (virtual/os-headers)
sys-libs/glibc:           2.22-r4::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="rsync://mirror.netcologne.de/gentoo/ http://mirror.netcologne.de/gentoo/ ftp://mirror.netcologne.de/gentoo/ http://ftp.halifax.rwth-aachen.de/gentoo/ rsync://ftp.halifax.rwth-aachen.de/gentoo/ ftp://ftp.halifax.rwth-aachen.de/gentoo/ rsync://ftp-stud.hs-esslingen.de/gentoo/ http://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/ ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/"
LANG="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X a52 aac acl acpi alsa amd64 berkdb bindist bluetooth branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr emboss encode exif fam firefox flac fortran gdbm gif glamor gpm gtk iconv infinality ipv6 jpeg lcms ldap libnotify mad mmx mmxext mng modules mp3 mp4 mpeg multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds qt3support readline sdl seccomp session spell sse sse2 ssl startup-notification svg tcpd tiff truetype udev udisks unicode upower usb vorbis wxwidgets x264 xattr xcb xml xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmxext mmx sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby20 ruby21" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
[/spoiler]

here is the complete build log:
https://bpaste.net/show/2a749de3a01d

if someone could lead me to the right direction i would really appreciate that :)

greetings, max


Last edited by maxe on Sat Nov 12, 2016 11:42 am; edited 1 time in total
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Wed Nov 09, 2016 7:43 pm    Post subject: Reply with quote

I think problem is here
Code:
checking whether bootstrap compiler is affected by bug 9439... You are using a new version of LLVM that hasn't been tested yet!
We will try though...
/usr/bin/opt: /var/tmp/portage/dev-lang/ghc-7.10.3/temp/ghc4801_0/ghc_2.ll:7:6: error: unexpected type in metadata definition
!0 = metadata !{metadata !"top", i8* null}
     ^
failed to compile

Not sure but seems that ghc 7.10 need 3.5.0 < llvm < 3.6.0.
Solution are or downgrade llvm or install ghc 8.0.1 from haskell overlay (this version work with llvm-3.6)

References:
https://bugzilla.redhat.com/show_bug.cgi?id=1206852#c4
https://ghc.haskell.org/trac/ghc/ticket/10286
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Wed Nov 09, 2016 8:05 pm    Post subject: Reply with quote

Thanks for the reply @fedeliallalinea

I would actually go ahead and downgrade llvm, but i noticed that its a dependency of mesa.
Thats seems a little bit to risky for me :)

How can i install ghc 8.0.1 from the haskell overlay?
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Wed Nov 09, 2016 8:12 pm    Post subject: Reply with quote

maxe wrote:
How can i install ghc 8.0.1 from the haskell overlay?

You need install layman add overlay with layman -a haskell and finally install ghc emerge -a =dev-lang/ghc-8.0.1::haskell
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Wed Nov 09, 2016 9:12 pm    Post subject: Reply with quote

Thanks for the help. :)

emerge -a =dev-lang/ghc-8.0.1::haskell failed to build.
Here is the log file
http://bpaste.net/show/e58068904a91

Its complaining alot about not found link destinations.
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Thu Nov 10, 2016 7:47 am    Post subject: Reply with quote

Now I have seen in first building this message
Code:
/var/tmp/portage/dev-lang/ghc-7.10.3/image/usr/lib64/ghc-7.10.3/Cabal_EAKqFnGO6aaLkb2rijLhrB/.copyFile16877767871470332231.tmp:
resource exhausted

Probably is only a out of memory problem.
I tried to compile ghc-7.10.3 with llvm-3.7.x and in my pc all compiled with success (me too, I've the error You are using a new version of LLVM that hasn't been tested yet! ).
Sorry yesterday I didn't have my gentoo box for make a test.
Try to compile ghc-7.10.3 with MAKEOPTS="-j1" or add more temporary swap space.
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Thu Nov 10, 2016 6:03 pm    Post subject: Reply with quote

Thanks for the help again fedeliallalinea.

ghc builds now without errors. Ive created a temporary 3GB Swapfile.
After emerging ghc, haskell-updater fails.
here agian the build log:
https://bpaste.net/show/55fd6fbff8e1

Sorry for just posting these. I wish i could do more.
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Thu Nov 10, 2016 9:15 pm    Post subject: Reply with quote

If you want keep version of ghc-8, I think you need to add this patch to haskell-updater-1.2.9 (see here how apply user patch).
Alternately install ghc-7.10.3 and haskell-updater will install without patch
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Fri Nov 11, 2016 3:27 pm    Post subject: Reply with quote

Thats all really informative.
Thanks for the help again.
Every solution you have posted brought me one step further, and i think this is going to end soon and
i finally can enjoy the beauty of xmonad :)

but i need your help once more.
haskell-updater compiled without errors after applying the patch and configuring my package.env file.
But know when i try to compile xmonad it stops at dev-haskell/cabal-1.22.8.0
Here is the log file:
https://bpaste.net/show/5655e5e44853

its an really short log file. at first i thought it may be because of missing swap space, but after adding 1GB more swap it still throws this error.
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Fri Nov 11, 2016 3:43 pm    Post subject: Reply with quote

Not sure but probably with ghc-8.0.1 you need newer version of cabal (try to unmask version 1.24).
At this point I would consider the option to install ghc-7.10.3 (stable version in portage tree)
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Fri Nov 11, 2016 3:52 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Not sure but probably with ghc-8.0.1 you need newer version of cabal (try to unmask version 1.24).
At this point I would consider the option to install ghc-7.10.3 (stable version in portage tree)


Thanks for the quick answer.

How would i go on and install ghc-7.10.3?
unmerging 8.0.1
masking anything higher than 7.10.3 and re-emerge?
Then there is no need for layman right?
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Fri Nov 11, 2016 4:05 pm    Post subject: Reply with quote

maxe wrote:
How would i go on and install ghc-7.10.3?
unmerging 8.0.1
masking anything higher than 7.10.3 and re-emerge?
Then there is no need for layman right?

I think that you have unmasked version 8.0.1 in package.unmask and then remove this entry from file and simply emerge -1a ghc, portage will downgrade.
Remeber to add temporary swap space and also remove patch file for haskell-updater (not needed for this version of ghc)
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Fri Nov 11, 2016 4:14 pm    Post subject: Reply with quote

I dont have a file called package.unmask.
Ive got package.mask which includes this:

Code:
<sys-devel/libtool-2.4.3-r2
<sys-apps/openrc-0.13.0
<sys-process/procps-3.3.9-r2
>dev-lang/perl-5.18.0

I would add
Code:
>dev-lang/ghc-7.10.3

to this file now.

edit: after that i would just run
Code:
emerge -- deep --update --newuse --pretend -va
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Fri Nov 11, 2016 4:22 pm    Post subject: Reply with quote

maxe wrote:
I would add
Code:
>dev-lang/ghc-7.10.3

to this file now.

Or simply remove haskell overlay layman -d haskell. You have added this only for ghc-8.0.1, it makes no sense to have it now
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Fri Nov 11, 2016 4:39 pm    Post subject: Reply with quote

fedeliallalinea wrote:
maxe wrote:
I would add
Code:
>dev-lang/ghc-7.10.3

to this file now.

Or simply remove haskell overlay layman -d haskell. You have added this only for ghc-8.0.1, it makes no sense to have it now


Oh okay, i thought ghc-8.0.1 is also in the portage tree so i have to mask it.
That makes sense.
But i still have to unemerge ghc-8.0.1 right?
Because i get this message here:
Code:
emerge -1a ghc

 * IMPORTANT: 17 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.


These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     UD ] dev-lang/ghc-7.10.3 [8.0.1]

!!! Multiple package instances within a single package slot have been pulled
!!! into the dependency graph, resulting in a slot conflict:

dev-lang/ghc:0

  (dev-lang/ghc-7.10.3:0/7.10.3::gentoo, ebuild scheduled for merge) pulled in by
    dev-lang/ghc (Argument)

  (dev-lang/ghc-8.0.1:0/8.0.1::haskell, installed) pulled in by
    (no parents that aren't satisfied by other packages in this slot)


!!! Enabling --newuse and --update might solve this conflict.
!!! If not, it might help emerge to give a more specific suggestion.


edit:
Code:
emerge -cvp ghc

Calculating dependencies... done!
  dev-lang/ghc-8.0.1 pulled in by:
    app-admin/haskell-updater-1.2.9 requires >=dev-lang/ghc-6.12.1

>>> No packages selected for removal by depclean
Packages installed:   530
Packages in world:    44
Packages in system:   44
Required packages:    530
Number removed:       0


If that helps ..
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Fri Nov 11, 2016 5:13 pm    Post subject: Reply with quote

maxe wrote:
But i still have to unemerge ghc-8.0.1 right?
Because i get this message here

Try with emerge --newuse --update -a ghc as portage suggest.
If not work unmerge ghc and then emerge -1a ghc.
Before unmerge or update create also a binary package of ghc-8.0.1 with quickpkg ghc, with this you can reinstall without recompiling (not required but you can revert current situation quickly if the case) .
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
maxe
n00b
n00b


Joined: 29 Oct 2016
Posts: 19

PostPosted: Fri Nov 11, 2016 6:55 pm    Post subject: Reply with quote

fedeliallalinea wrote:
maxe wrote:
But i still have to unemerge ghc-8.0.1 right?
Because i get this message here

Try with emerge --newuse --update -a ghc as portage suggest.
If not work unmerge ghc and then emerge -1a ghc.
Before unmerge or update create also a binary package of ghc-8.0.1 with quickpkg ghc, with this you can reinstall without recompiling (not required but you can revert current situation quickly if the case) .


Great hint with that quickpkg, wasnt aware of that command.
Seems like it could be handy in alot of situations :)

I unmerged ghc and its recompiling at the moment.
Gonna give feedback about that, hopefully soon :)

Thanks again fedeliallalinea, you were really helpful.

Just a quick question:
How do you knew what to do?
Is it just expierence? Or are there some keywords in logs which you are looking for?
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 21334
Location: here

PostPosted: Sat Nov 12, 2016 5:35 pm    Post subject: Reply with quote

maxe wrote:
Just a quick question:
How do you knew what to do?
Is it just expierence? Or are there some keywords in logs which you are looking for?

Yes the experience it helps a lot, but in most of case searching error in bug.gentoo.org or in bug tracker of package you can find solution.
Don't to forget that there is also the possibility of using google, but in this case you need to find error in build.log (usually search keywords error:).
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum