[PATCH] Fix use of hardlinks in "make install"

STALE3707d

8 messages, 2 authors, 2016-06-15 · open the first message on its own page

[PATCH] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:14

The code tried to create a hardlink to the file ($execdir/git-add) it just
removed, so ln failed (but because stderr was redirected into /dev/null the
error was never seen), and the whole install ended up using "ln -s" instead.

Signed-off-by: Alex Riesen <redacted>
---

It created endless symlink loops on cygwin, but obviously nowhere else.

 Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Re: [PATCH] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:14

2008/8/28 Alex Riesen [off-list ref]:
The code tried to create a hardlink to the file ($execdir/git-add) it just
removed, so ln failed (but because stderr was redirected into /dev/null the
error was never seen), and the whole install ended up using "ln -s" instead.

Signed-off-by: Alex Riesen <redacted>
---

It created endless symlink loops on cygwin, but obviously nowhere else.
Sh@#! Scrap that, there is something else going on in that cygwindows thing...

[PATCH] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:14

The code failed to filter-out git-add properly on platforms were $X is
not empty (ATM there is only one such a platform).

Than it tried to create a hardlink to the file ($execdir/git-add) it just
removed (because git-add is first in the BUILT_INS), so ln failed (but
because stderr was redirected into /dev/null the error was never seen), and
the whole install ended up using "ln -s" instead.

Signed-off-by: Alex Riesen <redacted>
---
 Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

2008/8/28 Alex Riesen [off-list ref]:
2008/8/28 Alex Riesen [off-list ref]:
quoted
It created endless symlink loops on cygwin, but obviously nowhere else.
Sh@#! Scrap that, there is something else going on in that cygwindows thing...
Well, as usual, simple fix for trivial typo caused by existence of an
idiotic platform.

[PATCH/resend] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:15

The code failed to filter-out git-add properly on platforms were $X is
not empty (ATM there is only one such a platform).

Than it tried to create a hardlink to the file ($execdir/git-add) it just
removed (because git-add is first in the BUILT_INS), so ln failed (but
because stderr was redirected into /dev/null the error was never seen), and
the whole install ended up using "ln -s" instead.

Signed-off-by: Alex Riesen <redacted>
---
2008/8/28 Alex Riesen [off-list ref]:
2008/8/28 Alex Riesen [off-list ref]:
quoted
It created endless symlink loops on cygwin, but obviously nowhere else.
Sh@#! Scrap that, there is something else going on in that cygwindows thing...
Well, as usual, simple fix for a trivial typo caused by existence of an
idiotic platform.

 Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Makefile b/Makefile
index bf400e6..20f028f 100644
--- a/Makefile
+++ b/Makefile
@@ -1379,7 +1379,7 @@ endif
 	{ $(RM) "$$execdir/git-add$X" && \
 		ln git-add$X "$$execdir/git-add$X" 2>/dev/null || \
 		cp git-add$X "$$execdir/git-add$X"; } && \
-	{ $(foreach p,$(filter-out git-add,$(BUILT_INS)), $(RM) "$$execdir/$p" && \
+	{ $(foreach p,$(filter-out git-add$X,$(BUILT_INS)), $(RM) "$$execdir/$p" && \
 		ln "$$execdir/git-add$X" "$$execdir/$p" 2>/dev/null || \
 		ln -s "git-add$X" "$$execdir/$p" 2>/dev/null || \
 		cp "$$execdir/git-add$X" "$$execdir/$p" || exit;) } && \
-- 
1.6.0.1.152.g6969c

Re: [PATCH/resend] Fix use of hardlinks in "make install"

From: Andreas Färber <hidden>
Date: 2016-06-15 22:45:15

Am 30.08.2008 um 02:20 schrieb Alex Riesen:
The code failed to filter-out git-add properly on platforms were $X is
not empty (ATM there is only one such a platform).

Than it tried to create a hardlink to the file ($execdir/git-add) it  
just
removed (because git-add is first in the BUILT_INS), so ln failed (but
because stderr was redirected into /dev/null the error was never  
seen), and
the whole install ended up using "ln -s" instead.

Signed-off-by: Alex Riesen <redacted>
---
quoted hunk
Well, as usual, simple fix for a trivial typo caused by existence of  
an
idiotic platform.

Makefile |    2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Makefile b/Makefile
index bf400e6..20f028f 100644
--- a/Makefile
+++ b/Makefile
@@ -1379,7 +1379,7 @@ endif
	{ $(RM) "$$execdir/git-add$X" && \
		ln git-add$X "$$execdir/git-add$X" 2>/dev/null || \
		cp git-add$X "$$execdir/git-add$X"; } && \
-	{ $(foreach p,$(filter-out git-add,$(BUILT_INS)), $(RM) "$$execdir/ 
$p" && \
+	{ $(foreach p,$(filter-out git-add$X,$(BUILT_INS)), $(RM) "$ 
$execdir/$p" && \
		ln "$$execdir/git-add$X" "$$execdir/$p" 2>/dev/null || \
		ln -s "git-add$X" "$$execdir/$p" 2>/dev/null || \
		cp "$$execdir/git-add$X" "$$execdir/$p" || exit;) } && \
-- 
1.6.0.1.152.g6969c
Your patch seems to work on Haiku, don't have a MinGW setup to test.  
Sorry for the breakage.

Andreas

Re: [PATCH/resend] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:15

2008/8/30 Andreas Färber [off-list ref]:
Am 30.08.2008 um 02:20 schrieb Alex Riesen:
quoted
Well, as usual, simple fix for a trivial typo caused by existence of an
idiotic platform.
Your patch seems to work on Haiku, don't have a MinGW setup to test. Sorry
for the breakage.
What?! Haiku uses stupid file extensions to mark executables?

Re: [PATCH/resend] Fix use of hardlinks in "make install"

From: Andreas Färber <hidden>
Date: 2016-06-15 22:45:15

Am 30.08.2008 um 12:08 schrieb Alex Riesen:
2008/8/30 Andreas Färber [off-list ref]:
quoted
Am 30.08.2008 um 02:20 schrieb Alex Riesen:
quoted
Well, as usual, simple fix for a trivial typo caused by existence  
of an
idiotic platform.
Your patch seems to work on Haiku, don't have a MinGW setup to  
test. Sorry
for the breakage.
What?! Haiku uses stupid file extensions to mark executables?
No, it doesn't. Like BeOS, it uses MIME types stored as BFS attributes  
as well as the standard POSIX executable bit.

Since no one appeared to have replied yet, I confirmed that your  
Windows patch does not break things here and looks reasonable to me as  
co-author of the offending commit.

Andreas

Re: [PATCH/resend] Fix use of hardlinks in "make install"

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:15

2008/8/30 Andreas Färber [off-list ref]:
Since no one appeared to have replied yet, I confirmed that your Windows
patch does not break things here and looks reasonable to me as co-author of
the offending commit.
Ok
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help