From patchwork Mon Oct 7 11:27:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "alexander.heinisch" X-Patchwork-Id: 3853 Return-Path: Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Mon, 07 Oct 2024 13:28:20 +0200 X-Sieve: CMU Sieve 2.4 Received: from mail-qv1-f55.google.com (mail-qv1-f55.google.com [209.85.219.55]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 497BSIIq015923 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 7 Oct 2024 13:28:19 +0200 Received: by mail-qv1-f55.google.com with SMTP id 6a1803df08f44-6cb375efe56sf76290216d6.2 for ; Mon, 07 Oct 2024 04:28:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1728300493; cv=pass; d=google.com; s=arc-20240605; b=Xe0aYqgaMwFrLeLMAdkRpa/WBkT1M2rsmyirAIztllLw6QuLNaPzRx+mBjDhK2sTrI JYb6NinB63u8/rCh7Q8Zah7dMk9pde5ort7zpqMVOx1zvBtcubzn7MB7q2gE9Ye/YALR QwVsuFQSZgivNnYFu5l/lZOKHLoeGIU+XfdiKWtZUxi45sEgdjygIhqMAKC67cHEGYEP 8P2bkcP4SwqZoZZ9Vgwe+UsaWI36dei9e+q57v6aKS8JQny2AE3QrDZ2xtSC+uzOqNkB +Eq0K6cHO8wX1ick7d6a756GcQRRS8ANUDU4hN2R4pfOBBi2eCDCISv4lE6XiFj0Rj+8 Rgxw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:feedback-id:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=j9UK5K1Q0/MAwYv+VACvaXGuAIoO4hsX/39qQ4kMLvQ=; fh=S0xwarIdgv1WIsNe7eGO8gSHYr8mYfiJ7NCEJ8ieJWU=; b=EmJNDhiEZXqJMcAMC8PWs5ujnzDp2QBI/XECtat6iMRwpXIqI5BRkPlhqnlWus0hr2 lPEjPlHYt9qRo1fZG4Bs9pJjBM8fr06AsTkaZyj4d/kw88Al3SyY//5ajhp3cz/PjJmA ovaQGSwVpMVu6wfeisFAXmgN2zf4TmapoAYTCKsN68pGZKeyoGNJLTuMh/Kgk7/1Qicf iKY7obLUFvvWnLgDKfkCzwopFsxalukYopQS4i5YMJRtgA4I2qZDSCpuo75AIf0M7tnq FIlN592R17l1y1zsc3mbAo5jYg0n7o+ziFMWWnw10QtbtlYV0OSAuFxvhhFDvjDoISsT SXNA==; darn=isar-build.org ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=iypHhsiq; spf=pass (google.com: domain of fm-1326448-20241007112808fb894fb608174699c9-l45rnj@rts-flowmailer.siemens.com designates 185.136.64.225 as permitted sender) smtp.mailfrom=fm-1326448-20241007112808fb894fb608174699c9-l45RNJ@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1728300493; x=1728905293; darn=isar-build.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=j9UK5K1Q0/MAwYv+VACvaXGuAIoO4hsX/39qQ4kMLvQ=; b=LukVI916BSo14BUSU+EYqrJpQVUo0s/0xNnrAMnSB+vjgrnRWhj2cpiYJhIwS1lmP9 M0IVXUmQJUiP+HFUMXV0qBWNbK9xzYdFRFAdY3u1GJR2r9J3f21nLTlOj7Zb9JZBhOMF gW8EB7Xw1rB4jVKoE0z2QSE+smYkcmwmDDrhBpAv6bO6vuPXlSAOVKQ5fBBnsosLEwh7 A+AIJ415+E6f/FoN3Y3ZmgC/8MO5JTqufeTvr+hVCEOEj26AFTOpSUTDa9MWbJNWtH6m YeyWcTMCnMHhapjL9BHOGoHirE9Ko/vR6D+ODo+3T2ISLKDINcYRFlh34NVmvu7Wb9I2 FI5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728300493; x=1728905293; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:x-beenthere :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=j9UK5K1Q0/MAwYv+VACvaXGuAIoO4hsX/39qQ4kMLvQ=; b=itN5Yzrlc8aokXz6SnfHbSro/1uH9yP3VhQqfWEg8sIdLXNKK+Yk3p45vmtOtHHYOZ vDYk+1klnER0jbksaqMKSVHmEtZ0bD3rWWIJGoXvyoQhkFgmVzs82XHbIaZfw/ND/dnn km6jEF3J9cFcaWJsaJKiupuvilxlkXUfrSVd8aNAvS4DbJ4yJEQeSA/EIMAK/w5hxv9x B5lX4m7x8tnPa2DLftBe6J9h735LTS1Ai34CtQKEOvcwArTus5y748nqLdt8L0G1hKiK wqZ7I96pQYn0q3qyO0nk4g8/p+wRU19cFfwM8hkJOGXbAOTM9Z84fTzufhkA+QpGGIyM toYQ== X-Forwarded-Encrypted: i=2; AJvYcCVggHm93WsAOJQizCBbCPY7koJNchMhcMxE+Skx5LQiubc7m4W8eTGmdKK7WsZdHTIiXSwWS38=@isar-build.org X-Gm-Message-State: AOJu0YzKk7FVyOrHJBN8rxWrCzEJIyFJ5lzL1eIIAda67WCU1CzGXCYF rZIvIqheACO5KBCX/Aj9R2Z6MbcJeG8OHpIGqQKTyIB2ocrsAXk5 X-Google-Smtp-Source: AGHT+IGYlnWfJDHi3wEf/8DbVO8ynW6SOLYX2ico5PjFd9Nsd6qebPYcEs4TxCKT4ubPZ/CoEz/pbQ== X-Received: by 2002:a05:6214:488d:b0:6cb:7104:f115 with SMTP id 6a1803df08f44-6cb9a1f83fbmr175487896d6.11.1728300492709; Mon, 07 Oct 2024 04:28:12 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:6214:240f:b0:6c5:127c:2ebc with SMTP id 6a1803df08f44-6cb9015b9b8ls66581706d6.2.-pod-prod-05-us; Mon, 07 Oct 2024 04:28:10 -0700 (PDT) X-Received: by 2002:a05:620a:3705:b0:7a9:a8c5:d490 with SMTP id af79cd13be357-7ae6f44c74emr1862777685a.29.1728300490177; Mon, 07 Oct 2024 04:28:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1728300490; cv=none; d=google.com; s=arc-20240605; b=fUUddMvnM625qUc3mnN8h2SKfYEF3oylhcbQMhK+6Ul4Q99sTQ9pIql4NkjKLQr9fX 7mil/bdcVhVqIHZ/kyJSq5aRb/OONAsL3x8dpl/GXhdzbHVciqeqsDDRZIBLHEvbKeOq O4WNwovlEve413vrUxf3q0sxr6KfxpwEj2y54WtjuieCdwa8Cl9U8z5SySRKkR3b6/kJ ayD1DHxL8HSOEyTPviffnrBU6hIvv1OOz909l0SLF1kMA2pRlDBMYnPmF3UrAVV0FlnI IflDANtPcaPUuZyTUs4J0uOdUx9L2WfPmQOXUPZoKSzKucZJfmMCUQozgV+XcahgBs3B l4vw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=feedback-id:content-transfer-encoding:mime-version:message-id:date :subject:cc:to:from:dkim-signature; bh=SrHV/xvE07gxctyvVTONYWsUYLfWaIq2JHwIePLOF3I=; fh=Z5Qnyb0EtJ8UwrxkpbdSYE+xHzQI6qPfwJivtsUki18=; b=FjNpiTkgiGOKX7tX1IymOA5PJ7S2wRPVAlvWZXzbmaOus3qdMjfwFCGWLz7hxEbgl7 tu+eA5LXNY1U801mMZS4XZM4pvmAjdZk4qlcqTk17hUT48tTTzQFzD6nSAY1n//0m2Kn b2fW4n6xjfUV/0sgAXMVroZzwdCDLp85Vxi2Y3+kPTtSlItt/Raj56RWQEPnojEwk9ln tt5BbzoIJnG4cWBQ+rfZCbsAF9fkZiOW40wxjjKBtgE0cY6ni+AsJCGMUPVflcNemVbU SnVbCQxtGqbnw55T7ZckIcH+h5kgmp1s/di8RNO2J9M/A0j5RtgPLX14t2yf9+hqG4/f Mo/w==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=iypHhsiq; spf=pass (google.com: domain of fm-1326448-20241007112808fb894fb608174699c9-l45rnj@rts-flowmailer.siemens.com designates 185.136.64.225 as permitted sender) smtp.mailfrom=fm-1326448-20241007112808fb894fb608174699c9-l45RNJ@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com Received: from mta-64-225.siemens.flowmailer.net (mta-64-225.siemens.flowmailer.net. [185.136.64.225]) by gmr-mx.google.com with ESMTPS id af79cd13be357-7ae7549ad6fsi19200185a.0.2024.10.07.04.28.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Oct 2024 04:28:10 -0700 (PDT) Received-SPF: pass (google.com: domain of fm-1326448-20241007112808fb894fb608174699c9-l45rnj@rts-flowmailer.siemens.com designates 185.136.64.225 as permitted sender) client-ip=185.136.64.225; Received: by mta-64-225.siemens.flowmailer.net with ESMTPSA id 20241007112808fb894fb608174699c9 for ; Mon, 07 Oct 2024 13:28:09 +0200 X-Patchwork-Original-From: "alexander.heinisch via isar-users" From: "alexander.heinisch" To: isar-users@googlegroups.com Cc: jan.kiszka@siemens.com, felix.moessbauer@siemens.com, Alexander Heinisch Subject: [PATCH] meta: Allow to specify the snapshot date in the upstream format. Date: Mon, 7 Oct 2024 13:27:45 +0200 Message-ID: <20241007112745.92905-1-alexander.heinisch@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-1326448:519-21489:flowmailer X-Original-Sender: alexander.heinisch@siemens.com X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=iypHhsiq; spf=pass (google.com: domain of fm-1326448-20241007112808fb894fb608174699c9-l45rnj@rts-flowmailer.siemens.com designates 185.136.64.225 as permitted sender) smtp.mailfrom=fm-1326448-20241007112808fb894fb608174699c9-l45RNJ@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com X-Original-From: alexander.heinisch@siemens.com Reply-To: alexander.heinisch@siemens.com Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , X-Spam-Status: No, score=-4.9 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H2,RCVD_IN_RP_CERTIFIED, RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= From: Alexander Heinisch Currently, it is only possible to specify a unix timestamp to resolve the snapshot version used. Since this is not very user friendly, most downstream projects put comments like `# 20240702T082400Z` next to the snapshot assignment `ISAR_APT_SNAPSHOT_TIMESTAMP = ...`. This patch makes it easier for users to specify the snapshot version in a more natural way by `APT_SNAPSHOT_DATE = 20240702T082400Z` Signed-off-by: Alexander Heinisch --- doc/user_manual.md | 3 ++- kas/opt/Kconfig | 2 +- meta/recipes-core/isar-bootstrap/isar-bootstrap.inc | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/doc/user_manual.md b/doc/user_manual.md index 706c74bf..bcfea5a0 100644 --- a/doc/user_manual.md +++ b/doc/user_manual.md @@ -435,7 +435,8 @@ Some other variables include: - `ISAR_USE_APT_SNAPSHOT` - Use a frozen apt snapshot instead of the live mirror. Optional. `ISAR_APT_DL_LIMIT` - Rate limit the apt fetching to n kB / s. Optional. - `DISTRO_APT_SNAPSHOT_PREMIRROR` - Similar to `DISTRO_APT_PREMIRRORS` but for a snapshot, pre-defined for supported distros. - - `ISAR_APT_SNAPSHOT_TIMESTAMP` - Timestamp of the apt snapshot. Automatically derived from `SOURCE_DATE_EPOCH` if not overwritten. + - `ISAR_APT_SNAPSHOT_TIMESTAMP` - Unix timestamp of the apt snapshot. Automatically derived from `SOURCE_DATE_EPOCH` if not overwritten. (Consider `APT_SNAPSHOT_DATE` for a more user friendly format) + - `APT_SNAPSHOT_DATE` - Timestamp in upstream format (e.g. `20240702T082400Z`) of the apt snapshot. Automatically derived from `ISAR_APT_SNAPSHOT_TIMESTAMP` - `THIRD_PARTY_APT_KEYS` - List of gpg key URIs used to verify apt repos for apt installation after bootstrapping. - `FILESEXTRAPATHS` - The default directories BitBake uses when it processes recipes are initially defined by the FILESPATH variable. You can extend FILESPATH variable by using FILESEXTRAPATHS. - `FILESOVERRIDES` - A subset of OVERRIDES used by the build system for creating FILESPATH. The FILESOVERRIDES variable uses overrides to automatically extend the FILESPATH variable. diff --git a/kas/opt/Kconfig b/kas/opt/Kconfig index 65482e3a..802bb1a0 100644 --- a/kas/opt/Kconfig +++ b/kas/opt/Kconfig @@ -44,7 +44,7 @@ config USE_APT_SNAPSHOT bool "Use the distros snapshot mirror" depends on !MIRROR_DEBIAN && (DEBIAN_BUSTER || DEBIAN_BULLSEYE || DEBIAN_BOOKWORM || DEBIAN_TRIXIE || DEBIAN_SID || UBUNTU_FOCAL || UBUNTU_JAMMY) help - Use a snapshot mirror for the selected distribution. The date is defined by ISAR_APT_SNAPSHOT_TIMESTAMP. + Use a snapshot mirror for the selected distribution. The date is defined by APT_SNAPSHOT_DATE. config KAS_INCLUDE_APT_SNAPSHOT string diff --git a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc index 12f32ff0..125554e1 100644 --- a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc +++ b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc @@ -34,7 +34,7 @@ DISTRO_VARS_PREFIX ?= "${@'HOST_' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR BOOTSTRAP_DISTRO = "${@d.getVar('HOST_DISTRO' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR_HOST')) else 'DISTRO')}" BOOTSTRAP_BASE_DISTRO = "${@d.getVar('HOST_BASE_DISTRO' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR_HOST')) else 'BASE_DISTRO')}" FILESEXTRAPATHS:append = ":${BBPATH}" -APT_SNAPSHOT_DATE = "${@ get_apt_snapshot_date(d)}" +APT_SNAPSHOT_DATE ?= "${@ get_apt_snapshot_date(d)}" inherit deb-dl-dir