[dev] Update RPM to 4.17.0 (#1510)

* Update RPM version to 4.17.0
* Add debugedit with tarballs
* Add changes related to encoding
* Update license map
* Update manifests
* Update SPECS/mariner-rpm-macros/gen-ld-script.sh
* Update signatures for mariner-rpm-macros
* Remove nss from the toolchain
* Substitute make invocations with macros
* Remove ndb sha from toolchain
* Fix toolchain manifests
Co-authored-by: Pawel Winogrodzki <pawelwi@microsoft.com>
This commit is contained in:
Mateusz Malisz 2021-10-14 16:41:40 -07:00 committed by GitHub
parent 973e10f0ff
commit 9c486c0633
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
32 changed files with 271 additions and 711 deletions

File diff suppressed because one or more lines are too long

View File

@ -258,6 +258,7 @@
"cloud-init-vmware-guestinfo",
"coredns-1.6.7",
"coredns-1.7.0",
"debugedit",
"dejavu-fonts",
"distroless-packages",
"dtc",

View File

@ -22,7 +22,7 @@
Summary: An SSL/TLS protocol implementation
Name: boringssl
Version: 20200921
Release: 2%{?dist}
Release: 3%{?dist}
License: OpenSSL
Vendor: Microsoft Corporation
Distribution: Mariner
@ -108,7 +108,7 @@ find %{buildroot}%{src_install_dir} -type f \( -name "*.a" -o -name "*.lib" -o -
find %{buildroot}%{src_install_dir} -type f -name "*.sh" -exec chmod +x "{}" +
# Fix env-script-interpreter error.
find %{buildroot}%{src_install_dir} -type f -name "*.pl" -exec sed -i 's|#!.*/usr/bin/env perl|#!%{_bindir}/perl|' "{}" +
find %{buildroot}%{src_install_dir} -type f -name "*.py" -exec sed -i 's|#!.*/usr/bin/env python.*|#!%[_bindir]/python3|' "{}" +
find %{buildroot}%{src_install_dir} -type f -name "*.py" -exec sed -i 's|#!.*/usr/bin/env python.*|#!%{_bindir}/python3|' "{}" +
find %{buildroot}%{src_install_dir} -type f -name "*.sh" -exec sed -i 's|#!.*/usr/bin/env bash|#!/bin/bash|' "{}" +
# To avoid conflicts with openssl development files, change all includes from
@ -137,6 +137,10 @@ find src/include/openssl -type f -execdir install -D -m0644 "{}" "%{buildroot}%{
%{src_install_dir}
%changelog
* Tue Oct 12 2021 Mateusz Malisz <mamalisz@microsoft.com> - 20200921-3
- Unify macro syntax used in the spec.
* Tue Oct 12 2021 Pawel Winogrodzki <pawelwi@microsoft.com> - 20200921-2
- Switching to using a single digit for the 'Release' tag.
@ -146,7 +150,7 @@ find src/include/openssl -type f -execdir install -D -m0644 "{}" "%{buildroot}%{
- Fix Source URL
- Change build requirement from ninja to ninja-build
- Modify location of shared library files
- Add _binaries_in_noarch_packages_terminate_build definition to resolve arch dependent binary error
- Add _binaries_in_noarch_packages_terminate_build definition to resolve arch dependent binary error
- Remove unsupported architectures in CBL-Mariner from ExclusiveArch list
* Mon May 17 2021 mrostecki@suse.com

View File

@ -0,0 +1,5 @@
{
"Signatures": {
"debugedit-5.0.tar.xz": "e9ecd7d350bebae1f178ce6776ca19a648b6fe8fa22f5b3044b38d7899aa553e"
}
}

View File

@ -0,0 +1,35 @@
Summary: Debugedit - obtain debug information from binaries.
Name: debugedit
Version: 5.0
Release: 1%{?dist}
License: GPLv3+
URL: https://sourceware.org/debugedit/
Vendor: Microsoft Corporation
Distribution: Mariner
Source0: https://sourceware.org/ftp/%{name}/%{version}/%{name}-%{version}.tar.xz
%description
%{summary}
%prep
%autosetup
%build
%configure
%make_build
%install
%make_install
%check
%make_build_check
%files
%defattr(-,root,root)
%license COPYING3
%{_bindir}/*
%{_mandir}/*/*
%changelog
* Fri Oct 08 2021 Mateusz Malisz <mamalisz@microsoft.com> 5.0-1
- Original version for CBL-Mariner

View File

@ -9,8 +9,8 @@
# /usr/lib/rpm/mariner/gen-ld-script.sh %{name} %{version}
echo "gen-ld-script.sh name($1) version($2)"
OS_ID=$(grep -oP '(?<=^ID=).+' /etc/os-release | tr -d '"')
OS_VERSION=$(grep -oP '(?<=^VERSION_ID=).+' /etc/os-release | tr -d '"')
OS_ID=$(sed -En 's/^ID="?([^"]+)"?/\1/p' /etc/os-release)
OS_VERSION=$(sed -En 's/^VERSION_ID="?([^"]+)"?/\1/p' /etc/os-release)
# Count number of dot separators in $2 (version)
NUM_DOT_SEPARATORS="${2//[^.]}"

View File

@ -9,7 +9,7 @@ import argparse
import json
import struct
VERSION = "2.0.0"
VERSION = "2.0.1"
MEMORY_ALIGN = 4
N_TYPE = 0xcafe1a7e
OWNER = 'FDO'
@ -225,7 +225,6 @@ class LinkerScript():
with open(file_name, "wb") as f:
f.write(bytearray(self.comment.encode('ascii')))
f.write(bytearray(self.text.encode('ascii')))
print("Linker script, {}, was written successfully.".format(file_name))
def generate_cpp_header(module_info):
@ -316,12 +315,10 @@ def parse_args():
sys.exit(0)
if __name__ == '__main__':
print("==== ELF note generator v{} ====\n\n".format(VERSION))
print("==== ELF note generator v{} ====".format(VERSION))
args = parse_args()
print("Note section memory alignment: {}\n\n".format(args.endian))
endian = Endian.map[args.endian]
stamp_method = args.stamp
print("Stamp method: {}\n".format(stamp_method))
delattr(args, 'endian')
delattr(args, 'stamp')

View File

@ -204,4 +204,7 @@ end
%_smp_mflags "-j%{_smp_build_ncpus}"
# A directory for appdata metainfo.
%_metainfodir %{_datadir}/metainfo
%_metainfodir %{_datadir}/metainfo
# New version of RPM has stricter approach to encoding; turn the errors off temporarily.
%_invalid_encoding_terminates_build 0

View File

@ -7,10 +7,10 @@
"default-hardened-cc1": "2102bdfbb06934d95ceb3c81f789c59c9f77f91b0f996fd39588e0aa052d6f77",
"default-hardened-ld": "4dbb822a27eed292759bc4e9cabb4b84f34fc6701535fcac2fdddac33328678b",
"forge.lua": "7390af6e81d8d61bc6957127fe9ebdbf5223e96d3810855641bdecc2a03800b4",
"gen-ld-script.sh": "299d6dd55f56bf58a175ce86f540299a02d9df2add199556f5825a39e34927f3",
"generate-package-note.py": "d06816bbe7f2ae5a92d4320effd83ad6cd88bcc24db4d1649b2790d87e33599e",
"gen-ld-script.sh": "aab480385968d2de16cc00e2662f97ee2ae7493dbb728b9d02b37c03b03db19a",
"generate-package-note.py": "c17de89e517833d107353f7ae700c596ed6116cb2e7c10bb7b632723f76cf58c",
"gpgverify": "db0e050f56b694497d70603a6f5c17dd60ddbcf7cee670616851cd389f6767c4",
"macros": "0db278ad00670f210c07ef23defe359b430767b9140d51c25115435ec3a16c3a",
"macros": "6dceae8e111c7f56b56c91c4cc10f488ed8fb98166db5e4e26f94d651455bf5e",
"macros.check": "79367176c3c7d10c0158b6e5d881e0fc3c8fd50c5957dad2f097c2d4a37833e7",
"macros.fonts": "f52edc646414c5dd0f5f4cdd570f2f9dbe6fb97d4f0db360908deb56d96492f8",
"macros.forge": "8785fe3de4570d6b78dc40aa2f0a4124ce1ddb6282fe3060fb0ae2001178abe6",

View File

@ -6,7 +6,7 @@
Summary: Mariner specific rpm macro files
Name: mariner-rpm-macros
Version: 2.0
Release: 5%{?dist}
Release: 6%{?dist}
License: GPL+ AND MIT
Vendor: Microsoft Corporation
Distribution: Mariner
@ -120,6 +120,11 @@ install -p -m 644 -t %{buildroot}%{rcluadir}/srpm forge.lua
%{_rpmconfigdir}/macros.d/macros.check
%changelog
* Mon Oct 11 2021 Mateusz Malisz <mamalisz@microsoft.com> - 2.0-6
- Remove too verbose logs from the linker script
- Update default mariner macros with invalid_encoding_terminates_build
- Update linker script to use sed instead of "grep -P" and "tr"
* Tue Sep 21 2021 Andrew Phelps <anphel@microsoft.com> - 2.0-5
- Modify gen-ld-script.sh to ensure moduleVersion contains 4 part version

View File

@ -1,104 +0,0 @@
From 8f4b3c3cab8922a2022b9e47c71f1ecf906077ef Mon Sep 17 00:00:00 2001
From: Demi Marie Obenour <athena@invisiblethingslab.com>
Date: Mon, 8 Feb 2021 16:05:01 -0500
Subject: [PATCH] hdrblobInit() needs bounds checks too
Users can pass untrusted data to hdrblobInit() and it must be robust
against this.
Modified to fit CBL-Mariner.
---
lib/header.c | 48 +++++++++++++++++++++++++++++++-----------------
1 file changed, 31 insertions(+), 17 deletions(-)
diff --git a/lib/header.c b/lib/header.c
index ea39e679f4..ebba9c2b09 100644
--- a/lib/header.c
+++ b/lib/header.c
@@ -11,6 +11,7 @@
#include "system.h"
#include <netdb.h>
#include <errno.h>
+#include <inttypes.h>
#include <rpm/rpmtypes.h>
#include <rpm/rpmstring.h>
#include "lib/header_internal.h"
@@ -1912,6 +1913,25 @@ hdrblob hdrblobFree(hdrblob blob)
return NULL;
}
+static rpmRC hdrblobVerifyLengths(rpmTagVal regionTag, uint32_t il, uint32_t dl,
+ char **emsg) {
+ uint32_t il_max = HEADER_TAGS_MAX;
+ uint32_t dl_max = HEADER_DATA_MAX;
+ if (regionTag == RPMTAG_HEADERSIGNATURES) {
+ il_max = 32;
+ dl_max = 64 * 1024 * 1024;
+ }
+ if (hdrchkRange(il_max, il)) {
+ rasprintf(emsg, _("hdr tags: BAD, no. of tags(%" PRIu32 ") out of range"), il);
+ return RPMRC_FAIL;
+ }
+ if (hdrchkRange(dl_max, dl)) {
+ rasprintf(emsg, _("hdr data: BAD, no. of bytes(%" PRIu32 ") out of range"), dl);
+ return RPMRC_FAIL;
+ }
+ return RPMRC_OK;
+}
+
rpmRC hdrblobRead(FD_t fd, int magic, int exact_size, rpmTagVal regionTag, hdrblob blob, char **emsg)
{
int32_t block[4];
@@ -1924,13 +1944,6 @@ rpmRC hdrblobRead(FD_t fd, int magic, int exact_size, rpmTagVal regionTag, hdrbl
size_t nb;
rpmRC rc = RPMRC_FAIL; /* assume failure */
int xx;
- int32_t il_max = HEADER_TAGS_MAX;
- int32_t dl_max = HEADER_DATA_MAX;
-
- if (regionTag == RPMTAG_HEADERSIGNATURES) {
- il_max = 32;
- dl_max = 8192;
- }
memset(block, 0, sizeof(block));
if ((xx = Freadall(fd, bs, blen)) != blen) {
@@ -1943,15 +1956,9 @@ rpmRC hdrblobRead(FD_t fd, int magic, int exact_size, rpmTagVal regionTag, hdrbl
goto exit;
}
il = ntohl(block[2]);
- if (hdrchkRange(il_max, il)) {
- rasprintf(emsg, _("hdr tags: BAD, no. of tags(%d) out of range"), il);
- goto exit;
- }
dl = ntohl(block[3]);
- if (hdrchkRange(dl_max, dl)) {
- rasprintf(emsg, _("hdr data: BAD, no. of bytes(%d) out of range"), dl);
+ if (hdrblobVerifyLengths(regionTag, il, dl, emsg))
goto exit;
- }
nb = (il * sizeof(struct entryInfo_s)) + dl;
uc = sizeof(il) + sizeof(dl) + nb;
@@ -1995,11 +2002,18 @@ rpmRC hdrblobInit(const void *uh, size_t uc,
struct hdrblob_s *blob, char **emsg)
{
rpmRC rc = RPMRC_FAIL;
-
memset(blob, 0, sizeof(*blob));
+ if (uc && uc < 8) {
+ rasprintf(emsg, _("hdr length: BAD"));
+ goto exit;
+ }
+
blob->ei = (int32_t *) uh; /* discards const */
- blob->il = ntohl(blob->ei[0]);
- blob->dl = ntohl(blob->ei[1]);
+ blob->il = ntohl((uint32_t)(blob->ei[0]));
+ blob->dl = ntohl((uint32_t)(blob->ei[1]));
+ if (hdrblobVerifyLengths(regionTag, blob->il, blob->dl, emsg) != RPMRC_OK)
+ goto exit;
+
blob->pe = (entryInfo) &(blob->ei[2]);
blob->pvlen = sizeof(blob->il) + sizeof(blob->dl) +
(blob->il * sizeof(*blob->pe)) + blob->dl;

View File

@ -1,192 +0,0 @@
From d6a86b5e69e46cc283b1e06c92343319beb42e21 Mon Sep 17 00:00:00 2001
From: Panu Matilainen <pmatilai@redhat.com>
Date: Thu, 4 Mar 2021 13:21:19 +0200
Subject: [PATCH] Be much more careful about copying data from the signature
header
Only look for known tags, and ensure correct type and size where known
before copying over. Bump the old arbitrary 16k count limit to 16M limit
though, it's not inconceivable that a package could have that many files.
While at it, ensure none of these tags exist in the main header,
which would confuse us greatly.
This is optimized for backporting ease, upstream can remove redundancies
and further improve checking later.
Reported and initial patches by Demi Marie Obenour.
Fixes: RhBug:1935049, RhBug:1933867, RhBug:1935035, RhBug:1934125, ...
Fixes: CVE-2021-3421, CVE-2021-20271
Modified to apply to version 4.14.2 by: Nicolas Ontiveros <niontive@microsoft.com>
diff --git a/lib/package.c b/lib/package.c
index 93a06ebfe..96a1737d8 100644
--- a/lib/package.c
+++ b/lib/package.c
@@ -20,76 +20,75 @@
#include "debug.h"
+struct taglate_s {
+ rpmTagVal stag;
+ rpmTagVal xtag;
+ rpm_count_t count;
+} const xlateTags[] = {
+ { RPMSIGTAG_SIZE, RPMTAG_SIGSIZE, 1 },
+ { RPMSIGTAG_PGP, RPMTAG_SIGPGP, 0 },
+ { RPMSIGTAG_MD5, RPMTAG_SIGMD5, 16 },
+ { RPMSIGTAG_GPG, RPMTAG_SIGGPG, 0 },
+ /* { RPMSIGTAG_PGP5, RPMTAG_SIGPGP5, 0 }, */ /* long obsolete, dont use */
+ { RPMSIGTAG_PAYLOADSIZE, RPMTAG_ARCHIVESIZE, 1 },
+ { RPMSIGTAG_FILESIGNATURES, RPMTAG_FILESIGNATURES, 0 },
+ { RPMSIGTAG_FILESIGNATURELENGTH, RPMTAG_FILESIGNATURELENGTH, 1 },
+ { RPMSIGTAG_VERITYSIGNATURES, RPMTAG_VERITYSIGNATURES, 0 },
+ { RPMSIGTAG_VERITYSIGNATUREALGO, RPMTAG_VERITYSIGNATUREALGO, 1 },
+ { RPMSIGTAG_SHA1, RPMTAG_SHA1HEADER, 1 },
+ { RPMSIGTAG_SHA256, RPMTAG_SHA256HEADER, 1 },
+ { RPMSIGTAG_DSA, RPMTAG_DSAHEADER, 0 },
+ { RPMSIGTAG_RSA, RPMTAG_RSAHEADER, 0 },
+ { RPMSIGTAG_LONGSIZE, RPMTAG_LONGSIGSIZE, 1 },
+ { RPMSIGTAG_LONGARCHIVESIZE, RPMTAG_LONGARCHIVESIZE, 1 },
+ { 0 }
+};
+
/** \ingroup header
* Translate and merge legacy signature tags into header.
* @param h header (dest)
* @param sigh signature header (src)
+ * @return failing tag number, 0 on success
*/
static
-void headerMergeLegacySigs(Header h, Header sigh)
+rpmTagVal headerMergeLegacySigs(Header h, Header sigh, char **msg)
{
- HeaderIterator hi;
+ const struct taglate_s *xl;
struct rpmtd_s td;
- hi = headerInitIterator(sigh);
- for (; headerNext(hi, &td); rpmtdFreeData(&td))
- {
- switch (td.tag) {
- /* XXX Translate legacy signature tag values. */
- case RPMSIGTAG_SIZE:
- td.tag = RPMTAG_SIGSIZE;
- break;
- case RPMSIGTAG_PGP:
- td.tag = RPMTAG_SIGPGP;
- break;
- case RPMSIGTAG_MD5:
- td.tag = RPMTAG_SIGMD5;
- break;
- case RPMSIGTAG_GPG:
- td.tag = RPMTAG_SIGGPG;
- break;
- case RPMSIGTAG_PGP5:
- td.tag = RPMTAG_SIGPGP5;
- break;
- case RPMSIGTAG_PAYLOADSIZE:
- td.tag = RPMTAG_ARCHIVESIZE;
- break;
- case RPMSIGTAG_SHA1:
- case RPMSIGTAG_SHA256:
- case RPMSIGTAG_DSA:
- case RPMSIGTAG_RSA:
- default:
- if (!(td.tag >= HEADER_SIGBASE && td.tag < HEADER_TAGBASE))
- continue;
- break;
- }
- if (!headerIsEntry(h, td.tag)) {
- switch (td.type) {
- case RPM_NULL_TYPE:
- continue;
+ for (xl = xlateTags; xl->stag; xl++) {
+ /* There mustn't be one in the main header */
+ if (headerIsEntry(h, xl->xtag))
+ goto exit;
+ }
+
+ rpmtdReset(&td);
+ for (xl = xlateTags; xl->stag; xl++) {
+ if (headerGet(sigh, xl->stag, &td, HEADERGET_RAW|HEADERGET_MINMEM)) {
+ /* Translate legacy tags */
+ if (xl->stag != xl->xtag)
+ td.tag = xl->xtag;
+ /* Ensure type and tag size match expectations */
+ if (td.type != rpmTagGetTagType(td.tag))
break;
- case RPM_CHAR_TYPE:
- case RPM_INT8_TYPE:
- case RPM_INT16_TYPE:
- case RPM_INT32_TYPE:
- case RPM_INT64_TYPE:
- if (td.count != 1)
- continue;
+ if (td.count < 1 || td.count > 16*1024*1024)
break;
- case RPM_STRING_TYPE:
- case RPM_BIN_TYPE:
- if (td.count >= 16*1024)
- continue;
+ if (xl->count && td.count != xl->count)
break;
- case RPM_STRING_ARRAY_TYPE:
- case RPM_I18NSTRING_TYPE:
- continue;
+ if (!headerPut(h, &td, HEADERPUT_DEFAULT))
break;
- }
- (void) headerPut(h, &td, HEADERPUT_DEFAULT);
+ rpmtdFreeData(&td);
}
}
- headerFreeIterator(hi);
+ rpmtdFreeData(&td);
+
+exit:
+ if (xl->stag) {
+ rasprintf(msg, "invalid signature tag %s (%d)",
+ rpmTagGetName(xl->xtag), xl->xtag);
+ }
+
+ return xl->stag;
}
/**
@@ -337,7 +336,8 @@
goto exit;
/* Append (and remap) signature tags to the metadata. */
- headerMergeLegacySigs(h, sigh);
+ if (headerMergeLegacySigs(h, sigh, &msg))
+ goto exit;
applyRetrofits(h);
/* Bump reference count for return. */
--- a/lib/rpmtag.h
+++ b/lib/rpmtag.h
@@ -65,6 +65,10 @@
RPMTAG_LONGARCHIVESIZE = RPMTAG_SIG_BASE+15, /* l */
/* RPMTAG_SIG_BASE+16 reserved */
RPMTAG_SHA256HEADER = RPMTAG_SIG_BASE+17, /* s */
+ /* RPMTAG_SIG_BASE+18 reserved for RPMSIGTAG_FILESIGNATURES */
+ /* RPMTAG_SIG_BASE+19 reserved for RPMSIGTAG_FILESIGNATURELENGTH */
+ RPMTAG_VERITYSIGNATURES = RPMTAG_SIG_BASE+20, /* s[] */
+ RPMTAG_VERITYSIGNATUREALGO = RPMTAG_SIG_BASE+21, /* i */
RPMTAG_NAME = 1000, /* s */
#define RPMTAG_N RPMTAG_NAME /* s */
@@ -422,6 +426,10 @@
RPMSIGTAG_LONGSIZE = RPMTAG_LONGSIGSIZE, /*!< internal Header+Payload size (64bit) in bytes. */
RPMSIGTAG_LONGARCHIVESIZE = RPMTAG_LONGARCHIVESIZE, /*!< internal uncompressed payload size (64bit) in bytes. */
RPMSIGTAG_SHA256 = RPMTAG_SHA256HEADER,
+ RPMSIGTAG_FILESIGNATURES = RPMTAG_SIG_BASE + 18,
+ RPMSIGTAG_FILESIGNATURELENGTH = RPMTAG_SIG_BASE + 19,
+ RPMSIGTAG_VERITYSIGNATURES = RPMTAG_VERITYSIGNATURES,
+ RPMSIGTAG_VERITYSIGNATUREALGO = RPMTAG_VERITYSIGNATUREALGO,
} rpmSigTag;

View File

@ -1,29 +0,0 @@
From a0998009aa0cf6c9536338c725adc7f4cdc8e08a Mon Sep 17 00:00:00 2001
From: Thomas Crain <thcrain@microsoft.com>
Date: Sun, 6 Jun 2021 13:02:09 -0500
Subject: [PATCH] Add RPM_LD_FLAGS definition to %%{__build_pre} macro
Adapted from Fedora downstream: https://src.fedoraproject.org/rpms/rpm/blob/rawhide/f/rpm-4.15.x-ldflags.patch
---
macros.in | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/macros.in b/macros.in
index a6069ee..5d6855b 100644
--- a/macros.in
+++ b/macros.in
@@ -801,9 +801,10 @@ package or when debugging this package.\
RPM_SOURCE_DIR=\"%{u2p:%{_sourcedir}}\"\
RPM_BUILD_DIR=\"%{u2p:%{_builddir}}\"\
RPM_OPT_FLAGS=\"%{optflags}\"\
+ RPM_LD_FLAGS=\"%{?build_ldflags}\"\
RPM_ARCH=\"%{_arch}\"\
RPM_OS=\"%{_os}\"\
- export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_ARCH RPM_OS\
+ export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_LD_FLAGS RPM_ARCH RPM_OS\
RPM_DOC_DIR=\"%{_docdir}\"\
export RPM_DOC_DIR\
RPM_PACKAGE_NAME=\"%{NAME}\"\
--
2.30.2

View File

@ -1,27 +0,0 @@
diff -Naur a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh
--- a/scripts/find-debuginfo.sh 2017-04-19 15:48:24.650406279 -0700
+++ b/scripts/find-debuginfo.sh 2017-04-19 15:49:16.090962375 -0700
@@ -292,10 +292,10 @@
fi
if [ -d "${RPM_BUILD_ROOT}/usr/lib" -o -d "${RPM_BUILD_ROOT}/usr/src" ]; then
- ((nout > 0)) ||
- test ! -d "${RPM_BUILD_ROOT}/usr/lib" ||
- (cd "${RPM_BUILD_ROOT}/usr/lib"; find debug -type d) |
- sed 's,^,%dir /usr/lib/,' >> "$LISTFILE"
+# ((nout > 0)) ||
+# test ! -d "${RPM_BUILD_ROOT}/usr/lib" ||
+# (cd "${RPM_BUILD_ROOT}/usr/lib"; find debug -type d) |
+# sed 's,^,%dir /usr/lib/,' >> "$LISTFILE"
(cd "${RPM_BUILD_ROOT}/usr"
test ! -d lib/debug || find lib/debug ! -type d
@@ -467,7 +467,7 @@
mv "${LISTFILE}.new" "$LISTFILE"
((++i))
done
-if ((nout > 0)); then
+if ((0 && nout > 0)); then
# Now add the right %dir lines to each output list.
(cd "${RPM_BUILD_ROOT}"; find usr/lib/debug -type d) |
sed 's#^.*$#\\@^/&/@{h;s@^.*$@%dir /&@p;g;}#' |

View File

@ -1,164 +0,0 @@
# Changes adopted from python3-rpm-generators-10-4.fc32.noarch.rpm
diff --git a/scripts/pythondistdeps.py b/scripts/pythondistdeps.py
index ac1cd62..8756fdf 100755
--- a/scripts/pythondistdeps.py
+++ b/scripts/pythondistdeps.py
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python3
# -*- coding: utf-8 -*-
#
# Copyright 2010 Per Øyvind Karlsen <proyvind@moondrake.org>
@@ -32,6 +32,11 @@ PyMajorVer_Deps = False
legacy_Provides = False
legacy = False
+def normalize_name(name):
+ """https://www.python.org/dev/peps/pep-0503/#normalized-names"""
+ import re
+ return re.sub(r'[-_.]+', '-', name).lower()
+
for o, a in opts:
if o in ('-h', '--help'):
print('-h, --help\tPrint help')
@@ -102,7 +107,7 @@ for f in files:
lower.endswith('.egg-info') or \
lower.endswith('.dist-info'):
# This import is very slow, so only do it if needed
- from pkg_resources import Distribution, FileMetadata, PathMetadata
+ from pkg_resources import Distribution, FileMetadata, PathMetadata, Requirement, parse_version
dist_name = basename(f)
if isdir(f):
path_item = dirname(f)
@@ -116,12 +121,24 @@ for f in files:
# Try to parse the Python version from the path the metadata
# resides at (e.g. /usr/lib/pythonX.Y/site-packages/...)
import re
- res = re.search(r"/python(?P<pyver>\d+\.\d)/", path_item)
+ res = re.search(r"/python(?P<pyver>\d+\.\d+)/", path_item)
if res:
dist.py_version = res.group('pyver')
else:
warn("Version for {!r} has not been found".format(dist), RuntimeWarning)
continue
+
+ # XXX: https://github.com/pypa/setuptools/pull/1275
+ import platform
+ platform.python_version = lambda: dist.py_version
+
+ # This is the PEP 503 normalized name.
+ # It does also convert dots to dashes, unlike dist.key.
+ # In the current code, we only add additional provides with this.
+ # Later, we can start requiring them.
+ # See https://bugzilla.redhat.com/show_bug.cgi?id=1791530
+ normalized_name = normalize_name(dist.project_name)
+
if Provides_PyMajorVer_Variant or PyMajorVer_Deps or legacy_Provides or legacy:
# Get the Python major version
pyver_major = dist.py_version.split('.')[0]
@@ -136,21 +153,34 @@ for f in files:
name = 'python{}dist({})'.format(dist.py_version, dist.key)
if name not in py_deps:
py_deps[name] = []
+ name_ = 'python{}dist({})'.format(dist.py_version, normalized_name)
+ if name_ not in py_deps:
+ py_deps[name_] = []
if Provides_PyMajorVer_Variant or PyMajorVer_Deps:
pymajor_name = 'python{}dist({})'.format(pyver_major, dist.key)
if pymajor_name not in py_deps:
py_deps[pymajor_name] = []
+ pymajor_name_ = 'python{}dist({})'.format(pyver_major, normalized_name)
+ if pymajor_name_ not in py_deps:
+ py_deps[pymajor_name_] = []
if legacy or legacy_Provides:
legacy_name = 'pythonegg({})({})'.format(pyver_major, dist.key)
if legacy_name not in py_deps:
py_deps[legacy_name] = []
if dist.version:
- spec = ('==', dist.version)
+ version = dist.version
+ while version.endswith('.0'):
+ version = version[:-2]
+ spec = ('==', version)
if spec not in py_deps[name]:
if not legacy:
py_deps[name].append(spec)
+ if name != name_:
+ py_deps[name_].append(spec)
if Provides_PyMajorVer_Variant:
py_deps[pymajor_name].append(spec)
+ if pymajor_name != pymajor_name_:
+ py_deps[pymajor_name_].append(spec)
if legacy or legacy_Provides:
py_deps[legacy_name].append(spec)
if Requires or (Recommends and dist.extras):
@@ -174,6 +204,13 @@ for f in files:
if dep in deps:
depsextras.remove(dep)
deps = depsextras
+ # console_scripts/gui_scripts entry points need pkg_resources from setuptools
+ if ((dist.get_entry_map('console_scripts') or
+ dist.get_entry_map('gui_scripts')) and
+ (lower.endswith('.egg') or
+ lower.endswith('.egg-info'))):
+ # stick them first so any more specific requirement overrides it
+ deps.insert(0, Requirement.parse('setuptools'))
# add requires/recommends based on egg/dist metadata
for dep in deps:
if legacy:
@@ -184,11 +221,12 @@ for f in files:
else:
name = 'python{}dist({})'.format(dist.py_version, dep.key)
for spec in dep.specs:
- if spec[0] != '!=':
- if name not in py_deps:
- py_deps[name] = []
- if spec not in py_deps[name]:
- py_deps[name].append(spec)
+ while spec[1].endswith('.0'):
+ spec = (spec[0], spec[1][:-2])
+ if name not in py_deps:
+ py_deps[name] = []
+ if spec not in py_deps[name]:
+ py_deps[name].append(spec)
if not dep.specs:
py_deps[name] = []
# Unused, for automatic sub-package generation based on 'extras' from egg/dist metadata
@@ -233,8 +271,35 @@ names.sort()
for name in names:
if py_deps[name]:
# Print out versioned provides, requires, recommends, conflicts
+ spec_list = []
for spec in py_deps[name]:
- print('{} {} {}'.format(name, spec[0], spec[1]))
+ if spec[0] == '!=':
+ spec_list.append('({n} < {v} or {n} >= {v}.0)'.format(n=name, v=spec[1]))
+ elif spec[0] == '~=':
+ # Parse the current version
+ next_ver = parse_version(spec[1]).base_version.split('.')
+ # Drop the micro version
+ next_ver = next_ver[0:-1]
+ # Increment the minor version
+ next_ver[-1] = str(int(next_ver[-1]) + 1)
+ next_ver = '.'.join(next_ver)
+ spec_list.append('({n} >= {v} with {n} < {vnext})'.format(n=name, v=spec[1], vnext=next_ver))
+ elif spec[0] == '==' and spec[1].endswith('.*'):
+ # Parse the current version
+ next_ver = parse_version(spec[1]).base_version.split('.')
+ # Drop the micro version from both the version in spec and next_ver
+ next_ver = next_ver[0:-1]
+ spec = (spec[0], '.'.join(next_ver))
+ # Increment the minor version
+ next_ver[-1] = str(int(next_ver[-1]) + 1)
+ next_ver = '.'.join(next_ver)
+ spec_list.append('({n} >= {v} with {n} < {vnext})'.format(n=name, v=spec[1], vnext=next_ver))
+ else:
+ spec_list.append('{} {} {}'.format(name, spec[0], spec[1]))
+ if len(spec_list) == 1:
+ print(spec_list[0])
+ else:
+ print('({})'.format(' with '.join(spec_list)))
else:
# Print out unversioned provides, requires, recommends, conflicts
print(name)

View File

@ -0,0 +1,45 @@
--- rpm-rpm-4.17.0-release/Makefile.am 2021-09-03 02:41:20.000000000 -0700
+++ rpm-rpm-4.17.0-release/Makefile2 2021-09-23 15:21:16.362202512 -0700
@@ -27,7 +27,7 @@
SUBDIRS = po misc
SUBDIRS += luaext
-SUBDIRS += rpmio lib sign build scripts fileattrs docs .
+SUBDIRS += rpmio lib sign build scripts fileattrs .
if ENABLE_PYTHON
SUBDIRS += python
@@ -41,7 +41,7 @@
SUBDIRS += tests
endif
-DIST_SUBDIRS = po misc luaext rpmio lib sign build python scripts fileattrs docs tests plugins
+DIST_SUBDIRS = po misc luaext rpmio lib sign build python scripts fileattrs tests plugins
pkgconfigdir = $(libdir)/pkgconfig
@@ -249,24 +249,6 @@
MAINTAINERCLEANFILES = ChangeLog
-# Always build librpm docs
-if DOXYGEN
-docs/librpm.doxy: docs/librpm.doxy.in docs/librpm/Doxyheader.h Makefile.am configure.ac $(pkginclude_HEADERS)
- files=`echo " $(pkginclude_HEADERS)" | $(SED) -e "s, , \@top_srcdir\@/,g"`; \
- $(SED) -e "s,[@]pkginclude_HEADERS[@],$$files," \
- -e "s,\@top_srcdir\@/,$(top_srcdir)/,g" \
- -e "s,[@]HAVE_DOT[@],$(HAVE_DOT)," \
- -e "s,[@]PACKAGE[@],$(PACKAGE)," \
- -e "s,[@]VERSION[@],$(VERSION)," \
- < $(top_srcdir)/docs/librpm.doxy.in > docs/librpm.doxy
-
-docs/librpm/html: docs/librpm.doxy
- @DOXYGEN@ docs/librpm.doxy
-noinst_DATA += docs/librpm/html
-endif
-EXTRA_DIST += docs/librpm.doxy.in docs/librpm/Doxyheader.h
-EXTRA_DIST += docs/librpm/html
-
.PHONY: ci
ci:
podman build -t rpm -f ci/Dockerfile .

View File

@ -2,6 +2,9 @@
"Signatures": {
"brp-strip-debug-symbols": "6cd7e01cd3ab55de6a04bd61a2a4f787bbddbfe575d85ec282f8d76563fa1cd4",
"brp-strip-unneeded": "b7d2323c52322b5f0144fd9de3ca86e4ea8ec24a262c0382490a9ea434dda3bf",
"rpm-4.14.2.1-release.tar.gz": "92cab9da7524cf4e4abf33f160cdfb9e63fe021bc7133f97735f70cdec777400"
"python.attr": "32eebee98c24edcc9524b4553cf05c0ec6707828fe14f76d250e294568e7091a",
"pythondeps.sh": "1cc7665252eb845c7e4741ff3e832c78f54ffb05552f1cdb2d43d2c0cbf7c07d",
"pythondistdeps.py": "f73f01bb78daa75d25d6581a6da40cf6f946654c5e9d166676036367307186d1",
"rpm-4.17.0-release.tar.gz": "2d8274d212b859b3ac90b276d462467ae2f8165143ef9f9e7ebfab77b1c7e272"
}
}

View File

@ -1,7 +1,7 @@
Summary: Package manager
Name: rpm
Version: 4.14.2.1
Release: 4%{?dist}
Version: 4.17.0
Release: 1%{?dist}
License: GPLv2+ AND LGPLv2+ AND BSD
Vendor: Microsoft Corporation
Distribution: Mariner
@ -10,30 +10,33 @@ URL: https://rpm.org
Source0: https://github.com/rpm-software-management/rpm/archive/%{name}-%{version}-release.tar.gz
Source1: brp-strip-debug-symbols
Source2: brp-strip-unneeded
Patch0: find-debuginfo-do-not-generate-dir-entries.patch
Patch1: python-dist-deps-version-parse.patch
Patch2: define-RPM_LD_FLAGS.patch
Patch3: CVE-2021-20271.patch
# CVE-2021-20271 patch also patches CVE-2021-3421
Patch4: CVE-2021-3421.nopatch
# The license for the files below is the same as for RPM as they have originally came from rpm.
# The git repo is hosted by centos. The version below is centos 8 stable.
Source3: https://git.centos.org/rpms/python-rpm-generators/raw/c8s/f/SOURCES/python.attr
Source4: https://git.centos.org/rpms/python-rpm-generators/raw/c8s/f/SOURCES/pythondeps.sh
Source5: https://git.centos.org/rpms/python-rpm-generators/raw/c8s/f/SOURCES/pythondistdeps.py
BuildRequires: debugedit
BuildRequires: elfutils-devel
BuildRequires: openssl-devel
BuildRequires: file-devel
BuildRequires: libarchive-devel
BuildRequires: libcap-devel
BuildRequires: libdb-devel
BuildRequires: libselinux-devel
BuildRequires: lua-devel
BuildRequires: nss-devel
BuildRequires: popt-devel
BuildRequires: python3-devel
BuildRequires: xz-devel
BuildRequires: zstd-devel
Requires: bash
Requires: debugedit
Requires: libarchive
Requires: libdb
Requires: libselinux
Requires: lua
Requires: rpm-libs = %{version}-%{release}
Requires: rpm-build = %{version}-%{release}
Patch0: remove-docs-from-makefile.patch
%description
RPM package manager
@ -107,36 +110,43 @@ Python3 rpm.
%autosetup -n rpm-%{name}-%{version}-release -p1
%build
sed -i '/define _GNU_SOURCE/a #include "../config.h"' tools/sepdebugcrcfix.c
# pass -L opts to gcc as well to prioritize it over standard libs
sed -i 's/-Wl,-L//g' python/setup.py.in
sed -i '/library_dirs/d' python/setup.py.in
sed -i 's/extra_link_args/library_dirs/g' python/setup.py.in
./autogen.sh --noconfigure
%configure \
CPPFLAGS='-I/usr/include/nspr -I/usr/include/nss -DLUA_COMPAT_APIINTCASTS' \
--program-prefix= \
--disable-dependency-tracking \
--disable-static \
--with-vendor=mariner \
--enable-python \
--with-cap \
--with-lua \
--disable-silent-rules \
--with-external-db \
--with-selinux
make %{?_smp_mflags}
CPPFLAGS='-DLUA_COMPAT_APIINTCASTS' \
--program-prefix= \
--with-crypto=openssl \
--enable-ndb \
--disable-dependency-tracking \
--disable-static \
--with-vendor=mariner \
--enable-python \
--with-cap \
--disable-silent-rules \
--with-selinux
# Remove manpages translations
rm -r docs/man/{fr,ja,ko,pl,ru,sk}
%make_build
pushd python
python3 setup.py build
%py3_build
popd
# Set provided python versions
sed -i 's/@MAJORVER-PROVIDES-VERSIONS@/%{python3_version}/' %{SOURCE3}
%check
make check
%make_build_check
%install
make DESTDIR=%{buildroot} install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print
find %{buildroot} -name 'perl*' -delete
@ -144,8 +154,10 @@ find %{buildroot} -name 'perl*' -delete
%find_lang %{name}
# System macros and prefix
install -dm 755 %{buildroot}%{_sysconfdir}/rpm
install -vm755 %{SOURCE1} %{buildroot}%{_libdir}/rpm/
install -vm755 %{SOURCE2} %{buildroot}%{_libdir}/rpm/
install -vm644 %{SOURCE3} %{buildroot}%{_fileattrsdir}/
install -vm755 %{SOURCE4} %{buildroot}%{_libdir}/rpm/
install -vm755 %{SOURCE5} %{buildroot}%{_libdir}/rpm/
pushd python
python3 setup.py install --skip-build --prefix=%{_prefix} --root=%{buildroot}
@ -178,22 +190,16 @@ popd
%{_libdir}/rpm/tgpg
%{_libdir}/rpm/platform
%{_libdir}/rpm-plugins/*
%{_libdir}/rpm/python-macro-helper
%{_libdir}/rpm/pythondistdeps.py
%{_mandir}/man8/rpm.8.gz
%{_mandir}/man8/rpm2cpio.8.gz
%{_mandir}/man8/rpmdb.8.gz
%{_mandir}/man8/rpmgraph.8.gz
%{_mandir}/man8/rpmkeys.8.gz
%{_mandir}/man8/rpm-misc.8.gz
%{_mandir}/man8/rpm-plugin-systemd-inhibit.8.gz
%exclude %{_mandir}/fr/man8/*.gz
%exclude %{_mandir}/ja/man8/*.gz
%exclude %{_mandir}/ko/man8/*.gz
%exclude %{_mandir}/pl/man1/*.gz
%exclude %{_mandir}/pl/man8/*.gz
%exclude %{_mandir}/ru/man8/*.gz
%exclude %{_mandir}/sk/man8/*.gz
%{_fileattrsdir}/python.attr
# Because of no doxygen dependency, we do not produce manpages that require it.
# %{_mandir}/man8/rpm.8.gz
# %{_mandir}/man8/rpm2cpio.8.gz
# %{_mandir}/man8/rpmdb.8.gz
# %{_mandir}/man8/rpmgraph.8.gz
# %{_mandir}/man8/rpmkeys.8.gz
# %{_mandir}/man8/rpm-misc.8.gz
# %{_mandir}/man8/rpm-plugin-systemd-inhibit.8.gz
%files libs
%defattr(-,root,root)
@ -211,15 +217,10 @@ popd
%{_bindir}/rpmsign
%{_bindir}/rpmspec
%{_libdir}/rpm/macros.*
%{_libdir}/rpm/find-debuginfo.sh
%{_libdir}/rpm/find-lang.sh
%{_libdir}/rpm/find-provides
%{_libdir}/rpm/find-requires
%{_libdir}/rpm/brp-*
%{_libdir}/rpm/mono-find-provides
%{_libdir}/rpm/mono-find-requires
%{_libdir}/rpm/ocaml-find-provides.sh
%{_libdir}/rpm/ocaml-find-requires.sh
%{_libdir}/rpm/fileattrs/*
%{_libdir}/rpm/script.req
%{_libdir}/rpm/check-buildroot
@ -227,24 +228,20 @@ popd
%{_libdir}/rpm/check-prereqs
%{_libdir}/rpm/check-rpaths
%{_libdir}/rpm/check-rpaths-worker
%{_libdir}/rpm/config.guess
%{_libdir}/rpm/config.sub
%{_libdir}/rpm/debugedit
%{_libdir}/rpm/elfdeps
%{_libdir}/rpm/libtooldeps.sh
%{_libdir}/rpm/mkinstalldirs
%{_libdir}/rpm/pkgconfigdeps.sh
%{_libdir}/rpm/*.prov
%{_libdir}/rpm/sepdebugcrcfix
%{_libdir}/rpm/pythondeps.sh
%{_libdir}/rpm/ocamldeps.sh
%{_libdir}/rpm/rpmdeps
%{_mandir}/man1/gendiff.1*
%{_mandir}/man8/rpmbuild.8*
%{_mandir}/man8/rpmdeps.8*
%{_mandir}/man8/rpmspec.8*
%{_mandir}/man8/rpmsign.8.gz
# Because of no doxygen dependency, we do not produce manpages that require it.
# %{_mandir}/man1/gendiff.1*
# %{_mandir}/man8/rpmbuild.8*
# %{_mandir}/man8/rpmdeps.8*
# %{_mandir}/man8/rpmspec.8*
# %{_mandir}/man8/rpmsign.8.gz
%files devel
%defattr(-,root,root)
@ -263,6 +260,10 @@ popd
%{python3_sitelib}/*
%changelog
* Wed Sep 15 2021 Mateusz Malisz <mamalisz@microsoft.com> - 4.17.0-1
- Upgrade to version 4.17.0
* Mon Jun 07 2021 Thomas Crain <thcrain@microsoft.com> - 4.14.2.1-4
- Add patch to define "$RPM_LD_FLAGS" during spec %%build phases
- Remove %%python3_sitelib redefinition

View File

@ -1121,6 +1121,16 @@
}
}
},
{
"component": {
"type": "other",
"other": {
"name": "debugedit",
"version": "5.0",
"downloadUrl": "https://sourceware.org/ftp/debugedit/5.0/debugedit-5.0.tar.xz"
}
}
},
{
"component": {
"type": "other",
@ -7572,8 +7582,8 @@
"type": "other",
"other": {
"name": "rpm",
"version": "4.14.2.1",
"downloadUrl": "https://github.com/rpm-software-management/rpm/archive/rpm-4.14.2.1-release.tar.gz"
"version": "4.17.0",
"downloadUrl": "https://github.com/rpm-software-management/rpm/archive/rpm-4.17.0-release.tar.gz"
}
}
},

View File

@ -86,9 +86,6 @@ nspr-devel-4.21-2.cm2.aarch64.rpm
sqlite-3.34.1-1.cm2.aarch64.rpm
sqlite-devel-3.34.1-1.cm2.aarch64.rpm
sqlite-libs-3.34.1-1.cm2.aarch64.rpm
nss-3.44-8.cm2.aarch64.rpm
nss-devel-3.44-8.cm2.aarch64.rpm
nss-libs-3.44-8.cm2.aarch64.rpm
elfutils-0.176-5.cm2.aarch64.rpm
elfutils-default-yama-scope-0.176-5.cm2.noarch.rpm
elfutils-devel-0.176-5.cm2.aarch64.rpm
@ -173,15 +170,14 @@ openssl-debuginfo-1.1.1k-5.cm2.aarch64.rpm
libcap-2.26-2.cm2.aarch64.rpm
libcap-devel-2.26-2.cm2.aarch64.rpm
libcap-ng-0.7.9-4.cm2.aarch64.rpm
libdb-5.3.28-5.cm2.aarch64.rpm
libdb-devel-5.3.28-5.cm2.aarch64.rpm
libdb-docs-5.3.28-5.cm2.aarch64.rpm
rpm-4.14.2.1-4.cm2.aarch64.rpm
rpm-build-4.14.2.1-4.cm2.aarch64.rpm
rpm-build-libs-4.14.2.1-4.cm2.aarch64.rpm
rpm-devel-4.14.2.1-4.cm2.aarch64.rpm
rpm-lang-4.14.2.1-4.cm2.aarch64.rpm
rpm-libs-4.14.2.1-4.cm2.aarch64.rpm
debugedit-5.0-1.cm2.aarch64.rpm
debugedit-debuginfo-5.0-1.cm2.aarch64.rpm
rpm-4.17.0-1.cm2.aarch64.rpm
rpm-build-4.17.0-1.cm2.aarch64.rpm
rpm-build-libs-4.17.0-1.cm2.aarch64.rpm
rpm-devel-4.17.0-1.cm2.aarch64.rpm
rpm-lang-4.17.0-1.cm2.aarch64.rpm
rpm-libs-4.17.0-1.cm2.aarch64.rpm
cpio-2.13-2.cm2.aarch64.rpm
cpio-lang-2.13-2.cm2.aarch64.rpm
e2fsprogs-libs-1.45.6-1.cm2.aarch64.rpm
@ -208,8 +204,8 @@ pcre-libs-8.44-3.cm2.aarch64.rpm
krb5-1.18-1.cm2.aarch64.rpm
lua-5.3.5-11.cm2.aarch64.rpm
lua-libs-5.3.5-11.cm2.aarch64.rpm
mariner-rpm-macros-2.0-5.cm2.noarch.rpm
mariner-check-macros-2.0-5.cm2.noarch.rpm
mariner-rpm-macros-2.0-6.cm2.noarch.rpm
mariner-check-macros-2.0-6.cm2.noarch.rpm
libassuan-2.5.1-5.cm2.aarch64.rpm
libgpg-error-1.32-6.cm2.aarch64.rpm
libgcrypt-1.8.7-3.cm2.aarch64.rpm

View File

@ -86,9 +86,6 @@ nspr-devel-4.21-2.cm2.x86_64.rpm
sqlite-3.34.1-1.cm2.x86_64.rpm
sqlite-devel-3.34.1-1.cm2.x86_64.rpm
sqlite-libs-3.34.1-1.cm2.x86_64.rpm
nss-3.44-8.cm2.x86_64.rpm
nss-devel-3.44-8.cm2.x86_64.rpm
nss-libs-3.44-8.cm2.x86_64.rpm
elfutils-0.176-5.cm2.x86_64.rpm
elfutils-default-yama-scope-0.176-5.cm2.noarch.rpm
elfutils-devel-0.176-5.cm2.x86_64.rpm
@ -173,15 +170,14 @@ openssl-debuginfo-1.1.1k-5.cm2.x86_64.rpm
libcap-2.26-2.cm2.x86_64.rpm
libcap-devel-2.26-2.cm2.x86_64.rpm
libcap-ng-0.7.9-4.cm2.x86_64.rpm
libdb-5.3.28-5.cm2.x86_64.rpm
libdb-devel-5.3.28-5.cm2.x86_64.rpm
libdb-docs-5.3.28-5.cm2.x86_64.rpm
rpm-4.14.2.1-4.cm2.x86_64.rpm
rpm-build-4.14.2.1-4.cm2.x86_64.rpm
rpm-build-libs-4.14.2.1-4.cm2.x86_64.rpm
rpm-devel-4.14.2.1-4.cm2.x86_64.rpm
rpm-lang-4.14.2.1-4.cm2.x86_64.rpm
rpm-libs-4.14.2.1-4.cm2.x86_64.rpm
debugedit-5.0-1.cm2.x86_64.rpm
debugedit-debuginfo-5.0-1.cm2.x86_64.rpm
rpm-4.17.0-1.cm2.x86_64.rpm
rpm-build-4.17.0-1.cm2.x86_64.rpm
rpm-build-libs-4.17.0-1.cm2.x86_64.rpm
rpm-devel-4.17.0-1.cm2.x86_64.rpm
rpm-lang-4.17.0-1.cm2.x86_64.rpm
rpm-libs-4.17.0-1.cm2.x86_64.rpm
cpio-2.13-2.cm2.x86_64.rpm
cpio-lang-2.13-2.cm2.x86_64.rpm
e2fsprogs-libs-1.45.6-1.cm2.x86_64.rpm
@ -208,8 +204,8 @@ pcre-libs-8.44-3.cm2.x86_64.rpm
krb5-1.18-1.cm2.x86_64.rpm
lua-5.3.5-11.cm2.x86_64.rpm
lua-libs-5.3.5-11.cm2.x86_64.rpm
mariner-rpm-macros-2.0-5.cm2.noarch.rpm
mariner-check-macros-2.0-5.cm2.noarch.rpm
mariner-rpm-macros-2.0-6.cm2.noarch.rpm
mariner-check-macros-2.0-6.cm2.noarch.rpm
libassuan-2.5.1-5.cm2.x86_64.rpm
libgpg-error-1.32-6.cm2.x86_64.rpm
libgcrypt-1.8.7-3.cm2.x86_64.rpm

View File

@ -44,6 +44,8 @@ curl-7.76.0-5.cm2.aarch64.rpm
curl-debuginfo-7.76.0-5.cm2.aarch64.rpm
curl-devel-7.76.0-5.cm2.aarch64.rpm
curl-libs-7.76.0-5.cm2.aarch64.rpm
debugedit-5.0-1.cm2.aarch64.rpm
debugedit-debuginfo-5.0-1.cm2.aarch64.rpm
diffutils-3.6-4.cm2.aarch64.rpm
diffutils-debuginfo-3.6-4.cm2.aarch64.rpm
docbook-dtd-xml-4.5-11.cm2.noarch.rpm
@ -164,11 +166,6 @@ libcap-devel-2.26-2.cm2.aarch64.rpm
libcap-ng-0.7.9-4.cm2.aarch64.rpm
libcap-ng-debuginfo-0.7.9-4.cm2.aarch64.rpm
libcap-ng-devel-0.7.9-4.cm2.aarch64.rpm
libdb-5.3.28-5.cm2.aarch64.rpm
libdb-debuginfo-5.3.28-5.cm2.aarch64.rpm
libdb-devel-5.3.28-5.cm2.aarch64.rpm
libdb-docs-5.3.28-5.cm2.aarch64.rpm
libdb-utils-5.3.28-5.cm2.aarch64.rpm
libffi-3.2.1-12.cm2.aarch64.rpm
libffi-debuginfo-3.2.1-12.cm2.aarch64.rpm
libffi-devel-3.2.1-12.cm2.aarch64.rpm
@ -244,7 +241,7 @@ m4-1.4.18-4.cm2.aarch64.rpm
m4-debuginfo-1.4.18-4.cm2.aarch64.rpm
make-4.2.1-5.cm2.aarch64.rpm
make-debuginfo-4.2.1-5.cm2.aarch64.rpm
mariner-check-macros-2.0-5.cm2.noarch.rpm
mariner-check-macros-2.0-6.cm2.noarch.rpm
mariner-release-2.0-1.cm2.noarch.rpm
mariner-repos-2.0-1.cm2.noarch.rpm
mariner-repos-extras-2.0-1.cm2.noarch.rpm
@ -254,7 +251,7 @@ mariner-repos-microsoft-preview-2.0-1.cm2.noarch.rpm
mariner-repos-preview-2.0-1.cm2.noarch.rpm
mariner-repos-ui-2.0-1.cm2.noarch.rpm
mariner-repos-ui-preview-2.0-1.cm2.noarch.rpm
mariner-rpm-macros-2.0-5.cm2.noarch.rpm
mariner-rpm-macros-2.0-6.cm2.noarch.rpm
meson-0.57.1-2.cm2.noarch.rpm
mpfr-4.0.1-3.cm2.aarch64.rpm
mpfr-debuginfo-4.0.1-3.cm2.aarch64.rpm
@ -273,10 +270,6 @@ npth-devel-1.6-3.cm2.aarch64.rpm
nspr-4.21-2.cm2.aarch64.rpm
nspr-debuginfo-4.21-2.cm2.aarch64.rpm
nspr-devel-4.21-2.cm2.aarch64.rpm
nss-3.44-8.cm2.aarch64.rpm
nss-debuginfo-3.44-8.cm2.aarch64.rpm
nss-devel-3.44-8.cm2.aarch64.rpm
nss-libs-3.44-8.cm2.aarch64.rpm
openjdk8-1.8.0.292-1.cm2.aarch64.rpm
openjdk8-debuginfo-1.8.0.292-1.cm2.aarch64.rpm
openjdk8-doc-1.8.0.292-1.cm2.aarch64.rpm
@ -534,7 +527,7 @@ python3-libxml2-2.9.12-2.cm2.aarch64.rpm
python3-magic-5.40-1.cm2.noarch.rpm
python3-pip-3.7.10-3.cm2.noarch.rpm
python3-pwquality-1.4.2-6.cm2.aarch64.rpm
python3-rpm-4.14.2.1-4.cm2.aarch64.rpm
python3-rpm-4.17.0-1.cm2.aarch64.rpm
python3-setuptools-3.7.10-3.cm2.noarch.rpm
python3-test-3.7.10-3.cm2.aarch64.rpm
python3-tools-3.7.10-3.cm2.aarch64.rpm
@ -545,13 +538,13 @@ readline-devel-7.0-5.cm2.aarch64.rpm
rpcsvc-proto-1.4-4.cm2.aarch64.rpm
rpcsvc-proto-debuginfo-1.4-4.cm2.aarch64.rpm
rpcsvc-proto-devel-1.4-4.cm2.aarch64.rpm
rpm-4.14.2.1-4.cm2.aarch64.rpm
rpm-build-4.14.2.1-4.cm2.aarch64.rpm
rpm-build-libs-4.14.2.1-4.cm2.aarch64.rpm
rpm-debuginfo-4.14.2.1-4.cm2.aarch64.rpm
rpm-devel-4.14.2.1-4.cm2.aarch64.rpm
rpm-lang-4.14.2.1-4.cm2.aarch64.rpm
rpm-libs-4.14.2.1-4.cm2.aarch64.rpm
rpm-4.17.0-1.cm2.aarch64.rpm
rpm-build-4.17.0-1.cm2.aarch64.rpm
rpm-build-libs-4.17.0-1.cm2.aarch64.rpm
rpm-debuginfo-4.17.0-1.cm2.aarch64.rpm
rpm-devel-4.17.0-1.cm2.aarch64.rpm
rpm-lang-4.17.0-1.cm2.aarch64.rpm
rpm-libs-4.17.0-1.cm2.aarch64.rpm
sed-4.5-3.cm2.aarch64.rpm
sed-debuginfo-4.5-3.cm2.aarch64.rpm
sed-lang-4.5-3.cm2.aarch64.rpm

View File

@ -44,6 +44,8 @@ curl-7.76.0-5.cm2.x86_64.rpm
curl-debuginfo-7.76.0-5.cm2.x86_64.rpm
curl-devel-7.76.0-5.cm2.x86_64.rpm
curl-libs-7.76.0-5.cm2.x86_64.rpm
debugedit-5.0-1.cm2.x86_64.rpm
debugedit-debuginfo-5.0-1.cm2.x86_64.rpm
diffutils-3.6-4.cm2.x86_64.rpm
diffutils-debuginfo-3.6-4.cm2.x86_64.rpm
docbook-dtd-xml-4.5-11.cm2.noarch.rpm
@ -164,11 +166,6 @@ libcap-devel-2.26-2.cm2.x86_64.rpm
libcap-ng-0.7.9-4.cm2.x86_64.rpm
libcap-ng-debuginfo-0.7.9-4.cm2.x86_64.rpm
libcap-ng-devel-0.7.9-4.cm2.x86_64.rpm
libdb-5.3.28-5.cm2.x86_64.rpm
libdb-debuginfo-5.3.28-5.cm2.x86_64.rpm
libdb-devel-5.3.28-5.cm2.x86_64.rpm
libdb-docs-5.3.28-5.cm2.x86_64.rpm
libdb-utils-5.3.28-5.cm2.x86_64.rpm
libffi-3.2.1-12.cm2.x86_64.rpm
libffi-debuginfo-3.2.1-12.cm2.x86_64.rpm
libffi-devel-3.2.1-12.cm2.x86_64.rpm
@ -244,7 +241,7 @@ m4-1.4.18-4.cm2.x86_64.rpm
m4-debuginfo-1.4.18-4.cm2.x86_64.rpm
make-4.2.1-5.cm2.x86_64.rpm
make-debuginfo-4.2.1-5.cm2.x86_64.rpm
mariner-check-macros-2.0-5.cm2.noarch.rpm
mariner-check-macros-2.0-6.cm2.noarch.rpm
mariner-release-2.0-1.cm2.noarch.rpm
mariner-repos-2.0-1.cm2.noarch.rpm
mariner-repos-extras-2.0-1.cm2.noarch.rpm
@ -254,7 +251,7 @@ mariner-repos-microsoft-preview-2.0-1.cm2.noarch.rpm
mariner-repos-preview-2.0-1.cm2.noarch.rpm
mariner-repos-ui-2.0-1.cm2.noarch.rpm
mariner-repos-ui-preview-2.0-1.cm2.noarch.rpm
mariner-rpm-macros-2.0-5.cm2.noarch.rpm
mariner-rpm-macros-2.0-6.cm2.noarch.rpm
meson-0.57.1-2.cm2.noarch.rpm
mpfr-4.0.1-3.cm2.x86_64.rpm
mpfr-debuginfo-4.0.1-3.cm2.x86_64.rpm
@ -273,10 +270,6 @@ npth-devel-1.6-3.cm2.x86_64.rpm
nspr-4.21-2.cm2.x86_64.rpm
nspr-debuginfo-4.21-2.cm2.x86_64.rpm
nspr-devel-4.21-2.cm2.x86_64.rpm
nss-3.44-8.cm2.x86_64.rpm
nss-debuginfo-3.44-8.cm2.x86_64.rpm
nss-devel-3.44-8.cm2.x86_64.rpm
nss-libs-3.44-8.cm2.x86_64.rpm
openjdk8-1.8.0.292-1.cm2.x86_64.rpm
openjdk8-debuginfo-1.8.0.292-1.cm2.x86_64.rpm
openjdk8-doc-1.8.0.292-1.cm2.x86_64.rpm
@ -534,7 +527,7 @@ python3-libxml2-2.9.12-2.cm2.x86_64.rpm
python3-magic-5.40-1.cm2.noarch.rpm
python3-pip-3.7.10-3.cm2.noarch.rpm
python3-pwquality-1.4.2-6.cm2.x86_64.rpm
python3-rpm-4.14.2.1-4.cm2.x86_64.rpm
python3-rpm-4.17.0-1.cm2.x86_64.rpm
python3-setuptools-3.7.10-3.cm2.noarch.rpm
python3-test-3.7.10-3.cm2.x86_64.rpm
python3-tools-3.7.10-3.cm2.x86_64.rpm
@ -545,13 +538,13 @@ readline-devel-7.0-5.cm2.x86_64.rpm
rpcsvc-proto-1.4-4.cm2.x86_64.rpm
rpcsvc-proto-debuginfo-1.4-4.cm2.x86_64.rpm
rpcsvc-proto-devel-1.4-4.cm2.x86_64.rpm
rpm-4.14.2.1-4.cm2.x86_64.rpm
rpm-build-4.14.2.1-4.cm2.x86_64.rpm
rpm-build-libs-4.14.2.1-4.cm2.x86_64.rpm
rpm-debuginfo-4.14.2.1-4.cm2.x86_64.rpm
rpm-devel-4.14.2.1-4.cm2.x86_64.rpm
rpm-lang-4.14.2.1-4.cm2.x86_64.rpm
rpm-libs-4.14.2.1-4.cm2.x86_64.rpm
rpm-4.17.0-1.cm2.x86_64.rpm
rpm-build-4.17.0-1.cm2.x86_64.rpm
rpm-build-libs-4.17.0-1.cm2.x86_64.rpm
rpm-debuginfo-4.17.0-1.cm2.x86_64.rpm
rpm-devel-4.17.0-1.cm2.x86_64.rpm
rpm-lang-4.17.0-1.cm2.x86_64.rpm
rpm-libs-4.17.0-1.cm2.x86_64.rpm
sed-4.5-3.cm2.x86_64.rpm
sed-debuginfo-4.5-3.cm2.x86_64.rpm
sed-lang-4.5-3.cm2.x86_64.rpm

View File

@ -264,6 +264,7 @@ generate_pkggen_core () {
grep "^openssl-" $TmpPkgGen
grep "^libcap-" $TmpPkgGen
grep "^libdb-" $TmpPkgGen
grep "^debugedit-" $TmpPkgGen
grep "^rpm-" $TmpPkgGen
grep "^cpio-" $TmpPkgGen
grep "^e2fsprogs-" $TmpPkgGen

View File

@ -54,7 +54,6 @@ clean-toolchain:
rm -f $(SCRIPTS_DIR)/toolchain/container/texinfo-perl-fix.patch
rm -f $(SCRIPTS_DIR)/toolchain/container/Awt_build_headless_only.patch
rm -f $(SCRIPTS_DIR)/toolchain/container/check-system-ca-certs.patch
rm -f $(SCRIPTS_DIR)/toolchain/container/rpm-define-RPM-LD-FLAGS.patch
rm -f $(SCRIPTS_DIR)/toolchain/container/.bashrc
clean-toolchain-rpms:

View File

@ -261,7 +261,6 @@ chroot_and_install_rpms zlib
build_rpm_in_chroot_no_install perl
chroot_and_install_rpms perl
build_rpm_in_chroot_no_install nss
build_rpm_in_chroot_no_install flex
build_rpm_in_chroot_no_install libarchive
build_rpm_in_chroot_no_install diffutils
@ -488,6 +487,9 @@ build_rpm_in_chroot_no_install libselinux
# util-linux and rpm require libselinux
chroot_and_install_rpms libselinux
build_rpm_in_chroot_no_install util-linux
# rpm requires debugedit
build_rpm_in_chroot_no_install debugedit
chroot_and_install_rpms debugedit
build_rpm_in_chroot_no_install rpm
# rebuild pam with selinux support

View File

@ -58,7 +58,6 @@ COPY [ "./toolchain-sha256sums", \
"./toolchain-remote-wget-list", \
"./toolchain-local-wget-list", \
"./texinfo-perl-fix.patch", \
"./rpm-define-RPM-LD-FLAGS.patch", \
"./toolchain-jdk8-wget.sh", \
"$LFS/tools/" ]
@ -105,4 +104,4 @@ COPY [ "./toolchain_initial_chroot_setup.sh", \
USER root
ENTRYPOINT [ "/tools/mount_chroot_start_build.sh" ]
ENTRYPOINT [ "/tools/mount_chroot_start_build.sh" ]

View File

@ -1,6 +1,7 @@
http://ftp.gnu.org/gnu/autoconf/autoconf-2.69.tar.xz
http://ftp.gnu.org/gnu/automake/automake-1.16.1.tar.xz
https://ftp.gnu.org/gnu/binutils/binutils-2.36.1.tar.xz
https://sourceware.org/ftp/debugedit/5.0/debugedit-5.0.tar.xz
http://ftp.gnu.org/gnu/dejagnu/dejagnu-1.6.2.tar.gz
https://prdownloads.sourceforge.net/e2fsprogs/e2fsprogs-1.45.6.tar.gz
https://sourceware.org/ftp/elfutils/0.176/elfutils-0.176.tar.bz2
@ -30,7 +31,7 @@ http://anduin.linuxfromscratch.org/BLFS/bdb/db-5.3.28.tar.gz
https://github.com/libarchive/libarchive/releases/download/v3.4.2/libarchive-3.4.2.tar.gz
http://www.lua.org/ftp/lua-5.3.5.tar.gz
ftp://anduin.linuxfromscratch.org/BLFS/popt/popt-1.16.tar.gz
http://ftp.rpm.org/releases/rpm-4.14.x/rpm-4.14.2.tar.bz2
https://github.com/rpm-software-management/rpm/archive/rpm-4.17.0-release.tar.gz
http://www.linuxfromscratch.org/patches/blfs/9.0/lua-5.3.5-shared_library-1.patch
https://ftp.gnu.org/gnu/gcc/gcc-9.1.0/gcc-9.1.0.tar.xz
http://ftp.gnu.org/gnu/glibc/glibc-2.28.tar.xz
@ -57,8 +58,6 @@ https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-2.26.t
http://download.savannah.gnu.org/releases/libpipeline/libpipeline-1.5.0.tar.gz
http://download.savannah.gnu.org/releases/man-db/man-db-2.8.4.tar.xz
https://archive.mozilla.org/pub/nspr/releases/v4.21/src/nspr-4.21.tar.gz
http://www.linuxfromscratch.org/patches/downloads/nss/nss-3.44-standalone-1.patch
https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_44_RTM/src/nss-3.44.tar.gz
https://cpan.metacpan.org/authors/id/E/ET/ETHER/Test-Warnings-0.028.tar.gz
https://cpan.metacpan.org/authors/id/M/MS/MSCHOUT/Text-Template-1.51.tar.gz
https://www.openssl.org/source/openssl-1.1.1g.tar.gz

View File

@ -20,7 +20,7 @@ e831b3a86091496cdba720411f9748de81507798f6130adeaef872d206e1b057 coreutils-8.30
eab5bdc5ae1df285c59f2a4f140a98fc33678a0bf61bdba67d9436ae26b46f6d cpio-2.13.tar.bz2
596d4db72651c335469ae5f37b0da72ac9f97d73e30838d787065f559dea98cc cups-2.2.4-source.tar.gz
5c7c112e9b9ea8a9d5b019e5f17d481ae20f766cb7a4648360e7c1b46fc9fc5b damageproto-1.2.1.tar.bz2
e0a992d740709892e81f9d93f06daf305cf73fb81b545afe72478043172c3628 db-5.3.28.tar.gz
e9ecd7d350bebae1f178ce6776ca19a648b6fe8fa22f5b3044b38d7899aa553e debugedit-5.0.tar.xz
0d0671e1b45189c5fc8ade4b3b01635fb9eeab45cf54f57db23e4c4c1a17d261 dejagnu-1.6.2.tar.gz
d621e8bdd4b573918c8145f7ae61817d1be9deb4c8d2328a65cea8e11d783bd6 diffutils-3.6.tar.xz
e72051e6a3e06b236d19eed56368117b745ca1e1a27bdc50fd51aa375bea6509 dmxproto-2.3.1.tar.bz2
@ -109,8 +109,6 @@ c2faa85e625cd7567dc1dec9f23d1af1f73e2ca6468bce1bdc13387ec56f97e8 man-pages-5.02
67874a60826303ee2fb6affc6dc0ddd3e749e9bfcb4c8655e3953d0458a6e16e mpfr-4.0.1.tar.xz
30306e0c76e0f9f1f0de987cf1c82a5c21e1ce6568b9227f7da5b71cbea86c9d ncurses-6.2.tar.gz
15ea32c7b100217b6e3193bc03e77f485d9bf7504051443ba9ce86d1c17c6b5a nspr-4.21.tar.gz
7b365cdfe968977296ed7b32a2cb196d05f364661dca856487717ee5dcb54b28 nss-3.44-standalone-1.patch
a5620e59b6eeedfd5a12c9298b50ad92e9898b223e214eb675e36f4ffb5b6aff nss-3.44.tar.gz
ddb04774f1e32f0c49751e21b67216ac87852ceb056b75209af2443400636d46 openssl-1.1.1g.tar.gz
ac610bda97abe0d9f6b7c963255a11dcb196c25e337c61f94e4778d632f1d8fd patch-2.7.6.tar.xz
32e04c8bb7b1aecb2742a7f7ac0eabac100f38247352a73ad7fa104e39e7406f perl-5.30.3.tar.gz
@ -124,7 +122,7 @@ fb799134b868199930b75f26678f18932214042639cd52b16da7fd134cd9b13f Python-3.7.4.t
a777548d2e92aa259f1528de3c4a36d15e07a4650d0976573a8e2ff5437e7370 recordproto-1.14.2.tar.bz2
06735a5b92b20759204e4751ecd6064a2ad8a6246bb65b3078b862a00def2537 renderproto-0.11.1.tar.bz2
3c66003a6bdeb0f70932a9ed3cf57cc554234154378d301e0c5cfa189d8f6818 resourceproto-1.2.0.tar.bz2
80cbc2c1e8e24e67c6f88b41d8ab5633b653a9a79d50d4750474a18cdb69352b rpm-4.14.2.tar.bz2
2d8274d212b859b3ac90b276d462467ae2f8165143ef9f9e7ebfab77b1c7e272 rpm-4.17.0-release.tar.gz
8bb70a8da164930cceaeb4c74180291660533ad3cc45377b30a795d1b85bcd65 scrnsaverproto-1.2.2.tar.bz2
7aad73c8839c2bdadca9476f884d2953cdace9567ecd0d90f9959f229d146b40 sed-4.5.tar.xz
486748abfb16abd8af664e3a5f03b228e5f124682b0c942e157644bf6fff7d10 sqlite-autoconf-3320100.tar.gz
@ -149,4 +147,5 @@ c6f9747da0bd3a95f86b17fb8dd5e717c8f3ab7f0ece3ba1b247899ec1ef7747 xproto-7.0.31.
adbd3b36932ce4c062cd10f57d78a156ba98d618bdb6f50664da327502bc8301 xtrans-1.3.5.tar.bz2
9717ae363760dedf573dad241420c5fea86256b65bc21d2cf71b2b12f0544f4b xz-5.2.4.tar.xz
4ff941449631ace0d4d203e3483be9dbc9da454084111f97ea0a2114e19bf066 zlib-1.2.11.tar.xz
5194fbfa781fcf45b98c5e849651aa7b3b0a008c6b72d4a0db760f3002291e94 zstd-1.5.0.tar.gz
5194fbfa781fcf45b98c5e849651aa7b3b0a008c6b72d4a0db760f3002291e94 zstd-1.5.0.tar.gz

View File

@ -1066,32 +1066,6 @@ popd
rm -rf db-5.3.28
touch /logs/status_libdb_complete
echo nss-3.44
tar xf nss-3.44.tar.gz
pushd nss-3.44
patch -Np1 -i ../nss-3.44-standalone-1.patch
cd nss
export NSS_DISABLE_GTESTS=1
# Build with single processor due to errors seen with parallel make
make -j1 BUILD_OPT=1 \
NSPR_INCLUDE_DIR=/usr/include/nspr \
USE_SYSTEM_ZLIB=1 \
ZLIB_LIBS=-lz \
NSS_ENABLE_WERROR=0 \
USE_64=1 \
$([ -f /usr/include/sqlite3.h ] && echo NSS_USE_SYSTEM_SQLITE=1)
cd ../dist
install -v -m755 Linux*/lib/*.so /usr/lib
install -v -m644 Linux*/lib/{*.chk,libcrmf.a} /usr/lib
install -v -m755 -d /usr/include/nss
cp -v -RL {public,private}/nss/* /usr/include/nss
chmod -v 644 /usr/include/nss/*
install -v -m755 Linux*/bin/{certutil,nss-config,pk12util} /usr/bin
install -v -m644 Linux*/lib/pkgconfig/nss.pc /usr/lib/pkgconfig
popd
rm -rf nss-3.44
touch /logs/status_nss_complete
echo cpio-2.13
tar xjf cpio-2.13.tar.bz2
pushd cpio-2.13
@ -1162,28 +1136,45 @@ popd
rm -rf lua-5.3.5
touch /logs/status_lua_complete
echo rpm-4.14.2
tar xjf rpm-4.14.2.tar.bz2
pushd rpm-4.14.2
patch -Np1 -i /tools/rpm-define-RPM-LD-FLAGS.patch
DEBUGEDIT_WITH_VERSION=debugedit-5.0
echo $DEBUGEDIT_WITH_VERSION
tar xf "$DEBUGEDIT_WITH_VERSION".tar.xz
pushd "$DEBUGEDIT_WITH_VERSION"
./configure --prefix=/usr
make
make install
popd
rm -rf "$DEBUGEDIT_WITH_VERSION"
touch /logs/status_debugedit_complete
RPM_WITH_VERSION=rpm-4.17.0
RPM_FOLDER="$RPM_WITH_VERSION"-release
echo $RPM_WITH_VERSION
tar xf "$RPM_WITH_VERSION"-release.tar.gz
mv rpm-"$RPM_WITH_VERSION"-release "$RPM_FOLDER"
pushd "$RPM_FOLDER"
# Do not build docs - pandoc dependency is not supplied in the toolchain.
sed -iE '/SUBDIRS/ s/docs //' Makefile.am
sed -iE '/Always build/,+16 d' Makefile.am
./autogen.sh --noconfigure
./configure --prefix=/usr \
--enable-posixmutexes \
--without-selinux \
--with-vendor=mariner \
--without-python \
--with-lua \
--without-javaglue
--enable-ndb \
--without-selinux \
--with-crypto=openssl \
--with-vendor=mariner
make -j$(nproc)
make install
install -d /var/lib/rpm
rpm --initdb --root=/ --dbpath /var/lib/rpm
popd
rm -rf rpm-4.14.2
rm -rf "$RPM_FOLDER"
touch /logs/status_rpm_complete
# Cleanup
rm -rf /tmp/*
unset BUILD_TARGET
echo sanity check - raw toolchain - after build complete - gcc -v
gcc -v

View File

@ -22,7 +22,6 @@ docker ps -a
cp -v $MARINER_SPECS_DIR/texinfo/texinfo-perl-fix.patch ./container
cp -v $MARINER_SPECS_DIR/openjdk8/Awt_build_headless_only.patch ./container
cp -v $MARINER_SPECS_DIR/openjdk8/check-system-ca-certs.patch ./container
cp -v $MARINER_SPECS_DIR/rpm/define-RPM_LD_FLAGS.patch ./container/rpm-define-RPM-LD-FLAGS.patch
# Create .bashrc file for lfs user in the container
cat > ./container/.bashrc << EOF
umask 022