From a48242913f447b303d55511b95a92042b49ed3fe Mon Sep 17 00:00:00 2001 From: srz_zumix Date: Sun, 13 Sep 2020 11:46:46 +0900 Subject: [PATCH 1/3] fix greeting --- .github/workflows/greetings.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml index 16f573e138..8fef47e11f 100644 --- a/.github/workflows/greetings.yml +++ b/.github/workflows/greetings.yml @@ -1,6 +1,6 @@ name: Greetings -on: [pull_request, issues] +on: [pull_request_target, issues] jobs: greeting: @@ -10,4 +10,4 @@ jobs: with: repo-token: ${{ secrets.GITHUB_TOKEN }} issue-message: 'Hey, thanks for contributing to this by raising an issue' - pr-message: 'Thanks for contributing and submitting your first pull request for this project' \ No newline at end of file + pr-message: 'Thanks for contributing and submitting your first pull request for this project' From 3aade96031e8bce99117a7121c39fab00a1e186f Mon Sep 17 00:00:00 2001 From: srz_zumix Date: Sun, 20 Sep 2020 12:25:12 +0900 Subject: [PATCH 2/3] zapcc with python test --- .github/workflows/main.yml | 9 ++++++++- tools/python/iutest_compile_error_test.py | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 02ad88d6f8..7284d20338 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -67,14 +67,21 @@ jobs: runs-on: ubuntu-18.04 container: docker://srzzumix/zapcc needs: prepare + env: + PYTHON_VERSION: 3.8 steps: - uses: actions/checkout@master + - uses: actions/setup-python@v2 + with: + python-version: ${{ env.PYTHON_VERSION }} + - name: Set Python environment variable + run: echo '::set-env name=LD_LIBRARY_PATH::${{ env.pythonLocation }}/lib' - name: zapcc test run: | make -C test clean make -C test showcxxversion make -C test check_stdlib - make -C test -j1 + make -C test -j1 IUTEST_REQUIRE_PYTHON=1 make -C test test arm-none-eabi: runs-on: ubuntu-18.04 diff --git a/tools/python/iutest_compile_error_test.py b/tools/python/iutest_compile_error_test.py index dd4eaff429..be070c0ef3 100644 --- a/tools/python/iutest_compile_error_test.py +++ b/tools/python/iutest_compile_error_test.py @@ -545,7 +545,7 @@ def parse_output(options): f = options.infile #f = codecs.getreader('utf-8')(options.infile) - if any(options.compiler.find(s) != -1 for s in ('clang', 'clang++')): + if any(options.compiler.find(s) != -1 for s in ('clang', 'clang++', 'zapcc', 'zapcc++')): l = parse_clang(options, f) elif any(options.compiler.find(s) != -1 for s in ('gcc', 'g++')): l = parse_gcc(options, f) From 069013683b2b0bb1d4072d0d24a5faf81a073afc Mon Sep 17 00:00:00 2001 From: srz_zumix Date: Wed, 23 Sep 2020 10:57:32 +0900 Subject: [PATCH 3/3] add make help --- test/GNUmakefile | 39 ++++++++++++++++++++++----------------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/test/GNUmakefile b/test/GNUmakefile index 2345887a48..81fb791c12 100644 --- a/test/GNUmakefile +++ b/test/GNUmakefile @@ -190,12 +190,12 @@ COVERITY_SCAN_BUILD_TARGETS = $(ALLTESTS_TARGET) $(EXTENSIONTESTS_TARGET) $(TARG default : $(TARGETS) -all : clean default test +all : clean default test ## clean and build, run # dir : # @if [ ! -e `dirname $(OUTDIR)` ]; then mkdir -p `dirname $(OUTDIR)`; fi -clean : +clean : ## clean $(RM) $(TARGETS) $(NO_DEFAULT_TARGETS) $(ALL_OBJS) *.o *.stackdump *.core *.exe *.log *.ns.cpp check_stdlib $(RM) -R *.dSYM ifdef OUTPUTXML @@ -205,25 +205,25 @@ ifdef USE_COVERAGE $(RM) *.xml *.gcov *.gcno *.gcda coverage.info endif -clean-xml : +clean-xml : ## clean xml $(RM) *.xml -clean-cov : +clean-cov : ## clean coverages $(RM) *.xml *.gcov *.gcno *.gcda coverage.info -clean-all : clean clean-xml clean-cov +clean-all : clean clean-xml clean-cov ## clean all make -C benchmark clean make -C configcheck clean make -C cpplint clean check : test -run : test -test : $(BUILD_ONLY) $(RUNNER) +run : test ## run tests +test : $(BUILD_ONLY) $(RUNNER) ## run tests -lint : cpplint/Makefile $(IUTEST_HEADERS) $(MAKEFILE) +lint : cpplint/Makefile $(IUTEST_HEADERS) $(MAKEFILE) ## lint make -C cpplint -showcxxversion: +showcxxversion: ## show compiler version $(CXX) --version ifeq ($(CXX_NAME),g++) $(CXX) -dumpversion @@ -238,10 +238,10 @@ ifdef CXX_NAME @echo ${CXX_NAME}-$(CXX_MAJOR).$(CXX_MINOR) endif -showcxxmacros: +showcxxmacros: ## show compiler predefined macros $(CXX) $(STDFLAG) -dM -E -x c++ - < /dev/null -showcxxflags: +showcxxflags: ## show cxxflags @echo $(CXXFLAGS) %_build: $(OUTDIR)/% @@ -266,11 +266,10 @@ endif run_% : %_run @echo $< > /dev/null -prepare: $(NAMESPACETESTS_TEST_SRCS) +prepare: $(NAMESPACETESTS_TEST_SRCS) ## test code prepare @if [[ ! -d "${OUTDIR}" ]]; then mkdir $(OUTDIR); fi -# gtest version test -gtest-version: clean gtest_version_tests_run +gtest-version: clean gtest_version_tests_run ## gtest version test coverity_scan: $(COVERITY_SCAN_BUILD_TARGETS) @@ -281,10 +280,10 @@ coverity_scan: $(COVERITY_SCAN_BUILD_TARGETS) FUSED_PY= ../tools/fused/*.py -fused: $(IUTEST_HEADERS) $(MAKEFILE) ../tools/fused/Makefile $(FUSED_PY) +fused: $(IUTEST_HEADERS) $(MAKEFILE) ../tools/fused/Makefile $(FUSED_PY) ## create fused-src make -C ../tools/fused -fused_min: $(IUTEST_HEADERS) $(MAKEFILE) ../tools/fused/Makefile $(FUSED_PY) +fused_min: $(IUTEST_HEADERS) $(MAKEFILE) ../tools/fused/Makefile $(FUSED_PY) ## create minimize fused-src make -C ../tools/fused min # @@ -485,7 +484,7 @@ check_incg: $(IUTEST_INCLUDE_GUARD_CHECK) # cppcheck # -cppcheck: +cppcheck: ## cppcheck make -C cppcheck # @@ -494,3 +493,9 @@ cppcheck: report: CXX_NAME=${CXX_NAME} CXX_VERSION=${CXX_VERSION} STDFLAG=${STDFLAG} ./../.ci/report-basic-test.sh || true + +# +# help +# +help: ## show help + @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sed -e 's/^GNUmakefile://' | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}'