diff --git a/.github/workflows/build-windows-msvc.yml b/.github/workflows/build-windows-msvc.yml new file mode 100644 index 000000000..1f3fc2c97 --- /dev/null +++ b/.github/workflows/build-windows-msvc.yml @@ -0,0 +1,29 @@ +name: build-test-windows-msvc-on-push + +on: [push, pull_request] + +jobs: + build-cmake-msvc: + runs-on: windows-latest + steps: + - uses: actions/checkout@v4 + + - name: Restore from cache and setup vcpkg executable and data files. + uses: lukka/run-vcpkg@v11 + with: + vcpkgJsonGlob: 'vcpkg.json' + + - name: Setup MSVC + uses: ilammy/msvc-dev-cmd@v1 + + - name: Configure C/C++ with CMake + run: | + cmake --preset vcpkg-ninja + + - name: Build with Ninja + run: | + cmake --build build + + - name: Install MLT + run: | + cmake --install build diff --git a/CMakePresets.json b/CMakePresets.json new file mode 100644 index 000000000..c299da88a --- /dev/null +++ b/CMakePresets.json @@ -0,0 +1,48 @@ +{ + "version": 3, + "configurePresets": [ + { + "name": "vcpkg", + "displayName": "vcpkg config", + "description": "Configure with vcpkg toolchain", + "binaryDir": "${sourceDir}/build", + "toolchainFile": "$env{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake", + "cacheVariables": { + "BUILD_TESTING": "OFF", + "SWIG_PYTHON": "OFF", + "MOD_AVFORMAT": "OFF", + "MOD_DECKLINK": "OFF", + "MOD_FREI0R": "OFF", + "MOD_GDK": "OFF", + "MOD_JACKRACK": "OFF", + "USE_LV2": "OFF", + "USE_VST2": "OFF", + "MOD_KDENLIVE": "OFF", + "MOD_NDI": "OFF", + "MOD_NORMALIZE": "OFF", + "MOD_OLDFILM": "OFF", + "MOD_OPENCV": "OFF", + "MOD_MOVIT": "OFF", + "MOD_PLUS": "OFF", + "MOD_PLUSGPL": "OFF", + "MOD_QT6": "OFF", + "MOD_SOX": "OFF", + "MOD_GLAXNIMATE_QT6": "OFF", + "MOD_RESAMPLE": "OFF", + "MOD_RTAUDIO": "OFF", + "MOD_RUBBERBAND": "OFF", + "MOD_SDL2": "ON", + "MOD_DOX": "OFF", + "MOD_VIDSTAB": "OFF", + "MOD_VORBIS": "OFF", + "MOD_XINE": "OFF", + "MOD_XML": "OFF" + } + }, + { + "name": "vcpkg-ninja", + "inherits": "vcpkg", + "generator": "Ninja" + } + ] +} diff --git a/vcpkg-configuration.json b/vcpkg-configuration.json new file mode 100644 index 000000000..d137e58f9 --- /dev/null +++ b/vcpkg-configuration.json @@ -0,0 +1,14 @@ +{ + "default-registry": { + "kind": "git", + "baseline": "cfcbdb245f1179a5a493890a0b69531d66969e62", + "repository": "https://github.com/microsoft/vcpkg" + }, + "registries": [ + { + "kind": "artifact", + "location": "https://github.com/microsoft/vcpkg-ce-catalog/archive/refs/heads/main.zip", + "name": "microsoft" + } + ] +} diff --git a/vcpkg.json b/vcpkg.json new file mode 100644 index 000000000..3d2c8d890 --- /dev/null +++ b/vcpkg.json @@ -0,0 +1,12 @@ +{ + "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", + "name": "mlt", + "dependencies": [ + "dirent", + "dlfcn-win32", + "libiconv", + "pkgconf", + "pthreads", + "sdl2" + ] +}