It's a bug alright. I actually just stumbled on that code a couple of days ago
thinking this doesn't look right. It isn't.
It's not just multiple identical options, it's any local macro multiply
defined, issue being that freeArgs() only ever pops once. Easily reproduced
with eg
> rpm --define
**Describe the bug**
I have spent some time trying to create a completely custom debuginfo file for
a package I maintain.
Currently it is not possible to do so. Even disabling the custom package
template and the whole debug_package machinery via `%global debug_package
%{nil}` if rpm build see
Note the patch was never backported to RHEL-8, hence CentOS 8 being affected
too.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3033#issuecomment-2072488384
You are receiving this because you are subscribed to this thread.
Message
This was fixed "recently" (in 2022) via #2176, closing.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3033#issuecomment-2072485700
You are receiving this because you are subscribed to this thread.
Message ID:
Closed #3033 as completed.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3033#event-12576755985
You are receiving this because you are subscribed to this thread.
Message ID:
___
Rpm-maint
Saner handling of multiple identical options would be nice, but even without
that, the described behavior is wrong. Agreed?
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3056#issuecomment-2072404151
You are receiving this because you
Yes, it's because the engine pushes the macro with each option but only pops it
once.
I guess we could modify freeArgs that it pops until the level is clear, or we
could change setupArgs so that it pushes just once.
But see also https://github.com/rpm-software-management/rpm/pull/2449 that asks
**Describe the bug**
Consider this situation:
Macros:
```
%macro_leaking(E:) %{nil}
%macro_infected(E:) echo -- "%{-E:-E was provided: %{-E*}}%{!-E:there was no
-E}"
```
Notice both macros take an `-E` option with a value. The exact name of that
option is not limited to `E`.
And run:
```
@dmnks commented on this pull request.
> @@ -32,7 +32,7 @@ directories, symlinks etc.
The file triggers are defined in spec files of packages. E.g. file trigger
executing `ldconfig` could be defined in glibc package.
-Similarly to regular triggers, file trigger scripts (except the
@dmnks commented on this pull request.
> @@ -248,4 +248,29 @@ char *argvJoin(ARGV_const_t argv, const char *sep)
return dest;
}
-
+
+ARGV_t argvFromVaList(const char *fmt, va_list ap)
+{
+ARGV_t argv = argvNew();
Oh, fair points, thanks. Will update the PR later.
--
Reply to
After a quick chat on our team channel, this may benefit from packagers'
feedback. It's meant for them, after all. I'll ask for it, let's convert to a
draft meanwhile.
--
Reply to this email directly or view it on GitHub:
@pmatilai commented on this pull request.
> @@ -248,4 +248,29 @@ char *argvJoin(ARGV_const_t argv, const char *sep)
return dest;
}
-
+
+ARGV_t argvFromVaList(const char *fmt, va_list ap)
+{
+ARGV_t argv = argvNew();
No need for argvNew(), argvAdd*() handles that as needed.
@pmatilai commented on this pull request.
> @@ -145,6 +145,9 @@
#%__systemd_sysusers @__SYSTEMD_SYSUSERS@
%__systemd_sysusers%{_rpmconfigdir}/sysusers.sh
+# enable debug package generation
+%_enable_debug_packages 1
I realized this doesn't belong to the main macros.in, really - it
@pmatilai commented on this pull request.
> %global __debug_package 1\
+%(cat > "%{specpartsdir}/rpm-debuginfo.specpart" << EOL\
I'd like it a whole lot more if the `cat` was in the template part. This is an
ugly side-effect for a macro to have, eg somebody doing `rpm --eval
Nice, thanks!
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3055#issuecomment-2071520497
You are receiving this because you are subscribed to this thread.
Message ID: ___
Rpm-maint mailing
Merged #3055 into master.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3055#event-12570092472
You are receiving this because you are subscribed to this thread.
Message ID:
___
Rpm-maint
Closed #3024 as completed via #3047.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3024#event-12570032397
You are receiving this because you are subscribed to this thread.
Message ID:
___
Merged #3047 into master.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3047#event-12570032216
You are receiving this because you are subscribed to this thread.
Message ID:
___
Rpm-maint
Merged #3054 into master.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3054#event-12570029080
You are receiving this because you are subscribed to this thread.
Message ID:
___
Rpm-maint
Added a bunch of rationale/background to the first commit message, no code
changes.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3054#issuecomment-2071512091
You are receiving this because you are subscribed to this thread.
Message
20 matches
Mail list logo