Skip to content

Commit

Permalink
Merge pull request #62 from pzaino/develop
Browse files Browse the repository at this point in the history
Cumulative merge of improvements from develop to main
  • Loading branch information
pzaino authored Jan 15, 2022
2 parents a250202 + a563a06 commit 2c6b5b1
Show file tree
Hide file tree
Showing 9 changed files with 870 additions and 675 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ tests/bin/
**/*.backup
/tests/bin/.*
.fuse_*
cppcheck_report.txt
.PVS-Studio/*

## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
Expand Down
9 changes: 8 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
],
"c-cpp-flylint.clang.language": "C",
"c-cpp-flylint.cppcheck.extraArgs": [
"--std c99",
"--bug-hunting",
"--enable=all",
"--suppress=missingIncludeSystem"
Expand Down Expand Up @@ -46,5 +47,11 @@
"editor.detectIndentation": true,
"files.trimTrailingWhitespace": true,
"C_Cpp.clang_format_fallbackStyle": "none",
"editor.tabSize": 8
"editor.tabSize": 8,
"editor.cursorStyle": "block",
"C_Cpp.default.systemIncludePath": [
"/usr/include/",
"/usr/local/include/",
"/usr/lib64/gcc/x86_64-suse-linux/11/include"
]
}
16 changes: 16 additions & 0 deletions scripts/cpp_check.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/bash

#################################################################
#
# Name: cpp_check.sh
Expand Down Expand Up @@ -102,13 +103,27 @@ grep_cmd="$($cpath/which grep)"
GCC_VER="$(${gcc_cmd} -v 2>&1 | ${grep_cmd} ${gpargs} 'gcc version \K[0-9]+\.[0-9]+\.[0-9]+')"
GCC_TARGET="$(${gcc_cmd} -v 2>&1 | ${grep_cmd} ${gpargs} 'Target: \K.*' )"
GCC_PATH="/usr/lib/gcc/${GCC_TARGET}/${GCC_VER}/include/"
if [ ! -d $GCC_PATH ];
then
if [ "$Arch" == "x86_64" ];
then
GCC_PATH="/usr/lib64/gcc/${GCC_TARGET}/${GCC_VER}/include/"
if [ ! -d $GCC_PATH ];
then
GCC_PATH="/usr/lib64/gcc/${GCC_TARGET}"
mjr="$(cut -d . -f 1 <<< $GCC_VER)"
GCC_PATH="${GCC_PATH}/${mjr}"
fi
fi
fi

###############
# Run CPPCheck:
###############

${cppcheck_cmd} ${start_path}/src/*.c --bug-hunting \
--enable=all \
--output-file=./cppcheck_report.txt \
--platform=${Platform} \
--std=c99 \
--force \
Expand All @@ -123,3 +138,4 @@ ${cppcheck_cmd} ${start_path}/src/*.c --bug-hunting \
--suppress=missingIncludeSystem -v 2>&1

exit $?

2 changes: 2 additions & 0 deletions scripts/mem_check.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/bash

#################################################################
#
# Name: mem_check.sh
Expand Down Expand Up @@ -104,3 +105,4 @@ ${valgrind_cmd} --leak-check=full \
${extra_opts} ${code_to_check} ${out_route}

exit $?

2 changes: 2 additions & 0 deletions scripts/ux_set_extension
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/bash

#################################################################
#
# Name: ux_set_extension
Expand Down Expand Up @@ -100,3 +101,4 @@ then
fi
echo ""
exit 0

Loading

0 comments on commit 2c6b5b1

Please sign in to comment.