Skip to content

Commit

Permalink
Merge pull request #371 from ut-issl/develop
Browse files Browse the repository at this point in the history
Update main (v3.6.0) on 2022-06-29
  • Loading branch information
meltingrabbit authored Jun 29, 2022
2 parents 76c7f78 + 577e7cd commit 954ea0d
Show file tree
Hide file tree
Showing 389 changed files with 20,969 additions and 17,908 deletions.
1 change: 1 addition & 0 deletions .github/workflows/.python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.10
2 changes: 1 addition & 1 deletion .github/workflows/actionlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
actionlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: reviewdog/action-actionlint@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
18 changes: 10 additions & 8 deletions .github/workflows/build_as_c89.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,11 @@ jobs:
matrix: ${{ fromJson(needs.gen_build_matrix.outputs.matrix) }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: install deps
run: |
sudo apt-get update
sudo apt-get install -y libc6-dev-i386 nkf
# - name: convert Shift-JIS to UTF-8
Expand All @@ -79,23 +80,24 @@ jobs:
echo "::set-output name=WEXTRA::${WEXTRA}"
- name: cmake
working-directory: ./Examples/minimum_user_for_s2e
working-directory: ./Examples/minimum_user
env:
CC: ${{ matrix.compiler }}
run: |
mkdir build
cd build
cmake --version
cmake .. -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DUSE_SILS_MOCKUP=ON -DADD_WERROR_FLAGS=${{ steps.compile_flags.outputs.WERROR }} -DADD_WEXTRA_FLAGS=${{ steps.compile_flags.outputs.WEXTRA }}
- name: build
id: build
continue-on-error: ${{ matrix.compiler == 'clang' }}
working-directory: ./Examples/minimum_user_for_s2e/build
working-directory: ./Examples/minimum_user/build
run: cmake --build .

- name: run
if: steps.build.outcome == 'success'
working-directory: ./Examples/minimum_user_for_s2e/build
working-directory: ./Examples/minimum_user/build
shell: bash
run: timeout 3 ./C2A || exit 0

Expand All @@ -110,22 +112,22 @@ jobs:

- name: clang-tidy
if: matrix.compiler == 'clang'
working-directory: ./Examples/minimum_user_for_s2e/build
working-directory: ./Examples/minimum_user/build
run: |
run-clang-tidy-11 \
| sed 's/\/home\/runner\/work\/c2a-core\/c2a-core\///g' \
| sed 's/Examples\/minimum_user_for_s2e\/src\/src_core\///g' \
| sed 's/Examples\/minimum_user\/src\/src_core\///g' \
> clang_tidy.log
- name: clang-tidy result
if: matrix.compiler == 'clang'
working-directory: ./Examples/minimum_user_for_s2e/build
working-directory: ./Examples/minimum_user/build
run: cat clang_tidy.log

- name: remove duplicate error
if: matrix.compiler == 'clang'
run: |
python Script/CI/remove_duplicate_error.py ./Examples/minimum_user_for_s2e/build/clang_tidy.log "clang-tidy" | tee clang_tidy.log
python Script/CI/remove_duplicate_error.py ./Examples/minimum_user/build/clang_tidy.log "clang-tidy" | tee clang_tidy.log
- name: reviewdog clang-tidy (github-pr-review)
if: matrix.compiler == 'clang' && matrix.warning == 'Werror'
Expand Down
14 changes: 8 additions & 6 deletions .github/workflows/build_as_cxx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,39 +11,41 @@ jobs:
build_minimum_user_as_cxx:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: setup
shell: cmd
run: ./setup.bat

- name: cmake
working-directory: ./Examples/minimum_user_for_s2e
working-directory: ./Examples/minimum_user
run: |
mkdir build
cd build
cmake --version
cmake .. -A Win32
- name: build
working-directory: ./Examples/minimum_user_for_s2e/build
working-directory: ./Examples/minimum_user/build
run: cmake --build .

build_s2e_mockup:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: setup
shell: cmd
run: ./setup.bat

- name: cmake
working-directory: ./Examples/minimum_user_for_s2e/src/s2e_mockup
working-directory: ./Examples/minimum_user/src/s2e_mockup
run: |
mkdir build
cd build
cmake --version
cmake .. -A Win32
- name: build
working-directory: ./Examples/minimum_user_for_s2e/src/s2e_mockup/build
working-directory: ./Examples/minimum_user/src/s2e_mockup/build
run: cmake --build .
93 changes: 93 additions & 0 deletions .github/workflows/build_with_s2e.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
name: build with S2E

on:
push:
branches:
- main
- develop
pull_request:

env:
S2E_CORE_VERSION: v5.0.0

jobs:
build_s2e_win:
name: Build on Windows VS2022
runs-on: windows-2022

steps:
- name: checkout S2E core
uses: actions/checkout@v3
with:
path: s2e-core
repository: ut-issl/s2e-core
ref: '${{ env.S2E_CORE_VERSION }}'
fetch-depth: 1

- name: checkout S2E user
uses: actions/checkout@v3
with:
path: s2e-user
repository: ut-issl/s2e-user-for-c2a-core
fetch-depth: 1

- name: checkout C2A user
uses: actions/checkout@v3
with:
path: c2a-core

- name: setup C2A
shell: cmd
working-directory: c2a-core
run: setup.bat

- name: Configure build for x86
uses: ilammy/msvc-dev-cmd@v1
with:
arch: amd64_x86

- name: cache extlib
id: cache-extlib
uses: actions/cache@v3
with:
key: extlib-${{ runner.os }}-${{ hashFiles('./s2e-core/ExtLibraries/**') }}
path: ./s2e-core/ExtLibraries

- name: build extlib
if: steps.cache-extlib.outputs.cache-hit != 'true'
shell: powershell
working-directory: ./s2e-core/ExtLibraries
run: |
$extlib_dir=(pwd).Path
cmake -G "Visual Studio 17 2022" -A Win32 -DCMAKE_CONFIGURATION_TYPES:STRING="Debug" -DEXT_LIB_DIR="${extlib_dir}"
cmake --build . --clean-first
- name: install extlib
if: steps.cache-extlib.outputs.cache-hit != 'true'
shell: powershell
working-directory: ./s2e-core/ExtLibraries
run: |
cmake --install .
- name: check extlib
shell: powershell
working-directory: ./s2e-core/ExtLibraries
run: |
ls cspice
ls cspice/cspice_msvs/lib
ls cspice/include
ls cspice/generic_kernels
ls nrlmsise00
ls nrlmsise00/table
ls nrlmsise00/lib
ls nrlmsise00/lib/libnrlmsise00.lib
ls nrlmsise00/src
- name: build
working-directory: ./s2e-user
shell: cmd
run: |
cl.exe
cmake --version
cmake -G "Visual Studio 17 2022" -A Win32 -DCMAKE_CONFIGURATION_TYPES:STRING="Debug" -DEXT_LIB_DIR=../s2e-core/ExtLibraries -DFLIGHT_SW_DIR=../c2a-core -DC2A_NAME=Examples/minimum_user -DUSE_C2A=ON
cmake --build . --clean-first
10 changes: 5 additions & 5 deletions .github/workflows/check_coding_rule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
check_coding_rule:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.x'
python-version-file: .github/workflows/.python-version
architecture: 'x64'
- name: setup
shell: bash
Expand All @@ -23,7 +23,7 @@ jobs:
id: check
shell: bash -e {0}
continue-on-error: true
working-directory: ./Examples/minimum_user_for_s2e/src
working-directory: ./Examples/minimum_user/src
run: |
python ./src_core/Script/CI/check_coding_rule.py ./src_core/Script/CI/check_coding_rule.json | tee /tmp/coding-rule.log
status="${PIPESTATUS[0]}"
Expand All @@ -38,7 +38,7 @@ jobs:
run: |
sed 's/.\/src_core\///g' < /tmp/coding-rule.log \
| > ./coding-rule.log \
sed 's/.\/src_user/Examples\/minimum_user_for_s2e\/src\/src_user/g'
sed 's/.\/src_user/Examples\/minimum_user\/src\/src_user/g'
cat ./coding-rule.log
- name: reviewdog(github-pr-review)
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/check_encoding.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
check_encoding:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.x'
python-version-file: .github/workflows/.python-version
architecture: 'x64'
- run: pip install chardet
- name: check_encoding
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Run Labeler
uses: crazy-max/ghaction-github-labeler@v3
uses: crazy-max/ghaction-github-labeler@v4
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
yaml-file: .github/labels.yml
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/python_check_format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ jobs:
black_format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

# - name: check python format with black
# uses: psf/black@stable

- uses: reviewdog/action-black@v2
- uses: reviewdog/action-black@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# reporter: github-pr-review # TODO: いい感じになったら直す
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/python_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ jobs:
flake8_lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Set up python environment
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "3.8"
python-version-file: .github/workflows/.python-version

- name: flake8 Lint
uses: reviewdog/action-flake8@v3
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/validate-renovate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: validate / renovate.json

on:
pull_request:
paths:
- 'renovate.json'
- '.github/workflows/validate-renovate.yml'

jobs:
validate-renovate:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3

- name: install
run: |
npm install -g renovate
- name: validate
run: |
renovate-config-validator
6 changes: 3 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ dkms.conf
._*

# for c2a user sample
Examples/minimum_user_for_s2e/src/src_core
Examples/minimum_user_for_s2e/build
Examples/minimum_user_for_s2e/src/src_user/Test/authorization.json
Examples/minimum_user/src/src_core
Examples/minimum_user/build
Examples/minimum_user/src/src_user/Test/authorization.json
*.pyc
15 changes: 15 additions & 0 deletions Applications/TestApp/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
cmake_minimum_required(VERSION 3.13)

project(C2A_CORE_TEST_APPS)

set(C2A_SRCS
test_ccp_util.c
)

if(BUILD_C2A_AS_CXX)
set_source_files_properties(${C2A_SRCS} PROPERTIES LANGUAGE CXX) # C++
endif()

add_library(${PROJECT_NAME} OBJECT ${C2A_SRCS})

include(${C2A_CORE_DIR}/common.cmake)
Loading

0 comments on commit 954ea0d

Please sign in to comment.