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

#### 操作步骤

1. 使用PuTTY工具，以root用户登录服务器。
2. 执行以下命令解压GSL安装包。

```
tar -xvf gsl-2.6.tar.gz
```


3. 执行以下命令进入解压后的目录。

```
cd gsl-2.6
```


4. 执行以下命令进行配置。

```
./configure --prefix=
/path/to
/GSL
/gsl
```


5. 执行以下命令进行编译。

```
make -j 32
make install
```


6. 执行以下命令设置环境变量。

```
export LIBRARY_PATH=
/path/to
/GSL
/gsl/lib:$LIBRARY_PATH
export LD_LIBRARY_PATH=
/path/to
/GSL
/gsl/lib:$LD_LIBRARY_PATH
```
