build system improvements

This commit is contained in:
Akash Mozumdar 2021-03-13 00:51:36 -07:00
parent 74121d7484
commit aa0c0e0047
4 changed files with 6 additions and 7 deletions

View File

@ -7,12 +7,10 @@ environment:
matrix: matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019 - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
arch: x64 arch: x64
msvc_name: Visual Studio 16 2019
platform: x64 platform: x64
qtbin: msvc2017_64 qtbin: msvc2017_64
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019 - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
arch: x86 arch: x86
msvc_name: Visual Studio 16 2019
platform: Win32 platform: Win32
qtbin: msvc2017 qtbin: msvc2017
@ -20,7 +18,7 @@ before_build:
- cd C:\ - cd C:\
- mkdir %arch% - mkdir %arch%
- cd %arch% - cd %arch%
- cmake -G "%msvc_name%" -A "%platform%" -DQt5_DIR="C:\Qt\5.13\%qtbin%\lib\cmake\Qt5" -DCMAKE_BUILD_TYPE="RelWithDebInfo" ../Textractor - cmake -G "Visual Studio 16 2019" -A "%platform%" -DQt5_DIR="C:\Qt\5.13\%qtbin%\lib\cmake\Qt5" -DCMAKE_BUILD_TYPE="RelWithDebInfo" -DVERSION="" ../Textractor
build: build:
project: C:\%arch%\Textractor.sln project: C:\%arch%\Textractor.sln

View File

@ -1,8 +1,8 @@
param([string]$version) param([string]$version)
cd $PSScriptRoot; cd $PSScriptRoot;
mkdir -Force -Verbose Builds; mkdir -Force -Verbose builds;
cd Builds; cd builds;
mkdir -Force -Verbose x86; mkdir -Force -Verbose x86;
mkdir -Force -Verbose x64; mkdir -Force -Verbose x64;
@ -85,6 +85,7 @@ foreach ($arch in @("x86", "x64"))
{ {
copy -Force -Recurse -Verbose -Destination "Runtime/$arch/$file" -Path "Release_$arch/$file"; copy -Force -Recurse -Verbose -Destination "Runtime/$arch/$file" -Path "Release_$arch/$file";
} }
copy -Force -Recurse -Verbose -Destination "$arch" -Path "C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Redist/MSVC/**/$arch/Microsoft.VC142.CRT/*"
} }
rm -Force -Recurse -Verbose "Textractor"; rm -Force -Recurse -Verbose "Textractor";

View File

@ -62,4 +62,4 @@ std::string Escape(const std::string& text)
return escaped; return escaped;
} }
TEST(assert(JSON::Parse<wchar_t>(LR"([{"string":"hello world","boolean":false,"number":1.67e+4,"null":null,"array":[]},"hello world"])"))) TEST(assert(JSON::Parse<wchar_t>(LR"([{"string":"hello world","boolean":false,"number":1.67e+4,"null":null,"array":[]},"hello world"])")));

View File

@ -139,7 +139,7 @@ inline void TEXTRACTOR_DEBUG(const wchar_t* format, const Args&... args) { std::
void Localize(); void Localize();
#ifdef _DEBUG #ifdef _DEBUG
#define TEST(...) static auto _ = CreateThread(nullptr, 0, [](auto) { __VA_ARGS__; return 0UL; }, NULL, 0, nullptr); #define TEST(...) static auto _ = CreateThread(nullptr, 0, [](auto) { __VA_ARGS__; return 0UL; }, NULL, 0, nullptr)
#else #else
#define TEST(...) #define TEST(...)
#endif #endif