Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 830391 - app-emulation/qemu-6.2.0-r2: /meson.build:1090:2: ERROR: C static library 'pam' not found
Summary: app-emulation/qemu-6.2.0-r2: /meson.build:1090:2: ERROR: C static library 'pa...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Virtualization Team
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2022-01-01 11:42 UTC by HougeLangley
Modified: 2022-01-04 21:21 UTC (History)
6 users (show)

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


Attachments
emerge --info (emerge --info.rtf,13.46 KB, text/rtf)
2022-01-01 11:43 UTC, HougeLangley
Details
emerge info (emerge --info.txt,9.17 KB, text/plain)
2022-01-01 11:46 UTC, HougeLangley
Details
Build Log (emerge --fulllog.txt,28.73 KB, text/plain)
2022-01-01 11:48 UTC, HougeLangley
Details
emerge -pqv (emerge -pqv.txt,1.25 KB, text/plain)
2022-01-01 11:49 UTC, HougeLangley
Details

Note You need to log in before you can comment on or make changes to this bug.
Description HougeLangley 2022-01-01 11:42:08 UTC
emerge -avuDN @world
app-emulation/qemu-6.2.0-r2 upgrade failed

Reproducible: Always
Comment 1 HougeLangley 2022-01-01 11:43:49 UTC
Created attachment 760959 [details]
emerge --info
Comment 2 HougeLangley 2022-01-01 11:46:09 UTC
Created attachment 760960 [details]
emerge info
Comment 3 HougeLangley 2022-01-01 11:48:25 UTC
Created attachment 760961 [details]
Build Log
Comment 4 HougeLangley 2022-01-01 11:49:48 UTC
Created attachment 760962 [details]
emerge -pqv
Comment 5 Iade Gesso 2022-01-01 14:25:18 UTC
I can confirm... same issue here!

kernel 5.15.6
sys-auth/pambase 20210201.1
sys-libs/pam 1.5.1_p20210622-r1
Comment 6 John Helmert III archtester Gentoo Infrastructure gentoo-dev Security 2022-01-01 18:14:55 UTC
Pam doesn't support static building anymore so not sure there's anything we can do here.
Comment 7 12101111 2022-01-02 07:36:06 UTC
Just remove the check. It build without any problem.

--- a/meson.build
+++ b/meson.build
@@ -1088,8 +1088,7 @@ endif
 pam = not_found
 if not get_option('auth_pam').auto() or have_system
   pam = cc.find_library('pam', has_headers: ['security/pam_appl.h'],
-                        required: get_option('auth_pam'),
-                        kwargs: static_kwargs)
+                        required: get_option('auth_pam'))
 endif
 if pam.found() and not cc.links('''
    #include <stddef.h>
Comment 8 Larry the Git Cow gentoo-dev 2022-01-02 18:38:17 UTC
The bug has been closed via the following commit(s):

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

commit dec64aedba5f8c0ac0c8db358ebeb3dd76f9c0ad
Author:     John Helmert III <ajak@gentoo.org>
AuthorDate: 2022-01-02 18:36:59 +0000
Commit:     John Helmert III <ajak@gentoo.org>
CommitDate: 2022-01-02 18:37:54 +0000

    app-emulation/qemu: REQ_USE+="static? ( !pam )"
    
    Closes: https://bugs.gentoo.org/830391
    Signed-off-by: John Helmert III <ajak@gentoo.org>

 app-emulation/qemu/qemu-6.2.0-r2.ebuild | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Comment 9 John Helmert III archtester Gentoo Infrastructure gentoo-dev Security 2022-01-02 18:40:18 UTC
(In reply to 12101111 from comment #7)
> Just remove the check. It build without any problem.
> 
> --- a/meson.build
> +++ b/meson.build
> @@ -1088,8 +1088,7 @@ endif
>  pam = not_found
>  if not get_option('auth_pam').auto() or have_system
>    pam = cc.find_library('pam', has_headers: ['security/pam_appl.h'],
> -                        required: get_option('auth_pam'),
> -                        kwargs: static_kwargs)
> +                        required: get_option('auth_pam'))
>  endif
>  if pam.found() and not cc.links('''
>     #include <stddef.h>

This seems like something that might work until it doesn't. Feel free to apply that locally, or try to get upstream to change the check, but I don't think it's a good idea to carry this kind of downstream patch.
Comment 10 Thomas Scheiblauer 2022-01-04 12:37:35 UTC
(In reply to Larry the Git Cow from comment #8)

This must also be done for the "static-user" USE flag!
Comment 11 Larry the Git Cow gentoo-dev 2022-01-04 20:21:12 UTC
The bug has been referenced in the following commit(s):

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

commit dcdcdc6949bb6cf0b2e67ee57178677c73a807b6
Author:     John Helmert III <ajak@gentoo.org>
AuthorDate: 2022-01-04 20:19:29 +0000
Commit:     John Helmert III <ajak@gentoo.org>
CommitDate: 2022-01-04 20:20:56 +0000

    app-emulation/qemu: REQ_USE+="static-user? ( !pam )"
    
    Bug: https://bugs.gentoo.org/830391
    Signed-off-by: John Helmert III <ajak@gentoo.org>

 app-emulation/qemu/qemu-6.2.0-r2.ebuild | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Comment 12 Mike Gilbert gentoo-dev 2022-01-04 20:26:26 UTC
It looks like qemu-user doesn't actually get linked with libpam (even with USE=pam), so it might make more sense to just disable pam unconditionally for user targets.
Comment 13 Larry the Git Cow gentoo-dev 2022-01-04 21:21:21 UTC
The bug has been referenced in the following commit(s):

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

commit a7ece93cbf55e30f1dd484d412dc515eed6bcd5d
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2022-01-04 20:45:51 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2022-01-04 21:21:12 +0000

    app-emulation/qemu: sync pam changes in live ebuild
    
    Bug: https://bugs.gentoo.org/830391
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 app-emulation/qemu/qemu-9999.ebuild | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

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

commit be76567556717ebbabdb98dd606ec007594a9678
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2022-01-04 20:40:57 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2022-01-04 21:21:09 +0000

    app-emulation/qemu: disable pam for user targets
    
    Bug: https://bugs.gentoo.org/830391
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 app-emulation/qemu/qemu-6.2.0-r2.ebuild | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)