1 |
commit: 3d656adb54ef2b718e3b14d720ff78ebae5af7d5 |
2 |
Author: Andrew Savchenko <bircoph <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Mar 5 21:23:43 2017 +0000 |
4 |
Commit: Andrew Savchenko <bircoph <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Mar 5 21:23:43 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3d656adb |
7 |
|
8 |
sci-physics/xfoil: version bump |
9 |
|
10 |
Bug: 556688 |
11 |
|
12 |
Package-Manager: Portage-2.3.3, Repoman-2.3.1 |
13 |
Signed-off-by: Andrew Savchenko <bircoph <AT> gentoo.org> |
14 |
|
15 |
sci-physics/xfoil/Manifest | 1 + |
16 |
sci-physics/xfoil/files/xfoil-6.99-overflow.patch | 11 ++++ |
17 |
sci-physics/xfoil/xfoil-6.99.ebuild | 76 +++++++++++++++++++++++ |
18 |
3 files changed, 88 insertions(+) |
19 |
|
20 |
diff --git a/sci-physics/xfoil/Manifest b/sci-physics/xfoil/Manifest |
21 |
index 75de844ff4e..8d653871e2a 100644 |
22 |
--- a/sci-physics/xfoil/Manifest |
23 |
+++ b/sci-physics/xfoil/Manifest |
24 |
@@ -1,2 +1,3 @@ |
25 |
DIST dataflow.pdf 7654 SHA256 4596c77a3fa24cd334b35c34fcbd0b4f1d9055273c0862643e2d07b5e774aff5 SHA512 1bb5be8e70fca1fa90f28d214140e96a8795c7d82a37f4fe4d68606fa3eb28252913b8fb13eb3e97a3cf05c3001c88dbfcdb8a2f20d4baed5e730770a2d602b1 WHIRLPOOL 8e13137933ae0e8edc2890ccdd0537444d5fa9530e76caefb3701173c7720d2cb68d9073b70e7948a11ed6668dcd64b3685c750f5cef889c31d1506d3788a530 |
26 |
DIST xfoil6.97.tar.gz 3972497 SHA256 293e28e269bd88a62f8b6ba6bf684f16843f6776736e6b77aaa8b6bebc467a81 SHA512 02c0a123fb99fa20de1e3577ca7c6ce00d494058f2ef3ec82e3fdea48901f4346180aea3436e001c5b90401007ccdd5b7e9daa6a96794f0d6b5781a5b36e36e7 WHIRLPOOL 3de5e6c56a906a71b2be1fcf39ea031454c9192b4a649a23aaa889566fea2e92b37239fa6ed90c4b050bdb5759943d0265881f316ecd5b48a06fe4217af36ef7 |
27 |
+DIST xfoil6.99.tgz 4515991 SHA256 5c0250643f52ce0e75d7338ae2504ce7907f2d49a30f921826717b8ac12ebe40 SHA512 6f5bed520826dba2efd1b191b1f90dd810b53d9041cbbaddde09207ba9042f99dd0c9e9aa8b8cdf48767bf2695e328ac8fbd297e1510e53ac10b0f1eea35cfef WHIRLPOOL 88ca7c92fb1335f416577dc7df67e22581a32b56affb234f440b9523122429ad7ad37455e3270461909b0eb3d181013daa3db0e869086e218e2eaf5bf5f4e3ce |
28 |
|
29 |
diff --git a/sci-physics/xfoil/files/xfoil-6.99-overflow.patch b/sci-physics/xfoil/files/xfoil-6.99-overflow.patch |
30 |
new file mode 100644 |
31 |
index 00000000000..d35528caa08 |
32 |
--- /dev/null |
33 |
+++ b/sci-physics/xfoil/files/xfoil-6.99-overflow.patch |
34 |
@@ -0,0 +1,11 @@ |
35 |
+--- Xfoil/src/xoper.f.orig 2013-12-08 22:21:22.000000000 +0400 |
36 |
++++ Xfoil/src/xoper.f 2017-03-05 23:02:33.214895357 +0300 |
37 |
+@@ -114,7 +114,7 @@ |
38 |
+ C---- don't try to read integers, since might get integer overflow |
39 |
+ DO I=1, NINPUT |
40 |
+ IF(ABS(RINPUT(I)) .GT. 2.1E9) THEN |
41 |
+- IINPUT(I) = 2**30 |
42 |
++ IINPUT(I) = HUGE(0) |
43 |
+ ELSE |
44 |
+ IINPUT(I) = INT(RINPUT(I)) |
45 |
+ ENDIF |
46 |
|
47 |
diff --git a/sci-physics/xfoil/xfoil-6.99.ebuild b/sci-physics/xfoil/xfoil-6.99.ebuild |
48 |
new file mode 100644 |
49 |
index 00000000000..f50b8bace44 |
50 |
--- /dev/null |
51 |
+++ b/sci-physics/xfoil/xfoil-6.99.ebuild |
52 |
@@ -0,0 +1,76 @@ |
53 |
+# Copyright 1999-2017 Gentoo Foundation |
54 |
+# Distributed under the terms of the GNU General Public License v2 |
55 |
+# $Id$ |
56 |
+ |
57 |
+EAPI=6 |
58 |
+ |
59 |
+inherit fortran-2 |
60 |
+ |
61 |
+DESCRIPTION="Design and analysis of subsonic isolated airfoils" |
62 |
+HOMEPAGE="http://raphael.mit.edu/xfoil/" |
63 |
+SRC_URI=" |
64 |
+ http://web.mit.edu/drela/Public/web/${PN}/${PN}${PV}.tgz |
65 |
+ doc? ( http://web.mit.edu/drela/Public/web/${PN}/dataflow.pdf )" |
66 |
+ |
67 |
+LICENSE="GPL-2" |
68 |
+SLOT="0" |
69 |
+KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux" |
70 |
+IUSE="doc examples" |
71 |
+ |
72 |
+RDEPEND="x11-libs/libX11" |
73 |
+DEPEND="${RDEPEND}" |
74 |
+ |
75 |
+PATCHES=( "${FILESDIR}"/${P}-overflow.patch ) |
76 |
+ |
77 |
+S="${WORKDIR}/${PN^}" |
78 |
+ |
79 |
+src_prepare() { |
80 |
+ # fix bug #147033 |
81 |
+ [[ $(tc-getFC) == *gfortran ]] && PATCHES+=( "${FILESDIR}"/${PN}-6.96-gfortran.patch ) |
82 |
+ default |
83 |
+ |
84 |
+ sed \ |
85 |
+ -e '/^FC/d' \ |
86 |
+ -e '/^CC/d' \ |
87 |
+ -e '/^FFLAGS/d' \ |
88 |
+ -e '/^CFLAGS/d' \ |
89 |
+ -e '/INSTALLCMD/d' \ |
90 |
+ -e 's/^\(FFLOPT .*\)/FFLOPT = $(FFLAGS)/g' \ |
91 |
+ -i {bin,plotlib,orrs/bin}/Makefile plotlib/config.make \ |
92 |
+ || die "sed for flags and compilers failed" |
93 |
+ |
94 |
+ sed \ |
95 |
+ -e "s:/var/local/codes/orrs/osmap.dat:${EPREFIX}/usr/share/xfoil/orrs/osmap.dat:" \ |
96 |
+ -i orrs/src/osmap.f || die "sed osmap.f failed" |
97 |
+} |
98 |
+ |
99 |
+src_compile() { |
100 |
+ emake -C orrs/bin FLG="${FFLAGS}" FTNLIB="${LDFLAGS}" OS |
101 |
+ pushd orrs >/dev/null || die |
102 |
+ bin/osgen osmaps_ns.lst || die |
103 |
+ popd >/dev/null || die |
104 |
+ emake -C plotlib CFLAGS="${CFLAGS} -DUNDERSCORE" |
105 |
+ |
106 |
+ local i |
107 |
+ for i in blu pplot pxplot xfoil; do |
108 |
+ emake -C bin \ |
109 |
+ PLTOBJ="../plotlib/libPlt_gSP.a" \ |
110 |
+ CFLAGS="${CFLAGS} -DUNDERSCORE" \ |
111 |
+ FTNLIB="${LDFLAGS}" \ |
112 |
+ $i |
113 |
+ done |
114 |
+} |
115 |
+ |
116 |
+src_install() { |
117 |
+ dobin bin/{blu,pplot,pxplot,xfoil} |
118 |
+ insinto /usr/share/xfoil/orrs |
119 |
+ doins orrs/osm*.dat |
120 |
+ |
121 |
+ local DOCS=( *.txt README ) |
122 |
+ use doc && DOCS+=( "${DISTDIR}"/dataflow.pdf ) |
123 |
+ einstalldocs |
124 |
+ if use examples; then |
125 |
+ dodoc -r runs |
126 |
+ docompress -x /usr/share/doc/${PF}/runs |
127 |
+ fi |
128 |
+} |