Index: uspace/app/binutils/intrusive.sh
===================================================================
--- uspace/app/binutils/intrusive.sh	(revision 3e22494fbf44938fa52b47456be801754f7cc071)
+++ uspace/app/binutils/intrusive.sh	(revision 4d4988ed64e25f70ccfc9f9bcd6850a87a04b88b)
@@ -66,4 +66,11 @@
 # became mandatory (although not really needed).
 #
+# Patch 4
+# Whereas most systems maps pid_t to signed type, HelenOS maps it
+# to unsigned type. This causes some type incompatibility in libiberty
+# files related to executing a subprocess. Since both as and ld are
+# not runtime dependent on this functionality, the simplest solution is
+# to patch libiberty to avoid compiler warnings.
+#
 
 case "$1" in
@@ -76,4 +83,5 @@
 		cp -f "$2/ld/configure" "$2/ld/configure.backup"
 		cp -f "$2/libiberty/configure" "$2/libiberty/configure.backup"
+		cp -f "$2/libiberty/pex-common.h" "$2/libiberty/pex-common.h.backup"
 		cp -f "$2/opcodes/configure" "$2/opcodes/configure.backup"
 
@@ -116,4 +124,10 @@
 		> "$2/libiberty/configure"
 
+		# Patch libiberty pex-common.h.
+		cat "$2/libiberty/pex-common.h.backup" | \
+		# See Patch 4.
+		sed 's/pid_t (\*wait)/int (*wait)/g' \
+		> "$2/libiberty/pex-common.h"
+
 		# Patch opcodes configure script.
 		cat "$2/opcodes/configure.backup" | \
@@ -133,4 +147,5 @@
 		mv -f "$2/ld/configure.backup" "$2/ld/configure"
 		mv -f "$2/libiberty/configure.backup" "$2/libiberty/configure"
+		mv -f "$2/libiberty/pex-common.h.backup" "$2/libiberty/pex-common.h"
 		mv -f "$2/opcodes/configure.backup" "$2/opcodes/configure"
 		;;
