1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Add Windows build for csvexport

Copy-pasted files from capture utility and adapted for csvexport
This commit is contained in:
kubouch
2020-07-11 15:48:08 +03:00
parent 1f6d18efcd
commit be34e5076c
4 changed files with 579 additions and 39 deletions
+13 -1
View File
@@ -1,3 +1,7 @@
#ifdef _WIN32
# include <windows.h>
#endif
#include <algorithm>
#include <cctype>
#include <fstream>
@@ -11,7 +15,7 @@
#include "../../server/TracyFileRead.hpp"
#include "../../server/TracyWorker.hpp"
#include "getopt.h"
#include "../../getopt/getopt.h"
void print_usage_exit(int e)
{
@@ -173,6 +177,14 @@ int64_t GetZoneChildTimeFast(
int main(int argc, char** argv)
{
#ifdef _WIN32
if (!AttachConsole(ATTACH_PARENT_PROCESS))
{
AllocConsole();
SetConsoleMode(GetStdHandle(STD_OUTPUT_HANDLE), 0x07);
}
#endif
Args args = parse_args(argc, argv);
auto f = std::unique_ptr<tracy::FileRead>(