From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 67610941458 for ; Mon, 11 Mar 2024 07:22:33 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=P4AP8CUIURzFMKhiYnpjYNIYqq+lSjmGyzRfmXUw9Kg=; c=relaxed/simple; d=groups.io; h=Received-SPF:From:To:CC:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding:Content-Type; s=20240206; t=1710141752; v=1; b=SdIHEHybQafPVwoG3hlbReS5ORVjBnQ3n6KKFDGGblBCgKVGi9E0djCIrCm4pnHajnN0bX5D VQmBNdCDxhKeO2FcmILZy3STDG9kW0X/u5+Jq1gc0o/kh9r0T1T5+Qc0iCaAm900enX5Ea7Mq7H aVo0DeeXcu8RJct4DFoILJmOOcwVuPZAHHKnOFAslbNnGbmotW/ApGj/SswbSTgyHT83JbiMzAV qsh8jN9WOpVibF3ToL1pDyDsypGGWyGAx5rq/S6aTcQv7q4YyNP++xYkU/OE/PxCDvTeJuZvT5Q dHpHa1FyWSx6awGyLPpxZtgUSR+ZaOYkg+jyUrleoLkLg== X-Received: by 127.0.0.2 with SMTP id DABlYY7687511x0MFMTewZjk; Mon, 11 Mar 2024 00:22:32 -0700 X-Received: from NAM12-MW2-obe.outbound.protection.outlook.com (NAM12-MW2-obe.outbound.protection.outlook.com [40.107.244.43]) by mx.groups.io with SMTP id smtpd.web11.56931.1710141751425690595 for ; Mon, 11 Mar 2024 00:22:31 -0700 X-Received: from CH0PR03CA0085.namprd03.prod.outlook.com (2603:10b6:610:cc::30) by SN7PR12MB6837.namprd12.prod.outlook.com (2603:10b6:806:267::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7362.35; Mon, 11 Mar 2024 07:22:28 +0000 X-Received: from CH3PEPF00000009.namprd04.prod.outlook.com (2603:10b6:610:cc:cafe::4f) by CH0PR03CA0085.outlook.office365.com (2603:10b6:610:cc::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7362.33 via Frontend Transport; Mon, 11 Mar 2024 07:22:28 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C X-Received: from SATLEXMB04.amd.com (165.204.84.17) by CH3PEPF00000009.mail.protection.outlook.com (10.167.244.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7386.12 via Frontend Transport; Mon, 11 Mar 2024 07:22:28 +0000 X-Received: from SHA-LX-MINGXZHA.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Mon, 11 Mar 2024 02:22:26 -0500 From: "Zhai, MingXin (Duke) via groups.io" To: CC: Abner Chang , Igniculus Fu , Ken Yao , Eric Xing Subject: [edk2-devel] [PATCH 3/4] AMD/AmdPlatformPkg: Enable capsule at linux build Date: Mon, 11 Mar 2024 00:22:31 -0700 Message-ID: <20240311072130.861-4-duke.zhai@amd.com> In-Reply-To: <20240311072130.861-1-duke.zhai@amd.com> References: <20240311072130.861-1-duke.zhai@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB04.amd.com (10.181.40.145) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH3PEPF00000009:EE_|SN7PR12MB6837:EE_ X-MS-Office365-Filtering-Correlation-Id: e29e9d82-1f27-4acb-bdd8-08dc419c0234 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Message-Info: jttIEyM4BuWH324taK8iVQwlYLxIzsVFp/KtoA41xoBBFzvHT0fGYCxPAlmw5yukoh19BF7FiYPMCpaAtWHTHLjyGKNIHAmRS5nrUXjLkiGGDMkZHjfNNcDtcb7y4jmBhGiRrOItJ4ddpxBw0MhOJuVV9O7tlHTQDBdga/Is1P1tTbpD9BoBR1t9f1Xp1wTpR1kZ1D65pJhPl/UzbIdi1nKpaHW/aFfX9q9gucyexCmhsnJfqHuidwcWGb55YBlFyQjCkirFOGUUKDegdyLo4jS9EacCLQ32Cb0ZPciaYxM5hKB1ZhlrIA/A0Dm0EM9eAvEDr3waBFsnOIxSvVGSqYRv4aIEuPbdrXmQ4aGy06GnXZ+QDZHhLu2yXPsOZFiMtnW+qEbUhre34CJl0lOO4plrOcicgkstF8OGjTZxJrH3tCpaq8TzQKXOQVqnIRZakxXru8j56vvXz01Q1FQc+phsRpFnOAOSUVNZK1zAiF3bMaiYsVSE0hSGL8P8W+1LLXAkJgT583u/kgZfkVzGj8OF6T1CP50HNSH47pkKKfTd+z2g8p1AQaWmY84QtX8C81LPGBxRjlMHCQNVpvgA/MXXQ8a+87oTalT9k/bH0Ls/a1mkWLxagOW7q1UEZx6OwGckHjyc8vwtWnlL5eEVIZYJjeV03ohB1RYx39C+aWp3xq8zd8dS3888zVdrh03nHZRhhYG4I1hxts/oK+XTYE6ahJHkBe41EmHoybmr8h4EMkFOyBRupSKkxN2TJSZh X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Mar 2024 07:22:28.6857 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e29e9d82-1f27-4acb-bdd8-08dc419c0234 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CH3PEPF00000009.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB6837 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,duke.zhai@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: zGV4LtaxudhpP7ZMk4icjALZx7686176AA= Content-Transfer-Encoding: quoted-printable Content-Type: text/plain X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=SdIHEHyb; dmarc=pass (policy=none) header.from=groups.io; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io From: Duke Zhai BZ #:4720 Linux build script include capsule build. Fix winodws capsule build issue. Cc: Abner Chang Cc: Igniculus Fu Reviewed-by: Ken Yao Reviewed-by: Eric Xing Signed-off-by: Duke Zhai --- .../ChachaniBoardPkg/GenCapsule.bat | 2 +- .../VanGoghBoard/ChachaniBoardPkg/build.sh | 22 +++++++++++++++++-- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/GenCapsule.bat b/Pl= atform/AMD/VanGoghBoard/ChachaniBoardPkg/GenCapsule.bat index 7dca22a4e3..c55f561772 100644 --- a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/GenCapsule.bat +++ b/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/GenCapsule.bat @@ -36,7 +36,7 @@ if not exist %WORKSPACE%\%BIOS_FILE_NAME% ( goto ERROR ) - Setup OpenSSL Command Line Environment +echo Setup OpenSSL Command Line Environment if not "%OPENSSL_PATH%" =3D=3D "" ( set OPENSSL_PATH_TEMP=3D%OPENSSL_PATH% ) diff --git a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/build.sh b/Platform= /AMD/VanGoghBoard/ChachaniBoardPkg/build.sh index f4652e91c6..0984876ef2 100644 --- a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/build.sh +++ b/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/build.sh @@ -1,3 +1,4 @@ +#!/bin/bash ## @file # Linux build script file to launch Chachani Board BIOS build # @@ -22,6 +23,7 @@ export OemBoard=3DChachani export PLATFORM_PATH=3Dedk2-platforms/Platform/AMD/VanGoghBoard export BUILD_TYPE=3DRELEASE export TOOLCHAIN_TAG=3DCLANGPDB +export OTA_CAPSULE_NAME=3DOTACAPSULE # You need to keep this name sync wit= h PlatformCapsule.fdf #TRUE / FALSE export COMPRESS_FSP_REGION=3DTRUE export KEY_MODE=3DTK @@ -35,16 +37,25 @@ export NASM_PREFIX=3D export GCC5_BIN=3D #CLANG_BIN shall end with a slash. export CLANG_BIN=3D +#OPENSSL_PATH shall end with a slash. +export OPENSSL_PATH=3D echo "Building for ${OemBoard} board, ${BUILD_TYPE} mode with ${TOOLCHAIN_= TAG}." -echo "IASL: ${IASL_PREFIX}iasl, NASM: ${NASM_PREFIX}nasm, GCC: ${GCC5_BIN}= gcc, CLANG:${CLANG_BIN}clang." +echo "IASL: ${IASL_PREFIX}iasl, NASM: ${NASM_PREFIX}nasm, GCC: ${GCC5_BIN}= gcc, CLANG:${CLANG_BIN}clang, OPENSSL:${OPENSSL_PATH}openssl." [[ ${COMPRESS_FSP_REGION} =3D=3D "TRUE" ]] && echo "FSP will be built with= compress support." # Env check echo_section "Checking compilation environment" [[ "${IASL_PREFIX}" =3D=3D "" ]] && export IASL_PREFIX=3D$(dirname $(which= iasl))/ [[ "${NASM_PREFIX}" =3D=3D "" ]] && export NASM_PREFIX=3D$(dirname $(which= nasm))/ +[[ "${OPENSSL_PATH}" =3D=3D "" ]] && export OPENSSL_PATH=3D$(dirname $(whi= ch openssl))/ [[ -f ${IASL_PREFIX}iasl ]] || (echo "IASL not found! Please specify IASL_= PREFIX!";exit -1) -[[ -f ${IASL_PREFIX}nasm ]] || (echo "NASM not found! Please specify NASM_= PREFIX!";exit -1) +[[ -f ${NASM_PREFIX}nasm ]] || (echo "NASM not found! Please specify NASM_= PREFIX!";exit -1) +[[ -f ${OPENSSL_PATH}openssl ]] || (echo "OpenSSL not found! Please specif= y OPENSSL_PATH!";exit -1) + +echo "IASL version $(LC_ALL=3DC ${IASL_PREFIX}iasl -v | sed -n '3,3p' | cu= t -d' ' -f5) detected." +echo "NASM version $(LC_ALL=3DC ${NASM_PREFIX}nasm --version | head -n1 | = cut -d' ' -f3) detected." +echo "OpenSSL version $(LC_ALL=3DC ${OPENSSL_PATH}openssl version | head -= n1 | cut -d' ' -f2) detected." + if [ ${TOOLCHAIN_TAG} !=3D "CLANGPDB" ] then [[ "${GCC5_BIN}" =3D=3D "" ]] && export GCC5_BIN=3D$(dirname $(which= gcc))/ @@ -174,4 +185,11 @@ python3 FlashABImage32M.py ${F1_ECSIG} ${F2_EC} ${F3_E= FS} ${F4_PSP_L1_DIRECTORY} ${F6_SLOT_HEADER_1} ${F7_SLOT_HEADER_2} ${F8_SLOT_A} ${F9_SLOT_B} ${F1= 0_OUT_IMAGE} popd +echo_section "Generating Capsule image" +rm -r ${WORKSPACE}/Build/ChachaniBoardPkg/${BUILD_TYPE}_${TOOLCHAIN_TAG}/F= V/SYSTEMFIRMWAREUPDATECARGO* +touch ${WORKSPACE}/Build/ChachaniBoardPkg/${BUILD_TYPE}_${TOOLCHAIN_TAG}/F= V/SYSTEMFIRMWAREUPDATECARGO.Fv +build -p ${PROJECT_PKG}/PlatformCapsule.dsc -t ${TOOLCHAIN_TAG} -b ${BUILD= _TYPE} -D BIOS_FILE=3D${BIOSNAME}UDK.FD +[[ $? -ne 0 ]] && exit -1 +cp ${WORKSPACE}/Build/ChachaniBoardPkg/${BUILD_TYPE}_${TOOLCHAIN_TAG}/FV/$= {OTA_CAPSULE_NAME}.Cap . + echo_section "Build success @ $(date)" -- 2.31.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#116580): https://edk2.groups.io/g/devel/message/116580 Mute This Topic: https://groups.io/mt/104858876/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-