Skip to content

Commit

Permalink
Try to install niche compilers on ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
LivInTheLookingGlass committed Jun 24, 2024
1 parent b1f31de commit 99b539f
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/on_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Set up extra compilers (Linux)
if: ${{ matrix.os == ubuntu-latest }}
run: make icc pcc

- name: Use Python 3.7
uses: actions/setup-python@v5
with:
Expand Down
30 changes: 30 additions & 0 deletions c/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,33 @@ lint:
else \
clang-tidy *.c; \
fi

ifeq ($(OS),Windows_NT)
else
pcc:
sudo apt-get install -y build-essential flex bison
mkdir pcc pcc-libs
wget -O - -o /dev/null http://pcc.ludd.ltu.se/ftp/pub/pcc-releases/pcc-1.1.0.tgz | tar -xz --no-seek -C pcc --strip-components=1
wget -O - -o /dev/null http://pcc.ludd.ltu.se/ftp/pub/pcc-releases/pcc-libs-1.1.0.tgz | tar -xz --no-seek -C pcc-libs --strip-components=1
cd pcc; \
sed -i 's/MANPAGE=@BINPREFIX@cpp/MANPAGE=@BINPREFIX@pcc-cpp/' cc/cpp/Makefile.in; \
./configure --prefix=/usr --libexecdir=/usr/lib/{x86_64,i386}-linux-gnu; \
sudo make && sudo make install; \
cd ../pcc-libs; \
./configure --prefix=/usr --libexecdir=/usr/lib/{x86_64,i386}-linux-gnu; \
sudo make && sudo make install

icc:
mkdir iccdir
wget -O - -o /dev/null https://registrationcenter-download.intel.com/akdlm/irc_nas/15873/intel-sw-tools-installer.tar.gz | tar -xz --no-seek -C iccdir --strip-components=1
sudo apt-get update
sudo apt-get install -y cpio
cd iccdir; \
sed -i -e "s/ACCEPT_EULA=decline/ACCEPT_EULA=accept/g" silent.cfg; \
sed -i -e "s/ACTIVATION_TYPE=no_license/ACTIVATION_TYPE=serial_number/g" silent.cfg; \
echo "ACTIVATION_SERIAL_NUMBER=CKDX-WNDG7BK7" >> silent.cfg; \
echo "SELECTION_CONFIG_FILES_PATH=$PWD/packages.json" >> silent.cfg; \
echo '{"selections":[{"moduleId":"intel_cpp_compiler"},{"moduleId":"intel_threading_building_blocks","isDependencyTool":true}]}' > packages.json; \
sudo ./install.sh -s silent.cfg; \
PATH="/opt/intel/system_studio_2019/bin${PATH:+:${PATH}}"; export PATH
endif

0 comments on commit 99b539f

Please sign in to comment.