From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl1-x62f.google.com (mail-pl1-x62f.google.com [IPv6:2607:f8b0:4864:20::62f]) by sourceware.org (Postfix) with ESMTPS id 699C03858D28 for ; Tue, 2 May 2023 03:46:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 699C03858D28 Authentication-Results: sourceware.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=google.com Received: by mail-pl1-x62f.google.com with SMTP id d9443c01a7336-1aae90f5ebcso18025ad.1 for ; Mon, 01 May 2023 20:46:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1682999215; x=1685591215; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=PbPAnhu1LeWVqttDkxvE5NeYqKz+GKg4xR/tslFlp6o=; b=iv4W02rNevWfsueTSgnqLsQqFG8bo09HyZQD/ylMI9omzCMRhCaNGxNl9j4uT9pQlQ UcznjGF4dCRPhw1R2MoKZYutD1k5+pZctdT0iszUcZWCg1cidsgSvIpw/66/q92yJCgb f+CTFNiSq/Dkq2obqv0dNIWmC0+4gMP9HnznIC45ReWC+0hZu1KWdRLe5TFPzBqOXqRq 3LQu6srw4vD/OsXBie8SzZuGT/C1y0nXCQccSfEEceLEDdId64E2M1H6y3I9OJYEjPiX T4t2JBxH0WB6seQ9HtpjK81VhJoBXd4CJ4w78eTAtVzAtg04GRS0cVxBt1A3rIMfLJ2I B0zQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682999215; x=1685591215; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PbPAnhu1LeWVqttDkxvE5NeYqKz+GKg4xR/tslFlp6o=; b=Ww8TkOZAGYZLm417Kk7znwAjUriyCX8iXSxxmIOm1u4GMPbs21gX9Mp9mnnz9MMelo HLRZR0fpfFFY6qq8qaKbsUAf/KzVY0QdIZd4kLKwuKbWD6gS4CwdIgRBRrZSw13M3mdw QJLeGEZm2Ta1rJpd9QgLzrD/Ar/AkVbjpe6Ev3sY2NnmDaX95R4nmjtwl/5fXnU4FUhg WlriYFHHKjPyN1nOfc7wkULl/tWcv6pG0X6tJ0jiDX7P1FzCD0mFJyhWmBQxKOcBF3oP tT0X2A4IrNYIxgPdhovZiYQ5UpZf1C5eIdBICUGlfoKjPhNEEsVoZqkh0xlDB/x/W27a Za4g== X-Gm-Message-State: AC+VfDy81XoJ0Lq43o1cu9uxT+PC2sRBtN7GbKP9k/N03b0hBWbEiK/m S1rMcYGQgH3aKtP0ecFLqoiL7yUbvTpK1N/sGXL5eA== X-Google-Smtp-Source: ACHHUZ4aLEOHi574T37pVkOOgjVcbJdfdaujdJeMHgopplnmCcnDlhgwfXuYahNTb/QuGTi3l/5D6nn/U+eK2xGw2/A= X-Received: by 2002:a17:902:ec88:b0:1a9:7cbf:a7c1 with SMTP id x8-20020a170902ec8800b001a97cbfa7c1mr81743plg.13.1682999215138; Mon, 01 May 2023 20:46:55 -0700 (PDT) MIME-Version: 1.0 References: <20230501084208.2h5k4hleimqmoopf@begin> In-Reply-To: From: Fangrui Song Date: Mon, 1 May 2023 20:46:43 -0700 Message-ID: Subject: Re: error: macro DT/STO_RISCV_VARIANT_CC redefined To: Palmer Dabbelt Cc: samuel.thibault@ens-lyon.org, libc-alpha@sourceware.org, vincent.chen@sifive.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-17.4 required=5.0 tests=BAYES_00,BODY_8BITS,DKIMWL_WL_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Mon, May 1, 2023 at 5:42=E2=80=AFAM Palmer Dabbelt = wrote: > > On Mon, 01 May 2023 01:42:08 PDT (-0700), samuel.thibault@ens-lyon.org wr= ote: > > Also, the kai.wang@sifive.com email address doesn't seem to be working, > > the mail server says it doesn't exist... > > Sorry, it's my fault -- I committed it thinking the test suite had been > run, but it hadn't. I've got some WIP, but I found another test suite > hook I need last night and I've yet to make sure that's enough as my > test box went down. > > I think we should just go ahead and commit the revert for now? That way > we can avoid having other folks be broken while I figure out what's up. I agree that committing a revert for 117e8b341c5c0ace8d65feeef136fececb3fdc9c will be cleaner. Then you may push another commit adding the macros to a conventional location, avoiding the duplicate. Then some of the patches in "[PATCH v3 0/6] elf.h: Fix and cleanup the RISC-V defines" can be avoided. > > > > Samuel Thibault, le lun. 01 mai 2023 10:40:30 +0200, a ecrit: > >> Hello, > >> > >> I'm getting these errors: > >> > >> FAIL: elf/tst-relro-ldso > >> FAIL: elf/tst-relro-libc > >> FAIL: elf/tst-glibcelf > >> > >> /mnt/scratch/sthibault/build-glibc/src/glibc/scripts/../elf/elf.h:4013= : error: macro STO_RISCV_VARIANT_CC redefined > >> /mnt/scratch/sthibault/build-glibc/src/glibc/scripts/../elf/elf.h:3941= : note: location of previous definition > >> /mnt/scratch/sthibault/build-glibc/src/glibc/scripts/../elf/elf.h:4023= : error: macro DT_RISCV_VARIANT_CC redefined > >> /mnt/scratch/sthibault/build-glibc/src/glibc/scripts/../elf/elf.h:3937= : note: location of previous definition > >> Traceback (most recent call last): > >> File "/mnt/scratch/sthibault/build-glibc/src/glibc/elf/tst-relro-sym= bols.py", line 33, in > >> import glibcelf > >> File "/mnt/scratch/sthibault/build-glibc/src/glibc/elf/../scripts/gl= ibcelf.py", line 226, in > >> _elf_h =3D _parse_elf_h() > >> File "/mnt/scratch/sthibault/build-glibc/src/glibc/elf/../scripts/gl= ibcelf.py", line 223, in _parse_elf_h > >> raise IOError('parse error in elf.h') > >> OSError: parse error in elf.h > >> > >> and indeed, elf/elf.h defines STO_RISCV_VARIANT_CC and > >> DT_RISCV_VARIANT_CC twice. > >> > >> This seems to have been introduced by 117e8b341c5c ("riscv: Resolve > >> symbols directly for symbols with STO_RISCV_VARIANT_CC.")? > >> > >> Samuel --=20 =E5=AE=8B=E6=96=B9=E7=9D=BF