---
title: 编译和安装
description: "1. 使用PuTTY工具，以root用户登录服务器。"
url: https://www.hikunpeng.com/document/detail/zh/kunpenghpcs/hpcindapp/prtg-osc/kunpengbreakdancer_02_0006.html
sourcePath: /source/zh/kunpenghpcs/hpcindapp/prtg-osc/kunpengbreakdancer_02_0006.html
indexId: 81762d98d734582e26c2dc3cf7da59827b7af1b3cdc9ca787d86f210fb1857d673
---
# 编译和安装

#### 操作步骤

1. 使用PuTTY工具，以root用户登录服务器。
2. 执行以下命令进入主程序安装目录。

```
cd
/path/to/breakdancer
/breakdancer
```


3. 执行以下命令进行编译安装。

```
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=release -DCMAKE_INSTALL_PREFIX=
/
path/to
/breakdancer
make && make install
```


4. 执行以下命令加载环境变量。

```
export PATH
=
/
path/to
/breakdancer
/bin:$PATH
```
