1 |
commit: 87d9cf08f438478856d352c15b7096998928c4de |
2 |
Author: Alexey Shvetsov <alexxy <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Oct 8 10:54:03 2020 +0000 |
4 |
Commit: Alexey Shvetsov <alexxy <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Oct 8 10:54:03 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=87d9cf08 |
7 |
|
8 |
sci-chemistry/modeller: Version bump |
9 |
|
10 |
Package-Manager: Portage-3.0.8, Repoman-3.0.1 |
11 |
Signed-off-by: Alexey Shvetsov <alexxy <AT> gentoo.org> |
12 |
|
13 |
sci-chemistry/modeller/files/9v5-setup.patch | 12 - |
14 |
.../modeller/files/modeller-9.25-convert2to3.patch | 702 +++++++++++++++++++++ |
15 |
sci-chemistry/modeller/modeller-9.19.ebuild | 145 ----- |
16 |
...odeller-9.12-r3.ebuild => modeller-9.25.ebuild} | 16 +- |
17 |
4 files changed, 712 insertions(+), 163 deletions(-) |
18 |
|
19 |
diff --git a/sci-chemistry/modeller/files/9v5-setup.patch b/sci-chemistry/modeller/files/9v5-setup.patch |
20 |
deleted file mode 100644 |
21 |
index 5fe460580..000000000 |
22 |
--- a/sci-chemistry/modeller/files/9v5-setup.patch |
23 |
+++ /dev/null |
24 |
@@ -1,12 +0,0 @@ |
25 |
-diff -Nu -Nu -uarN modeller-9v3.orig/src/swig/setup.py modeller-9v3/src/swig/setup.py |
26 |
---- modeller-9v4.orig/src/swig/setup.py 2008-04-15 12:57:50.000000000 +0200 |
27 |
-+++ modeller-9v4/src/swig/setup.py 2008-04-15 12:57:59.000000000 +0200 |
28 |
-@@ -19,7 +19,7 @@ |
29 |
- include_dirs=['../include', '../include/%s' % exetype] + \ |
30 |
- glib['include_dirs'], |
31 |
- libraries=['modeller'] + glib['libraries'], |
32 |
-- library_dirs=['../../lib/%s' % exetype] + glib['library_dirs']) |
33 |
-+ library_dirs=['../../lib/%s' % exetype]) |
34 |
- |
35 |
- setup(name='Modeller', |
36 |
- description='Protein structure modeling by satisfaction of ' \ |
37 |
|
38 |
diff --git a/sci-chemistry/modeller/files/modeller-9.25-convert2to3.patch b/sci-chemistry/modeller/files/modeller-9.25-convert2to3.patch |
39 |
new file mode 100644 |
40 |
index 000000000..d7df05ce6 |
41 |
--- /dev/null |
42 |
+++ b/sci-chemistry/modeller/files/modeller-9.25-convert2to3.patch |
43 |
@@ -0,0 +1,702 @@ |
44 |
+--- modeller-9.25/modlib/modeller/__init__.py (original) |
45 |
++++ modeller-9.25/modlib/modeller/__init__.py (refactored) |
46 |
+@@ -48,7 +48,7 @@ |
47 |
+ return sys.maxsize > 2**32 |
48 |
+ # This works on older Pythons, but not in Python 3 |
49 |
+ else: |
50 |
+- return type(sys.dllhandle) == long |
51 |
++ return type(sys.dllhandle) == int |
52 |
+ |
53 |
+ # Special processing on Windows to find _modeller.pyd and Modeller DLLs: |
54 |
+ if hasattr(config, 'install_dir') and hasattr(sys, 'dllhandle'): |
55 |
+--- modeller-9.25/modlib/modeller/coordinates.py (original) |
56 |
++++ modeller-9.25/modlib/modeller/coordinates.py (refactored) |
57 |
+@@ -147,7 +147,7 @@ |
58 |
+ (startres, endres) = self._get_resind() |
59 |
+ (startatm, endatm) = get_residue_atom_indices(self.seq, startres, |
60 |
+ endres) |
61 |
+- return (range(startatm+1, endatm+1), self.seq) |
62 |
++ return (list(range(startatm+1, endatm+1)), self.seq) |
63 |
+ |
64 |
+ atoms = property(__get_atoms, doc="List of all atoms in this chain") |
65 |
+ |
66 |
+@@ -158,7 +158,7 @@ |
67 |
+ def get_atom_indices(self): |
68 |
+ (startind, endind) = get_residue_atom_indices(self.mdl, self._num, |
69 |
+ self._num + 1) |
70 |
+- return range(startind + 1, endind + 1), self.mdl |
71 |
++ return list(range(startind + 1, endind + 1)), self.mdl |
72 |
+ |
73 |
+ def __repr__(self): |
74 |
+ # Get residue number before we do anything else. For alignment |
75 |
+@@ -252,7 +252,7 @@ |
76 |
+ def get_atom_indices(self): |
77 |
+ (startind, endind) = get_residue_atom_indices(self.mdl, self.offset, |
78 |
+ self.offset + len(self)) |
79 |
+- return range(startind + 1, endind + 1), self.mdl |
80 |
++ return list(range(startind + 1, endind + 1)), self.mdl |
81 |
+ |
82 |
+ def __getitem__(self, indx): |
83 |
+ ret = modutil.handle_seq_indx(self, indx, self.mdl._indxres, |
84 |
+@@ -398,7 +398,7 @@ |
85 |
+ return self.mdl.natm |
86 |
+ |
87 |
+ def get_atom_indices(self): |
88 |
+- return range(self.offset + 1, self.offset + len(self) + 1), self.mdl |
89 |
++ return list(range(self.offset + 1, self.offset + len(self) + 1)), self.mdl |
90 |
+ |
91 |
+ def __getitem__(self, indx): |
92 |
+ ret = modutil.handle_seq_indx(self, indx, self.mdl._indxatm, |
93 |
+--- modeller-9.25/modlib/modeller/id_table.py (original) |
94 |
++++ modeller-9.25/modlib/modeller/id_table.py (refactored) |
95 |
+@@ -40,7 +40,7 @@ |
96 |
+ def write_seqid_matrix(fh, coder, mat): |
97 |
+ """Write a sequence identity matrix to a file""" |
98 |
+ nseq = len(mat) |
99 |
+- print(" " * 9 + "".join([ s[:8] for s in coder ])) |
100 |
++ print((" " * 9 + "".join([ s[:8] for s in coder ]))) |
101 |
+ for n1 in range(nseq): |
102 |
+ fh.write(coder[n1][:8] + " " + \ |
103 |
+ "".join(["%8d" % (mat[n1][n2]+0.5) for n2 in range(nseq)])) |
104 |
+--- modeller-9.25/modlib/modeller/libraries.py (original) |
105 |
++++ modeller-9.25/modlib/modeller/libraries.py (refactored) |
106 |
+@@ -32,7 +32,7 @@ |
107 |
+ return BytesIO(*args) |
108 |
+ else: |
109 |
+ def _make_bytes_io(self, *args): |
110 |
+- from cStringIO import StringIO |
111 |
++ from io import StringIO |
112 |
+ return StringIO(*args) |
113 |
+ |
114 |
+ def __getstate__(self): |
115 |
+--- modeller-9.25/modlib/modeller/model.py (original) |
116 |
++++ modeller-9.25/modlib/modeller/model.py (refactored) |
117 |
+@@ -121,7 +121,7 @@ |
118 |
+ |
119 |
+ def get_atom_indices(self): |
120 |
+ """Get the indices of all atoms in this model""" |
121 |
+- return (range(1, self.natm+1), self) |
122 |
++ return (list(range(1, self.natm+1)), self) |
123 |
+ |
124 |
+ def read(self, file, model_format='PDB', |
125 |
+ model_segment=('FIRST:@', 'LAST:'), io=None, |
126 |
+@@ -340,7 +340,7 @@ |
127 |
+ dope_score = sel.assess_dope() |
128 |
+ scorer = normalized_dope.DOPEScorer(self) |
129 |
+ z_score = scorer.get_z_score(dope_score) |
130 |
+- print(">> Normalized DOPE z score: %.3f" % z_score) |
131 |
++ print((">> Normalized DOPE z score: %.3f" % z_score)) |
132 |
+ return z_score |
133 |
+ |
134 |
+ def assess_normalized_dopehr(self): |
135 |
+@@ -351,7 +351,7 @@ |
136 |
+ dope_score = sel.assess_dopehr() |
137 |
+ scorer = normalized_dope.DOPEHRScorer(self) |
138 |
+ z_score = scorer.get_z_score(dope_score) |
139 |
+- print(">> Normalized DOPE-HR z score: %.3f" % z_score) |
140 |
++ print((">> Normalized DOPE-HR z score: %.3f" % z_score)) |
141 |
+ return z_score |
142 |
+ |
143 |
+ def get_normalized_dope_profile(self): |
144 |
+--- modeller-9.25/modlib/modeller/model_topology.py (original) |
145 |
++++ modeller-9.25/modlib/modeller/model_topology.py (refactored) |
146 |
+@@ -50,7 +50,7 @@ |
147 |
+ self.check_args = args |
148 |
+ def __iter__(self): |
149 |
+ return self |
150 |
+- def next(self): |
151 |
++ def __next__(self): |
152 |
+ while True: |
153 |
+ atoms = self.__int_next() |
154 |
+ if self.check_func is None \ |
155 |
+@@ -82,7 +82,7 @@ |
156 |
+ self.check_args = args |
157 |
+ def __iter__(self): |
158 |
+ return self |
159 |
+- def next(self): |
160 |
++ def __next__(self): |
161 |
+ while True: |
162 |
+ atoms = self.__int_next() |
163 |
+ if self.check_func is None \ |
164 |
+--- modeller-9.25/modlib/modeller/physical.py (original) |
165 |
++++ modeller-9.25/modlib/modeller/physical.py (refactored) |
166 |
+@@ -31,7 +31,7 @@ |
167 |
+ def __init__(self, default=1.0, **keys): |
168 |
+ self._default = default |
169 |
+ self._dict = {} |
170 |
+- for (term,val) in keys.items(): |
171 |
++ for (term,val) in list(keys.items()): |
172 |
+ term = eval("%s" % term) |
173 |
+ self[term] = val |
174 |
+ |
175 |
+--- modeller-9.25/modlib/modeller/salign.py (original) |
176 |
++++ modeller-9.25/modlib/modeller/salign.py (refactored) |
177 |
+@@ -38,8 +38,8 @@ |
178 |
+ return aln.salign(auto_overhang=True, overhang_auto_limit=5, |
179 |
+ overhang_factor=1, **keys) |
180 |
+ except modeller.ModellerError: |
181 |
+- print("SALIGN with auto_overhang failed: %s" \ |
182 |
+- % str(sys.exc_info()[1])) |
183 |
++ print(("SALIGN with auto_overhang failed: %s" \ |
184 |
++ % str(sys.exc_info()[1]))) |
185 |
+ print("Retrying without auto_overhang") |
186 |
+ return aln.salign(**keys) |
187 |
+ |
188 |
+@@ -118,13 +118,13 @@ |
189 |
+ self.qscore = res.qscorepct |
190 |
+ self.aln.write(file=output_aln_file, alignment_format='PIR') |
191 |
+ better = True |
192 |
+- print("Qlty scrs %g\t%g\t%g" % (open_penalty, extend_penalty, |
193 |
+- res.qscorepct)) |
194 |
++ print(("Qlty scrs %g\t%g\t%g" % (open_penalty, extend_penalty, |
195 |
++ res.qscorepct))) |
196 |
+ except modeller.ModellerError: |
197 |
+- print("Set of parameters %s %g %g resulted in the " |
198 |
++ print(("Set of parameters %s %g %g resulted in the " |
199 |
+ "following error\t%s" % (str(weights), open_penalty, |
200 |
+ extend_penalty, |
201 |
+- str(sys.exc_info()[1]))) |
202 |
++ str(sys.exc_info()[1])))) |
203 |
+ return better |
204 |
+ |
205 |
+ |
206 |
+@@ -181,7 +181,7 @@ |
207 |
+ best.try_struc_align(opfile, opfile2, fw2, ogp3d, egp3d, |
208 |
+ align_block) |
209 |
+ |
210 |
+- print("final max quality = %g" % best.qscore) |
211 |
++ print(("final max quality = %g" % best.qscore)) |
212 |
+ |
213 |
+ if best.found_struc_align: |
214 |
+ aln.clear() |
215 |
+--- modeller-9.25/modlib/modeller/saxsdata.py (original) |
216 |
++++ modeller-9.25/modlib/modeller/saxsdata.py (refactored) |
217 |
+@@ -206,7 +206,7 @@ |
218 |
+ try: |
219 |
+ fh = open(saxsfilename,'r') |
220 |
+ except: |
221 |
+- print("file "+saxsfilename+" not found :(") |
222 |
++ print(("file "+saxsfilename+" not found :(")) |
223 |
+ return |
224 |
+ fh.close() |
225 |
+ ns = 0 |
226 |
+@@ -225,8 +225,8 @@ |
227 |
+ s_low = s_min - .001 |
228 |
+ if (not s_hi): |
229 |
+ s_hi = s_max + .001 |
230 |
+- print("s_min=%s, s_max=%s" % (str(s_min), str(s_max))) |
231 |
+- print("s_low=%s, s_hi=%s" % (str(s_low), str(s_hi))) |
232 |
++ print(("s_min=%s, s_max=%s" % (str(s_min), str(s_max)))) |
233 |
++ print(("s_low=%s, s_hi=%s" % (str(s_low), str(s_hi)))) |
234 |
+ self.ini_saxs(atmsel, |
235 |
+ filename=formfacfilename, |
236 |
+ s_min=s_min, s_max=s_max, maxs=ns, nmesh=ns, natomtyp=natomtyp, |
237 |
+--- modeller-9.25/modlib/modeller/selection.py (original) |
238 |
++++ modeller-9.25/modlib/modeller/selection.py (refactored) |
239 |
+@@ -23,7 +23,7 @@ |
240 |
+ return self.mdl.atoms[obj - 1] |
241 |
+ else: |
242 |
+ def next(self): |
243 |
+- obj = self.seliter.next() |
244 |
++ obj = next(self.seliter) |
245 |
+ return self.mdl.atoms[obj - 1] |
246 |
+ |
247 |
+ class selection(object): |
248 |
+@@ -52,7 +52,7 @@ |
249 |
+ :rtype: list of ints |
250 |
+ """ |
251 |
+ if sys.version_info[:2] == (2,3): |
252 |
+- keys = self.__selection.keys() |
253 |
++ keys = list(self.__selection.keys()) |
254 |
+ keys.sort() |
255 |
+ else: |
256 |
+ keys = sorted(self.__selection.keys()) |
257 |
+@@ -722,9 +722,9 @@ |
258 |
+ def assess(self, assessor, output='SHORT NO_REPORT', **vars): |
259 |
+ """Assess with the given assessor object |
260 |
+ (e.g. :class:`soap_loop.Scorer`).""" |
261 |
+- print(">> Model assessment by %s" % assessor.name) |
262 |
++ print((">> Model assessment by %s" % assessor.name)) |
263 |
+ molpdf, terms = assessor._assess(self, output=output, **vars) |
264 |
+- print("%s : %12.6f" % (assessor.name, molpdf)) |
265 |
++ print(("%s : %12.6f" % (assessor.name, molpdf))) |
266 |
+ return molpdf |
267 |
+ |
268 |
+ def _dope_energy(self, gprsr, name, output='SHORT NO_REPORT', |
269 |
+@@ -733,7 +733,7 @@ |
270 |
+ nonbond_spline=1.), **vars): |
271 |
+ """Internal function to do DOPE or DOPE-HR assessment""" |
272 |
+ mdl = self.__mdl |
273 |
+- print(">> Model assessment by %s potential" % name) |
274 |
++ print((">> Model assessment by %s potential" % name)) |
275 |
+ edat = self.get_dope_energy_data() |
276 |
+ old_gprsr = mdl.group_restraints |
277 |
+ mdl.group_restraints = gprsr |
278 |
+@@ -744,7 +744,7 @@ |
279 |
+ **vars) |
280 |
+ finally: |
281 |
+ mdl.group_restraints = old_gprsr |
282 |
+- print("%s score : %12.6f" % (name, molpdf)) |
283 |
++ print(("%s score : %12.6f" % (name, molpdf))) |
284 |
+ return molpdf |
285 |
+ |
286 |
+ def debug_function(self, residue_span_range=(0, 99999), |
287 |
+--- modeller-9.25/modlib/modeller/test.py (original) |
288 |
++++ modeller-9.25/modlib/modeller/test.py (refactored) |
289 |
+@@ -2,7 +2,7 @@ |
290 |
+ import modeller |
291 |
+ import math |
292 |
+ try: |
293 |
+- from cStringIO import StringIO |
294 |
++ from io import StringIO |
295 |
+ except ImportError: |
296 |
+ from io import StringIO |
297 |
+ import sys |
298 |
+@@ -150,7 +150,7 @@ |
299 |
+ diff = abs(num1 - num2) |
300 |
+ if msg is None: |
301 |
+ msg = "%f != %f within %g" % (num1, num2, tolerance) |
302 |
+- self.assert_(diff < tolerance, msg) |
303 |
++ self.assertTrue(diff < tolerance, msg) |
304 |
+ |
305 |
+ def run_capture_stdout(self, method, *args, **keys): |
306 |
+ """Run a method and capture its standard output. Returns both the |
307 |
+--- modeller-9.25/modlib/modeller/automodel/automodel.py (original) |
308 |
++++ modeller-9.25/modlib/modeller/automodel/automodel.py (refactored) |
309 |
+@@ -203,13 +203,13 @@ |
310 |
+ |
311 |
+ def write_ok_summary(self, all, modeltyp): |
312 |
+ """Print out a summary of all successfully generated models""" |
313 |
+- print("\n>> Summary of successfully produced %s:" % modeltyp) |
314 |
+- fields = [x for x in all[0].keys() if x.endswith(' score')] |
315 |
++ print(("\n>> Summary of successfully produced %s:" % modeltyp)) |
316 |
++ fields = [x for x in list(all[0].keys()) if x.endswith(' score')] |
317 |
+ fields.sort() |
318 |
+ fields = ['molpdf'] + fields |
319 |
+ header = '%-25s ' % 'Filename' + " ".join(['%14s' % x for x in fields]) |
320 |
+ print(header) |
321 |
+- print('-' * len(header)) |
322 |
++ print(('-' * len(header))) |
323 |
+ for mdl in all: |
324 |
+ text = '%-25s' % mdl['name'] |
325 |
+ for field in fields: |
326 |
+@@ -222,9 +222,9 @@ |
327 |
+ |
328 |
+ def write_failure_summary(self, all, modeltyp): |
329 |
+ """Print out a summary of all failed models""" |
330 |
+- print("\n>> Summary of failed %s:" % modeltyp) |
331 |
++ print(("\n>> Summary of failed %s:" % modeltyp)) |
332 |
+ for mdl in all: |
333 |
+- print("%-25s %s" % (mdl['name'], mdl['failure'])) |
334 |
++ print(("%-25s %s" % (mdl['name'], mdl['failure']))) |
335 |
+ print('') |
336 |
+ |
337 |
+ def rd_restraints(self): |
338 |
+@@ -692,8 +692,8 @@ |
339 |
+ elif atmsel.get_model() is not self: |
340 |
+ raise ModellerError("selection is defined on the wrong model") |
341 |
+ elif len(atmsel) < len(self.atoms): |
342 |
+- print("%d (of %d total) atoms selected for optimization" \ |
343 |
+- % (len(atmsel), len(self.atoms))) |
344 |
++ print(("%d (of %d total) atoms selected for optimization" \ |
345 |
++ % (len(atmsel), len(self.atoms)))) |
346 |
+ return atmsel |
347 |
+ |
348 |
+ def mkhomcsr(self, atmsel, aln): |
349 |
+@@ -774,9 +774,9 @@ |
350 |
+ selstd = selection(self).only_std_residues() |
351 |
+ selca = selstd.only_atom_types('CA') |
352 |
+ |
353 |
+- print("%d atoms in HETATM/BLK residues constrained\n" % len(selhet) \ |
354 |
++ print(("%d atoms in HETATM/BLK residues constrained\n" % len(selhet) \ |
355 |
+ + "to protein atoms within %.2f angstroms\n" % bond_distance \ |
356 |
+- + "and protein CA atoms within %.2f angstroms" % ca_distance) |
357 |
++ + "and protein CA atoms within %.2f angstroms" % ca_distance)) |
358 |
+ # Build the bonds first; this avoids duplicated CA-ligand bonds since |
359 |
+ # make_distance() will not build restraints that are already on the |
360 |
+ # nonbond exclusion list |
361 |
+@@ -823,8 +823,8 @@ |
362 |
+ selhet = selhet.only_no_topology() |
363 |
+ |
364 |
+ # Intra-residue: |
365 |
+- print("%d atoms in residues without defined topology\n" % len(selhet) \ |
366 |
+- + "constrained to be rigid bodies") |
367 |
++ print(("%d atoms in residues without defined topology\n" % len(selhet) \ |
368 |
++ + "constrained to be rigid bodies")) |
369 |
+ rsr = self.restraints |
370 |
+ rsr.make_distance(selhet, selhet, aln=aln, |
371 |
+ distance_rsr_model=7, maximal_distance=10.0, |
372 |
+@@ -898,8 +898,8 @@ |
373 |
+ print("\nThe following CHARMM atom type assignments were made:") |
374 |
+ print(" Atom Old type New type") |
375 |
+ for atom, old_type, new_type in zip(sel, old_types, new_types): |
376 |
+- print(" %-20s %-15s %-15s" |
377 |
+- % (str(atom), fmt_typ(old_type), fmt_typ(new_type))) |
378 |
++ print((" %-20s %-15s %-15s" |
379 |
++ % (str(atom), fmt_typ(old_type), fmt_typ(new_type)))) |
380 |
+ |
381 |
+ def select_atoms(self): |
382 |
+ """Select atoms to be optimized in the model building procedure. By |
383 |
+--- modeller-9.25/modlib/modeller/automodel/generate.py (original) |
384 |
++++ modeller-9.25/modlib/modeller/automodel/generate.py (refactored) |
385 |
+@@ -88,11 +88,11 @@ |
386 |
+ to_rebuild.append(r) |
387 |
+ _unbuild_ring(r, ring_atoms + extra_atoms) |
388 |
+ if len(to_rebuild) > 0: |
389 |
+- print("The following %d residues contain 6-membered rings with " |
390 |
++ print(("The following %d residues contain 6-membered rings with " |
391 |
+ "poor geometries\nafter transfer from templates. Rebuilding " |
392 |
+ "rings from internal coordinates:\n %s" \ |
393 |
+ % (len(to_rebuild), |
394 |
+- "\n ".join([str(r) for r in to_rebuild]))) |
395 |
++ "\n ".join([str(r) for r in to_rebuild])))) |
396 |
+ mdl.build(initialize_xyz=False, build_method='INTERNAL_COORDINATES') |
397 |
+ |
398 |
+ def read_xyz(mdl, aln): |
399 |
+--- modeller-9.25/modlib/modeller/automodel/loopmodel.py (original) |
400 |
++++ modeller-9.25/modlib/modeller/automodel/loopmodel.py (refactored) |
401 |
+@@ -105,7 +105,7 @@ |
402 |
+ lendef = len(self._defined_indices) |
403 |
+ if lenall > lendef: |
404 |
+ s = selection(self) - s |
405 |
+- print(""" |
406 |
++ print((""" |
407 |
+ The following %d atoms were not found in the input model's non-loop region, |
408 |
+ and were added automatically by Modeller in order to determine correct |
409 |
+ interactions between the loop and the rest of the protein: |
410 |
+@@ -115,7 +115,7 @@ |
411 |
+ rest of the protein may exist (note, however, that the score of the loop does |
412 |
+ not include protein-protein internal interactions, so will not be adversely |
413 |
+ affected by any clashes).""" \ |
414 |
+-% (lenall - lendef, ", ".join([repr(a) for a in s]))) |
415 |
++% (lenall - lendef, ", ".join([repr(a) for a in s])))) |
416 |
+ |
417 |
+ if self.loop.write_defined_only: |
418 |
+ print(""" |
419 |
+@@ -406,7 +406,7 @@ |
420 |
+ elif len(atmsel.only_no_topology()) > 0: |
421 |
+ raise ModellerError("some selected residues have no topology") |
422 |
+ else: |
423 |
+- print("%d atoms selected for loop refinement" % len(atmsel)) |
424 |
++ print(("%d atoms selected for loop refinement" % len(atmsel))) |
425 |
+ return atmsel |
426 |
+ |
427 |
+ def optimize_loop(self, atmsel, sched, actions): |
428 |
+--- modeller-9.25/modlib/modeller/mmcif/writer.py (original) |
429 |
++++ modeller-9.25/modlib/modeller/mmcif/writer.py (refactored) |
430 |
+@@ -4,7 +4,7 @@ |
431 |
+ # which works as far back as 2.3, so imports need to be protected by a |
432 |
+ # version check |
433 |
+ |
434 |
+-from __future__ import print_function |
435 |
++ |
436 |
+ import sys |
437 |
+ import textwrap |
438 |
+ |
439 |
+@@ -12,7 +12,7 @@ |
440 |
+ if sys.version_info[0] >= 3: |
441 |
+ _long_type = int |
442 |
+ else: |
443 |
+- _long_type = long |
444 |
++ _long_type = int |
445 |
+ |
446 |
+ class _LineWriter(object): |
447 |
+ def __init__(self, writer, line_len=80): |
448 |
+--- modeller-9.25/modlib/modeller/optimizers/builtin_optimizer.py (original) |
449 |
++++ modeller-9.25/modlib/modeller/optimizers/builtin_optimizer.py (refactored) |
450 |
+@@ -9,7 +9,7 @@ |
451 |
+ # delete the key entirely, as __getstate__ must return a non-empty |
452 |
+ # dict in order for our __setstate__ method to be called). |
453 |
+ d = self.__dict__.copy() |
454 |
+- for key in self.__dict__.keys(): |
455 |
++ for key in list(self.__dict__.keys()): |
456 |
+ if key.endswith("_modpt") or key.endswith("__optpt"): |
457 |
+ d[key] = None |
458 |
+ return d |
459 |
+@@ -21,7 +21,7 @@ |
460 |
+ vars = params.copy() |
461 |
+ self._update_params(vars, ok_keys, extravars) |
462 |
+ for key in ok_keys: |
463 |
+- if key not in vars.keys() \ |
464 |
++ if key not in list(vars.keys()) \ |
465 |
+ and key not in ("edat", "libs", "actions", "schedule_scale"): |
466 |
+ raise ValueError("a value must be given for %s" % key) |
467 |
+ |
468 |
+--- modeller-9.25/modlib/modeller/optimizers/optimizer.py (original) |
469 |
++++ modeller-9.25/modlib/modeller/optimizers/optimizer.py (refactored) |
470 |
+@@ -10,7 +10,7 @@ |
471 |
+ return self.atmsel |
472 |
+ |
473 |
+ def _update_params(self, params, ok_keys, vars): |
474 |
+- for key in vars.keys(): |
475 |
++ for key in list(vars.keys()): |
476 |
+ if key in ok_keys: |
477 |
+ params[key] = vars[key] |
478 |
+ else: |
479 |
+--- modeller-9.25/modlib/modeller/parallel/data_types.py (original) |
480 |
++++ modeller-9.25/modlib/modeller/parallel/data_types.py (refactored) |
481 |
+@@ -3,7 +3,7 @@ |
482 |
+ import sys |
483 |
+ |
484 |
+ try: |
485 |
+- import cPickle as pickle |
486 |
++ import pickle as pickle |
487 |
+ except ImportError: |
488 |
+ import pickle |
489 |
+ |
490 |
+--- modeller-9.25/modlib/modeller/parallel/job.py (original) |
491 |
++++ modeller-9.25/modlib/modeller/parallel/job.py (refactored) |
492 |
+@@ -106,7 +106,7 @@ |
493 |
+ if id and id in pending_slaves: |
494 |
+ slave = pending_slaves.pop(id) |
495 |
+ connected_slaves[id] = slave |
496 |
+- print("Identified slave %s " % str(slave)) |
497 |
++ print(("Identified slave %s " % str(slave))) |
498 |
+ slave.accept_connection(sock) |
499 |
+ slave.set_directory(self.cwd) |
500 |
+ if sys.path[0] != '': |
501 |
+@@ -117,7 +117,7 @@ |
502 |
+ return slave |
503 |
+ elif id and id in connected_slaves: |
504 |
+ slave = connected_slaves[id] |
505 |
+- print("Reconnect from slave %s " % str(slave)) |
506 |
++ print(("Reconnect from slave %s " % str(slave))) |
507 |
+ slave.accept_connection(sock) |
508 |
+ else: |
509 |
+ print("Ignoring request from unknown slave") |
510 |
+@@ -159,7 +159,7 @@ |
511 |
+ """Run all tasks and return all the results, in the same order that they |
512 |
+ were submitted, when all the jobs have completed.""" |
513 |
+ tasks = self.tasks[:] |
514 |
+- print("Running %d tasks on %d slaves" % (len(tasks), len(self))) |
515 |
++ print(("Running %d tasks on %d slaves" % (len(tasks), len(self)))) |
516 |
+ self.push_tasks_to_slaves() |
517 |
+ while True: |
518 |
+ try: |
519 |
+@@ -174,7 +174,7 @@ |
520 |
+ def yield_tasks_unordered(self): |
521 |
+ """Run all tasks and return their results (as a generator), in |
522 |
+ whatever order they complete.""" |
523 |
+- print("Running %d tasks on %d slaves" % (len(self.tasks), len(self))) |
524 |
++ print(("Running %d tasks on %d slaves" % (len(self.tasks), len(self)))) |
525 |
+ self.push_tasks_to_slaves() |
526 |
+ while True: |
527 |
+ try: |
528 |
+@@ -215,7 +215,7 @@ |
529 |
+ task = obj.task_results() |
530 |
+ if task: |
531 |
+ # The slave completed its task |
532 |
+- print("%s on %s completed" % (str(task), str(obj))) |
533 |
++ print(("%s on %s completed" % (str(task), str(obj)))) |
534 |
+ if len(self.tasks) > 0: |
535 |
+ obj.run_task(self.tasks.pop(0)) |
536 |
+ return task |
537 |
+@@ -225,14 +225,14 @@ |
538 |
+ except (NetworkError, TaskSetupError): |
539 |
+ self.kill_slaves((obj,), sys.exc_info()[1]) |
540 |
+ else: |
541 |
+- print("Warning: slave %s reports data, but is not running a task" \ |
542 |
+- % str(obj)) |
543 |
++ print(("Warning: slave %s reports data, but is not running a task" \ |
544 |
++ % str(obj))) |
545 |
+ |
546 |
+ def kill_slaves(self, slaves, err=""): |
547 |
+ if err != "": |
548 |
+ err = "(%s) " % err |
549 |
+ for s in slaves: |
550 |
+- print("%s failed %s- removing from %s" % (s, err, self)) |
551 |
++ print(("%s failed %s- removing from %s" % (s, err, self))) |
552 |
+ task = s.kill() |
553 |
+ if task: |
554 |
+ self.tasks.append(task) |
555 |
+@@ -248,8 +248,8 @@ |
556 |
+ timedout = [a for a in self if a.running_task() and \ |
557 |
+ a.contact_timeout(self.heartbeat_timeout)] |
558 |
+ if len(timedout) > 0: |
559 |
+- print("Did not hear from slaves %s in %d seconds" % \ |
560 |
+- (str(timedout), self.heartbeat_timeout)) |
561 |
++ print(("Did not hear from slaves %s in %d seconds" % \ |
562 |
++ (str(timedout), self.heartbeat_timeout))) |
563 |
+ self.kill_slaves(timedout) |
564 |
+ |
565 |
+ def push_tasks_to_slaves(self): |
566 |
+@@ -264,8 +264,8 @@ |
567 |
+ slave.run_task(t) |
568 |
+ # If a network error occurred, kill the slave and requeue the task |
569 |
+ except socket.error: |
570 |
+- print("slave %s failed on run task with %s; removing from job" \ |
571 |
+- % (slave, sys.exc_info()[1])) |
572 |
++ print(("slave %s failed on run task with %s; removing from job" \ |
573 |
++ % (slave, sys.exc_info()[1]))) |
574 |
+ slave.kill() |
575 |
+ self.tasks.insert(0, t) |
576 |
+ self.expand_for_tasks() |
577 |
+--- modeller-9.25/modlib/modeller/parallel/myspawn.py (original) |
578 |
++++ modeller-9.25/modlib/modeller/parallel/myspawn.py (refactored) |
579 |
+@@ -10,7 +10,7 @@ |
580 |
+ ``output``.""" |
581 |
+ |
582 |
+ fp = open(output, "w") |
583 |
+- print("%s >& %s" % (cmd, output)) |
584 |
++ print(("%s >& %s" % (cmd, output))) |
585 |
+ if sys.platform == 'win32': |
586 |
+ _myspawn_win32(cmd, fp) |
587 |
+ else: |
588 |
+@@ -27,4 +27,4 @@ |
589 |
+ # Ignore Windows "file not found" errors, so that behavior is consistent |
590 |
+ # between Unix and Windows |
591 |
+ except WindowsError: |
592 |
+- print("WindowsError: %s (ignored)" % sys.exc_info()[1]) |
593 |
++ print(("WindowsError: %s (ignored)" % sys.exc_info()[1])) |
594 |
+--- modeller-9.25/modlib/modeller/parallel/sge_qsub_array.py (original) |
595 |
++++ modeller-9.25/modlib/modeller/parallel/sge_qsub_array.py (refactored) |
596 |
+@@ -36,7 +36,7 @@ |
597 |
+ outlines = output.readlines() |
598 |
+ output.close() |
599 |
+ for line in outlines: |
600 |
+- print(line.rstrip('\r\n')) |
601 |
++ print((line.rstrip('\r\n'))) |
602 |
+ a.require_clean_exit() |
603 |
+ self._set_jobid(outlines) |
604 |
+ |
605 |
+--- modeller-9.25/modlib/modeller/parallel/sge_qsub_slave.py (original) |
606 |
++++ modeller-9.25/modlib/modeller/parallel/sge_qsub_slave.py (refactored) |
607 |
+@@ -38,7 +38,7 @@ |
608 |
+ qsub = "qsub -S /bin/sh -o '%s' -N '%s' %s %s" % \ |
609 |
+ (output, name, self.standard_options, self._options) |
610 |
+ cmd = "%s -slave %s" % (path, id) |
611 |
+- print("%s | %s" % (cmd, qsub)) |
612 |
++ print(("%s | %s" % (cmd, qsub))) |
613 |
+ a = MyPopen4(qsub) |
614 |
+ (input, output) = (a.stdin, a.stdout) |
615 |
+ input.write(cmd + '\n') |
616 |
+@@ -46,7 +46,7 @@ |
617 |
+ outlines = output.readlines() |
618 |
+ output.close() |
619 |
+ for line in outlines: |
620 |
+- print(line.rstrip('\r\n')) |
621 |
++ print((line.rstrip('\r\n'))) |
622 |
+ a.require_clean_exit() |
623 |
+ self._set_jobid(outlines) |
624 |
+ |
625 |
+--- modeller-9.25/modlib/modeller/parallel/slaveloop.py (original) |
626 |
++++ modeller-9.25/modlib/modeller/parallel/slaveloop.py (refactored) |
627 |
+@@ -51,14 +51,14 @@ |
628 |
+ master.send_data(communicator.ErrorWrapper(detail)) |
629 |
+ except socket.error: |
630 |
+ detail2 = sys.exc_info()[1] |
631 |
+- print("Warning: ignored exception " + str(detail2) \ |
632 |
++ print(("Warning: ignored exception " + str(detail2) \ |
633 |
+ + " when trying to send error state " \ |
634 |
+- + str(detail) + " back to master") |
635 |
++ + str(detail) + " back to master")) |
636 |
+ raise detail |
637 |
+ raise |
638 |
+ |
639 |
+ def run(self): |
640 |
+- print("Slave startup: connect to master at %s" % self.addr) |
641 |
++ print(("Slave startup: connect to master at %s" % self.addr)) |
642 |
+ (host, port, identifier) = self.addr.split(":", 2) |
643 |
+ port = int(port) |
644 |
+ lock = threading.Lock() |
645 |
+--- modeller-9.25/modlib/modeller/top_interpreter/__init__.py (original) |
646 |
++++ modeller-9.25/modlib/modeller/top_interpreter/__init__.py (refactored) |
647 |
+@@ -65,7 +65,7 @@ |
648 |
+ if len(line) > 0: |
649 |
+ try: |
650 |
+ self._parse_top_ini_line(line.split(None, 4), vars) |
651 |
+- except TypeError, detail: |
652 |
++ except TypeError as detail: |
653 |
+ mod_log_write("read_top__E> " + str(detail)) |
654 |
+ mod_log_write(" top.ini line: " + line) |
655 |
+ raise |
656 |
+@@ -113,7 +113,7 @@ |
657 |
+ self._set_top_vars(vars) |
658 |
+ try: |
659 |
+ fh = self._open_include_file(self.variables['include_file']) |
660 |
+- except IOError, detail: |
661 |
++ except IOError as detail: |
662 |
+ mod_log_write("runlines__E> " + str(detail)) |
663 |
+ mod_log_write(" TOP Command line: " + line) |
664 |
+ raise |
665 |
+@@ -160,7 +160,7 @@ |
666 |
+ indxca = self._run_top_cmd(cmd, indxca, lines, callstack, |
667 |
+ subrout) |
668 |
+ _modeller.mod_top_post() |
669 |
+- except (IndexError, SyntaxError, TypeError), detail: |
670 |
++ except (IndexError, SyntaxError, TypeError) as detail: |
671 |
+ mod_log_write("runlines__E> " + str(detail)) |
672 |
+ mod_log_write(" TOP Command line: " + line) |
673 |
+ raise |
674 |
+--- modeller-9.25/modlib/modeller/top_interpreter/topcmds.py (original) |
675 |
++++ modeller-9.25/modlib/modeller/top_interpreter/topcmds.py (refactored) |
676 |
+@@ -19,7 +19,7 @@ |
677 |
+ if not isinstance(vars, (list, tuple)): |
678 |
+ vars = (vars,) |
679 |
+ for var in vars: |
680 |
+- if keys.has_key(var): |
681 |
++ if var in keys: |
682 |
+ args.append(keys[var]) |
683 |
+ else: |
684 |
+ args.append(self.vars[var]) |
685 |
+--- modeller-9.25/modlib/modeller/top_interpreter/util.py (original) |
686 |
++++ modeller-9.25/modlib/modeller/top_interpreter/util.py (refactored) |
687 |
+@@ -1,7 +1,7 @@ |
688 |
+ import _modeller |
689 |
+ |
690 |
+ def set_topvars(topvardict, vars, topini): |
691 |
+- for name in topvardict.keys(): |
692 |
++ for name in list(topvardict.keys()): |
693 |
+ value = topvardict[name] |
694 |
+ if value is None: |
695 |
+ continue |
696 |
+--- modeller-9.25/modlib/modeller/top_interpreter/variables.py (original) |
697 |
++++ modeller-9.25/modlib/modeller/top_interpreter/variables.py (refactored) |
698 |
+@@ -32,11 +32,11 @@ |
699 |
+ def __init__(self, topcmds): |
700 |
+ self._topcmds = topcmds |
701 |
+ self._topvars = {} |
702 |
+- for var in self._deftops.keys(): |
703 |
++ for var in list(self._deftops.keys()): |
704 |
+ self._ourvars[var] = self._deftops[var] |
705 |
+- for var in self._edat_members.keys(): |
706 |
++ for var in list(self._edat_members.keys()): |
707 |
+ self._ourvars[var] = self._edat_members[var] |
708 |
+- for var in self._io_members.keys(): |
709 |
++ for var in list(self._io_members.keys()): |
710 |
+ self._ourvars[var] = self._io_members[var] |
711 |
+ |
712 |
+ def __setitem__(self, key, value): |
713 |
+--- modeller-9.25/modlib/modeller/util/modobject.py (original) |
714 |
++++ modeller-9.25/modlib/modeller/util/modobject.py (refactored) |
715 |
+@@ -1,8 +1,8 @@ |
716 |
+ class modobject(object): |
717 |
+ def __setattr__(self, name, val): |
718 |
+ if name not in dir(self): |
719 |
+- print("runcmd_____W>: creation of new member '%s' in %s: " |
720 |
+- "possible typo!" % (name, str(self))) |
721 |
++ print(("runcmd_____W>: creation of new member '%s' in %s: " |
722 |
++ "possible typo!" % (name, str(self)))) |
723 |
+ object.__setattr__(self, name, val) |
724 |
+ |
725 |
+ def __getstate__(self): |
726 |
+@@ -11,7 +11,7 @@ |
727 |
+ # delete the key entirely, as __getstate__ must return a non-empty |
728 |
+ # dict in order for our __setstate__ method to be called). |
729 |
+ d = self.__dict__.copy() |
730 |
+- for key in self.__dict__.keys(): |
731 |
++ for key in list(self.__dict__.keys()): |
732 |
+ if key.endswith("_modpt"): |
733 |
+ d[key] = None |
734 |
+ return d |
735 |
+--- modeller-9.25/modlib/modeller/util/modutil.py (original) |
736 |
++++ modeller-9.25/modlib/modeller/util/modutil.py (refactored) |
737 |
+@@ -17,7 +17,7 @@ |
738 |
+ else: |
739 |
+ return indx |
740 |
+ elif isinstance(indx, slice): |
741 |
+- return range(*indx.indices(len(seqtype))) |
742 |
++ return list(range(*indx.indices(len(seqtype)))) |
743 |
+ elif lookup_func is not None: |
744 |
+ args = lookup_args + (indx,) |
745 |
+ int_indx = lookup_func(*args) |
746 |
|
747 |
diff --git a/sci-chemistry/modeller/modeller-9.19.ebuild b/sci-chemistry/modeller/modeller-9.19.ebuild |
748 |
deleted file mode 100644 |
749 |
index 0d29c3843..000000000 |
750 |
--- a/sci-chemistry/modeller/modeller-9.19.ebuild |
751 |
+++ /dev/null |
752 |
@@ -1,145 +0,0 @@ |
753 |
-# Copyright 1999-2018 Gentoo Foundation |
754 |
-# Distributed under the terms of the GNU General Public License v2 |
755 |
- |
756 |
-EAPI=6 |
757 |
- |
758 |
-PYTHON_COMPAT=( python2_7 ) |
759 |
- |
760 |
-inherit distutils-r1 eutils multilib versionator |
761 |
- |
762 |
-DESCRIPTION="Homology or comparative modeling of protein three-dimensional structures" |
763 |
-HOMEPAGE="http://salilab.org/modeller/" |
764 |
-SRC_URI="http://salilab.org/${PN}/${PV}/${P}.tar.gz" |
765 |
- |
766 |
-LICENSE="modeller" |
767 |
-KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
768 |
-IUSE="doc examples" |
769 |
-SLOT="0" |
770 |
- |
771 |
-RESTRICT="mirror" |
772 |
- |
773 |
-DEPEND=">=dev-lang/swig-1.3" |
774 |
-RDEPEND="" |
775 |
- |
776 |
-INPATH="${EPREFIX}"/opt/modeller${ver} |
777 |
- |
778 |
-QA_PREBUILT="/opt/*" |
779 |
- |
780 |
-pkg_setup() { |
781 |
- case ${ARCH} in |
782 |
- x86) |
783 |
- EXECTYPE="i386-intel8";; |
784 |
- amd64) |
785 |
- EXECTYPE="x86_64-intel8";; |
786 |
- *) |
787 |
- die "Your arch "${ARCH}" does not appear supported at this time.";; |
788 |
- esac |
789 |
-} |
790 |
- |
791 |
-python_prepare_all(){ |
792 |
- sed "s:i386-intel8:${EXECTYPE}:g" -i src/swig/setup.py || die |
793 |
- distutils-r1_python_prepare_all |
794 |
-} |
795 |
- |
796 |
-python_compile(){ |
797 |
- cd src/swig || die |
798 |
- swig -python -keyword -nodefaultctor -nodefaultdtor -noproxy modeller.i || die |
799 |
- distutils-r1_python_compile |
800 |
-} |
801 |
- |
802 |
-python_install() { |
803 |
- cd src/swig || die |
804 |
- distutils-r1_python_install |
805 |
-} |
806 |
- |
807 |
-python_install_all(){ |
808 |
- cd "${S}" || die |
809 |
- sed \ |
810 |
- -e "/^EXECUTABLE_TYPE/s:xxx:${EXECTYPE}:g" \ |
811 |
- -e "/MODINSTALL/s:xxx:\"${INPATH}\":g" \ |
812 |
- -i bin/modscript || die |
813 |
- |
814 |
- sed -e "s;@TOPDIR\@;\"${INPATH}\";" \ |
815 |
- -e "s;@EXETYPE\@;${EXECTYPE};" \ |
816 |
- bin/modpy.sh.in > "${T}/modpy.sh" |
817 |
- |
818 |
- insinto ${INPATH} |
819 |
- doins -r modlib |
820 |
- python_foreach_impl python_domodule modlib/modeller |
821 |
- |
822 |
- insinto ${INPATH}/bin |
823 |
- doins -r bin/{lib,*top} |
824 |
- |
825 |
- exeinto ${INPATH}/bin |
826 |
- doexe bin/{modscript,mod${PV}_${EXECTYPE}} "${T}"/modpy.sh |
827 |
- |
828 |
- python_foreach_impl python_doscript bin/modslave.py |
829 |
- dosym ${INPATH}/bin/modscript /opt/bin/mod${PV} |
830 |
- dosym ${INPATH}/bin/modpy.sh /opt/bin/modpy.sh |
831 |
- |
832 |
- exeinto ${INPATH}/lib/${EXECTYPE}/ |
833 |
- doexe lib/${EXECTYPE}/lib* |
834 |
- dosym libmodeller.so.8 ${INPATH}/lib/${EXECTYPE}/libmodeller.so |
835 |
- dosym ../../${INPATH}/lib/${EXECTYPE}/libmodeller.so.8 /usr/$(get_libdir)/libmodeller.so.8 |
836 |
- |
837 |
- use doc && HTML_DOCS=( doc/. ) |
838 |
- distutils-r1_python_install_all |
839 |
- |
840 |
- if use examples; then |
841 |
- insinto /usr/share/${PN}/ |
842 |
- doins -r examples |
843 |
- fi |
844 |
- |
845 |
- insinto /etc/revdep-rebuild |
846 |
- cat >> "${T}"/40-${PN} <<- EOF |
847 |
- SEARCH_DIRS_MASK="${EPREFIX}/opt/modeller/lib/" |
848 |
- EOF |
849 |
- doins "${T}"/40-${PN} |
850 |
-} |
851 |
- |
852 |
-pkg_postinst() { |
853 |
- if [[ ! -e "${INPATH}/modlib/modeller/config.py" ]]; then |
854 |
- echo install_dir = \"${INPATH}/\"> ${INPATH}/modlib/modeller/config.py |
855 |
- fi |
856 |
- |
857 |
- if grep -q license ${INPATH}/modlib/modeller/config.py; then |
858 |
- einfo "A license key file is already present in ${IN_PATH}/modlib/modeller/config.py" |
859 |
- else |
860 |
- ewarn "Obtain a license Key from" |
861 |
- ewarn "http://salilab.org/modeller/registration.html" |
862 |
- ewarn "And run this before using modeller:" |
863 |
- ewarn "emerge --config =${CATEGORY}/${PF}" |
864 |
- ewarn "That way you can [re]enter your license key." |
865 |
- fi |
866 |
-} |
867 |
- |
868 |
-pkg_postrm() { |
869 |
- ewarn "This package leaves a license Key file in ${INPATH}/modlib/modeller/config.py" |
870 |
- ewarn "that you need to remove to completely get rid of modeller." |
871 |
-} |
872 |
- |
873 |
-pkg_config() { |
874 |
- ewarn "Your license key is NOT checked for validity here." |
875 |
- ewarn " Make sure you type it in correctly." |
876 |
- eerror "If you CTRL+C out of this, modeller will not run!" |
877 |
- while true |
878 |
- do |
879 |
- einfo "Please enter your license key:" |
880 |
- read license_key1 |
881 |
- einfo "Please re-enter your license key:" |
882 |
- read license_key2 |
883 |
- if [[ "$license_key1" == "" ]] |
884 |
- then |
885 |
- echo "You entered a blank license key. Try again." |
886 |
- else |
887 |
- if [[ "$license_key1" == "$license_key2" ]] |
888 |
- then |
889 |
- echo license = '"'$license_key1'"' >> "${INPATH}/modlib/modeller/config.py" |
890 |
- einfo "Thank you!" |
891 |
- break |
892 |
- else |
893 |
- eerror "Your license key entries do not match. Try again." |
894 |
- fi |
895 |
- fi |
896 |
- done |
897 |
-} |
898 |
|
899 |
diff --git a/sci-chemistry/modeller/modeller-9.12-r3.ebuild b/sci-chemistry/modeller/modeller-9.25.ebuild |
900 |
similarity index 90% |
901 |
rename from sci-chemistry/modeller/modeller-9.12-r3.ebuild |
902 |
rename to sci-chemistry/modeller/modeller-9.25.ebuild |
903 |
index de64378e1..cf3af567e 100644 |
904 |
--- a/sci-chemistry/modeller/modeller-9.12-r3.ebuild |
905 |
+++ b/sci-chemistry/modeller/modeller-9.25.ebuild |
906 |
@@ -1,15 +1,15 @@ |
907 |
-# Copyright 1999-2016 Gentoo Foundation |
908 |
+# Copyright 1999-2020 Gentoo Authors |
909 |
# Distributed under the terms of the GNU General Public License v2 |
910 |
|
911 |
-EAPI=6 |
912 |
+EAPI=7 |
913 |
|
914 |
-PYTHON_COMPAT=( python2_7 ) |
915 |
+PYTHON_COMPAT=( python3_{6,7,8,9} ) |
916 |
|
917 |
-inherit distutils-r1 eutils multilib versionator |
918 |
+inherit distutils-r1 eutils multilib |
919 |
|
920 |
DESCRIPTION="Homology or comparative modeling of protein three-dimensional structures" |
921 |
-HOMEPAGE="http://salilab.org/modeller/" |
922 |
-SRC_URI="http://salilab.org/${PN}/${PV}/${P}.tar.gz" |
923 |
+HOMEPAGE="https://salilab.org/modeller/" |
924 |
+SRC_URI="https://salilab.org/${PN}/${PV}/${P}.tar.gz" |
925 |
|
926 |
LICENSE="modeller" |
927 |
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
928 |
@@ -25,6 +25,8 @@ INPATH="${EPREFIX}"/opt/modeller${ver} |
929 |
|
930 |
QA_PREBUILT="/opt/*" |
931 |
|
932 |
+PATCHES=( "${FILESDIR}/${P}-convert2to3.patch" ) |
933 |
+ |
934 |
pkg_setup() { |
935 |
case ${ARCH} in |
936 |
x86) |
937 |
@@ -38,6 +40,8 @@ pkg_setup() { |
938 |
|
939 |
python_prepare_all(){ |
940 |
sed "s:i386-intel8:${EXECTYPE}:g" -i src/swig/setup.py || die |
941 |
+ rm -rf modlib/modeller/python_library || die |
942 |
+ sed -i '1 i\#!/usr/bin/python' bin/modslave.py |
943 |
distutils-r1_python_prepare_all |
944 |
} |