diff options
author | thead_admin <occ_thead@service.alibaba.com> | 2022-09-13 11:04:33 +0800 |
---|---|---|
committer | thead_admin <occ_thead@service.alibaba.com> | 2022-09-13 11:04:33 +0800 |
commit | 43db9e00d5837c100c0b2fbbee64a08ab807d1e0 (patch) | |
tree | b40c0eed02935b6682e8c5c975e3016b6b2f55fe /scripts/gcc-stack-usage.sh |
Linux_SDK_V0.9.5Linux_SDK_V0.9.5
Diffstat (limited to 'scripts/gcc-stack-usage.sh')
-rwxr-xr-x | scripts/gcc-stack-usage.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/gcc-stack-usage.sh b/scripts/gcc-stack-usage.sh new file mode 100755 index 00000000..3db32e35 --- /dev/null +++ b/scripts/gcc-stack-usage.sh @@ -0,0 +1,17 @@ +#!/bin/sh +# SPDX-License-Identifier: GPL-2.0+ +# Test for gcc '-fstack-usage' support +# Copyright (C) 2013, Masahiro Yamada <yamada.m@jp.panasonic.com> +# + +TMP="$$" + +cat <<END | $@ -Werror -fstack-usage -x c - -c -o $TMP >/dev/null 2>&1 \ + && echo "y" +int main(void) +{ + return 0; +} +END + +rm -f $TMP $TMP.su |