Created
August 2, 2018 16:11
-
-
Save ermakovpetr/ee2bfe6bdd94814e18b2fea9abe7850a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: Setup GCC | |
hosts: jupyterhubs_main | |
tasks: | |
- name: Create dirs for gcc build | |
file: | |
path: /tmp/tmp_for_gcc | |
state: directory | |
become: yes | |
become_user: jupyterhub_user | |
- name: Download gcc | |
get_url: | |
url: http://ftp.mirrorservice.org/sites/sourceware.org/pub/gcc/releases/gcc-8.2.0/gcc-8.2.0.tar.gz | |
dest: /tmp/tmp_for_gcc/gcc.tar.gz | |
mode: 0700 | |
become: yes | |
become_user: jupyterhub_user | |
- name: Unarchive gcc | |
command: tar zxf /tmp/tmp_for_gcc/gcc.tar.gz -C /tmp/tmp_for_gcc/ | |
become: yes | |
become_user: jupyterhub_user | |
- name: Download prerequisites for gcc | |
command: ./contrib/download_prerequisites --force | |
args: | |
chdir: /tmp/tmp_for_gcc/gcc-8.2.0 | |
become: yes | |
become_user: jupyterhub_user | |
- name: Configure gcc | |
command: ./configure --disable-multilib --enable-languages=all | |
args: | |
chdir: /tmp/tmp_for_gcc/gcc-8.2.0 | |
creates: /tmp/tmp_for_gcc/gcc-8.2.0/Makefile | |
become: yes | |
become_user: jupyterhub_user | |
- name: Make gcc | |
command: make -j 64 | |
args: | |
chdir: /tmp/tmp_for_gcc/gcc-8.2.0 | |
become: yes | |
become_user: jupyterhub_user | |
- name: Make install gcc | |
command: make install | |
args: | |
chdir: /tmp/tmp_for_gcc/gcc-8.2.0 | |
become: yes | |
become_user: root | |
- name: Remove build dir | |
command: rm -rf /tmp/tmp_for_gcc | |
become: yes | |
become_user: jupyterhub_user |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment