Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 668850

Summary: mail-mta/nullmailer should respect AR RANLIB
Product: Gentoo Linux Reporter: Denis Pronin <dannftk>
Component: Current packagesAssignee: Robin Johnson <robbat2>
Status: RESOLVED FIXED    
Severity: normal CC: bertrand, haubi, net-mail+disabled, sam
Priority: Normal Keywords: PullRequest
Version: unspecified   
Hardware: All   
OS: Linux   
URL: https://github.com/bruceg/nullmailer/pull/56
See Also: https://github.com/gentoo/gentoo/pull/20604
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Build log

Description Denis Pronin 2018-10-17 08:01:23 UTC
Hi, 

I found the package not correctly compiling and linking when -flto provided in CFLAGS/CXXFLAGS/LDFLAGS
I sort it out and made a PR in github https://github.com/bruceg/nullmailer/pull/56

I am waiting for a response from the maintainer. When they are through we will need to introduce changes

Thank you
Comment 1 Denis Pronin 2018-10-17 09:48:38 UTC
Guys, my mistake, package is not required to have anything changed

We need to update our ebuild-file so that, when we're about to configure package, provide environment variables like AR=$(AR) and RANLIB=$(RANLIB), so that it would look like:

AR=$(AR) RANLIB=$(RANLIB) <ANY_OTHER_ENVIRONMENT_VARIABLES_PASSED>  ./configure
Comment 2 Denis Pronin 2018-10-17 09:54:30 UTC
also we need to remove this line from ebuild 
sed \
		-e "s:^AC_PROG_RANLIB:AC_CHECK_TOOL(AR, ar, false)\nAC_PROG_RANLIB:g" \
		-i configure.ac || die
Comment 3 Denis Pronin 2018-10-17 10:36:06 UTC
So, the solution is to use tc-getAR and tc-getRANLIB eclass's functions when configuring the package by means of econf
Comment 4 Michael Haubenwallner (RETIRED) gentoo-dev 2019-03-29 15:14:59 UTC
(In reply to Denis Pronin from comment #3)
> So, the solution is to use tc-getAR and tc-getRANLIB eclass's functions when
> configuring the package by means of econf

Which values for AR and RANLIB does configure detect on your box without these?
Comment 5 tastytea 2021-04-29 19:04:32 UTC
Created attachment 704100 [details]
Build log

I'm getting the following error with sys-devel/gcc-config[-native-symlinks]:

./mergelib.sh: line 12: ar: command not found

and with `export AR="$(tc-getAR)"` I get:

./mergelib.sh: line 16: ranlib: command not found
Comment 6 Larry the Git Cow gentoo-dev 2022-03-23 01:08:17 UTC
The bug has been closed via the following commit(s):

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

commit 4f8c49d13e49fc5818e759e3b6f6b4020a8b49cc
Author:     Ronny (tastytea) Gutbrod <gentoo@tastytea.de>
AuthorDate: 2021-04-29 19:01:10 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-03-23 01:08:05 +0000

    mail-mta/nullmailer: Set environment variables AR and RANLIB.
    
    The build systems falls back to `ar` and `ranlib` otherwise.
    
    Closes: https://bugs.gentoo.org/668850
    Signed-off-by: Ronny (tastytea) Gutbrod <gentoo@tastytea.de>
    Closes: https://github.com/gentoo/gentoo/pull/20604
    Signed-off-by: Sam James <sam@gentoo.org>

 mail-mta/nullmailer/nullmailer-2.2-r2.ebuild | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)