1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 inherit pax-utils versionator
8 MY_PV=$(get_version_component_range 1-3)
10 DATE=$(get_version_component_range 4)
12 DATE=${DATE:0:4}-${DATE:4:2}-${DATE:6}
13 INSTALLER=${PN}-${DATE}-installer.run
15 DESCRIPTION="PathScale EKOPath Compiler Suite"
16 HOMEPAGE="http://www.pathscale.com/ekopath-compiler-suite"
17 SRC_URI="http://c591116.r16.cf2.rackcdn.com/${PN}/nightly/Linux/${INSTALLER}"
19 LICENSE="all-rights-reserved"
24 DEPEND="!!app-arch/rpm"
25 RDEPEND="!dev-lang/ekopath:0/${MY_PV}"
27 RESTRICT="bindist mirror"
29 QA_PREBUILT="opt/${MY_P}/*"
34 cp "${DISTDIR}/${INSTALLER}" "${S}/" || die
35 chmod +x "${S}/${INSTALLER}" || die
39 # EI_PAX marking is obsolete and PT_PAX breaks the binary.
40 # We must use XT_PAX to run the installer.
41 if [[ ${PAX_MARKINGS} == "XT" ]]; then
42 pax-mark m "${INSTALLER}"
46 --prefix "${ED%/}/opt/${MY_P}" \
47 --mode unattended || die
49 if [[ ! -d ${ED%/}/opt/${MY_P}/lib/${MY_PV} ]]; then
51 cd "${ED%/}/opt/${MY_P}/lib" && guess=( * )
53 if [[ ${guess[@]} ]]; then
54 die "Incorrect release version in PV, guessing it should be: ${guess[*]}"
56 die "No libdir installed"
59 [[ -x ${ED%}/opt/${MY_P}/bin/pathcc ]] || die "No pathcc executable was installed, your hardware is unsupported most likely"
61 rm -r "${ED}/opt/${MY_P}"/uninstall* || die