Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 779109 - sys-apps/ibm-powerpc-utils-1.3.8-r1 - configure: error: librtasevent library is missing (on musl)
Summary: sys-apps/ibm-powerpc-utils-1.3.8-r1 - configure: error: librtasevent library ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: PPC64 Linux
: Normal normal (vote)
Assignee: PPC Porters
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: musl-porting
  Show dependency tree
 
Reported: 2021-03-29 15:58 UTC by ernsteiswuerfel
Modified: 2021-05-30 17:40 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (ibm-powerpc-utils-1.3.8-r1:20210329-135037.log,8.14 KB, text/plain)
2021-03-29 15:58 UTC, ernsteiswuerfel
Details
config.log (config.log,45.65 KB, text/plain)
2021-03-29 15:58 UTC, ernsteiswuerfel
Details
emerge --info (file_779109.txt,6.03 KB, text/plain)
2021-03-29 15:59 UTC, ernsteiswuerfel
Details
build.log (ibm-powerpc-utils-1.3.8-r1:20210530-151856.log,8.25 KB, text/plain)
2021-05-30 15:26 UTC, ernsteiswuerfel
Details
config.log (config.log,46.46 KB, text/plain)
2021-05-30 15:27 UTC, ernsteiswuerfel
Details
emerge --info (file_779109.txt,5.82 KB, text/plain)
2021-05-30 15:27 UTC, ernsteiswuerfel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ernsteiswuerfel archtester 2021-03-29 15:58:18 UTC
Created attachment 695976 [details]
build.log

[...]
checking librtas.h usability... yes
checking librtas.h presence... yes
checking for librtas.h... yes
checking for rtas_errinjct_open in -lrtas... yes
checking librtasevent.h usability... yes
checking librtasevent.h presence... yes
checking for librtasevent.h... yes
checking for parse_rtas_event in -lrtasevent... no
configure: error: in `/var/tmp/portage/sys-apps/ibm-powerpc-utils-1.3.8-r1/work/powerpc-utils-1.3.8':
configure: error: librtasevent library is missing (--without-librtas to disable)
See `config.log' for more details

!!! Please attach the following file when seeking support:
!!! /var/tmp/portage/sys-apps/ibm-powerpc-utils-1.3.8-r1/work/powerpc-utils-1.3.8/config.log
 * ERROR: sys-apps/ibm-powerpc-utils-1.3.8-r1::gentoo failed (configure phase):
 *   econf failed
Comment 1 ernsteiswuerfel archtester 2021-03-29 15:58:55 UTC
Created attachment 695979 [details]
config.log
Comment 2 ernsteiswuerfel archtester 2021-03-29 15:59:35 UTC
Created attachment 695982 [details]
emerge --info
Comment 3 Fabian Groffen gentoo-dev 2021-05-21 09:32:10 UTC
The library isn't missing, it is miscompiled.

@ppc, I've filed upsteam:
- https://github.com/ibm-power-utilities/librtas/issues/10
- https://github.com/ibm-power-utilities/powerpc-utils/pull/63

This basically amounts to this musl patch for librtas:

--- a/librtasevent_src/rtas_event.h
+++ b/librtasevent_src/rtas_event.h
@@ -23,6 +23,8 @@
 #ifndef _H_RTAS_EVENT
 #define _H_RTAS_EVENT

+#include <endian.h>
+
 #define PRNT_FMT        "%-20s%08x"
 #define PRNT_FMT_L      PRNT_FMT"    "
 #define PRNT_FMT_R      PRNT_FMT"\n"


and the patch in the pull-request for ibm-powerpc-utils.

Would you be ok with me committing the patches for musl support?
Comment 4 Georgy Yakovlev archtester gentoo-dev 2021-05-29 17:50:16 UTC
feel free to commit those patches to ppcutils and rtas straight to ::gentoo, as long as it still builds on glibc =)
Comment 5 Larry the Git Cow gentoo-dev 2021-05-30 13:57:02 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=201709d5fe0cb18bb6f8f1fd8942ee2cba15a18b

commit 201709d5fe0cb18bb6f8f1fd8942ee2cba15a18b
Author:     Fabian Groffen <grobian@gentoo.org>
AuthorDate: 2021-05-30 13:56:49 +0000
Commit:     Fabian Groffen <grobian@gentoo.org>
CommitDate: 2021-05-30 13:56:58 +0000

    sys-libs/librtas-2.0.2-r1: fix resulting libs using musl
    
    Bug: https://bugs.gentoo.org/779109
    Package-Manager: Portage-3.0.18, Repoman-3.0.2
    Signed-off-by: Fabian Groffen <grobian@gentoo.org>

 sys-libs/librtas/files/librtas-2.0.2-musl.patch | 30 +++++++++++++++++++++++++
 sys-libs/librtas/librtas-2.0.2-r1.ebuild        |  4 +++-
 2 files changed, 33 insertions(+), 1 deletion(-)
Comment 6 Larry the Git Cow gentoo-dev 2021-05-30 14:02:28 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9f43b91a9e3987fbb5aa958d0b32ed5759d7c230

