diff --git a/.drone.yml b/.drone.yml index ed12047..be38818 100644 --- a/.drone.yml +++ b/.drone.yml @@ -2,14 +2,15 @@ kind: pipeline type: exec name: macrohard doors - +trigger: + branch: + - main platform: os: windows arch: amd64 clone: disable: true - steps: - name: clone environment: @@ -22,10 +23,6 @@ steps: kind: pipeline type: docker name: unit tests -clone: - recursive: true - submodule_update_remote: true - trigger: branch: - main @@ -38,13 +35,13 @@ steps: - | set -e - git submodule update --init --recursive conan build . \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ -s build_type=Release \ -o enable_static_analysis=False \ -o enable_tests=True \ + -o use_mold=True \ --build=missing for test in $(find ./build -type f -name '*_tests' -executable); do @@ -56,10 +53,6 @@ steps: kind: pipeline type: docker name: valgrind -clone: - recursive: true - submodule_update_remote: true - trigger: branch: - main @@ -72,13 +65,13 @@ steps: - | set -e - git submodule update --init --recursive conan build . \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ -s build_type=Release \ -o enable_static_analysis=False \ -o enable_tests=True \ + -o use_mold=True \ --build=missing find ./build -type f -name "*_tests" -executable | xargs -I {} bash -c 'valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes --verbose --error-exitcode=255 {}' || exit 1 @@ -87,10 +80,6 @@ steps: kind: pipeline type: docker name: leak sanitizer -clone: - recursive: true - submodule_update_remote: true - trigger: branch: - main @@ -103,12 +92,7 @@ steps: - | set -e - git submodule update --init --recursive conan build . \ - -s build_type=Release \ - -s compiler=clang \ - -s compiler.version=20 \ - -s compiler.libcxx=libc++ \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ -c tools.build:cxxflags='["-g", "-fno-omit-frame-pointer", "-nostdinc++", "-isystem", "/libcxx_lsan/include/c++/v1/", "-fsanitize=leak"]' \ @@ -116,8 +100,11 @@ steps: -c tools.build:exelinkflags='["-L/libcxx_lsan/lib", "-Wl,-rpath,/libcxx_lsan/lib", "-lc++", "-lc++abi", "-fsanitize=leak"]' \ -c tools.info.package_id:confs='["tools.build:cxxflags","tools.build:sharedlinkflags","tools.build:exelinkflags"]' \ -c tools.build:compiler_executables='{"c": "clang", "cpp": "clang++"}' \ - -o enable_static_analysis=False \ - -o enable_tests=True \ + -s build_type=Release \ + -s compiler=clang \ + -s compiler.version=20 \ + -s compiler.libcxx=libc++ \ + -o use_mold=True \ --build=missing for test in $(find ./build -type f -name '*_tests' -executable); do echo "Running $test" @@ -128,10 +115,6 @@ steps: kind: pipeline type: docker name: static analysis -clone: - recursive: true - submodule_update_remote: true - trigger: branch: - main @@ -143,24 +126,19 @@ steps: privileged: true commands: - | - git submodule update --init --recursive - conan build . \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ - -s build_type=Debug \ + -s build_type=Release \ -o enable_static_analysis=True \ -o enable_tests=True \ + -o use_mold=True \ --build=missing --- kind: pipeline type: docker name: clang format -clone: - recursive: true - submodule_update_remote: true - trigger: branch: - main diff --git a/tools/ci/images/leak_sanitizer/Dockerfile b/tools/ci/images/leak_sanitizer/Dockerfile index 5fcf25d..5d85e43 100644 --- a/tools/ci/images/leak_sanitizer/Dockerfile +++ b/tools/ci/images/leak_sanitizer/Dockerfile @@ -49,7 +49,7 @@ RUN git clone --depth=1 https://github.com/llvm/llvm-project.git -b llvmorg-20.1 && ninja -C . install-cxx install-cxxabi \ && rm -r /llvm-project/ -RUN git clone 'https://git.light7734.com/light7734/light.git' --recursive \ +RUN git clone 'https://git.light7734.com/light7734/light.git' \ && cd light \ && conan install . \ -c tools.system.package_manager:mode=install \ @@ -63,4 +63,5 @@ RUN git clone 'https://git.light7734.com/light7734/light.git' --recursive \ -s compiler=clang \ -s compiler.version=20 \ -s compiler.libcxx=libc++ \ + -o use_mold=True \ --build=missing diff --git a/tools/ci/images/static_analysis/Dockerfile b/tools/ci/images/static_analysis/Dockerfile index 5651efc..64eea9b 100644 --- a/tools/ci/images/static_analysis/Dockerfile +++ b/tools/ci/images/static_analysis/Dockerfile @@ -31,11 +31,12 @@ RUN clang --version \ && mold --version -RUN git clone 'https://git.light7734.com/light7734/light.git' --recursive \ +RUN git clone 'https://git.light7734.com/light7734/light.git' \ && cd light \ && conan install . \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ - -s build_type=Debug \ + -s build_type=Release \ -o enable_static_analysis=True \ + -o use_mold=True \ --build=missing diff --git a/tools/ci/images/unit_tests/Dockerfile b/tools/ci/images/unit_tests/Dockerfile index 0ab6a45..cb3b6a0 100644 --- a/tools/ci/images/unit_tests/Dockerfile +++ b/tools/ci/images/unit_tests/Dockerfile @@ -16,7 +16,6 @@ RUN apk add --no-cache \ ninja \ mold - RUN pip install --no-cache-dir --break-system-packages conan gitpython \ && conan profile detect @@ -29,15 +28,11 @@ RUN clang --version \ && ninja --version \ && mold --version -RUN git clone 'https://git.light7734.com/light7734/light.git' --recursive \ +RUN git clone 'https://git.light7734.com/light7734/light.git' \ && cd light \ - && conan install . \ - -s build_type=Debug \ - -c tools.system.package_manager:mode=install \ - -c tools.cmake.cmaketoolchain:generator=Ninja \ - --build=missing \ && conan install . \ -s build_type=Release \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ + -o use_mold=True \ --build=missing diff --git a/tools/ci/images/valgrind/Dockerfile b/tools/ci/images/valgrind/Dockerfile index d17736b..eafa3f6 100644 --- a/tools/ci/images/valgrind/Dockerfile +++ b/tools/ci/images/valgrind/Dockerfile @@ -29,15 +29,11 @@ RUN clang --version \ && ninja --version \ && mold --version -RUN git clone 'https://git.light7734.com/light7734/light.git' --recursive \ +RUN git clone 'https://git.light7734.com/light7734/light.git' \ && cd light \ - && conan install . \ - -s build_type=Debug \ - -c tools.system.package_manager:mode=install \ - -c tools.cmake.cmaketoolchain:generator=Ninja \ - --build=missing \ && conan install . \ -s build_type=Release \ -c tools.system.package_manager:mode=install \ -c tools.cmake.cmaketoolchain:generator=Ninja \ + -o use_mold=True \ --build=missing