| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
We've removed a tonne of obsolete APIs in this release so...
|
|
|
|
|
|
|
|
|
| |
which was accidentially dropped when converting to cmake
Use CMAKE_INSTALL_FULL_SYSCONFDIR as it expands to /etc instead of
/usr/etc
Resolves: #2474
|
|
|
|
| |
Another attempt at commit 7184fb80137363e39d79e2b5a0eb2c4fb060cc2e.
|
| |
|
|
|
|
|
|
|
| |
This fixes a regression from automake where we also didn't use
pkg-config for libmagic.
Fixes: #2246
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There are multiple strange details buried in this all, such as
having to run the main tarball creation in VERBATIM mode due to
git submodule foreach variables, and because of that we can't use
globs in the other commands but have to mask them behind other rules
to do other steps and then concatenate the tarballs at end.
On the build side we need to manually test for the presence of pre-built
content in the source directory (normally that content would be in
binary directories) and install differently in absence of the tooling
that could actually build those docs.
While at it, put both the API docs and man pages in their expected
destinations, install(FILES .. TYPE MAN) is not aware of sections
(:facepalm:) and just puts stuff into the root man directory. With
DOC that is expected, but not where packaging expects to find it.
Except that we're now *installing* the API docs too, put them under
rpm/API docs without any extra html directories in between.
|
| |
|
| |
|
|
|
|
| |
as that's was we actually use
|
|
|
|
|
| |
defaulting to ON. The if clauses were already in place just the option
line was missing.
|
|
|
|
|
|
| |
This has brainfarts and is broken.
This reverts commit 7184fb80137363e39d79e2b5a0eb2c4fb060cc2e.
|
|
|
|
|
|
|
| |
We already violate the 3.12 requirement in a place or two, and
there are many nice things in the later releases. 3.18 is three years
old and is available pretty much anywhere that is even remotely relevant
for us.
|
|
|
|
|
|
|
| |
Most of our dependencies are imported targets already, so while for just
one site this isn't actually any shorter in terms of LoC it's more
consistent with the surroundings in the consuming site, and more so if
we ever need to link to this from some other place.
|
|
|
|
|
| |
Both find_path() and find_library() accept REQUIRED argument, use it
instead of rolling our own.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RPM_MASK_RETURN_TYPE is 0xffff0000 which is UINT_MAX. Per ISO C,
enumerator values must be in the signed int range. gcc is more
forgiving with this than certain versions of clang and if you are on a
random system, such as FreeBSD 13.1 with clang 13.0.0, you will get
this error when trying to compile software that links with librpm and
uses the rpm headers:
error: ISO C restricts enumerator values to range of 'int' (4294901760 is too large) [-Werror,-Wpedantic]
Similar to the other enums in rpmtag.h, RPM_MASK_RETURN_TYPE is not
actually a value used from the enum, so take it out of the enum and
make it a macro.
Signed-off-by: David Cantrell <dcantrell@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Set to 0xffff0000 (or 4294901760), I was getting:
error: ISO C restricts enumerator values to range of 'int' (4294901760 is too large) [-Werror,-Wpedantic]
This happened not when building rpm itself, but when building
rpminspect which links with librpm and uses rpm's headers. The system
in question was FreeBSD 13.1 which has clang 13.0.0.
It is a corner case, but I like testing things on non-Linux platforms
as often as I can to find errors like this.
With this change, the rpm test suite passes for me.
Signed-off-by: David Cantrell <dcantrell@redhat.com>
|
|
|
|
| |
that breaks the OpenSSL build of the interenal PGP parser
|
|
|
|
|
|
| |
'%-x*'
Fixes: #2457
|
|
|
|
|
|
| |
The code in commit 6e03ef19a6b166d7b35ca0952e6091f557b892ca uses single
underscore as intended but the macros file + docs got two due to
whatever brainlapse.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ensure proper installation order and dependencies for custom user/group
usage across packages. These are effectively Requires(pre,postun)
dependencies to prefer during install and preserve the dependency for
installed packages as well.
These new requires require distro level bootstrapping of sorts to get
the provides into place first. To make that less painful, allow turning
the requires into recommends so they wont cause hard failures but will
still cause the right thing to happen when ordering (and depsolving too)
for the packages that do have the provides already.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new built-in %sysusers scriptlet that executes before unpacking
files and creates any sysuser users and groups provided by this package.
This scriptlet gets called with the same arguments as %pre, and
sysusers.d(5) lines are fed into the stdin of the script (ie similar to
file triggers).
systemd-sysusers is the native solution, but compatibility with
non-systemd distros can be achieved by pointing %__systemd_sysusers to a
script that translates the sysusers.d(5) lines into adduser/addgroup
calls or similar.
Unlike all the other package-related scripts, this runs from the outside
of a possible chroot to have access to the user-creation utilities
from the start of the transaction even in case of initial installation.
Users and groups are never deleted, on purpose, as that would lead to
uid/gid reuse and consequently, data leak and general weirdness.
|
|
|
|
|
|
| |
Normally all scriptlets are of course chrooted when the installation is,
but we're about to get an exception to that. No functional changes, just
adding necessary infrastructure for the next steps.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Encode the actual sysusers.d line as base64 in the EVR string to be
passed to systemd-sysusers (or a compatibility script) by rpm during
installation. The source string is \0 padded as needed to avoid base64's
'=' padding in the output as this is not a welcome character in EVR
strings.
For example:
u dnsmasq - "Dnsmasq DHCP and DNS server" /var/lib/dnsmasq
user(dnsmasq) = dSBkbnNtYXNxIC0gIkRuc21hc3EgREhDUCBhbmQgRE5TIHNlcnZlciIgL3Zhci9saWIvZG5zbWFzcQAA
group(dnsmasq)
The EVR string is omitted from the group as that gets created as a
side-effect of the user creation and does not require calling
systemd-sysusers.
|
|
|
|
|
|
|
| |
These often come from a separate package that is installed early on
and form the basis of system users and groups, augmented by sysusers
from other packages. We don't want to create such users, but we need to
be aware of where they come from for dependency resolution and ordering.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Take advantage of the new %{getncpus:proc/thread} functionality when
calculating the number of processes/threads to use during build.
The goal here is to avoid gross overallocation of processes/threads
on constrained systems. In particular threads on 32bit systems where
address space is limited, but also to allow packagers to easily tune for
gigantic build jobs such as webkit that may overwhelm otherwise adequate
systems.
Fixes: #804, RhBug:1118734
|
|
|
|
|
|
| |
Take advantage of the new %{getncpus:thread} functionality when
calculating the number of threads to use for io stream compression
(when not in parallel region)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
"total" equals calling with no arguments, "proc" and "thread" consider
further constraints, what is implemented here is heuristics based on
available physical memory and address-space and %_smp_tasksize_proc /
%_smp_tasksize_thread tunables.
Change the previous %getncpus related tests to use %getconfdir instead,
they are testing unexpected arguments behavior for this type of macro,
not %getncpus itself. Add a test for the actual functionality: if nproc
is available, test that our total matches with that, and that defining
tasksize to total memory only allocates one thread. Optimally we'd
test separately for 32bit address space limitations but that gets tough
when we have no idea where this will be executed.
|
| |
|
|
|
|
|
|
| |
For whatever historical reasons RPMCONFIGDIR was used in automake
whereas the environment variable is RPM_CONFIGDIR. Just call it that
everywhere.
|
|
|
|
|
|
|
|
|
|
| |
The vendor was hardwired to "redhat" as a leftoever from early cmake
bootstrapping phase and bugs in the surrounding logic. Simplify the
setup somewhat: call the setting RPM_VENDOR and pass that around in the
code tree as well. The CANON fubar along with other similar weirdness
can thus remain hidden in the makemacros() cmake function.
Reported and initial patch by Neil Gompa.
|
|
|
|
|
|
|
|
|
|
| |
Refactor the dist rule into a slightly more generic function that
we can call with suitable values for generating dist and snapshot
tarballs.
This includes preliminaries for requiring a tag for dist tarball
but that involves further complications so not done yet. Local HEAD
is not exactly the right thing to be building dist tarballs from.
|
| |
|
| |
|
| |
|
|
|
|
| |
Now that we can, let rpmdsSetIx() take care of the details.
|
|
|
|
| |
I'll add the printf() if I need it...
|
|
|
|
|
|
| |
Globally exported variables like this are evil. This one hasn't done
anything in a while, just forgotten. We're bumping soname so we're free
to remove cruft like this.
|
|
|
|
|
|
|
|
|
|
|
| |
rpmdsSetIx() has shared the same flaw that was fixed for rpmfiSetFX()
in commit 318efbaec80a90f1d9ac76d0cd433f6ea3c103fa: sometimes -1 means
success and sometimes it means error. And like in that case, this is so
broken that nobody can have relied on the behavior (we had one internal
user which was lucky if anything).
At least as bad is that it never actually bothered to check whether the
newly set index is valid.
|
|
|
|
|
|
| |
We have rpmdsCompareIndex(), use it so we don't need to muck around with
the iterator index and attempt to restore with the broken API that
rpmdsSetIx() is. Cleans up the code quite a bit.
|