Gentoo Archives: gentoo-commits

From: Kacper Kowalik <xarthisius@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/sci:master commit in: dev-lang/path64/
Date: Fri, 29 Jul 2011 07:47:10
Message-Id: d5fb1a1ad1dd9e2540e898568a2558e69751a12a.xarthisius@gentoo
1 commit: d5fb1a1ad1dd9e2540e898568a2558e69751a12a
2 Author: Kacper Kowalik (Xarthisius) <xarthisius.kk <AT> gmail <DOT> com>
3 AuthorDate: Fri Jul 29 07:46:54 2011 +0000
4 Commit: Kacper Kowalik <xarthisius <AT> gentoo <DOT> org>
5 CommitDate: Fri Jul 29 07:46:54 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=d5fb1a1a
7
8 [dev-lang/path64] Add snapshot
9
10 ---
11 dev-lang/path64/ChangeLog | 6 ++
12 dev-lang/path64/path64-1.0.0_pre20110729.ebuild | 94 +++++++++++++++++++++++
13 2 files changed, 100 insertions(+), 0 deletions(-)
14
15 diff --git a/dev-lang/path64/ChangeLog b/dev-lang/path64/ChangeLog
16 index 7575956..0a811f8 100644
17 --- a/dev-lang/path64/ChangeLog
18 +++ b/dev-lang/path64/ChangeLog
19 @@ -2,6 +2,12 @@
20 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
21 # $Header: $
22
23 +*path64-1.0.0_pre20110729 (29 Jul 2011)
24 +
25 + 29 Jul 2011; Kacper Kowalik <xarthisius@g.o>
26 + +path64-1.0.0_pre20110729.ebuild:
27 + Add snapshot
28 +
29 27 Jul 2011; Kacper Kowalik <xarthisius@g.o> path64-9999.ebuild:
30 Add missing LDPATH to env file
31
32
33 diff --git a/dev-lang/path64/path64-1.0.0_pre20110729.ebuild b/dev-lang/path64/path64-1.0.0_pre20110729.ebuild
34 new file mode 100644
35 index 0000000..3d784cc
36 --- /dev/null
37 +++ b/dev-lang/path64/path64-1.0.0_pre20110729.ebuild
38 @@ -0,0 +1,94 @@
39 +# Copyright 1999-2011 Gentoo Foundation
40 +# Distributed under the terms of the GNU General Public License v2
41 +# $Header: $
42 +
43 +EAPI=4
44 +CMAKE_VERBOSE=1
45 +
46 +inherit cmake-utils multilib toolchain-funcs
47 +
48 +DESCRIPTION="Path64 Compiler Suite Community Edition"
49 +HOMEPAGE="http://www.pathscale.com/ekopath-compiler-suite"
50 +SRC_URI="http://dev.gentoo.org/~xarthisius/${PN}-suite-${PV}.tbz2
51 + http://dev.gentoo.org/~xarthisius/${PN}-compiler-${PV}.tbz2
52 + assembler? ( http://dev.gentoo.org/~xarthisius/${PN}-assembler-${PV}.tbz2 )
53 + debugger? ( http://dev.gentoo.org/~xarthisius/${PN}-debugger-${PV}.tbz2 )"
54 +
55 +LICENSE="GPL-3"
56 +SLOT="0"
57 +KEYWORDS="~amd64"
58 +IUSE="assembler custom-cflags debugger fortran +native +openmp valgrind"
59 +
60 +DEPEND="!native? ( sys-devel/gcc[vanilla] )
61 + native? ( || ( dev-lang/ekopath dev-lang/path64 ) )
62 + valgrind? ( dev-util/valgrind )"
63 +RDEPEND="${DEPEND}"
64 +
65 +S=${WORKDIR}/${PN}
66 +
67 +pkg_setup() {
68 + if use custom-cflags ; then
69 + ewarn "You are trying to build ${PN} with custom-cflags"
70 + ewarn "There is a high chance that you will utterly fail!"
71 + ewarn "Unless you know what you are doing you'd better stop now"
72 + ewarn "Should you decide to proceed, you are on your own..."
73 + epause
74 + fi
75 +}
76 +
77 +src_prepare() {
78 + local ver=$(grep 'SET(PSC_FULL_VERSION' CMakeLists.txt | cut -d'"' -f2)
79 + cat > "98${PN}" <<-EOF
80 + PATH=/usr/$(get_libdir)/${PN}/bin
81 + ROOTPATH=/usr/$(get_libdir)/${PN}/bin
82 + LDPATH=/usr/$(get_libdir)/${PN}/lib:/usr/$(get_libdir)/${PN}/lib/${ver}/x8664/64
83 + EOF
84 + sed -i -e "s/-Wl,-s //" CMakeLists.txt || die #strip
85 +}
86 +
87 +src_configure() {
88 + local linker=$($(tc-getCC) --help -v 2>&1 >/dev/null | grep '\-dynamic\-linker' | cut -f7 -d' ')
89 + local libgcc=$($(tc-getCC) -print-libgcc-file-name)
90 + local crt=$($(tc-getCC) -print-file-name=crt1.o)
91 + use custom-cflags && flags=(
92 + -DCMAKE_C_FLAGS="${CFLAGS}"
93 + -DCMAKE_CXX_FLAGS="${CXXFLAGS}"
94 + )
95 +
96 + # Yup, I know how bad it is, but I'd rather have a working compiler
97 + unset FC F90 F77 FCFLAGS F90FLAGS FFLAGS CFLAGS CXXFLAGS
98 +
99 + if use native ; then
100 + export CMAKE_BUILD_TYPE=Release
101 + export CC=pathcc
102 + export CXX=pathCC
103 + export MYCMAKEARGS="-UCMAKE_USER_MAKE_RULES_OVERRIDE"
104 + else
105 + export CMAKE_BUILD_TYPE=Debug
106 + fi
107 + mycmakeargs=(
108 + -DCMAKE_INSTALL_PREFIX=/usr/$(get_libdir)/${PN}
109 + -DPATH64_ENABLE_TARGETS="x86_64"
110 + -DPATH64_ENABLE_PROFILING=ON
111 + -DPATH64_ENABLE_MATHLIBS=ON
112 + -DPATH64_ENABLE_PATHOPT2=OFF
113 + $(cmake-utils_use assembler PATH64_ENABLE_PATHAS)
114 + $(cmake-utils_use assembler PATH64_ENABLE_DEFAULT_PATHAS)
115 + $(cmake-utils_use fortran PATH64_ENABLE_FORTRAN)
116 + $(cmake-utils_use openmp PATH64_ENABLE_OPENMP)
117 + $(cmake-utils_use debugger PATH64_ENABLE_PATHDB)
118 + $(cmake-utils_use valgrind PATH64_ENABLE_VALGRIND)
119 + -DPSC_CRT_PATH_x86_64=$(dirname ${crt})
120 + -DPSC_CRTBEGIN_PATH=$(dirname ${libgcc})
121 + -DPSC_DYNAMIC_LINKER_x86_64=${linker}
122 + -DCMAKE_C_COMPILER="$(tc-getCC)"
123 + -DCMAKE_CXX_COMPILER="$(tc-getCXX)"
124 + "${flags[@]}"
125 + )
126 + cmake-utils_src_configure
127 +}
128 +
129 +src_install() {
130 + cmake-utils_src_install
131 + doenvd "98${PN}"
132 +}