commit 9f43b91a9e3987fbb5aa958d0b32ed5759d7c230
Author:     Fabian Groffen <grobian@gentoo.org>
AuthorDate: 2021-05-30 14:02:17 +0000
Commit:     Fabian Groffen <grobian@gentoo.org>
CommitDate: 2021-05-30 14:02:17 +0000

    sys-apps/ibm-powerpc-utils: fix build using musl
    
    Closes: https://bugs.gentoo.org/779109
    Package-Manager: Portage-3.0.18, Repoman-3.0.2
    Signed-off-by: Fabian Groffen <grobian@gentoo.org>

 .../files/ibm-powerpc-utils-1.3.8-musl.patch       | 95 ++++++++++++++++++++++
 .../ibm-powerpc-utils-1.3.8-r1.ebuild              |  3 +-
 .../ibm-powerpc-utils-99999.ebuild                 |  3 +-
 3 files changed, 99 insertions(+), 2 deletions(-)
Comment 7 ernsteiswuerfel archtester 2021-05-30 15:23:20 UTC
Thanks for your efforts but unfortunately it still does not build despite the musl.patch is pulled in:

[...]
checking for inflate in -lz... yes
checking librtas.h usability... yes
checking librtas.h presence... yes
checking for librtas.h... yes
checking for rtas_errinjct_open in -lrtas... yes
checking librtasevent.h usability... yes
checking librtasevent.h presence... yes
checking for librtasevent.h... yes
checking for parse_rtas_event in -lrtasevent... no
configure: error: in `/var/tmp/portage/sys-apps/ibm-powerpc-utils-1.3.8-r1/work/powerpc-utils-1.3.8':
configure: error: librtasevent library is missing (--without-librtas to disable)
See `config.log' for more details

!!! Please attach the following file when seeking support:
!!! /var/tmp/portage/sys-apps/ibm-powerpc-utils-1.3.8-r1/work/powerpc-utils-1.3.8/config.log
 * ERROR: sys-apps/ibm-powerpc-utils-1.3.8-r1::gentoo failed (configure phase):
 *   econf failed
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-05-30 15:24:43 UTC
Have you rebuilt librtas first?
Comment 9 ernsteiswuerfel archtester 2021-05-30 15:26:56 UTC
Created attachment 712581 [details]
build.log
Comment 10 ernsteiswuerfel archtester 2021-05-30 15:27:17 UTC
Created attachment 712584 [details]
config.log
Comment 11 ernsteiswuerfel archtester 2021-05-30 15:27:59 UTC
Created attachment 712587 [details]
emerge --info
Comment 12 Fabian Groffen gentoo-dev 2021-05-30 15:30:56 UTC
configure:5417: checking for parse_rtas_event in -lrtasevent
configure:5442: powerpc64-gentoo-linux-musl-gcc -o conftest -Os -mcpu=970 -mtune=970 -pipe  -Wl,-O1 -Wl,--as-needed conftest.c -lrtasevent  -lrtas -lz  >&5
/usr/lib/gcc/powerpc64-gentoo-linux-musl/10.2.0/../../../../powerpc64-gentoo-linux-musl/bin/ld: /usr/lib/gcc/powerpc64-gentoo-linux-musl/10.2.0/../../../../lib/librtasevent.so: undefined reference to `be16toh'
/usr/lib/gcc/powerpc64-gentoo-linux-musl/10.2.0/../../../../powerpc64-gentoo-linux-musl/bin/ld: /usr/lib/gcc/powerpc64-gentoo-linux-musl/10.2.0/../../../../lib/librtasevent.so: undefined reference to `be32toh'
collect2: error: ld returned 1 exit status

you probably didn't rebuild librtas
Comment 13 ernsteiswuerfel archtester 2021-05-30 15:46:59 UTC
Oops, true! Now it builds fine. Sorry for the noise..
Comment 14 Michael 'veremitz' Everitt 2021-05-30 15:53:45 UTC
Is there a better way to catch this than we currently do? I know there was talk on IRC (in #g-portage) of a way to rebuild a package WITH all it's dependencies.. but I don't think this has come to fruition.

It's probably one of a few cases, where a revbump makes adjustments easier to 'catch' ..
Comment 15 Michael 'veremitz' Everitt 2021-05-30 15:54:57 UTC
(In reply to Michael 'veremitz' Everitt from comment #14)
> Is there a better way to catch this than we currently do? I know there was
> talk on IRC (in #g-portage) of a way to rebuild a package WITH all it's
> dependencies.. but I don't think this has come to fruition.
> 
> It's probably one of a few cases, where a revbump makes adjustments easier
> to 'catch' ..

I suppose a policy change to make ALL changes to libs /require/ a revbump, might not be a bad thing? WTYT...
Comment 16 Fabian Groffen gentoo-dev 2021-05-30 15:56:38 UTC
I did NOT revbump this on purpose, for I don't want to cause rebuilds for everyone just for 2 people running musl here.  That being, me and OP :)
Comment 17 Michael 'veremitz' Everitt 2021-05-30 15:57:34 UTC
(In reply to Fabian Groffen from comment #16)
> I did NOT revbump this on purpose, for I don't want to cause rebuilds for
> everyone just for 2 people running musl here.  That being, me and OP :)

yeah I know how policy works, and I don't doubt your reasoning either! :]
Comment 18 Fabian Groffen gentoo-dev 2021-05-30 17:40:27 UTC
Just for the record, revbumps would normally be in order here, but since musl on ppc64 isn't even official, let alone musl being very widespread at this point, I just want to keep the rebuild-noise down for "normal" users, this is the same tradeoff I make for Prefix users.  Anyone observing this wrt policies will typically frown, I just keep the majority of users in mind.