Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve ReadMe #37

Merged
merged 24 commits into from
Oct 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG VARIANT=22.10
ARG VARIANT=22.04
FROM ubuntu:${VARIANT}

# Install necessary dependencies
Expand All @@ -15,6 +15,8 @@ RUN apt-get update &&\
wget \
git \
gcc \
g++-9 \
clang-14 \
curl \
gnupg \
zlib1g-dev \
Expand All @@ -28,6 +30,7 @@ RUN apt-get update &&\
clang-format \
python3-pip \
doxygen \
graphviz \
net-tools \
iproute2 \
locales-all &&\
Expand All @@ -50,7 +53,7 @@ ARG DLT_MAJOR_VERSION="2"
ARG DLT_MINOR_VERSION="18"
ARG DLT_PATCH_VERSION="8"

RUN wget "https://github.com/COVESA/dlt-daemon/archive/refs/tags/v2.18.8.tar.gz" && \
RUN wget "https://github.com/COVESA/dlt-daemon/archive/refs/tags/v${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}.tar.gz" && \
mkdir /opt/dlt-daemon && \
tar -xvf v${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}.tar.gz -C /opt/dlt-daemon && \
rm -rf v${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}.tar.gz && \
Expand Down
9 changes: 5 additions & 4 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@
"austin.code-gnu-global",
"BazelBuild.vscode-bazel",
"piotrkosek.vscode-gtest-test-adapter-with-code-lens",
"monokai.theme-monokai-pro-vscode"
],
"postCreateCommand":
"bash ${containerWorkspaceFolder}/.devcontainer/post_start.sh"
"cfcluan.project-scopes",
"GitHub.vscode-pull-request-github",
"matepek.vscode-catch2-test-adapter",
"github.vscode-github-actions"
]
}
19 changes: 11 additions & 8 deletions .github/setup.sh
Original file line number Diff line number Diff line change
@@ -1,28 +1,31 @@
#!/bin/bash
apt-get update -qq

# install boost
# Install compilers
apt-get install clang-14
apt-get install g++-9

# Install Boost library
BOOST_MAJOR_VERSION="1"
BOOST_MINOR_VERSION="79"

wget "https://boostorg.jfrog.io/artifactory/main/release/"${BOOST_MAJOR_VERSION}"."${BOOST_MINOR_VERSION}".0/source/boost_"${BOOST_MAJOR_VERSION}"_"${BOOST_MINOR_VERSION}"_0.tar.gz"

wget "https://boostorg.jfrog.io/artifactory/main/release/${BOOST_MAJOR_VERSION}.${BOOST_MINOR_VERSION}.0/source/boost_${BOOST_MAJOR_VERSION}_${BOOST_MINOR_VERSION}_0.tar.gz"
mkdir boost
tar -zxvf boost_${BOOST_MAJOR_VERSION}_${BOOST_MINOR_VERSION}_0.tar.gz -C boost
cd boost/boost_${BOOST_MAJOR_VERSION}_${BOOST_MINOR_VERSION}_0
cd boost/boost_${BOOST_MAJOR_VERSION}_${BOOST_MINOR_VERSION}_0 || exit
./bootstrap.sh
./b2 variant=release install
cd ../../

# install dlt daemon
# Install DLT daemon (needed for logging)
DLT_MAJOR_VERSION="2"
DLT_MINOR_VERSION="18"
DLT_PATCH_VERSION="8"
wget "https://github.com/COVESA/dlt-daemon/archive/refs/tags/v2.18.8.tar.gz"
mkdir dlt-daemon
wget "https://github.com/COVESA/dlt-daemon/archive/refs/tags/v${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}.tar.gz"
mkdir dlt-daemon
tar -xvf v${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}.tar.gz -C dlt-daemon
mkdir -p dlt-daemon/dlt-daemon-${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}/build
cd dlt-daemon/dlt-daemon-${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION}
cd dlt-daemon/dlt-daemon-${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_VERSION} || exit
cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release
cmake --install build --config Release
25 changes: 25 additions & 0 deletions .github/workflows/clang14.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Clang14

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Debug

jobs:
Build-clang-14:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo sh .github/setup.sh
- name: Configure CMake
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DBUILD_WITH_DLT:BOOL=ON -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_EXAMPLES:BOOL=ON -DCMAKE_TOOLCHAIN_FILE=toolchains/linux_clang_14.cmake

- name: Build
# Build your program with the given configuration
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
40 changes: 0 additions & 40 deletions .github/workflows/cmake.yml

This file was deleted.

74 changes: 0 additions & 74 deletions .github/workflows/codeql.yml

This file was deleted.

34 changes: 34 additions & 0 deletions .github/workflows/doxygen-gh-pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Doxygen Action

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Debug

jobs:
Doxygen:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Doxygen
run: |
sudo apt-get install doxygen
sudo apt install graphviz

- name: Generate documentation
run: |
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DBUILD_DIAG_CLIENT:BOOL=OFF -DBUILD_DOXYGEN:BOOL=ON -DCMAKE_TOOLCHAIN_FILE=toolchains/linux_gcc_9.cmake
cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}

- name: Publish
uses: peaceiris/actions-gh-pages@v3
if: github.ref == 'refs/heads/main'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ${{github.workspace}}/build/docs/html

25 changes: 25 additions & 0 deletions .github/workflows/gcc9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Gcc9

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Debug

jobs:
Build-gcc-9:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo sh .github/setup.sh
- name: Configure CMake
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DBUILD_WITH_DLT:BOOL=ON -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_EXAMPLES:BOOL=ON -DCMAKE_TOOLCHAIN_FILE=toolchains/linux_gcc_9.cmake

- name: Build
# Build your program with the given configuration
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
41 changes: 41 additions & 0 deletions .github/workflows/gcc9_with_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Gcc9_Gtest

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Debug
COMPILER_NAME: gcc9
jobs:
Gtest-gcc-9:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo sh .github/setup.sh

- name: Configure CMake
run: cmake -B ${{github.workspace}}/build/${{env.COMPILER_NAME}} -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DBUILD_WITH_DLT:BOOL=ON -DBUILD_WITH_TEST:BOOL=ON -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_EXAMPLES:BOOL=ON -DCMAKE_TOOLCHAIN_FILE=toolchains/linux_gcc_9.cmake

- name: Build
run: cmake --build ${{github.workspace}}/build/${{env.COMPILER_NAME}} --config ${{env.BUILD_TYPE}}

- name: Network Setup
run: sudo sh tools/setup_network_interface.sh

- name: Test
working-directory: ${{github.workspace}}/build/${{env.COMPILER_NAME}}/test
run: |
export DLT_LOCAL_PRINT_MODE=FORCE_ON
export DLT_INITIAL_LOG_LEVEL="::6"
./gtest-diag-client-lib --gtest_output="xml:test-report.xml"

- name: Archive test results
uses: actions/upload-artifact@v3
with:
name: test-run-report
path: ${{github.workspace}}/build/${{env.COMPILER_NAME}}/test/test-report.xml
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@
# Others
.idea
cmake-build*
build*
build/*
Loading
Loading