mirror of
https://github.com/yse/easy_profiler.git
synced 2024-12-26 08:01:51 +08:00
Add bazel build for easy profiler core
This commit is contained in:
parent
47c3ddc09f
commit
bb889d4d31
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,6 +1,8 @@
|
|||||||
bin
|
bin
|
||||||
*build*
|
*build*
|
||||||
|
!BUILD
|
||||||
.*
|
.*
|
||||||
*.user
|
*.user
|
||||||
/*.prof
|
/*.prof
|
||||||
.idea/
|
.idea/
|
||||||
|
bazel*
|
||||||
|
13
easy_profiler_core/BUILD
Normal file
13
easy_profiler_core/BUILD
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
cc_library(
|
||||||
|
name = "easy_profiler",
|
||||||
|
srcs = glob(["**/*.cpp", "**/*.h"]),
|
||||||
|
hdrs = glob(["include/**"]),
|
||||||
|
includes = ["include", "."],
|
||||||
|
visibility = ["//visibility:public"],
|
||||||
|
defines = [
|
||||||
|
"EASY_PROFILER_VERSION_MAJOR=2",
|
||||||
|
"EASY_PROFILER_VERSION_MINOR=1",
|
||||||
|
"EASY_PROFILER_VERSION_PATCH=0",
|
||||||
|
"BUILD_WITH_EASY_PROFILER=1",
|
||||||
|
]
|
||||||
|
)
|
@ -45,6 +45,7 @@ The Apache License, Version 2.0 (the "License");
|
|||||||
|
|
||||||
#include <easy/details/arbitrary_value_aux.h>
|
#include <easy/details/arbitrary_value_aux.h>
|
||||||
#include <easy/details/profiler_public_types.h>
|
#include <easy/details/profiler_public_types.h>
|
||||||
|
#include <string>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
namespace profiler
|
namespace profiler
|
||||||
|
@ -303,7 +303,7 @@ PROFILER_API const profiler::BaseBlockDescriptor* registerDescription(profiler::
|
|||||||
const char*, const char*, int,
|
const char*, const char*, int,
|
||||||
profiler::block_type_t, profiler::color_t, bool)
|
profiler::block_type_t, profiler::color_t, bool)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const BaseBlockDescriptor*>(0xbad);
|
return reinterpret_cast<const profiler::BaseBlockDescriptor*>(0xbad);
|
||||||
}
|
}
|
||||||
|
|
||||||
PROFILER_API void endBlock() { }
|
PROFILER_API void endBlock() { }
|
||||||
|
7
sample/BUILD
Normal file
7
sample/BUILD
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
cc_binary(
|
||||||
|
name = "easy_profiler_sample",
|
||||||
|
srcs = ["main.cpp"],
|
||||||
|
deps = [
|
||||||
|
"//easy_profiler_core:easy_profiler",
|
||||||
|
],
|
||||||
|
)
|
Loading…
x
Reference in New Issue
Block a user