patches/glibc/2.7/240-sh-lowlevellock-asm.patch
author Anthony Foiani <anthony.foiani@gmail.com>
Thu Apr 26 19:55:59 2012 -0600 (2012-04-26)
changeset 2939 58974be61289
permissions -rw-r--r--
Allow multi-word "install" command.

Autoconf can determine that the correct install command includes flags,
e.g., "/usr/bin/install -c". When using this as a command, we can't
enclose the value in double-quotes, as that makes some shells use the
whole expression as a filename:

# this is the value returned by autoconf and stored in CT_install
$ ins="/usr/bin/install -c"

# if we call it with quotes, the command is not found
$ "${ins}"
bash: /usr/bin/install -c: No such file or directory

# removing the quotes lets it work as expected
$ ${ins}
/usr/bin/install: missing file operand
Try `/usr/bin/install --help' for more information.

Signed-Off-By: Anthony Foiani <anthony.foiani@gmail.com>
yann@962
     1
--- glibc-2.7/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S.orig	2007-08-03 16:44:15.000000000 +0100
yann@962
     2
+++ glibc-2.7/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S	2008-08-19 21:08:19.000000000 +0100
yann@962
     3
@@ -76,7 +76,7 @@
yann@962
     4
 	add	tmp2, tmp 	; \
yann@962
     5
 	mov.l	@tmp, tmp2	; \
yann@962
     6
 	bra	98f		; \
yann@962
     7
-	 mov	#FUTEX_PRIVATE_FLAG, tmp
yann@962
     8
+	 mov	#FUTEX_PRIVATE_FLAG, tmp ; \
yann@962
     9
 99:	.word	PRIVATE_FUTEX - TLS_PRE_TCB_SIZE ; \
yann@962
    10
 98:	extu.b	tmp, tmp	; \
yann@962
    11
 	xor	tmp, reg	; \
yann@962
    12
@@ -88,7 +88,7 @@
yann@962
    13
 	add	tmp2, tmp 	; \
yann@962
    14
 	mov.l	@tmp, tmp2	; \
yann@962
    15
 	bra	98f		; \
yann@962
    16
-	 mov	#FUTEX_PRIVATE_FLAG, tmp
yann@962
    17
+	 mov	#FUTEX_PRIVATE_FLAG, tmp ; \
yann@962
    18
 99:	.word	PRIVATE_FUTEX - TLS_PRE_TCB_SIZE ; \
yann@962
    19
 98:	extu.b	tmp, tmp	; \
yann@962
    20
 	xor	tmp, reg	; \
yann@962
    21
@@ -96,13 +96,13 @@
yann@962
    22
 	mov	#FUTEX_WAIT, tmp ; \
yann@962
    23
 	or	tmp, reg
yann@962
    24
 # endif
yann@962
    25
-# define LOAD_FUTEX_WAKE(reg,tmp) \
yann@962
    26
+# define LOAD_FUTEX_WAKE(reg,tmp,tmp2) \
yann@962
    27
 	stc	gbr, tmp	; \
yann@962
    28
 	mov.w	99f, tmp2	; \
yann@962
    29
 	add	tmp2, tmp 	; \
yann@962
    30
 	mov.l	@tmp, tmp2	; \
yann@962
    31
 	bra	98f		; \
yann@962
    32
-	 mov	#FUTEX_PRIVATE_FLAG, tmp
yann@962
    33
+	 mov	#FUTEX_PRIVATE_FLAG, tmp ; \
yann@962
    34
 99:	.word	PRIVATE_FUTEX - TLS_PRE_TCB_SIZE ; \
yann@962
    35
 98:	extu.b	tmp, tmp	; \
yann@962
    36
 	xor	tmp, reg	; \
yann@962
    37
--- glibc-2.7/nptl/sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S.orig	2007-08-03 16:44:57.000000000 +0100
yann@962
    38
+++ glibc-2.7/nptl/sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S	2008-08-19 21:08:22.000000000 +0100
yann@962
    39
@@ -42,7 +42,7 @@
yann@962
    40
 	add	tmp2, tmp 	; \
yann@962
    41
 	mov.l	@tmp, tmp2	; \
yann@962
    42
 	bra	98f		; \
yann@962
    43
-	 mov	#FUTEX_PRIVATE_FLAG, tmp
yann@962
    44
+	 mov	#FUTEX_PRIVATE_FLAG, tmp ; \
yann@962
    45
 99:	.word	PRIVATE_FUTEX - TLS_PRE_TCB_SIZE ; \
yann@962
    46
 98:	extu.b	tmp, tmp	; \
yann@962
    47
 	xor	tmp, reg	; \
yann@962
    48
@@ -54,7 +54,7 @@
yann@962
    49
 	add	tmp2, tmp 	; \
yann@962
    50
 	mov.l	@tmp, tmp2	; \
yann@962
    51
 	bra	98f		; \
yann@962
    52
-	 mov	#FUTEX_PRIVATE_FLAG, tmp
yann@962
    53
+	 mov	#FUTEX_PRIVATE_FLAG, tmp ; \
yann@962
    54
 99:	.word	PRIVATE_FUTEX - TLS_PRE_TCB_SIZE ; \
yann@962
    55
 98:	extu.b	tmp, tmp	; \
yann@962
    56
 	xor	tmp, reg	; \