summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Seifert <soap@gentoo.org>2020-11-01 19:36:14 +0100
committerDavid Seifert <soap@gentoo.org>2020-11-01 19:36:14 +0100
commitcc1e91fc1e8a7302af0ab19c8ad3c5ef5721ec92 (patch)
tree4792106915a4acf89c26d8e04f884c5dc447426a
parentsci-biology/newick-utils: Port to EAPI 7 (diff)
downloadgentoo-cc1e91fc1e8a7302af0ab19c8ad3c5ef5721ec92.tar.gz
gentoo-cc1e91fc1e8a7302af0ab19c8ad3c5ef5721ec92.tar.bz2
gentoo-cc1e91fc1e8a7302af0ab19c8ad3c5ef5721ec92.zip
sci-biology/seaview: Port to EAPI 7
* Fix building against GCC 10 / -fno-common * Fix building against Clang Closes: https://bugs.gentoo.org/707842 Closes: https://bugs.gentoo.org/741198 Package-Manager: Portage-3.0.8, Repoman-3.0.2 Signed-off-by: David Seifert <soap@gentoo.org>
-rw-r--r--sci-biology/seaview/files/seaview-4.6-Wreserved-user-defined-literal.patch76
-rw-r--r--sci-biology/seaview/files/seaview-4.6-fno-common.patch110
-rw-r--r--sci-biology/seaview/seaview-4.6-r1.ebuild (renamed from sci-biology/seaview/seaview-4.6.ebuild)29
3 files changed, 203 insertions, 12 deletions
diff --git a/sci-biology/seaview/files/seaview-4.6-Wreserved-user-defined-literal.patch b/sci-biology/seaview/files/seaview-4.6-Wreserved-user-defined-literal.patch
new file mode 100644
index 00000000000..c9595748e90
--- /dev/null
+++ b/sci-biology/seaview/files/seaview-4.6-Wreserved-user-defined-literal.patch
@@ -0,0 +1,76 @@
+--- a/align.cxx
++++ b/align.cxx
+@@ -754,7 +754,7 @@
+ alignitems[clustalopt + MAX_MSA_ALGOS].label(strdup(options));
+ alignitems[clustalopt + MAX_MSA_ALGOS].flags = attr;
+ if (view->alignment_algorithm < 2) alignitems[clustalopt + MAX_MSA_ALGOS + 3].flags = FL_MENU_INACTIVE;
+- delete options;
++ delete[] options;
+ view->menu_align = alignitems;
+ view->menubar->add("Align", 0, NULL, (void*)view->menu_align, FL_SUBMENU_POINTER);
+ if (view->count_msa_algos >= MAX_MSA_ALGOS) (alignitems + clustalopt + MAX_MSA_ALGOS + 2)->deactivate();
+--- a/seaview.cxx
++++ b/seaview.cxx
+@@ -3314,7 +3314,7 @@
+ if(p != NULL) *p = 0;
+ if(printout_black == TEXT_ONLY) strcat(suggested, ".txt");
+ else {
+- strcat(suggested, "."PDF_OR_PS_EXT);
++ strcat(suggested, "." PDF_OR_PS_EXT);
+ }
+ if( view->alt_col_rank != NULL ) {
+ for(anerr = 0; anerr < view->tot_seqs; anerr++)
+@@ -3424,7 +3424,7 @@
+
+ pdf_form = new Fl_Window(415, 90);
+ pdf_form->box(FL_FLAT_BOX);
+-pdf_form->label("Set "PDF_OR_PS" output options");
++pdf_form->label("Set " PDF_OR_PS " output options");
+
+ x = 5 + (int)fl_width("block size:"); y = 5; w = 50; h = 25;
+ sizeinput = new Fl_Input(x, y, w, h, "font size:");
+@@ -5000,10 +5000,10 @@
+ {"Save prot alignmt", 0,file_menu_callback, 0, FL_MENU_INACTIVE},
+ {"Save bootstrap replicates", 0,file_menu_callback, 0, FL_MENU_INACTIVE | FL_MENU_DIVIDER},
+ #if !defined(__APPLE__)
+- {"Prepare "PDF_OR_PS"", 0, file_menu_callback, 0, 0},
+- {""PDF_OR_PS" options...", 0, file_menu_callback, 0, FL_MENU_DIVIDER},
++ {"Prepare " PDF_OR_PS "", 0, file_menu_callback, 0, 0},
++ {"" PDF_OR_PS " options...", 0, file_menu_callback, 0, FL_MENU_DIVIDER},
+ #else
+- {"Prepare "PDF_OR_PS"", 0, file_menu_callback, 0, FL_MENU_DIVIDER},
++ {"Prepare " PDF_OR_PS "", 0, file_menu_callback, 0, FL_MENU_DIVIDER},
+ #endif
+ {"Concatenate", 0,file_menu_callback, 0, FL_MENU_DIVIDER},
+ {"New window", FL_COMMAND | 'n', file_menu_callback, 0, 0},
+--- a/treedraw.cxx
++++ b/treedraw.cxx
+@@ -210,7 +210,7 @@
+ {"Save all trees", 0, file_callback, NULL, 0},
+ {"Save patristic distances", 0, patristic_callback, NULL, FL_MENU_DIVIDER},
+ {"Print", FL_COMMAND | 'p', file_callback, NULL, 0},
+- {"Save as "PDF_OR_PS"", 0, file_callback, NULL, 0},
++ {"Save as " PDF_OR_PS "", 0, file_callback, NULL, 0},
+ {"Save as SVG", 0, file_callback, NULL, 0},
+ {"A4", 0, file_callback, NULL, FL_MENU_RADIO | 0},
+ {"Letter", 0, file_callback, NULL, FL_MENU_RADIO | 0},
+--- a/xfmatpt.cxx
++++ b/xfmatpt.cxx
+@@ -205,7 +205,7 @@
+ compute->callback(compute_proc, fdui);
+ fdui->compute_butt = compute;
+
+-Fl_Widget *postscript = cre_button(fin, curr_y, &width, but_height, fontsize, "Write "PDF_OR_PS);
++Fl_Widget *postscript = cre_button(fin, curr_y, &width, but_height, fontsize, "Write " PDF_OR_PS);
+ fin += width;
+ postscript->callback(plot_button_proc, fdui);
+
+@@ -870,7 +870,7 @@
+ #ifndef MICRO
+ matpt->form->hide(); Fl::flush(); // because of strange bug on 32-bit Linux only
+ #endif
+- fl_message("Dot plot is now in file\n%s\nin "PDF_OR_PS" format", surface->outfname());
++ fl_message("Dot plot is now in file\n%s\nin " PDF_OR_PS " format", surface->outfname());
+ delete surface;
+ #ifndef MICRO
+ matpt->form->show(); Fl::flush();
diff --git a/sci-biology/seaview/files/seaview-4.6-fno-common.patch b/sci-biology/seaview/files/seaview-4.6-fno-common.patch
new file mode 100644
index 00000000000..24cc28dfb3b
--- /dev/null
+++ b/sci-biology/seaview/files/seaview-4.6-fno-common.patch
@@ -0,0 +1,110 @@
+--- a/csrc/dnapars.c
++++ b/csrc/dnapars.c
+@@ -77,41 +77,43 @@
+ /* function prototypes */
+
+
+-Char infilename[FNMLNGTH], outfilename[FNMLNGTH], intreename[FNMLNGTH], *outtreename,
++extern Char infilename[FNMLNGTH], outfilename[FNMLNGTH], intreename[FNMLNGTH], *outtreename,
+ weightfilename[FNMLNGTH];
+ char basechar[32]="ACMGRSVTWYHKDBNO???????????????";
+-node *root;
+-long chars, col, msets, ith, njumble, jumb, maxtrees;
++extern node *root;
++extern long chars, col, msets, ith, njumble, jumb;
++long maxtrees;
+ /* chars = number of sites in actual sequences */
+-long inseed, inseed0;
+-double threshold;
+-boolean jumble, usertree, thresh, weights, thorough, rearrfirst,
+- trout, progress, stepbox, ancseq, mulsets, justwts, firstset, mulf,
+- multf;
++extern long inseed, inseed0;
++extern double threshold;
++boolean thorough, rearrfirst, mulf, multf;
++extern boolean justwts, ancseq, weights, thresh, jumble, usertree, trout, mulsets, progress, stepbox, firstset;
+ steptr oldweight;
+-longer seed;
+-pointarray treenode; /* pointers to all nodes in tree */
+-long *enterorder;
++extern longer seed;
++extern pointarray treenode; /* pointers to all nodes in tree */
++extern long *enterorder;
+ long *zeros;
+
+ /* local variables for Pascal maketree, propagated globally for C version: */
+
+-long minwhich;
++extern long minwhich;
+ static double like, minsteps, bestyet, bestlike, bstlike2;
+-boolean lastrearr, recompute;
+-double nsteps[maxuser];
+-long **fsteps;
+-node *there, *oldnufork;
+-long *place;
+-bestelm *bestrees;
+-long *threshwt;
++extern boolean lastrearr, recompute;
++extern double nsteps[maxuser];
++extern long **fsteps;
++extern node *there;
++node *oldnufork;
++extern long *place;
++extern bestelm *bestrees;
++extern long *threshwt;
+ baseptr nothing;
+-gbases *garbage;
+-node *temp, *temp1, *temp2, *tempsum, *temprm, *tempadd, *tempf, *tmp, *tmp1,
++extern gbases *garbage;
++extern node *temp, *temp1;
++node *temp2, *tempsum, *temprm, *tempadd, *tempf, *tmp, *tmp1,
+ *tmp2, *tmp3, *tmprm, *tmpadd;
+-boolean *names;
++extern boolean *names;
+ node *grbg;
+-char *progname;
++extern char *progname;
+
+
+ static void getoptions(int arg_maxtrees, dnapars_S_option s_option)
+--- a/csrc/phylip.c
++++ b/csrc/phylip.c
+@@ -35,6 +35,8 @@
+
+ #include "phylip.h"
+
++boolean javarun;
++
+ #ifdef WIN32
+ #include <windows.h>
+ /* for console code (clear screen, text color settings) */
+--- a/csrc/phylip.h
++++ b/csrc/phylip.h
+@@ -342,7 +342,7 @@
+ /* Lower-triangular format. */
+ #define MAT_LOWERTRI (MAT_LOWER | MAT_MACHINE)
+
+-boolean javarun;
++extern boolean javarun;
+
+ typedef long *steptr;
+ typedef long longer[6];
+@@ -363,7 +363,6 @@
+ extern boolean ibmpc, ansi, tranvsp;
+ //extern naym *nayme; /* names of species */
+ extern char* *nayme; /* names of species */
+-boolean firstplotblock; // for debugging BMP output
+
+ #define ebcdic EBCDIC
+
+--- a/csrc/protpars.c
++++ b/csrc/protpars.c
+@@ -127,7 +127,7 @@
+ node *temp, *temp1;
+ Char ch;
+ aas tmpa;
+-char *progname;
++extern char *progname;
+
+ /* Local variables for maketree, propagated globally for c version: */
+ long minwhich;
diff --git a/sci-biology/seaview/seaview-4.6.ebuild b/sci-biology/seaview/seaview-4.6-r1.ebuild
index 4ad8ad61b72..469f8872812 100644
--- a/sci-biology/seaview/seaview-4.6.ebuild
+++ b/sci-biology/seaview/seaview-4.6-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=7
-inherit eutils toolchain-funcs
+inherit desktop toolchain-funcs
DESCRIPTION="A graphical multiple sequence alignment editor"
HOMEPAGE="http://pbil.univ-lyon1.fr/software/seaview.html"
@@ -15,19 +15,24 @@ KEYWORDS="~amd64 ~x86"
IUSE="+xft"
RDEPEND="
+ sci-biology/clustalw:2
+ sci-biology/phyml
+ || (
+ sci-libs/libmuscle
+ sci-biology/muscle
+ )
sys-libs/zlib
- x11-libs/fltk:1
+ x11-libs/fltk:1[xft?]
x11-libs/libX11
- xft? (
- x11-libs/libXft
- x11-libs/fltk:1[xft] )
- sci-biology/clustalw:2
- || ( sci-libs/libmuscle sci-biology/muscle )
- sci-biology/phyml"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
+ xft? ( x11-libs/libXft )"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
S="${WORKDIR}/${PN}"
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.6-fno-common.patch
+ "${FILESDIR}"/${PN}-4.6-Wreserved-user-defined-literal.patch
+)
src_prepare() {
default