From patchwork Mon Mar 20 10:26:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Marchand X-Patchwork-Id: 125313 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C65FA427E0; Mon, 20 Mar 2023 11:26:44 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B8A95410F3; Mon, 20 Mar 2023 11:26:44 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 1E185406BC for ; Mon, 20 Mar 2023 11:26:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1679308003; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WxOs+ge8n2z1PpFhzksDtNZjWpeoofb1VfW6N/vlKLw=; b=IZ8Pa8k/ulyLsmpRpjkXBWDdZBUjwOYHgJxiZjJcjtQwAdtFt+ByH98wkn2yaRiepc3v+L sLTDJYxFtEDSpBi6Fkw5gSY7C0ZJ+n0PyTwOyCnJuD3DeQI8yAcgq1A0cLCVOkJL/PcIix ZIQmvovjZ9+d2PT7U11EHoQJqIZNhd0= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-131-516XRPUkNcaTtiwKC0gfFA-1; Mon, 20 Mar 2023 06:26:37 -0400 X-MC-Unique: 516XRPUkNcaTtiwKC0gfFA-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 43A7588B7A1; Mon, 20 Mar 2023 10:26:37 +0000 (UTC) Received: from dmarchan.redhat.com (unknown [10.45.224.63]) by smtp.corp.redhat.com (Postfix) with ESMTP id 89C064619F4; Mon, 20 Mar 2023 10:26:36 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: Aaron Conole , Michael Santana Subject: [PATCH 2/2] ci: test compilation with debug Date: Mon, 20 Mar 2023 11:26:23 +0100 Message-Id: <20230320102624.1258816-2-david.marchand@redhat.com> In-Reply-To: <20230320102624.1258816-1-david.marchand@redhat.com> References: <20230320102624.1258816-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org We often miss compilation issues with -O0 -g. Add a test in GHA. Signed-off-by: David Marchand --- .ci/linux-build.sh | 8 +++++++- .github/workflows/build.yml | 4 ++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh index ab0994388a..150b38bd7a 100755 --- a/.ci/linux-build.sh +++ b/.ci/linux-build.sh @@ -65,6 +65,12 @@ if [ "$RISCV64" = "true" ]; then cross_file=config/riscv/riscv64_linux_gcc fi +buildtype=debugoptimized + +if [ "$BUILD_DEBUG" = "true" ]; then + buildtype=debug +fi + if [ "$BUILD_DOCS" = "true" ]; then OPTS="$OPTS -Denable_docs=true" fi @@ -85,7 +91,7 @@ fi OPTS="$OPTS -Dplatform=generic" OPTS="$OPTS -Ddefault_library=$DEF_LIB" -OPTS="$OPTS -Dbuildtype=debugoptimized" +OPTS="$OPTS -Dbuildtype=$buildtype" OPTS="$OPTS -Dcheck_includes=true" if [ "$MINI" = "true" ]; then OPTS="$OPTS -Denable_drivers=net/null" diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 154be70cc1..d90ecfc6f0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,6 +18,7 @@ jobs: ABI_CHECKS: ${{ contains(matrix.config.checks, 'abi') }} ASAN: ${{ contains(matrix.config.checks, 'asan') }} BUILD_32BIT: ${{ matrix.config.cross == 'i386' }} + BUILD_DEBUG: ${{ contains(matrix.config.checks, 'debug') }} BUILD_DOCS: ${{ contains(matrix.config.checks, 'doc') }} CC: ccache ${{ matrix.config.compiler }} DEF_LIB: ${{ matrix.config.library }} @@ -37,6 +38,9 @@ jobs: - os: ubuntu-20.04 compiler: gcc mini: mini + - os: ubuntu-20.04 + compiler: gcc + checks: debug - os: ubuntu-20.04 compiler: gcc checks: abi+doc+tests