mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-07 21:23:32 +00:00
infra: fix build failure using c++17 (or later) with MSVC.
the WIN32_LEAN_AND_MEAN definition will remove the unused features in windows.h that helps to improve the build-speed as well as fixing the issue. Issue: https://github.com/thorvg/thorvg/issues/2225 Co-Authored-By: Hermet Park <hermet@lottiefiles.com>
This commit is contained in:
parent
55c4d6fe28
commit
b1912e2ef9
4 changed files with 6 additions and 1 deletions
|
@ -124,6 +124,8 @@ if get_option('log') == true
|
||||||
config_h.set10('THORVG_LOG_ENABLED', true)
|
config_h.set10('THORVG_LOG_ENABLED', true)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
#Miscellaneous
|
||||||
|
config_h.set10('WIN32_LEAN_AND_MEAN', true)
|
||||||
|
|
||||||
configure_file(
|
configure_file(
|
||||||
output: 'config.h',
|
output: 'config.h',
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <thorvg.h>
|
#include <thorvg.h>
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#ifndef PATH_MAX
|
#ifndef PATH_MAX
|
||||||
#define PATH_MAX MAX_PATH
|
#define PATH_MAX MAX_PATH
|
||||||
|
|
|
@ -24,8 +24,8 @@
|
||||||
#include <thread>
|
#include <thread>
|
||||||
#include <thorvg.h>
|
#include <thorvg.h>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include "lodepng.h"
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#ifndef PATH_MAX
|
#ifndef PATH_MAX
|
||||||
#define PATH_MAX MAX_PATH
|
#define PATH_MAX MAX_PATH
|
||||||
|
@ -36,6 +36,7 @@
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#endif
|
#endif
|
||||||
|
#include "lodepng.h"
|
||||||
|
|
||||||
#define WIDTH_8K 7680
|
#define WIDTH_8K 7680
|
||||||
#define HEIGHT_8K 4320
|
#define HEIGHT_8K 4320
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
#include <thread>
|
#include <thread>
|
||||||
#include <thorvg.h>
|
#include <thorvg.h>
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#ifndef PATH_MAX
|
#ifndef PATH_MAX
|
||||||
#define PATH_MAX MAX_PATH
|
#define PATH_MAX MAX_PATH
|
||||||
|
|
Loading…
Add table
Reference in a new issue