svn commit: r546884 - head/biology/phyml/files
Tobias C. Berner
tcberner at FreeBSD.org
Sat Aug 29 08:34:29 UTC 2020
Author: tcberner
Date: Sat Aug 29 08:34:27 2020
New Revision: 546884
URL: https://svnweb.freebsd.org/changeset/ports/546884
Log:
biology/phyml: fix build on recent current
mostly backport of:
https://github.com/stephaneguindon/phyml/commit/3574fb82d54438518d50d5ba8f74423d5395a96a
Obtained from: https://github.com/stephaneguindon/phyml/commit/3574fb82d54438518d50d5ba8f74423d5395a96a
Added:
head/biology/phyml/files/
head/biology/phyml/files/patch-src_io.c (contents, props changed)
head/biology/phyml/files/patch-src_phyrex.c (contents, props changed)
head/biology/phyml/files/patch-src_utilities.c (contents, props changed)
head/biology/phyml/files/patch-src_utilities.h (contents, props changed)
Added: head/biology/phyml/files/patch-src_io.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/biology/phyml/files/patch-src_io.c Sat Aug 29 08:34:27 2020 (r546884)
@@ -0,0 +1,20 @@
+--- src/io.c.orig 2020-07-09 11:49:16 UTC
++++ src/io.c
+@@ -39,8 +39,6 @@ t_tree *Read_Tree(char **s_tree)
+ if((*s_tree)[i] == ',') n_otu++;
+ }
+ n_otu+=1;
+-
+-
+
+ tree = Make_Tree_From_Scratch(n_otu,NULL);
+ subs = Sub_Trees((*s_tree),°ree);
+@@ -2312,7 +2310,7 @@ void Print_Fp_Out(FILE *fp_out, time_t t_beg, time_t t
+ div_t hour,min;
+ int i, j;
+
+- if (precision > 0) snprintf (format, 8, "%%.%df", precision);
++ if (precision > 0) snprintf(format,8,"%%.%huf",(unsigned short)precision);
+
+ if(n_data_set == 1)
+ {
Added: head/biology/phyml/files/patch-src_phyrex.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/biology/phyml/files/patch-src_phyrex.c Sat Aug 29 08:34:27 2020 (r546884)
@@ -0,0 +1,11 @@
+--- src/phyrex.c.orig 2020-07-09 11:49:16 UTC
++++ src/phyrex.c
+@@ -958,7 +958,7 @@ phydbl *PHYREX_MCMC(t_tree *tree)
+ PHYREX_Label_Nodes_With_Locations(tree);
+ PHYREX_Label_Edges(tree);
+ char *s = Write_Tree(tree);
+- PhyML_Fprintf(fp_tree,"\ntree %d [&lnP=%f,precision={1.e-1,1e-02,1e-01}] = [&R] %s",tree->mcmc->sample_num,tree->c_lnL,s);
++ PhyML_Fprintf(fp_tree,"\ntree %d [&lnP=%f,precision={1.e-1,1e-02,1e-01}] = [&R] %s",tree->mcmc->run,tree->c_lnL,s);
+ PhyML_Fprintf(fp_tree,"\nend;");
+ fseek(fp_tree,-5,SEEK_END);
+ tree->write_tax_names = YES;
Added: head/biology/phyml/files/patch-src_utilities.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/biology/phyml/files/patch-src_utilities.c Sat Aug 29 08:34:27 2020 (r546884)
@@ -0,0 +1,30 @@
+--- src/utilities.c.orig 2020-07-09 11:49:16 UTC
++++ src/utilities.c
+@@ -17,6 +17,9 @@ the GNU public licence. See http://www.opensource.org
+ #include "beagle_utils.h"
+ #endif
+
++int CALL;
++int TIME;
++
+ //////////////////////////////////////////////////////////////
+ //////////////////////////////////////////////////////////////
+
+@@ -3066,7 +3069,7 @@ int Assign_State_With_Ambiguity(char *c, int datatype,
+ if(Is_Ambigu(c,GENERIC,stepsize)) state[0] = T_MAX_ALPHABET-1;
+ else
+ {
+- char format[6];
++ char format[20];
+ sprintf(format,"%%%dd",stepsize);
+ if(!sscanf(c,format,state))
+ {
+@@ -4891,7 +4894,7 @@ int Are_Compatible(char *statea, char *stateb, int ste
+ else
+ {
+ int a,b;
+- char format[6];
++ char format[20];
+
+ sprintf(format,"%%%dd",stepsize);
+
Added: head/biology/phyml/files/patch-src_utilities.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/biology/phyml/files/patch-src_utilities.h Sat Aug 29 08:34:27 2020 (r546884)
@@ -0,0 +1,13 @@
+--- src/utilities.h.orig 2020-08-29 08:31:23 UTC
++++ src/utilities.h
+@@ -94,8 +94,8 @@ static inline int isinf_ld (long double x) { return is
+ #endif
+
+
+-int CALL;
+-int TIME;
++extern int CALL;
++extern int TIME;
+
+ #define SLFV_GAUSSIAN 0 /* Spatial Lambda-Fleming-Viot model (Gaussian) */
+ #define SLFV_UNIFORM 1 /* Spatial Lambda-Fleming-Viot model (Uniform) */
More information about the svn-ports-head
mailing list