Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread ニール・ゴンパ
I dropped the checking because I don't understand `%{expr:}` well enough to use it yet, and your points make a lot of sense for dropping the checking anyway. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com

Re: [Rpm-maint] [rpm-software-management/rpm] Process scriplets by dependency generators (#1033)

2020-02-04 Thread mikhailnov
Thanks for explaining. Very bad! I see that scriptlets are not treated as separate files there. Maybe it is possible to send scriptlet text to stdin of a generator? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://gi

Re: [Rpm-maint] [rpm-software-management/rpm] Process scriplets by dependency generators (#1033)

2020-02-04 Thread ニール・ゴンパ
> Here I would appreceate pointing to code that generates dependencies by > shebangs for scriplets to see how it works. That's not code generation. The shebang is set as a program in macros or via `-p` and just pushed as `Requires(interp)` dependencies. -- You are receiving this because you ar

Re: [Rpm-maint] [rpm-software-management/rpm] Process scriplets by dependency generators (#1033)

2020-02-04 Thread mikhailnov
Here I would appreceate pointing to code that generates dependencies by shebangs for scriplets to see how it works. > Moreover, attempts to identify programs in shell scripts have been > problematic. If this identifies >50% of programs and does not produces a lot of unresolvable Requires, than

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > @@ -8,13 +8,99 @@ #include "build/rpmbuild_internal.h" #include "debug.h" +static int addLinesFromFile(rpmSpec spec, const char * const fn, rpmTagVal tag) +{ +int nlines = 0; +int flags = STRIP_COMMENTS | STRIP_TRAILINGSPACE; +ARGV_t arg

Re: [Rpm-maint] [rpm-software-management/rpm] Process scriplets by dependency generators (#1033)

2020-02-04 Thread ニール・ゴンパ
It is not possible to evaluate scriptlets for dependencies and pushing that back into rpm. Dependency generators work off of evaluating files to generate dependencies leveraging specific content. Scriptlets generally lack this information. Moreover, attempts to identify programs in shell scripts

Re: [Rpm-maint] [rpm-software-management/rpm] Move out of system.h (#1048)

2020-02-04 Thread Panu Matilainen
Merged #1048 into master. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1048#event-3006346830___ Rpm-maint mailing list Rpm-mai

Re: [Rpm-maint] [rpm-software-management/rpm] Move out of system.h (#1048)

2020-02-04 Thread Panu Matilainen
Yay :smile: -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1048#issuecomment-581940194___ Rpm-maint mailing list Rpm-maint@list

Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread ニール・ゴンパ
Oh, I forgot about that... Lemme rework for that... -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1039#issuecomment-581937258__

Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread Panu Matilainen
Oh and BTW, except for the actual rm and mkdir calls, you could now do all of that checking with just macros, thanks to the new conditional expression stuff, ending with %{error: invalid buildroot}" basically. -- You are receiving this because you are subscribed to this thread. Reply to this em

Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread Panu Matilainen
Okay, but now we're using data from two different sources: %{buildroot} macro and $RPM_BUILD_ROOT environment variable. So it looks inconsistent, but also might *be* inconsistent: they are defined and evaluated in different points in time, and ... although it shouldn't, stuff can happen in the i

Re: [Rpm-maint] [rpm-software-management/rpm] Move out of system.h (#1048)

2020-02-04 Thread Florian Festi
As requested in #1043 -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1048#issuecomment-581924805___ Rpm-maint mailing list Rpm-

[Rpm-maint] [rpm-software-management/rpm] Move out of system.h (#1048)

2020-02-04 Thread Florian Festi
It is needed in lib/rpmplugins.c only anyway. You can view, comment on, or merge this pull request online at: https://github.com/rpm-software-management/rpm/pull/1048 -- Commit Summary -- * Move out of system.h -- File Changes -- M lib/rpmplugins.c (2) M system.h (2) --

Re: [Rpm-maint] [rpm-software-management/rpm] RFC: Limit build parallelism by available memory too, add tunables (#804) (#821)

2020-02-04 Thread Panu Matilainen
This is broken and not going to go anywhere soon. I'll resubmit once fixed. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/821#issuecomment-581905200___

Re: [Rpm-maint] [rpm-software-management/rpm] RFC: Limit build parallelism by available memory too, add tunables (#804) (#821)

2020-02-04 Thread Panu Matilainen
Closed #821. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/821#event-3006041141___ Rpm-maint mailing list Rpm-maint@lists.rpm.o

Re: [Rpm-maint] [rpm-software-management/rpm] Add %alias_provides() as a new "useful generic macro" (#614)

2020-02-04 Thread Florian Festi
Ehmm, this is embarrassing... Sorry, this PR has deserved a far earlier reaction . While I see the use for a macro like this I doubt that the added cost of packagers needing to be aware of it (at latest when encountering it in a spec file) really outweighs the inconvenience of having to write ou

Re: [Rpm-maint] [rpm-software-management/rpm] Add %alias_provides() as a new "useful generic macro" (#614)

2020-02-04 Thread Florian Festi
Closed #614. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/614#event-3005903931___ Rpm-maint mailing list Rpm-maint@lists.rpm.o

Re: [Rpm-maint] [rpm-software-management/rpm] [RFC] Add support for sorting the plus ('+') higher than base version (#924)

2020-02-04 Thread Javier Martinez Canillas
@ffesti that's OK. For the GRUB blscfg module we diverged from the RPM sorting algorithm and added support for the plus character, since debug kernels contains that as a suffix and the expectation is that the debug and non-debug kernels are not the same. -- You are receiving this because you a

Re: [Rpm-maint] [rpm-software-management/rpm] elfdeps: Add full multiarch deps support (#1038)

2020-02-04 Thread ニール・ゴンパ
@Conan-Kudo pushed 1 commit. 17a2747565834832809d2ae53b739c9d94b9bca2 elfdeps: Add full multiarch deps support -- You are receiving this because you are subscribed to this thread. View it on GitHub: https://github.com/rpm-software-management/rpm/pull/1038/files/7532c16153a793d516989f7b0cec622

Re: [Rpm-maint] [rpm-software-management/rpm] [RFC] Add support for sorting the plus ('+') higher than base version (#924)

2020-02-04 Thread Florian Festi
Closed #924. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/924#event-3005860957___ Rpm-maint mailing list Rpm-maint@lists.rpm.o

Re: [Rpm-maint] [rpm-software-management/rpm] [RFC] Add support for sorting the plus ('+') higher than base version (#924)

2020-02-04 Thread Florian Festi
As mentioned above this got rejected already and things have not changed since. We just can't change the way version comparison works as thousands of packages rely on it and any change will break lots of them. Tilde and caret could only be added as they were not allowed previously. See http://li

Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread ニール・ゴンパ
@pmatilai yay, I think I fixed it now. 🤪 -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1039#issuecomment-581882272___ Rpm-maint

Re: [Rpm-maint] [rpm-software-management/rpm] platform: Ensure empty buildroot for %install (#1039)

2020-02-04 Thread ニール・ゴンパ
@Conan-Kudo pushed 1 commit. c730ef92f1fc746495663517e3ef6d92f348ea0f platform: Ensure empty buildroot for %install -- You are receiving this because you are subscribed to this thread. View it on GitHub: https://github.com/rpm-software-management/rpm/pull/1039/files/c5f22b6a202285cb1780a50954

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Florian Festi
ffesti commented on this pull request. > @@ -8,13 +8,99 @@ #include "build/rpmbuild_internal.h" #include "debug.h" +static int addLinesFromFile(rpmSpec spec, const char * const fn, rpmTagVal tag) +{ +int nlines = 0; +int flags = STRIP_COMMENTS | STRIP_TRAILINGSPACE; +ARGV_t argv

Re: [Rpm-maint] [rpm-software-management/rpm] Order Packages by size during build (#1045)

2020-02-04 Thread Panu Matilainen
Yup. Right now this tends to be backwards as debuginfo packages are typically among the largest ones. Starting with the largest ones will also help in further allocating resources (eg use more threads for compressing the larger packages) if we some day get that far. -- You are receiving this

Re: [Rpm-maint] [rpm-software-management/rpm] Fix isUnorderedReq() for multiple qualifiers (#1031)

2020-02-04 Thread Panu Matilainen
Hmm. I think I actually prefer the original fix to isUnorderedReq() instead afterall (sorry). That has the benefit of being trivially backportable (this code is in 4.15 too) and contrary to what I said in the ticket, it *is* different from those install pre/post things. -- You are receiving t

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > @@ -126,5 +126,6 @@ extern int fdatasync(int fildes); #include "misc/fnmatch.h" #include +#include FWIW, the dlfcn.h include doesn't belong there either. -- You are receiving this because you are subscribed to this thread. Reply to this email d

[Rpm-maint] [rpm-software-management/rpm] Cleanups for running external programs (#1047)

2020-02-04 Thread Florian Festi
Do not unset $MALLOC_CHECK_ for external processes Do not use rpmlog() after fork (locking is not safe across fork) You can view, comment on, or merge this pull request online at: https://github.com/rpm-software-management/rpm/pull/1047 -- Commit Summary -- * Do not unset $MALLOC_CHECK_ *

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > @@ -126,5 +126,6 @@ extern int fdatasync(int fildes); #include "misc/fnmatch.h" #include +#include This doesn't belong in system.h. That beast is something to reduce until removed, rather than add to. -- You are receiving this because you are

[Rpm-maint] [rpm-software-management/rpm] If fork fails in getOutputFrom(), close opened unused pipe fds on err… (#1046)

2020-02-04 Thread Florian Festi
…or code path Signed-off-by: Denys Vlasenko You can view, comment on, or merge this pull request online at: https://github.com/rpm-software-management/rpm/pull/1046 -- Commit Summary -- * If fork fails in getOutputFrom(), close opened unused pipe fds on error code pat

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > + rpmlog(RPMLOG_ERR, _("line %d: Bad option %s: %s\n"), + spec->lineNum, + poptBadOption(optCon, POPT_BADOPTION_NOALIAS), + spec->line); + goto exit; +} + +lst = argvNew(); + +for (arg = 1; ar

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > @@ -8,13 +8,99 @@ #include "build/rpmbuild_internal.h" #include "debug.h" +static int addLinesFromFile(rpmSpec spec, const char * const fn, rpmTagVal tag) +{ +int nlines = 0; +int flags = STRIP_COMMENTS | STRIP_TRAILINGSPACE; +ARGV_t arg

Re: [Rpm-maint] [rpm-software-management/rpm] Make "%patchlist -f patches" work. v2 (#1043)

2020-02-04 Thread Panu Matilainen
pmatilai commented on this pull request. > @@ -2244,6 +2245,12 @@ int readManifest(rpmSpec spec, const char *path, const > char *descr, int flags, continue; if (specExpand(spec, lineno, buf, &expanded)) goto exit; + if (flags & STRIP_TRAILINGSPACE) { +

Re: [Rpm-maint] [rpm-software-management/rpm] Fix build regression in commit 307872f71b357a3839fd037514a1c3dabfacc611 (#1044)

2020-02-04 Thread Florian Festi
Merged #1044 into master. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1044#event-3005191389___ Rpm-maint mailing list Rpm-mai

[Rpm-maint] [rpm-software-management/rpm] Order Packages by size during build (#1045)

2020-02-04 Thread Florian Festi
We are now creating the packages in parallel during build. But if the small packages get done quickly and only one big package remains there is nothing left to do in parallel. Ordering the packages by size should improve this and have smaller packages left over for longer during the build. This

[Rpm-maint] [rpm-software-management/rpm] Fix build regression in commit 307872f71b357a3839fd037514a1c3dabfacc611 (#1044)

2020-02-04 Thread Panu Matilainen
Commit 307872f71b357a3839fd037514a1c3dabfacc611 broke build with SELinux enabled but was accidentally merged. Fix the breakage. You can view, comment on, or merge this pull request online at: https://github.com/rpm-software-management/rpm/pull/1044 -- Commit Summary -- * Fix build regression