summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripts/build/internals.sh1
-rw-r--r--scripts/wrapper.c3
2 files changed, 4 insertions, 0 deletions
diff --git a/scripts/build/internals.sh b/scripts/build/internals.sh
index 7837f00..093636a 100644
--- a/scripts/build/internals.sh
+++ b/scripts/build/internals.sh
@@ -61,6 +61,7 @@ do_finish() {
CT_DoExecLog "${HOST_CC}" \
-Wall -Wextra -Wunreachable-code -Werror \
-O3 -static ${_t} \
+ "${CT_LIB_DIR}/scripts/wrapper.c" \
-o ".${CT_TARGET}-wrapper"
;;
esac
diff --git a/scripts/wrapper.c b/scripts/wrapper.c
index dbbcdd9..3d815b4 100644
--- a/scripts/wrapper.c
+++ b/scripts/wrapper.c
@@ -27,6 +27,9 @@ int main( int argc,
size_t len;
int execve_ret;
+ /* Avoid the warning-treated-as-error: "error: unused parameter 'argc'" */
+ len = argc;
+
/* In case we have a relative or absolute pathname (ie. contains a slash),
* then realpath wll work. But if the tool was found in the PATH, realpath
* won't work, and we'll have to search ourselves.