Skip to content

Commit

Permalink
v1.0.2
Browse files Browse the repository at this point in the history
  • Loading branch information
yse committed Feb 7, 2017
1 parent 7ef004e commit d338c02
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 7 deletions.
38 changes: 32 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# easy_profiler [![version](https://img.shields.io/badge/version-1.0.1-009688.svg)](https://github.com/yse/easy_profiler/releases)
# easy_profiler [![version](https://img.shields.io/badge/version-1.0.2-009688.svg)](https://github.com/yse/easy_profiler/releases)

[![Build Status](https://travis-ci.org/yse/easy_profiler.svg?branch=develop)](https://travis-ci.org/yse/easy_profiler)

Expand All @@ -7,6 +7,9 @@

1. [About](#about)
2. [Usage](#usage)
- [Prepare build system](#prepare-build-system)
- [General build system](#general)
- [CMake](#build-with-cmake)
- [Add profiling blocks](#add-profiling-blocks)
- [Collect blocks](#collect-blocks)
3. [Build](#build)
Expand Down Expand Up @@ -35,11 +38,38 @@ You can see the results of measuring in simple GUI application which provides fu

# Usage

## Add profiling blocks
## Prepare build system

### General

First of all you can specify path to include directory which contains `include/profiler` directory and define macro `BUILD_WITH_EASY_PROFILER`.
For linking with easy_profiler you can specify path to library.

### Build with cmake

If you are using `cmake` set `CMAKE_PREFIX_PATH` to `cmake/easy_profiler` directory (from [release](https://github.com/yse/easy_profiler/releases) package) and use function `find_package(easy_profiler)` with `target_link_libraries(... easy_profiler)`. Don't forget to define macro `BUILD_WITH_EASY_PROFILER`. Example:

``` cmake
project(app_for_profiling)
set(SOURCES
main.cpp
)
#CMAKE_PREFIX_PATH should be set to <easy_profiler-release_dir>/cmake/easy_profiler
find_package(easy_profiler REQUIRED)
add_definitions(
-DBUILD_WITH_EASY_PROFILER
)
add_executable(app_for_profiling ${SOURCES})
target_link_libraries(app_for_profiling easy_profiler)
```

## Add profiling blocks

Example of usage.

This code snippet will generate block with function name and Magenta color:
Expand Down Expand Up @@ -135,7 +165,3 @@ $ mkdir build
$ cd build
$ cmake .. -G "Visual Studio 12 2013 Win64"
```



[![Analytics](https://ga-beacon.appspot.com/UA-82899176-1/easy_profiler/readme)](https://github.com/yse/easy_profiler)
1 change: 1 addition & 0 deletions easy_profiler_core/reader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ extern const uint32_t EASY_CURRENT_VERSION;
# define EASY_VERSION_INT(v_major, v_minor, v_patch) ((static_cast<uint32_t>(v_major) << 24) | (static_cast<uint32_t>(v_minor) << 16) | static_cast<uint32_t>(v_patch))
const uint32_t EASY_V_100 = EASY_VERSION_INT(1, 0, 0);
const uint32_t COMPATIBLE_VERSIONS[] = {
EASY_VERSION_INT(1, 0, 1),
EASY_V_100,
EASY_VERSION_INT(0, 1, 0)
};
Expand Down
2 changes: 1 addition & 1 deletion easy_profiler_core/version.info
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.1
1.0.2

0 comments on commit d338c02

Please sign in to comment.