diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4aeba94..50fe2cc 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -7,6 +7,8 @@ jobs: steps: - name: Checkout code uses: actions/checkout@v4 + with: + submodules: true - name: Build with meson run: | pip install meson @@ -25,6 +27,8 @@ jobs: steps: - name: Checkout code uses: actions/checkout@v4 + with: + submodules: true - name: Build with meson run: | pip install meson @@ -43,6 +47,8 @@ jobs: steps: - name: Checkout code uses: actions/checkout@v4 + with: + submodules: true - name: Build with meson run: | pip install meson diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..d2939f5 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "plutovg"] + path = plutovg + url = https://github.com/sammycage/plutovg.git diff --git a/CMakeLists.txt b/CMakeLists.txt index faa3e00..19d9c28 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,15 +6,10 @@ set(LUNASVG_VERSION_MICRO 0) project(lunasvg LANGUAGES CXX VERSION ${LUNASVG_VERSION_MAJOR}.${LUNASVG_VERSION_MINOR}.${LUNASVG_VERSION_MICRO}) -include(FetchContent) -FetchContent_Declare(plutovg - GIT_REPOSITORY https://github.com/sammycage/plutovg.git - GIT_TAG main - GIT_SHALLOW ON - FIND_PACKAGE_ARGS 0.0.4 -) - -FetchContent_MakeAvailable(plutovg) +find_package(plutovg 0.0.4 QUIET) +if(NOT plutovg_FOUND) + add_subdirectory(plutovg) +endif() set(lunasvg_sources source/lunasvg.cpp diff --git a/plutovg b/plutovg new file mode 160000 index 0000000..e026d0a --- /dev/null +++ b/plutovg @@ -0,0 +1 @@ +Subproject commit e026d0ac7ba29818cd0a73548b9903eef7da50c1