readline does not work on gentoo amd64 (ghc-6.10.4)

Hi, dear list! libraries@haskell.org treats me as a spammer, so I'm writing here. Today I've stuck with following problems: 1. After recent readline upgrade (5 -> 6) in my distro I got unbuildable lambdabot. After investigating a little I've noticed I'm having broken readline: //===-------------------- $cabal install readline ... $ ghci -package readline GHCi, version 6.10.4: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ... linking ... done. Loading package integer ... linking ... done. Loading package base ... linking ... done. Loading package syb ... linking ... done. Loading package base-3.0.3.1 ... linking ... done. Loading package filepath-1.1.0.2 ... linking ... done. Loading package old-locale-1.0.0.1 ... linking ... done. Loading package old-time-1.0.0.2 ... linking ... done. Loading package unix-2.3.2.0 ... linking ... done. Loading package directory-1.0.0.3 ... linking ... done. Loading package process-1.0.1.1 ... linking ... done. Loading package readline-1.0.1.0 ... <command line>: can't load .so/.DLL for: readline (/usr/lib64/libreadline.so: invalid ELF header) //===-------------------- It's true, there is no real ELF library, but none of packages complained before. //===-------------------- $ cat /usr/lib64/libreadline.so /* GNU ld script Since Gentoo has critical dynamic libraries in /lib, and the static versions in /usr/lib, we need to have a "fake" dynamic lib in /usr/lib, otherwise we run into linking problems. This "fake" dynamic lib is a linker script that redirects the linker to the real lib. And yes, this works in the cross- compiling scenario as the sysroot-ed linker will prepend the real path. See bug http://bugs.gentoo.org/4411 for more info. */ OUTPUT_FORMAT ( elf64-x86-64 ) GROUP ( /lib64/libreadline.so.6 ) //===-------------------- Looks like readline package can't resolve real ELF library path to readline in readline.buildinfo (right after cabal configure): //===-------------------- $ cat readline.buildinfo buildable: True cc-options: ld-options: extra-libraries: readline ncurses frameworks: //===-------------------- And second minor nit: readline tarball is unusable after issuing 'cabal clean': //===-------------------- $ cabal clean && cabal configure cleaning... Resolving dependencies... Configuring readline-1.0.1.0... configure: error: cannot find sources (include/HsReadline.h) in . or .. //===-------------------- Practically these issues can be solved by moving lambdabot to haskeline tracks. Thanks! -- Sergei
participants (1)
-
Sergei Trofimovich