IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
- Generate debuginfo for kernel packages.
- Process debuginfo in parallel using process-debuginfo script.
- debugedit -n to avoid recomputing build-id.
Allow `crash` (gdb-7.6 based) to work out of the box.
Otherwise it will fail with the error:
Dwarf Error: wrong version in compilation unit header (is 0, should be 2, 3, or 4)
Alas, it will not be able to load debuginfo for the ko modules, but, advanced
user can `eu-elfcompress -t none` them manually.
We can't keep modules uncompressed due to `cpio archive too big - 4136M'
RPM build error.
Avoid `DWARF version 0 unhandled' for compressed ELFs in
find-debuginfo-files.
Based on 6e9fd97f6 ("debugedit: Add -n, --no-recompute-build-id.")
by Mark Wielaard <mark@klomp.org>.
- Support uncompressed (std-def) and compressed (un-def) modules. Also,
support xz(1) compression if we'd switch to it.
- If module is uncompressed it stays in the kernel-image rpm, if it's
compressed then uncompressed module goes into /usr/lib/debug tree and
will be in debuginfo rpm. Compressed modules will be re-compressed after
stripping.
- vmlinuz binary triggers extraction of vmlinux from the kernel-source
tree, and it's then placed into /usr/lib/debug tree, then processed and
stripped as usual.
- Logic of processing of vmlinux binary for domU packages is not changed.
Some flavours do not even pack it. Thus, do not remove your
`%brp_strip_none'.
- Output of file(1) for vmlinuz is only parsed for filename, because, on
different architectures it detects completely different things.
- Debug files are compressed with `eu-elfcompress'.
- You still need to enable `CONFIG_DEBUG_INFO=y' in for `.config'.
No other changes to spec should be needed.
Thanks to Nikita Ermakov for starting this work.
- Added /usr/lib/rpm/armv8l-alt-linux/macros for builds on armv8l machines.
(Fixes 4.0.4-alt108:
- installplatform, rpmrc.in: made armv8l compatible with armh.)
* * *
Add arch_canon statements for "armh", "armv7l", "armv8l". Re-order
them to be more similar to the current upstream rpmrc.in (say,
rpm-4.15 or rpm-4.13.0.1-alt22). Note, however, that this change
doesn't seem to be essential for anything, since "the arch in the lead
[the arch number] is not used for any purpose for most of this
century".[1]
[1]: https://stackoverflow.com/a/39426935/94687 "answer by Jeff Johnson"
* * *
Re-order ARM arch_compat statements to get an order similar to the
upstream (say, rpm-4.15 or rpm-4.13.0.1-alt22) to be able to compare
them more easily; compare to our rpmrc.in:
* the upstream first lists the big-endian archs (noarch -> armv4b);
* then the little-endian ones without hardfloat (noarch -> armv3l -> armv4l ->
-> armv4tl -> armv5tl -> armv5tel -> armv5tejl -> armv6l -> armv7l -> armv8l);
* the the little-endian ones with hardfloat
(noarch -> armv6hl -> armv7hl -> armv7hnl -> armv8hl);
* and separately the 64-bit one (noarch -> aarch64).
In our version of rpm-build we don't have any code for the detection
of the 'h' (hardfloat) or 'n' (neon) CPU features, but we actually
insert our "armh" arch into this chain (with 'h' hardfloat) between
what ought to be "armv6hl" and "armv7hl", and drop "armv6hl" from our
chain; in our compatibility chain, 'h' is silently supposed for "armv7l"
and "armv8l".
However, note a bad thing about this discrepancy: when our rpm-build
builds a package on armv8l targeting this arch, it's arch is armv8l.
However, when installing such a package on a normal ARMv8-A machine,
the 'h' feature must have been detected by "rpm -i", so our just built
package must not match the system arch and the installation must be
denied. However, in practice, I don't see such bad behavior in our
Girar builder when rpminstall-test-archcompat-checkinstall is
invoked... (I don't know why. Perhaps, the 'h' detection code doesn't
work as expected in rpm.)
* * *
Re-order similarly buildarch_compat statements.
Targeting armv8l should trigger all the general ARM conditions in
specfiles and set the custom optflags.
Fixes: c18f1b7d ("installplatform, rpmrc.in: made armv8l compatible with armh")
If rpmbuild is invoked without --target, it looks for the macros based
on `uname -m`. The resulting error message on armv8l machines (when
building a noarch package) was like this:
> Invalid or unknown architecture: noarch-alt-linux
> Executing(%install): /bin/sh -e /tmp/sh.txFqhrP3/rpm-tmp.63120
> error: Bad exit status from /tmp/sh.txFqhrP3/rpm-tmp.63120 (%install)
--a bit misleading due to the following fallback code from macros.in
being executed:
%___build_pre \
%{warn:Invalid or unknown architecture: %{_target_cpu}-%{_vendor}-%{_target_os}\
}exit 1\
%nil
(Are there additional customizations that we might want to enable on
armv8l compared to our armv7l or armh configuration?
armv8l means having AArch32 architecture, typically on a CPU with
AArch64, too. AArch32 means that A32 (ARM) and T32 (Thumb-2)
instruction sets are admitted. See, e.g.,
<https://bgamari.github.io/posts/2019-06-12-arm-terminology.html>.
Currently, our armv8l-alt-linux/macros won't differ essentially from
armv7l-alt-linux/macros. Probably, that's fine, because it seems that
all ARMv8 and all ARMv7 processors support Thumb-2 instructions in the
T32 instruction set, so there are no essential differences in the
optimizations that can be applied.)
Reported-by: Vitaly Chikunov <vt@altlinux.org>
Suggested-by: Dmitry V. Levin <ldv@altlinux.org>
Fixes: c18f1b7d ("installplatform, rpmrc.in: made armv8l compatible with armh")
FCFLAGS is modern replacement of FFLAGS for gfortran.
Details can be found in [1].
Modern Fortran applications use FCFLAGS instead of FFLAGS, so we have
them built without platform-specific and general optimizations.
As an example one may look how libgfortran is being built within gcc-9:
libgfortran/Makefile.in uses only FCFLAGS, not FFLAGS and mary other
applications follow.
[1] https://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.69/html_node/Fortran-Compiler.html
- ldd.in: made preloading of PIE objects work again.
- Set the value of SOURCE_DATE_EPOCH environment variable (if any)
as the source package buildtime.
glibc starting with commit glibc-2.30~85
(elf: Refuse to dlopen PIE objects [BZ #24323])
no longer supports preloading of PIE objects.
Workaround this by swapping the target object and the preloading
PIE object when possible.
Reported-by: ALT beekeeper
Reported-by: Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
When hasher generates an src.rpm from pkg.tar, it sets $SOURCE_DATE_EPOCH
according to pkg.tar's specfile modification time which in turn is set to
the corresponding commit time.
When hasher builds from an src.rpm, it sets $SOURCE_DATE_EPOCH according
to the src.rpm's RPMTAG_BUILDTIME.
This changes helps to connect these two stages, setting the
RPMTAG_BUILDTIME of the generated src.rpm to $SOURCE_DATE_EPOCH.
Co-Authored-by: Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
- find-package, shebang.req: introduced RPM_FINDPACKAGE_MANDATORY=1.
When an interpreter is invoked by name, as in "#!/usr/bin/env python32",
and is missing, this will now force the dependency on /usr/bin/python32.
* build/parsePrep.c (doPatch): Do not pass null pointer to sprintf.
(doAutopatchMacro): Do not pass null pointer to strcmp.
Fixes: 9c18a402 ("Make %autopatch and %patch accept -pg")
- Generate requirements on binaries used in systemd service files
(by Anton V. Boyarshinov)
- Made %autopatch and %patch accept -pg (by Vladimir D. Seleznev).
- Fixed build with new gettext.
* parsePrep.c (doPatch): Change strip argument type to const char *.
(doPatchMacro, doAutopatchMacro): Change opt_p variable type to char *,
change checking of opt_p: it can be either a number or a 'g' symbol
assuming that -pg is a valid option for patch command.
Mechanically substitute _IO_off64_t with off64_t using
$ git grep -Fwl _IO_off64_t |xargs -r sed -i s/_IO_off64_t/off64_t/g
This follows glibc-2.28~574 and fixes build with glibc >= 2.28.
Spec files have a lot of metadata about a project. However one of the
most key components is the upstream version control system which was
notably lacking.
Resolve this by adding a "VCS" key. There is no specification
for contents of this key, given that the set of version control
systems (and features thereof) are not well-defined. However,
recommendations are:
* git: This URL should be in a form that can be passed to "git clone",
with the additional feature that an optional fragment identifier "#foo"
denotes a branch or tag.
%autopatch is a directive to apply all patches, it supports -p<num> and
-F<num> options
%autopatch was initially introduced in rpm.org with version 4.11 but with
different implementation.
The previous attempt to fail build in case of syntax errors
and unknown dependency qualifiers made in commit
rpm-4.8.0-beta1-385-gbf2bc18ebb325f081ade65adc2fbb6858f0b8396
missed the following classes of erroneous dependencies:
Requires(,) -- erroneously treated as Requires(),
Requires(;) -- erroneously treated as Requires(),
Requires(,pre) -- erroneously treated as Requires(),
Requires(;pre) -- erroneously treated as Requires(),
Requires(pre,) -- erroneously treated as Requires(pre),
Requires(pre,,postun) -- erroneously treated as Requires(pre),
Requires(pre,,junk) -- erroneously treated as Requires(pre),
Requires(pre;postun) -- erroneously treated as Requires(pre),
Requires(pre;junk) -- erroneously treated as Requires(pre).
Found by code inspection.
Fixes: bf2bc18ebb32 ("Always fail build on unknown dependency qualifiers")
(cherry picked from rpm.org commit aafb861846db97d78964e98d603b4e6cd88ed3ae)
The two last cases listed above have already been fixed by commit
f7280d8302.
It's always annoying when important information such as compilation
options used for build is not available in build logs just because
silent build rules are enabled by default.
Fix this for the case of build rules generated by configure
by disabling silent rules.
- Fixed deps optimization "due to repentancy": if subpkg A requires subpkg B,
and B has a dependency on C, a weaker dependency on C is removed from A
(say, without an epoch or disttag).
compare_deps() was simply called with a wrong argument (an illegal value
for this parameter); so it returned a meaningful result only if
the compared deps were identical. (Always, since the inception in f5ed7f870a .)
Example where the dep was not optimized out:
Name: test-epoch-repentancy
Version: 1
Release: alt1
Summary: test-epoch-repentancy
License: public domain
Group: Other
Requires: %name-sub = %EVR
Requires: foo = 1-alt1
BuildArch: noarch
%description
%summary
%package sub
Summary: sub
Group: Other
Requires: foo = 0:1-alt1
%description sub
%summary
%files
%files sub
%changelog
* Wed Feb 27 2019 Ivan Zakharyaschev <imz@altlinux.org> 1-alt1
- initial build for ALT Linux Sisyphus.
(cherry picked from commit 492396b532660f4debc46e96eb306f07a3261d66)
# Conflicts:
# build/interdep.c
- Reverted one of the changes (for disttag-unaware tools compatibility)
from 4.0.4-alt127 (useful in rare cases, but bad for external dependencies
on virtual Provides when interpreted by the old rpm):
+ %EVR macro (for intersubpackage deps) upgraded to include %disttag
- Always fix interpackage deps that need Epoch or Disttag (ALT#36180).
(This completes the improvement of 4.0.4-alt100.63.)
- Made deps optimization more aware of disttag:
+ build/reqprov.c: made addReqProv() aware of the disttag of
the package (affects deps optimization).
+ add disttag to struct availablePackage (like buildtime; affects
rpm -U & interdep.c)
[rpm-4.13.0.1-alt5 alike]
+ Implemented DistTag support when comparing package versions (with
help by Vladimir D. Seleznev).
[rpm-4.13.0.1-alt6 alike]
+ rpmEVRcmp() (and hence rpmRangesOverlap()) made asymmetric w.r.t.
underspecified release. (Provides: N = V can't anymore satisfy
Requires: N = V-R.) (with help of Vladimir D. Seleznev)