IO-Uring Archive mirror
 help / color / mirror / Atom feed
From: Arthur Williams <taaparthur@disroot.org>
To: axboe@kernel.dk
Cc: io-uring@vger.kernel.org, Arthur Williams <taaparthur@disroot.org>
Subject: [PATCH] Fix portability issues in configure script
Date: Tue,  9 Apr 2024 10:27:35 -0700	[thread overview]
Message-ID: <20240409172735.1082-1-taaparthur@disroot.org> (raw)

The configure script failed on my setup because of the invalid printf
directive "%" and for use of the unportable "echo -e". These have been
replaced with more portable options.
---
 configure | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/configure b/configure
index 052920d..f6b590b 100755
--- a/configure
+++ b/configure
@@ -519,9 +519,9 @@ print_config "CXX" "$cxx"
 # generate io_uring_version.h
 # Reset MAKEFLAGS
 MAKEFLAGS=
-MAKE_PRINT_VARS="include Makefile.common\nprint-%: ; @echo \$(\$*)\n"
-VERSION_MAJOR=$(env echo -e "$MAKE_PRINT_VARS" | make -s --no-print-directory -f - print-VERSION_MAJOR)
-VERSION_MINOR=$(env echo -e "$MAKE_PRINT_VARS" | make -s --no-print-directory -f - print-VERSION_MINOR)
+MAKE_PRINT_VARS="include Makefile.common\nprint-%%: ; @echo \$(\$*)\n"
+VERSION_MAJOR=$(printf "$MAKE_PRINT_VARS" | make -s --no-print-directory -f - print-VERSION_MAJOR)
+VERSION_MINOR=$(printf "$MAKE_PRINT_VARS" | make -s --no-print-directory -f - print-VERSION_MINOR)
 io_uring_version_h="src/include/liburing/io_uring_version.h"
 cat > $io_uring_version_h << EOF
 /* SPDX-License-Identifier: MIT */
-- 
2.44.0


             reply	other threads:[~2024-04-09 17:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-09 17:27 Arthur Williams [this message]
2024-04-09 17:37 ` [PATCH] Fix portability issues in configure script Ammar Faizi
2024-04-26  6:31   ` Arthur Williams
2024-04-26 14:30     ` Jens Axboe

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=20240409172735.1082-1-taaparthur@disroot.org \
    --to=taaparthur@disroot.org \
    --cc=axboe@kernel.dk \
    --cc=io-uring@vger.kernel.org \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).