1 |
commit: 478391cc3cacbc5797f6676de5be8c3476b1ede5 |
2 |
Author: Sergey Torokhov <torokhov-s-a <AT> yandex <DOT> ru> |
3 |
AuthorDate: Thu Sep 9 05:46:01 2021 +0000 |
4 |
Commit: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Sep 9 05:46:01 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=478391cc |
7 |
|
8 |
dev-libs/StringiFor: 1.1.3 version bump |
9 |
|
10 |
Signed-off-by: Sergey Torokhov <torokhov-s-a <AT> yandex.ru> |
11 |
|
12 |
dev-libs/StringiFor/Manifest | 4 + |
13 |
dev-libs/StringiFor/StringiFor-1.1.3.ebuild | 100 +++++++++++++++++++++ |
14 |
.../files/stringifor-1.1.3_fix_tests.patch | 22 +++++ |
15 |
3 files changed, 126 insertions(+) |
16 |
|
17 |
diff --git a/dev-libs/StringiFor/Manifest b/dev-libs/StringiFor/Manifest |
18 |
index cc3d264d8..069adca0f 100644 |
19 |
--- a/dev-libs/StringiFor/Manifest |
20 |
+++ b/dev-libs/StringiFor/Manifest |
21 |
@@ -1,4 +1,8 @@ |
22 |
DIST BeFoR64-1.1.4.tar.gz 32928 BLAKE2B ef5ca349508525c48843c613ef945f33e165069d2ade3f98acf25810daa22617d8c5fe45c4127d3eef36a5358cc1052237e6d94fce0ab4ae289a28a0d9c99b48 SHA512 26b0fa2cb754fa0f3809f5de29136073fdd399d0b192a5d97b67759a1a9f68fd59894f5fa9a805c7626732b63f18990922d88b110bd6d4ccdd5218fd330a4c81 |
23 |
+DIST BeFoR64-1.1.4_p20201012.tar.gz 37269 BLAKE2B 6930f3d9ce2c0f3f93d7c9a9e0662c65de3f3cef9b701b864033c98499b5d1d2fdee97da9efadcce7c3d1e4aec49b5223dd24e86c2cfd317620407f8d07b6e3e SHA512 6e4c49a7f4eb32cf1ecc0db335e315bdf82f0f46cf1075811394646264da023a30afbccd00c73619b6c93cf5d6daefc4a36e5f1fe44060f0f8131418a7e71f70 |
24 |
DIST FACE-1.1.2.tar.gz 159747 BLAKE2B 007c6bfc4148649a28f322f451f665750dc7cca515fae3c3d9b96694ea20ed0586471b9def43c92039bdf9450a1ebf9a927e5d50e8df4ea829284f41c331464e SHA512 e9eb336923780bf1a1b37a5f897a72181599bf843e91f118d4d418aebf26489bdeaedbd9025b8abda446b7bdb5e97746346e68ff6357d159a675d0aca3a3ee4c |
25 |
+DIST FACE-1.1.2_p20201005.tar.gz 157807 BLAKE2B f263abdb64b1153eb4eedf9e65a28614ff20bacf59f635d6ddfaa4e30cc47521fde8ae885e961b52fa8b86c7133fea4e67f7dde8676b25a0df8f1e28008a84f7 SHA512 9fb594211d583ef7176787f02268afa95700bf8a1905d26c51c5e40982fffb42b1b08e83f524d81d420981d607245c36e2a4a69464f8b1c5ae7c75c03643950d |
26 |
DIST PENF-1.2.2.tar.gz 143245 BLAKE2B d59353195c7502514091ad0a4dae42d9c3d5e8b383160f46e512ce42ed242539347683c5d79ae6a2093feee428af6137f6ecf8673c54ac15dc13a7029984dcf2 SHA512 12086abad9bdf552a9f41f862819a9fe6d91b18827515473f3ec36722fcd593cdb5d01a6769567dbc91238233d706ae4f2520e7767556e17b0dcb42e10999571 |
27 |
+DIST PENF-1.2.2_p20201012.tar.gz 142299 BLAKE2B 253697c67c62ffc4f7b32375a1451913b178dbf3d79f0c7eab76a14c9f6969df65ce8b9422c0851a819065a979d0935724bc3121a48fb40a1c963880c375670d SHA512 14b6246c0e6c8f4a4602bac22c1d8f6fd89ca174c7a6539d5da97c0bbe4049891117b0a469e72472ca5dbac44b613b806ed050a41a357b96cf939a525e3cb307 |
28 |
DIST StringiFor-1.1.1.tar.gz 80098 BLAKE2B d42774323703550355b90ce706e62356a30cb4a27a37622841c28bbff9f9504ce7da8997222f6a0bb1e5ec56894ffdd679dc1a5b2a8f8bb353580491554fbce7 SHA512 14639dbb62e2b1ccb9cdb3c8100da7da8ff7d2a06d304bce2a9e8574e52adbd2f589f0017498ce7489f4977acdc99cfc889a5a752bc8efd58da41cea104c0712 |
29 |
+DIST StringiFor-1.1.3.tar.gz 83606 BLAKE2B 5cd00941d2ac8c7fbe501e7fed0747f8c4ae5f61edf336a86ea89f9fd500ee016e97664ca0bbcdbcfd4c007c203fdc4fbbdbef617c0d0d115b5a96dd89b98fbf SHA512 d1a1a7848cec657544ec4fab5517cb19fbf2b8655500c86d2b4dd0fc6bdb143c4929770b0e61c7e2d9c7b5660ca8e7e6cf283bb4744d17ca252cc8e71a08c163 |
30 |
|
31 |
diff --git a/dev-libs/StringiFor/StringiFor-1.1.3.ebuild b/dev-libs/StringiFor/StringiFor-1.1.3.ebuild |
32 |
new file mode 100644 |
33 |
index 000000000..074ba8377 |
34 |
--- /dev/null |
35 |
+++ b/dev-libs/StringiFor/StringiFor-1.1.3.ebuild |
36 |
@@ -0,0 +1,100 @@ |
37 |
+# Copyright 1999-2021 Gentoo Authors |
38 |
+# Distributed under the terms of the GNU General Public License v2 |
39 |
+ |
40 |
+EAPI=7 |
41 |
+ |
42 |
+FORTRAN_STANDARD=2003 |
43 |
+ |
44 |
+inherit fortran-2 toolchain-funcs |
45 |
+ |
46 |
+# Unfortunately the releases don't have appropriate release-tags |
47 |
+# so there commits sha-1 checksum are used |
48 |
+StringiFor_sha="bad95cb8c1ae0f17dd3e15acd6bc2a8cde4bb606" # StringiFor-1.1.3 (18 jun 2021) |
49 |
+BeFoR64_sha="e222ede7f1207f74acafd30c6c6e1d3585b5bb74" # BeFoR-1.1.4_p20201012 (12 oct 2020) |
50 |
+FACE_sha="748688899f73bcb0d2723f5c00e3d0fe13648167" # FACE-1.1.2_p20201005 (5 oct 2020) |
51 |
+PENF_sha="b146a7d6444e0cd8a42a20452a7c4a4f4f16c667" # PENF-1.2.2_20201012 (12 oct 2020) |
52 |
+ |
53 |
+DESCRIPTION="StringiFor, Strings Fortran Manipulator, yet another strings Fortran module" |
54 |
+HOMEPAGE="https://github.com/szaghi/StringiFor" |
55 |
+SRC_URI=" |
56 |
+ https://github.com/szaghi/${PN}/archive/"${StringiFor_sha}".tar.gz -> ${P}.tar.gz |
57 |
+ https://github.com/szaghi/BeFoR64/archive/"${BeFoR64_sha}".tar.gz -> BeFoR64-1.1.4_p20201012.tar.gz |
58 |
+ https://github.com/szaghi/FACE/archive/"${FACE_sha}".tar.gz -> FACE-1.1.2_p20201005.tar.gz |
59 |
+ https://github.com/szaghi/PENF/archive/"${PENF_sha}".tar.gz -> PENF-1.2.2_p20201012.tar.gz |
60 |
+" |
61 |
+ |
62 |
+S="${WORKDIR}/${PN}-${StringiFor_sha}" |
63 |
+ |
64 |
+# For FOSS projects: GPL-3 |
65 |
+# For closed source/commercial projects: BSD 2-Clause, BSD 3-Clause, MIT |
66 |
+LICENSE="GPL-3 BSD-2 BSD MIT" |
67 |
+SLOT="0" |
68 |
+KEYWORDS="~amd64 ~x86" |
69 |
+ |
70 |
+IUSE="static-libs test" |
71 |
+RESTRICT="!test? ( test )" |
72 |
+ |
73 |
+BDEPEND="dev-util/FoBiS" |
74 |
+ |
75 |
+PATCHES=( |
76 |
+ "${FILESDIR}/stringifor-1.1.1_fobos_soname.patch" |
77 |
+ "${FILESDIR}/stringifor-1.1.3_fix_tests.patch" |
78 |
+) |
79 |
+ |
80 |
+set_build_mode() { |
81 |
+ case $(tc-getFC) in |
82 |
+ *gfortran* ) |
83 |
+ BUILD_MODE_SHARED="-mode stringifor-shared-gnu" |
84 |
+ BUILD_MODE_STATIC="-mode stringifor-static-gnu" |
85 |
+ BUILD_MODE_TESTS="-mode tests-gnu" ;; |
86 |
+ *ifort* ) |
87 |
+ BUILD_MODE_SHARED="-mode stringifor-shared-intel" |
88 |
+ BUILD_MODE_STATIC="-mode stringifor-static-intel" |
89 |
+ BUILD_MODE_TESTS="-mode tests-intel" ;; |
90 |
+ * ) |
91 |
+ die "Sorry, GNU gfortran or Intel ifort are currently supported in the ebuild" ;; |
92 |
+ esac |
93 |
+} |
94 |
+ |
95 |
+pkg_setup() { |
96 |
+ fortran-2_pkg_setup |
97 |
+ set_build_mode |
98 |
+} |
99 |
+ |
100 |
+src_prepare() { |
101 |
+ mv -T "${WORKDIR}"/BeFoR64-"${BeFoR64_sha}" "${S}"/src/third_party/BeFoR64 |
102 |
+ mv -T "${WORKDIR}"/FACE-"${FACE_sha}" "${S}"/src/third_party/FACE |
103 |
+ mv -T "${WORKDIR}"/PENF-"${PENF_sha}" "${S}"/src/third_party/PENF |
104 |
+ default |
105 |
+ |
106 |
+ sed -i -e 's:\$OPTIMIZE = -O2:\$OPTIMIZE = '"${FFLAGS}"':' \ |
107 |
+ -e '/^\$LSHARED/s:$: '"${LDFLAGS}"':' fobos || die |
108 |
+} |
109 |
+ |
110 |
+src_compile() { |
111 |
+ FoBiS.py build -verbose -compiler custom -fc $(tc-getFC) ${BUILD_MODE_SHARED} |
112 |
+ use static-libs && FoBiS.py build -verbose -compiler custom -fc $(tc-getFC) ${BUILD_MODE_STATIC} |
113 |
+} |
114 |
+ |
115 |
+src_test() { |
116 |
+ FoBiS.py build -compiler custom -fc $(tc-getFC) ${BUILD_MODE_TESTS} |
117 |
+ for e in $( find ./exe/ -type f -executable -print ); do |
118 |
+ if [ "$e" != "./exe/stringifor_test_parse_large_csv" ] ; then |
119 |
+ echo " run test $e :" && $e |
120 |
+ else |
121 |
+ # The output of this test is too huge so it's cutted here |
122 |
+ echo " run test $e :" && $e | tail -n 10 |
123 |
+ fi |
124 |
+ done |
125 |
+} |
126 |
+ |
127 |
+src_install() { |
128 |
+ mv lib/mod lib/stringifor |
129 |
+ doheader -r lib/stringifor/ |
130 |
+ |
131 |
+ mv lib/libstringifor.so{,.1} |
132 |
+ dosym libstringifor.so.1 /usr/$(get_libdir)/libstringifor.so |
133 |
+ dolib.so lib/libstringifor.so.1 |
134 |
+ |
135 |
+ use static-libs && dolib.a lib/libstringifor.a |
136 |
+} |
137 |
|
138 |
diff --git a/dev-libs/StringiFor/files/stringifor-1.1.3_fix_tests.patch b/dev-libs/StringiFor/files/stringifor-1.1.3_fix_tests.patch |
139 |
new file mode 100644 |
140 |
index 000000000..7eb7460e6 |
141 |
--- /dev/null |
142 |
+++ b/dev-libs/StringiFor/files/stringifor-1.1.3_fix_tests.patch |
143 |
@@ -0,0 +1,22 @@ |
144 |
+diff -Naur a/src/third_party/FACE/src/tests/face_test_ucs4.F90 b/src/third_party/FACE/src/tests/face_test_ucs4.F90 |
145 |
+--- a/src/third_party/FACE/src/tests/face_test_ucs4.F90 |
146 |
++++ b/src/third_party/FACE/src/tests/face_test_ucs4.F90 |
147 |
+@@ -2,9 +2,10 @@ |
148 |
+ program face_test_ucs4 |
149 |
+ !< FACE test. |
150 |
+ use face |
151 |
++use iso_fortran_env |
152 |
+ |
153 |
+ implicit none |
154 |
+-#ifdef UCS4_SUPPORTED |
155 |
++ |
156 |
+ character(kind=UCS4, len=:), allocatable :: string_1 !< A string. |
157 |
+ character(kind=UCS4, len=:), allocatable :: string_2 !< A string. |
158 |
+ character(kind=UCS4, len=:), allocatable :: string_3 !< A string. |
159 |
+@@ -13,5 +14,5 @@ |
160 |
+ string_2 = colorize(UCS4_' ÜÇŞ4', color_fg='red') |
161 |
+ string_3 = colorize(' World', color_fg='blue') |
162 |
+ print '(A)', string_1//string_2//string_3 |
163 |
+-#endif |
164 |
++ |
165 |
+ endprogram face_test_ucs4 |