From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by sourceware.org (Postfix) with ESMTPS id 0AAFC385840C for ; Mon, 24 Oct 2022 12:17:19 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 0AAFC385840C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=suse.cz Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 47FFA1FD74; Mon, 24 Oct 2022 12:17:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1666613838; h=from:from:reply-to: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=mM5kvwuLl5/3+c+Ni4rMIqx7Ku8mCCcZAQiCkDrKpNY=; b=C+UO18hadxvvJ8ui4e2H5HMaNX6j9c5t+vRqeldWwGjkSIAu0LVPpBbAXA/LMh1TDCFTvg /XoYN/J9qnaXj36X+xVLGIkjfxqsChJHNFju6Gr2cvk+MLLk2vQxwdJLqFqHjJIpuxIW9J Y3ldq6fNg19uUutZmRhuxhFMcIuI2KE= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1666613838; h=from:from:reply-to: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=mM5kvwuLl5/3+c+Ni4rMIqx7Ku8mCCcZAQiCkDrKpNY=; b=CkoNzTxQDMlrmlFTYE+FTLMdVHrW/ChvTC7T9udtNVJ1WmfAhaYZ3dqtfX2MSIjl2QMXS1 bA+Bn0zHJbq2vJCg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 1CCE413A79; Mon, 24 Oct 2022 12:17:18 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id uW2QBU6CVmPlUwAAMHmgww (envelope-from ); Mon, 24 Oct 2022 12:17:18 +0000 Message-ID: <0375dd0c-2410-d1ca-8ce7-41293e8e2fa2@suse.cz> Date: Mon, 24 Oct 2022 14:17:17 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.0 Subject: Re: [PATCH][RFC] readelf: partial support of ZSTD compression Content-Language: en-US To: "Dmitry V. Levin" Cc: elfutils-devel@sourceware.org, Mark Wielaard , Fangrui Song References: <542eb279-d15d-6f17-02c0-c53fd0f33055@suse.cz> <20221024114137.GA19251@altlinux.org> From: =?UTF-8?Q?Martin_Li=c5=a1ka?= In-Reply-To: <20221024114137.GA19251@altlinux.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,NICE_REPLY_A,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE,SPF_SOFTFAIL,TXREP 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 10/24/22 13:41, Dmitry V. Levin wrote: > On Mon, Oct 24, 2022 at 01:09:59PM +0200, Martin Liška wrote: > [...] >> One TODO I see is that: >> +libelf_so_LDLIBS = $(libelf_so_DEPS) -lz -lzstd >> >> should be conditional based on HAVE_ZSTD. But I don't know how to do that? > > I suppose you're talking about libzstd_LIBS. Hm, can't see it after autoreconf -fi and ./configure. > > [...] >> diff --git a/m4/zstd.m4 b/m4/zstd.m4 >> new file mode 100644 >> index 00000000..6da4db68 >> --- /dev/null >> +++ b/m4/zstd.m4 >> @@ -0,0 +1,23 @@ >> +dnl Copyright (C) 2022 Free Software Foundation, Inc. >> +dnl This file is free software, distributed under the terms of the GNU >> +dnl General Public License. As a special exception to the GNU General >> +dnl Public License, this file may be distributed as part of a program >> +dnl that contains a configuration script generated by Autoconf, under >> +dnl the same distribution terms as the rest of that program. >> + >> +dnl Enable features using the zstd library. >> +AC_DEFUN([AC_ZSTD], [ >> +AC_ARG_WITH(zstd, >> + [AS_HELP_STRING([--with-zstd], [support zstd compressed debug sections (default=auto)])], >> + [], [with_zstd=auto]) > > Where does this code come from? > I though the "AC_" prefix is reserved for the GNU Autoconf. It comes from binutils './config/zstd.m4' file. > Also, looks like it would be more appropriate to call it --enable-zstd > rather than --with-zstd. > Ah, I see. Thanks, Martin