Compare commits

..

No commits in common. "a06b940892bda2f5ffaaae71dcae605166a119bb" and "ece34c270c7d28b76fa5392e8edb2d6677e0a592" have entirely different histories.

4 changed files with 11 additions and 21 deletions

View file

@ -5,7 +5,7 @@ project(
default_options: [
'default_library=static',
'warning_level=everything',
'buildtype=debugoptimized',
'buildtype=release',
'cpp_args=-fvisibility=hidden',
],
)
@ -128,23 +128,17 @@ endif
deps += ftxui_dep
cmake_opts = cmake.subproject_options()
cmake_opts.add_cmake_defines({
'CMAKE_CXX_FLAGS': '-Wno-everything',
})
cmake_opts.append_compile_args('cpp', '-Wno-everything')
reflectcpp_proj = cmake.subproject('reflectcpp', options: cmake_opts)
reflectcpp_dep = reflectcpp_proj.dependency('reflectcpp', include_type: 'system')
reflectcpp_proj = cmake.subproject('reflectcpp')
reflectcpp_dep = reflectcpp_proj.dependency('reflectcpp')
deps += reflectcpp_dep
objc_args = []
link_args = ['-static-libgcc', '-static-libstdc++', '-static']
link_args = []
if host_machine.system() == 'darwin'
objc_args += ['-fobjc-arc']
elif host_machine.system() == 'linux'
link_args += ['-static-libgcc', '-static-libstdc++']
endif
executable(

View file

@ -1,9 +1,7 @@
#ifdef __WIN32__
#include <iostream>
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <wincrypt.h>
#include <winrt/Windows.Foundation.h>
#include <winrt/Windows.Media.Control.h>
#include <winrt/base.h>
@ -41,7 +39,6 @@ namespace {
}
RegCloseKey(key);
// Remove null terminator if present
if (!value.empty() && value.back() == '\0')
value.pop_back();
@ -53,7 +50,6 @@ namespace {
fn GetRunningProcesses() -> std::vector<string> {
std::vector<string> processes;
HANDLE hSnapshot = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);
if (hSnapshot == INVALID_HANDLE_VALUE)
return processes;
@ -65,7 +61,7 @@ namespace {
return processes;
}
while (Process32Next(hSnapshot, &pe32)) processes.emplace_back(pe32.szExeFile);
while (Process32Next(hSnapshot, &pe32)) { processes.emplace_back(pe32.szExeFile); }
CloseHandle(hSnapshot);
return processes;
@ -162,10 +158,8 @@ fn GetKernelVersion() -> string {
if (ntdllHandle) {
auto rtlGetVersion = std::bit_cast<RtlGetVersionPtr>(GetProcAddress(ntdllHandle, "RtlGetVersion"));
if (rtlGetVersion) {
RTL_OSVERSIONINFOW osInfo = {};
RTL_OSVERSIONINFOW osInfo = {};
osInfo.dwOSVersionInfoSize = sizeof(osInfo);
if (rtlGetVersion(&osInfo) == 0)
versionStream << osInfo.dwMajorVersion << "." << osInfo.dwMinorVersion << "." << osInfo.dwBuildNumber << "."
<< osInfo.dwPlatformId;
@ -231,7 +225,6 @@ fn GetDesktopEnvironment() -> optional<string> {
if (build >= 9600)
return "Metro (Windows 8.1)";
return "Metro (Windows 8)";
}

1
subprojects/sdbus-c++ Submodule

@ -0,0 +1 @@
Subproject commit 48ea775531523ac290abec91107c628f00156543

2
subprojects/sqlite3.wrap Normal file
View file

@ -0,0 +1,2 @@
[wrap-redirect]
filename = SQLiteCpp-3.3.2/subprojects/sqlite3.wrap