From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ej1-x636.google.com (mail-ej1-x636.google.com [IPv6:2a00:1450:4864:20::636]) by sourceware.org (Postfix) with ESMTPS id 045023858433 for ; Mon, 22 Jan 2024 12:19:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 045023858433 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 045023858433 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::636 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705925952; cv=none; b=xQgtcQ1ofWMFxFCUIMI11fndRKoxDRpjftmrfNAFm8nsvFEyA8eXc4RrHYMokm50JO1VGBICcY9fv7TQPc8BF8lJEminv1WeOgfyMZMGhVRCSNfPbdFv91C3Rfub2ivNfQ1RiHIM0dAbuoYYV/o5QGoangO6Who3+8UI38uHvu8= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705925952; c=relaxed/simple; bh=70d+x4x71ggoWQkHLwIlno/bE3sGGQEZ22taRzM2Fao=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=vDXnZSWi1jJHva42WMOxzSeKRObj6iaKDajBl33/egytsq533BJuFmePJ0woTnrlQXUc8FTBwPzjj7fjE1zE+Nst11muItM1bPxjKjbdFu6Lq59tpsS3JjjS34p+Wao5LuD5JXyhZptDkHDb3ksapg67g/b+KffgB3wU7H6+gfM= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-ej1-x636.google.com with SMTP id a640c23a62f3a-a28a6cef709so300597166b.1 for ; Mon, 22 Jan 2024 04:19:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1705925949; x=1706530749; darn=sourceware.org; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=flva43jjZR0040UBF4DMT1vBMdDUO7wu0qYhWnOvosk=; b=GwbgNPTd37pIPSrYL6aSBpIVkN2SBCLTgX40nf/ZvEsS1Cnu0ayBZ3Num2KtclKaTm AFlzrPeGD7OPc/5l8yNLWx+z91VyTPHZruEU1dMX/qe57W1QSeOPlBgmV1g97bvEeZwN wuIGZHs1g0aBlG22LKeNiIILJ7Sapgo5M1X50KvcZTKZKYdJp7+clTXgs9PgA1OrVU9Q EEEKX5adBP4NZnLDdqbvyxoZqIX0ZqXsSPRGhE+QeIVukAMIWhHS5JZF1KJbiaF5+Bnp geEeKDg+uGOO18OualNaeTJyoxRob2erN8PHFeXa8+dw7LAEj3/8oiH9BjUDuG0Ohy44 6noA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705925949; x=1706530749; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=flva43jjZR0040UBF4DMT1vBMdDUO7wu0qYhWnOvosk=; b=sc8cJpT0k0kYUu0BeNXxzq2EbNehRh7NHPSbkgilLJb7ms13GNv8XkjzBoQ0NFkUAA TQyLLZ6YeaTRmttsYW9Wh6fPkyaTpYYKhHi76bXj0VpUvFm3cyRtJC0MFYuDJ15PP9YU GRYj+exzzDxjM1F08kwckN89pcREY9F4Ycq7e8KoMbnl+PK+vTBeTqUWBSE6rkKS5D4b g1KQDN1ETGLASOs//EHlOOoIqYVkrf23x7riYBrVndn7rK5qOTxH7x2FdGcDWL+b9+Ew rVFs7zJTvo95RYWsGSUsBGp3k+sONOGl2OdQZC93T0/fN+66SHUgabayfv4sx8B8p3GF hQwQ== X-Gm-Message-State: AOJu0YwGjXMJZGyOw21DZi87MEkUHDQ0AsVynu0M3pJ4SQa+QG5TjHR8 fADuZnpHozR2LKV/otDtiRuaNBLtj9F/ZTbfYa3yyKuiswPmUXefLhf4tOfEzleQkwlrK8GEQdY = X-Google-Smtp-Source: AGHT+IHcb2KeU3kTX0BM0smcvumfx1z4ASd7dRq7oV12L8Xzx8RcFvFQeqwgUX34vAESR3zQd/23Fw== X-Received: by 2002:a17:906:f94d:b0:a2d:da6e:d64 with SMTP id ld13-20020a170906f94d00b00a2dda6e0d64mr1861466ejb.125.1705925948705; Mon, 22 Jan 2024 04:19:08 -0800 (PST) Received: from [10.156.60.236] (ip-037-024-206-209.um08.pools.vodafone-ip.de. [37.24.206.209]) by smtp.gmail.com with ESMTPSA id c64-20020a029646000000b0046e92a0d8b3sm3056637jai.155.2024.01.22.04.19.07 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 22 Jan 2024 04:19:08 -0800 (PST) Message-ID: Date: Mon, 22 Jan 2024 13:19:05 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: readelf --string-dump analog for objdump Content-Language: en-US To: Maxim Dementyev Cc: binutils@sourceware.org References: From: Jan Beulich Autocrypt: addr=jbeulich@suse.com; keydata= xsDiBFk3nEQRBADAEaSw6zC/EJkiwGPXbWtPxl2xCdSoeepS07jW8UgcHNurfHvUzogEq5xk hu507c3BarVjyWCJOylMNR98Yd8VqD9UfmX0Hb8/BrA+Hl6/DB/eqGptrf4BSRwcZQM32aZK 7Pj2XbGWIUrZrd70x1eAP9QE3P79Y2oLrsCgbZJfEwCgvz9JjGmQqQkRiTVzlZVCJYcyGGsD /0tbFCzD2h20ahe8rC1gbb3K3qk+LpBtvjBu1RY9drYk0NymiGbJWZgab6t1jM7sk2vuf0Py O9Hf9XBmK0uE9IgMaiCpc32XV9oASz6UJebwkX+zF2jG5I1BfnO9g7KlotcA/v5ClMjgo6Gl MDY4HxoSRu3i1cqqSDtVlt+AOVBJBACrZcnHAUSuCXBPy0jOlBhxPqRWv6ND4c9PH1xj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0ZnMQi+G0A nAuWpQkjM1ASeQwSHEeAWPgskBQL In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3025.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE 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 22.01.2024 13:11, Maxim Dementyev wrote: > Thanks for pointing me out the objdump utility! > Unfortunately, --only-section isn't a good choice: it produces all other > information in the output file, not only the section in question. > But I've found the need option of objdump utility: --dump-section > Unfortunately, apart from this, again, the objdump utility creates a > formatted file as an output, and I can add --only-section to reduce the > size of it and redirect it to /dev/null. But you're aware of objcopy's --output-target option, by using of which you could have it produce a raw binary output file? > So, this is usable with one intermediate file for a section. > But it is much more complicated than just: > "readelf -p section file | grep something". > > And a possible solution (how to improve the objdump utility in a generic > way) could be a special value for the --dump-section option to produce the > output only for this section instead of redirecting it to a separate file: > "objcopy --dump-section section=stdout | grep something" Maybe. Plain "stdout" would be at risk of being ambiguous though. Then again the use of '=' there is making the whole construct ambiguous already, for '=' potentially (even if unlikely) being part of the section name. Jan