* Uncompress the ifort archive.
This commit is contained in:
parent
20a22818b2
commit
5e99149c58
|
@ -39,6 +39,10 @@ class ifort (
|
|||
$dep_pkg_name = $ifort::params::dep_pkg_name,
|
||||
$dep_pkg_ensure = $ifort::params::dep_pkg_ensure,
|
||||
$dep_pkg_manage = $ifort::params::dep_pkg_manage,
|
||||
$ifort_pkg_url = $ifort::params::ifort_pkg_url,
|
||||
$ifort_pkg_path = $ifort::params::ifort_pkg_path,
|
||||
$ifort_install_tmp_path = $ifort::params::ifort_install_tmp_path,
|
||||
$ifort_install_script_path = $ifort::params::ifort_install_script_path,
|
||||
) inherits ifort::params {
|
||||
|
||||
include ifort::install
|
||||
|
|
|
@ -2,6 +2,11 @@
|
|||
#
|
||||
class ifort::install {
|
||||
|
||||
Exec {
|
||||
path => [ '/bin', '/sbin', '/usr/bin', '/usr/sbin' ],
|
||||
logoutput => 'on_failure',
|
||||
}
|
||||
|
||||
## Packages
|
||||
# Dependencies packages
|
||||
if $ifort::dep_pkg_manage == true {
|
||||
|
@ -14,4 +19,13 @@ class ifort::install {
|
|||
|
||||
}
|
||||
|
||||
|
||||
## Archive
|
||||
# Uncompress
|
||||
exec { "Uncompress ${ifort::ifort_pkg_path}":
|
||||
command => "zcat ${ifort::ifort_pkg_path} | tar xvf - -C ${ifort::ifort_install_tmp_path} --",
|
||||
creates => $ifort::ifort_install_script_path,
|
||||
onlyif => "test -f ${ifort::ifort_pkg_path}",
|
||||
}
|
||||
|
||||
} # Private class: ifort::install
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
# === Class: ifort::params
|
||||
#
|
||||
class ifort::params {
|
||||
case $::osfamily {
|
||||
'Debian': {
|
||||
if $::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '7.0') >= 0 {
|
||||
|
||||
## Packages
|
||||
# Dependencies packages
|
||||
$dep_pkg_name = [ 'rpm', 'build-essential' ]
|
||||
$dep_pkg_ensure = 'present' # Useless if use is_ifort instead
|
||||
$dep_pkg_manage = true
|
||||
|
||||
## Archives
|
||||
# Compiler
|
||||
$ifort_pkg_url = ''
|
||||
$ifort_pkg_path = ''
|
||||
$ifort_install_tmp_path = '/opt'
|
||||
$ifort_install_script_path = '/opt/l_fcompxe_2015.2.164/install.sh'
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
} # Private class ifort::params
|
Loading…
Reference in New Issue