rust-for-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Martin Rodriguez Reboredo <yakoyoku@gmail.com>
To: Matthew Leach <dev@mattleach.net>,
	Miguel Ojeda <ojeda@kernel.org>,
	Wedson Almeida Filho <wedsonaf@gmail.com>,
	Boqun Feng <boqun.feng@gmail.com>, Gary Guo <gary@garyguo.net>
Cc: rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scripts: rust_is_available: check for empty libclang version
Date: Sun, 7 May 2023 20:15:54 -0300	[thread overview]
Message-ID: <44dc8206-a42b-047b-bd2d-62b54fbe8ee8@gmail.com> (raw)
In-Reply-To: <20230507084116.1099067-1-dev@mattleach.net>

On 5/7/23 05:41, Matthew Leach wrote:
> If bindgen can't find libclang, then bindgen will panic with the
> following error:
> 
> thread 'main' panicked at 'Unable to find libclang: "couldn't find any
> valid shared libraries matching: ['libclang.so', 'libclang-*.so',
> 'libclang.so.*', 'libclang-*.so.*'], set the `LIBCLANG_PATH` environment
> variable to a path where one of these files can be found.
> 
> This is outputted to stderr, leaving stdout empty. The empty string is
> then passed to get_canonical_version and the following is show to the
> user:
> 
> $ make LLVM=1 rustavailable
> ./scripts/rust_is_available.sh: line 21: 100000 *  + 100 *  + : syntax error: operand expected (error token is "+ ")
> make: *** [Makefile:1825: rustavailable] Error 1
> 
> Note: bindgen's bad exit code isn't caught by 'set -e' since it is ran
> in a subshell.
> 
> Fix this by prnting out a more helpful error message if the output of
> bindgen is empty.
> 
> Signed-off-by: Matthew Leach <dev@mattleach.net>
> ---
> [...]

Reviewed-by: Martin Rodriguez Reboredo <yakoyoku@gmail.com>

  reply	other threads:[~2023-05-07 23:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-07  8:41 [PATCH] scripts: rust_is_available: check for empty libclang version Matthew Leach
2023-05-07 23:15 ` Martin Rodriguez Reboredo [this message]
2023-06-16  0:27 ` Miguel Ojeda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=44dc8206-a42b-047b-bd2d-62b54fbe8ee8@gmail.com \
    --to=yakoyoku@gmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=dev@mattleach.net \
    --cc=gary@garyguo.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=wedsonaf@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).