Re: Any way to disable debugsource generation on fedora >= 27

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

 



stan wrote:
> On Wed, 2 May 2018 23:57:53 -0400
> Todd Zullinger <tmz@xxxxxxxxx> wrote:
>> The --with/--without arguments toggle conditions set via
>> %bcond_with and %bcond_without.  So that won't do what Robin
>> wants.
>> 
>> More details on --with/--without are here:
>> 
>> http://rpm.org/user_doc/conditional_builds.html
>> 
> 
> Thanks.
> 
> My knowledge of this is minimal, but I was going by the kernel, which
> was probably a bad choice, as the kernel is unique.  There, passing
> --without-debuginfo turns off debug package generation, but that is
> probably due to special coding in the spec file, shown below.
[...]

Well... I didn't go into all the details about how the
--with/--without options work.  I started to write more in
my initial reply, but then I thought I was getting too deep
in the weeds, so I dropped that. ;)

For a little more detail on it, the kernel isn't doing
anything special there with regards to --with/--without.
They're doing essentially what the %bcond_with/out macros
do.

In /usr/lib/rpm/macros, %bcond_with and %bcond_without are
defined like this:

%bcond_with()    %{expand:%%{?_with_%{1}:%%global with_%{1} 1}}
%bcond_without() %{expand:%%{!?_without_%{1}:%%global with_%{1} 1}}

They're really just shortcuts for setting %with_$foo and
related macros.  You can read more in the macros file,
starting around line 104 in rpm-4.14.0:

https://github.com/rpm-software-management/rpm/blob/rpm-4.14.0-release/macros.in#L104

It's a lot of macro work there, but it boils down to making
things easier for packages to use the %bcond macros and the
--with/--without command line arguments.  Even the command
line arguments are just shortcuts to define %_with_$foo and
%_without_$foo macros.

Hopefully that's at least mildly interesting and/or useful
information.  More importantly, I hope I managed to sum it
up reasonably, without any major errors. ;)

-- 
Todd
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If God had meant for us to be naked, we would have been born that way.

Attachment: signature.asc
Description: PGP signature

_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux