ramips: add switch port index for I-O DATA WN-GX300GR
[openwrt/openwrt.git] / scripts / strip-kmod.sh
index 13e6b58007f92fa870afcb58da9ac88df7957c19..313015b909af6957d8b24f36b489c5b1c7e11974 100755 (executable)
@@ -18,13 +18,18 @@ else
        ARGS="-x -G __this_module --strip-unneeded"
 fi
 
+if [ -z "$KEEP_BUILD_ID" ]; then
+    ARGS="$ARGS -R .note.gnu.build-id"
+fi
+
 ${CROSS}objcopy \
        -R .comment \
        -R .pdr \
        -R .mdebug.abi32 \
-       -R .note.gnu.build-id \
        -R .gnu.attributes \
        -R .reginfo \
+       -R .MIPS.abiflags \
+       -R .note.GNU-stack \
        $ARGS \
        "$MODULE" "$MODULE.tmp"