Science&Enigneering

Installation of oneAPI on Ubuntu using apt

##- 2023. 4. 5. 16:57
728x90

oneAPi 설치 방법

https://www.intel.com/content/www/us/en/docs/oneapi/installation-guide-linux/2023-0/apt.html#GUID-560A487B-1B5B-4406-BB93-22BC7B526BCD

 

APT

Install Intel oneAPI Toolkits on Linux* OS

www.intel.com

 

 

1. install CMake, pkg-config, and the GNU development tools

sudo apt update
sudo apt -y install cmake pkg-config build-essential

 

2. download the key to system keyring

wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB \
| gpg --dearmor | sudo tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null

 

3. add signed entry to apt sources and configure the APT client to use Intel repository:

echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list

 

4, update packages list and repository index:

sudo apt update

 

5. install the Intel® oneAPI Base Toolkit package

sudo apt install intel-basekit

 

6. install the Intel® oneAPI HPC Toolkit package

sudo apt install hpc-basekit

7. Set Environment Variables for CLI Development

. /opt/intel/oneapi/setvars.sh

 

Build and Run a Sample Project Using the Command Line

1. run oneapi-cli

oneapi-cli

follow steps...

 

2, and make source codes..

make all
make run

 

Compile with oneAPI

dpcpp vector_add.cpp -o vector_add-sycl
300x250