infra: Add window build test in CI
authorJunsuChoi <jsuya.choi@samsung.com>
Tue, 28 Sep 2021 02:07:58 +0000 (11:07 +0900)
committerJunsuChoi <jsuya.choi@samsung.com>
Wed, 6 Oct 2021 03:03:14 +0000 (12:03 +0900)
Add build test for normal build

.github/workflows/build_win.yml [new file with mode: 0644]
meson.build
src/lib/tvgInitializer.cpp

diff --git a/.github/workflows/build_win.yml b/.github/workflows/build_win.yml
new file mode 100644 (file)
index 0000000..9584a00
--- /dev/null
@@ -0,0 +1,30 @@
+name: Build(Window)
+
+on:
+  pull_request:
+    branches:
+      - master
+
+jobs:
+  build:
+    runs-on: windows-latest
+    steps:
+    - uses: actions/checkout@v2
+    - uses: ilammy/msvc-dev-cmd@v1
+      with:
+        submodules: true
+    - name: Install Packages
+      run: |
+        pip install meson==0.58.0 ninja
+    - name: Build
+      run: |
+        meson --backend=ninja build --buildtype=release
+        where link
+        ninja -C build
+        ninja -C build install
+
+    - uses: actions/upload-artifact@v2
+      with:
+        name: result
+        path: build/src\thorvg*
+
index 2cd27e90f3093747c994b70f991200604035fef0..5ab4edfd75eb2c9c0c39c633bd8b38c15f599f47 100644 (file)
@@ -1,6 +1,6 @@
 project('thorvg',
         'cpp',
-        default_options : ['buildtype=debugoptimized', 'b_sanitize=none', 'werror=false', 'optimization=s', 'cpp_std=gnu++14'],
+        default_options : ['buildtype=debugoptimized', 'b_sanitize=none', 'werror=false', 'optimization=s', 'cpp_std=c++14'],
         version : '0.5.99',
         license : 'MIT')
 
index eb57d5a6c822b9dae74ec0b5d296b544071c13ff..83ec50be95f8ffbc881bc542c996cb9b14077256 100644 (file)
 #include "tvgTaskScheduler.h"
 #include "tvgLoader.h"
 
+#ifdef _WIN32
+    #include <cstring>
+#endif
+
 #ifdef THORVG_SW_RASTER_SUPPORT
     #include "tvgSwRenderer.h"
 #endif