Re: Changes to build environment

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thursday, June 22, 2023 2:14:22 PM EDT Fabio Valentini wrote:
> On Thu, Jun 22, 2023 at 7:57 PM Steve Grubb <sgrubb@xxxxxxxxxx> wrote:
> > I have switched to F38 and find a couple items annoying. I have a
> > workflow that checks things I develop out of github, rolls it up into
> > an rpm, builds it, and runs the results through annocheck.
> >
> > If there is a warning I'd like to investigate, I cd into the build
> > directory.  But oops, now its gone (problem #1). OK, I use rpmbuild -bc 
> > to rebuild it. I cd into the build directory make a change and run make.
> >
> > gcc: fatal error: environment variable 'RPM_ARCH' not defined
> >
> > (problem #2)
> >
> > How do I fix these things?
> 
> Not sure if these *can* be fixed in general.

This worked fine in F37. There is some intentional change somewhere that 
causes this.

> #1 is a behaviour change of RPM in a recent release, but there's a CLI
> switch to turn off cleaning up the build directory.

Is there a rpmmacros configuration option that undoes this so I do not have to 
fix dozens of scripts?

> In the case of RPM_ARCH, it's because the CFLAGS / LDFLAGS (I think?)
> build flags set in %build use this environment variable.

This sounds like something rolled out without proper automake/autoconf 
support. If rpmbuild is supplying this during build, it should not. It should 
supply this to configure and it get captured into the Makefile and then into 
the link targets. This is a very recent problem. I now complain about #1 
because we now have #2.

> I think trying to recreate the RPM build environment outside of mock
> manually (to reproduce issues) is a lost cause though (and you get a
> different environment than the one that had the issue!) ...It's not
> perfect, but mock is almost always the best way to build RPMs (i.e.
> never use "rpmbuild -bb" outside mock), but that's just my opinion
> ¯\_(ツ)_/¯

It works fine on F37. This is a recent regression.

-Steve

_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux