Skip to content

Commit

Permalink
fix: dev: still more msvc bat cleanup, update workflow/tox files
Browse files Browse the repository at this point in the history
* setup python and use tox in smoke.yml, add mising exclude in ci.yml
* need to skip missing installer section in build_msvc.bat
* set default parallel make args to 1, higher is iffy in gh ci

Signed-off-by: Stephen L Arnold <[email protected]>
  • Loading branch information
sarnold committed Nov 17, 2022
1 parent 264ee5d commit 0cb270d
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
make
- name: Install and setup msvc prompt
if: runner.os == 'Windows'
if: runner.os == 'Windows' && matrix.compiler == 'cl'
uses: ilammy/msvc-dev-cmd@v1

- name: Build and test windows MSVC
Expand Down
14 changes: 10 additions & 4 deletions .github/workflows/smoke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,18 @@ jobs:
which gcc
if: startsWith(matrix.os, 'win')

- name: build
run: make cccc
- uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Add requirements
run: |
python -m pip install --upgrade pip
pip install tox
- name: run test
- name: Build and test
run: |
make test
tox -e build
windows:
runs-on: windows-2019
Expand Down
8 changes: 5 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ LD ?= g++
DOX = doxygen
CCCC = ./cccc/cccc
CCCOPTS = --lang=c++
CCCCSRC = ./cccc/*.cc ./cccc/*.h
CCCCSRC = ./cccc/*.cc ./cccc/*.cpp ./cccc/*.h
GENSRC = cccc/CLexer.cpp \
cccc/CLexer.h \
cccc/CParser.cpp \
Expand Down Expand Up @@ -71,11 +71,13 @@ docs : Doxyfile.html_cfg $(CCCCSRC) $(DOCS)/.keep_dir
@echo "API docs now in $(DOCS)/html"

clean :
rm -f cccc/cccc_ver.h cccc/*.o cccc/cccc pccts/bin/*
rm -f cccc/*.o cccc/cccc

reallyclean : clean
rm -rf ccccout/* doxygen/html test/.cccc $(TESTOBJ) $(GENSRC)
rm -f pccts/bin/* test/.cccc $(TESTOBJ) $(GENSRC)
rm -rf ccccout/ doxygen/
make -C pccts clean

clobber : reallyclean
rm -f cccc/cccc_ver.h
make -C pccts scrub
8 changes: 2 additions & 6 deletions build_msvc.bat
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,10 @@ call run_test java prn13
call run_test java prn14
call run_test java prn15
call run_test java prn16
echo All tests passed
cd ..
endlocal
if not exist "c:\Program Files\My Inno Setup Extensions\iscc.exe" goto :end

rem The visual C++ addin can't be built using MS Visual C++ Toolkit 2003
rem because it doesn't provide MFC header files and libraries
Expand Down Expand Up @@ -184,10 +186,4 @@ echo Please rerun the script with the argument --clean to build these binaries.
goto :end



:end





6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ deps =

commands =
#{build,clang}: bash release.sh
{build,clang}: bash -c 'make -j4 CXX=$CXX CC=$CC mini'
{build,clang}: bash -c 'make -j4 CCC=$CXX CC=$CC cccc'
{build,clang}: bash -c 'make -j{posargs:1} CXX=$CXX CC=$CC mini'
{build,clang}: bash -c 'make -j{posargs:1} CCC=$CXX CC=$CC cccc'
{build,clang}: bash -c 'make -j1 CCC=$CXX test 2>&1 | tail -n5'
{build,clang}: bash -c './cccc/cccc --version'
lint: bash -c 'cpplint --output=gsed {toxinidir}/cccc/*'
changes: bash -c 'gitchangelog {posargs} > CHANGELOG.md'
clean: bash -c 'make clean'
clean: bash -c 'make {posargs:clean}'

0 comments on commit 0cb270d

Please sign in to comment.