public inbox for [email protected]
 help / color / mirror / Atom feed
* [PATCH liburing] configure: Respect relative prefix path
@ 2024-07-23 23:20 Gabriel Krisman Bertazi
  2024-07-24  0:22 ` Jens Axboe
  0 siblings, 1 reply; 2+ messages in thread
From: Gabriel Krisman Bertazi @ 2024-07-23 23:20 UTC (permalink / raw)
  To: axboe, asml.silence; +Cc: io-uring, Gabriel Krisman Bertazi

When the user passes a relative path, we end up splitting the
installation in multiple directories because it is relative to $CWD,
which changes when we recurse into subdirectories.

A common idiom I use is:

  ./configure --prefix=install ; make ; make install

and that currently results in part of the installation inside prefix
and part of it elsewhere:

 $ find . -type d  -name 'install'
  ./src/install
  ./install

Not biggy, but annoying.  Let's use the path where the configure command
was invoked as basedir, like other projects usually do.

Signed-off-by: Gabriel Krisman Bertazi <[email protected]>
---
 configure | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/configure b/configure
index f6b590b..21a9356 100755
--- a/configure
+++ b/configure
@@ -10,7 +10,7 @@ for opt do
   case "$opt" in
   --help|-h) show_help=yes
   ;;
-  --prefix=*) prefix="$optarg"
+  --prefix=*) prefix="$(realpath -s $optarg)"
   ;;
   --includedir=*) includedir="$optarg"
   ;;
-- 
2.45.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH liburing] configure: Respect relative prefix path
  2024-07-23 23:20 [PATCH liburing] configure: Respect relative prefix path Gabriel Krisman Bertazi
@ 2024-07-24  0:22 ` Jens Axboe
  0 siblings, 0 replies; 2+ messages in thread
From: Jens Axboe @ 2024-07-24  0:22 UTC (permalink / raw)
  To: asml.silence, Gabriel Krisman Bertazi; +Cc: io-uring


On Tue, 23 Jul 2024 19:20:26 -0400, Gabriel Krisman Bertazi wrote:
> When the user passes a relative path, we end up splitting the
> installation in multiple directories because it is relative to $CWD,
> which changes when we recurse into subdirectories.
> 
> A common idiom I use is:
> 
>   ./configure --prefix=install ; make ; make install
> 
> [...]

Applied, thanks!

[1/1] configure: Respect relative prefix path
      commit: 476a6a9e92f390b16d12a3d66c046d456b5783e3

Best regards,
-- 
Jens Axboe




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-07-24  0:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-23 23:20 [PATCH liburing] configure: Respect relative prefix path Gabriel Krisman Bertazi
2024-07-24  0:22 ` Jens Axboe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox