Menu

#26 cannot find -liberty, Does msys2 has libiberty package?

1.0
closed
Alexx83
None
2016-03-14
2014-03-05
LiTuX
No

Hi, in gettext package, there is libbfd.a. When I'm trying to compile backtrace-mingw, ld said that cannot find -liberty (I've installed binutils).

I've searching via pacman, it seems that there's no libiberty. So which package include it, or will it be added in some package later?

Discussion

  • Alexx83

    Alexx83 - 2014-03-05

    Do you use mingw-w64-{i686,x86_64}-{gcc,binutils} packages?
    If you install just binutils,gcc then it not right because it MSYS versions of packages.

     
    • LiTuX

      LiTuX - 2014-03-05

      I have mingw-w64-i686-gcc, mingw-w64-i686-binutils (and x86_64) installed, not the msys version (msys2-dev).

      Before I install mingw-w64-i686-gettext, libbfd is not available too. Then I installed gettext, now my /mingw32/lib/binutils is:
      $ ls /mingw32/lib/binutils/
      libbfd.a libopcodes.a
      No libiberty.a found in those folders (via find -name).

       
  • Alexx83

    Alexx83 - 2014-03-05
    • status: open --> accepted
    • assigned_to: Alexx83
     
  • Alexx83

    Alexx83 - 2014-03-05

    Fixed in binutils-2.24-5

     
  • Alexx83

    Alexx83 - 2014-03-05
    • status: accepted --> closed
     
  • LiTuX

    LiTuX - 2014-03-05

    Thanks. But I can't upgrade the x86_64 version of binutils, pacman report a 404 (I'll try later).

    I've tested the i686 version, now there is libiberty.a in /mingw32/lib/binutils/, so problem solved. Thank you for your work.

     
  • Mikk

    Mikk - 2016-03-07

    Hi,
    I have same problem - missing "libiberty.a". But if it was fixed in binutils 2.24.5 then why doesn't it exist in new binutils 2.25.1-1 ?

     
  • Alexx83

    Alexx83 - 2016-03-07

    Look into /mingw*/lib/binutils

     
  • Mikk

    Mikk - 2016-03-08

    I don't see "binutils" folder under "mingw32\lib". I have installed all mingw32-binutils 2.25.2-1 package classes. .bin package creates "mingw32\lib\ldscripts" folder with some files but the rest don't put anything there.
    I use Win7 64-bit. MinGW is the regular 32-bit.

    I also created a new issue because this topic is under msys: https://sourceforge.net/p/mingw/bugs/2287/

     

    Last edit: Mikk 2016-03-08
  • Ray Donnelly

    Ray Donnelly - 2016-03-14

    We have nothing to do with msys or mingw. We are MSYS2 and use mingw-w64. libiberty is a convenience library in autotools terms which means it should not be packaged. So really If
    you have some project that needs it then that project is meant to import the sources from gcc, the same way that gdb/binutils does.

     

    Last edit: Ray Donnelly 2016-03-14
  • Mikk

    Mikk - 2016-03-14

    Hi Ray,
    Does this mean that the libiberty is actually not meant to be part of the msys and mingw anymore?
    I know this is msys forum but it's really hard to find release notes or any official statement about what has happened to libiberty.
    I relied on the sentence in this guide that tells to install binutils "dev" package to get libiberty:
    http://www.mingw.org/wiki/howto_install_the_mingw_gcc_compiler_suite
    And since i couldn't get the library i considered it as an issue.

     
  • Alexx83

    Alexx83 - 2016-03-14

    Look carefully into /mingw32/lib folder. There are "binutils" folder there.

     
  • Ray Donnelly

    Ray Donnelly - 2016-03-14

    We package it on MSYS2 as Alexey said. But Mikk, you are not using MSYS2 as far as I can tell! I was making a general point about convenience libraries. In the case of libiberty I agree with the decision to package it with binutils (or gdb or separately).

     
  • Mikk

    Mikk - 2016-03-14

    Hi,
    I have made hidden files visible and i have browsed the mingw-get XML files and there is no libiberty.a installed. I also manually downloaded all binutils files from here:
    https://sourceforge.net/projects/mingw/files/MinGW/Base/binutils/binutils-2.25.1/
    And none of them contains mingw32\lib\libiberty.a
    Last binutils which contained it was binutils-2.23.2-1-mingw32-dev.tar.lzma
    However libiberty source is in binutils-2.25.1-1-mingw32-src.tar.xz
    If it's true that library binary isn't part of the binutils dev anymore then i could try building it also. Maybe after building it ends up in mingwer/lib folder?

     
  • Ray Donnelly

    Ray Donnelly - 2016-03-14

    We are MSYS2 and share nothing in common with mingw.org. Install MSYS2 if you want support from us

     
  • Mikk

    Mikk - 2016-03-14

    Sorry guys... i didn't do enough homework about msys and msys2. I thought they are the same and tighty related with mingw so i continued the disucssion here.
    But now i found a post from you Ray:
    http://stackoverflow.com/questions/25019057/how-are-msys-msys2-and-msysgit-related-to-each-other
    That explains it :)
    Anyway i will try to get help from mingw team directly.

     
  • Ray Donnelly

    Ray Donnelly - 2016-03-14

    No problem. You are welcome to use MSYS2, where as Alexey said, we have libiberty (and countless other benefits)