application run workflow from timer #28
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Test Proxy Build Dependencies | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| test-build: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Install system dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| build-essential \ | |
| libstdc++-12-dev \ | |
| cppcheck \ | |
| checkinstall \ | |
| clang-15 \ | |
| clang++-15 \ | |
| wget \ | |
| git | |
| # Clean apt cache | |
| sudo apt-get clean | |
| sudo rm -rf /var/lib/apt/lists/* | |
| # Clean apt cache | |
| sudo apt-get clean | |
| sudo rm -rf /var/lib/apt/lists/* | |
| - name: Install CMake 3.26.4 | |
| run: | | |
| wget https://github.com/Kitware/CMake/releases/download/v3.26.4/cmake-3.26.4-linux-x86_64.sh | |
| sudo sh cmake-3.26.4-linux-x86_64.sh --skip-license --prefix=/usr/local | |
| cmake --version | |
| - name: Cache OpenSSL | |
| id: cache-openssl | |
| uses: actions/cache@v3 | |
| with: | |
| path: /usr/local/ssl | |
| key: openssl-1.1.1-ubuntu-22.04 | |
| - name: Install OpenSSL 1.1.1 | |
| if: steps.cache-openssl.outputs.cache-hit != 'true' | |
| run: | | |
| git clone --branch OpenSSL_1_1_1-stable --depth 1 https://github.com/openssl/openssl.git | |
| cd openssl | |
| ./config --prefix=/usr/local/ssl --openssldir=/usr/local/ssl | |
| make -j$(nproc) | |
| sudo make install | |
| sudo ldconfig | |
| - name: Cache Boost | |
| id: cache-boost | |
| uses: actions/cache@v3 | |
| with: | |
| path: | | |
| /usr/local/include/boost | |
| /usr/local/lib/libboost_* | |
| key: boost-1.86.0-ubuntu-22.04-static | |
| - name: Install Boost 1.86.0 | |
| if: steps.cache-boost.outputs.cache-hit != 'true' | |
| run: | | |
| # Download Boost 1.86.0 | |
| wget --no-check-certificate https://archives.boost.io/release/1.86.0/source/boost_1_86_0.tar.gz | |
| tar -xzf boost_1_86_0.tar.gz | |
| cd boost_1_86_0 | |
| # Bootstrap Boost | |
| ./bootstrap.sh --prefix=/usr/local | |
| # Build and install libraries | |
| ./b2 release -j$(nproc) | |
| sudo ./b2 install -j$(nproc) | |
| # CLEAN UP BOOST FILES | |
| cd .. | |
| echo "🧹 Cleaning up Boost installation files..." | |
| sudo rm -rf boost_1_86_0 boost_1_86_0.tar.gz | |
| echo "✅ Boost 1.86.0 installed successfully" | |
| - name: Verify all dependencies | |
| run: | | |
| echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" | |
| echo "🔍 DEPENDENCY VERIFICATION" | |
| echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" | |
| # CMake version | |
| echo "✓ CMake: $(cmake --version | head -n1)" | |
| # Boost version | |
| if [ -f "/usr/local/include/boost/version.hpp" ]; then | |
| BOOST_VERSION=$(grep "#define BOOST_LIB_VERSION" /usr/local/include/boost/version.hpp | awk '{print $3}' | tr -d '"') | |
| echo "✓ Boost: ${BOOST_VERSION}" | |
| else | |
| echo "✗ Boost not found" | |
| exit 1 | |
| fi | |
| # Clang version | |
| echo "✓ Clang: $(clang-15 --version | head -n1)" | |
| echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" | |
| echo "✅ All dependencies verified successfully" | |
| echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" | |
| - name: Configure CMake | |
| working-directory: ./proxy | |
| run: | | |
| mkdir -p build | |
| cd build | |
| cmake .. \ | |
| -DCMAKE_BUILD_TYPE=Release \ | |
| -DENABLE_LTO=OFF \ | |
| -DENABLE_NATIVE=OFF | |
| - name: Build project | |
| working-directory: ./proxy/build | |
| run: | | |
| cmake --build . \ | |
| --config Release \ | |
| -j$(nproc) | |
| - name: Verify build | |
| working-directory: ./proxy | |
| run: | | |
| ls -lh bin/ | |
| file bin/proxy || true | |
| file bin/proxy_test || true |