From eae42212ced6a5cbd5658b629f70d8851a922b61 Mon Sep 17 00:00:00 2001 From: Kishan Kumar Date: Wed, 29 Nov 2017 23:21:19 +0545 Subject: [PATCH] Added the installation guide for Ubuntu (#489) * Initial CLA Requirement * Added Installation steps to the Readme.md * Fixed error in running benchmark of Installation * Remove unwanted commands Removed the lengthy install procedure with suggested install mechanism --- AUTHORS | 1 + CONTRIBUTORS | 1 + README.md | 33 +++++++++++++++++++++++++++++++++ 3 files changed, 35 insertions(+) diff --git a/AUTHORS b/AUTHORS index 4e92e6d0..4e4c4ed4 100644 --- a/AUTHORS +++ b/AUTHORS @@ -27,6 +27,7 @@ JianXiong Zhou Joao Paulo Magalhaes Jussi Knuuttila Kaito Udagawa +Kishan Kumar Lei Xu Matt Clarkson Maxim Vafin diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 457e0ea4..c59134b9 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -40,6 +40,7 @@ JianXiong Zhou Joao Paulo Magalhaes Jussi Knuuttila Kai Wolf +Kishan Kumar Kaito Udagawa Lei Xu Matt Clarkson diff --git a/README.md b/README.md index d363095a..c6a9caf2 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,39 @@ IRC channel: https://freenode.net #googlebenchmark [Additional Tooling Documentation](docs/tools.md) + +## Installation Guide + +For Ubuntu and Debian Based System + +First make sure you have git and cmake installed (If not please install it) + +``` +sudo apt-get install git +sudo apt-get install cmake +``` + +Now, let's clone the repository and build it + +``` +git clone https://github.com/google/benchmark.git +cd benchmark +mkdir build +cd build +cmake .. -DCMAKE_BUILD_TYPE=RELEASE +make +``` + +We need to install the library globally now + +``` +sudo make install +``` + +Now you have google/benchmark installed in your machine +Note: Don't forget to link to pthread library while building + + ## Example usage ### Basic usage Define a function that executes the code to be measured.