diff options
author | David Seifert <soap@gentoo.org> | 2020-11-01 19:36:11 +0100 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2020-11-01 19:36:11 +0100 |
commit | f812704e44f3d927dd47f3901c59ee7716adefd0 (patch) | |
tree | 743c8c5a88bcd5616b78b44fa273543ec409ab0b /sci-biology | |
parent | sci-biology/embassy-phylipnew: Patch out -L/usr/lib for LLD (diff) | |
download | gentoo-f812704e44f3d927dd47f3901c59ee7716adefd0.tar.gz gentoo-f812704e44f3d927dd47f3901c59ee7716adefd0.tar.bz2 gentoo-f812704e44f3d927dd47f3901c59ee7716adefd0.zip |
sci-biology/newick-utils: Port to EAPI 7
* Don't build static libraries by default
* Fix GCC 10 / -fno-common
* Disable automagic guile and lua
Closes: https://bugs.gentoo.org/708534
Closes: https://bugs.gentoo.org/712312
Closes: https://bugs.gentoo.org/727986
Package-Manager: Portage-3.0.8, Repoman-3.0.2
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'sci-biology')
5 files changed, 245 insertions, 24 deletions
diff --git a/sci-biology/newick-utils/files/newick-utils-1.6-deduplicate-libnw.patch b/sci-biology/newick-utils/files/newick-utils-1.6-deduplicate-libnw.patch new file mode 100644 index 000000000000..ca997830aced --- /dev/null +++ b/sci-biology/newick-utils/files/newick-utils-1.6-deduplicate-libnw.patch @@ -0,0 +1,153 @@ +Don't rebuild all of libnw.la pointlessly + +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -8,6 +8,8 @@ + showsrc: + @echo $(srcdir) + ++LDADD = $(top_builddir)/src/libnw.la ++ + TESTS = test_newick_scanner test_newick_parser test_rnode test_list \ + test_link test_masprintf test_svg_graph_radial \ + test_canvas test_concat test_hash test_lca test_enode \ +@@ -37,100 +39,57 @@ + + SRC = $(top_builddir)/src + +-test_newick_scanner_SOURCES = test_newick_scanner.c $(SRC)/newick_scanner.c \ +- $(SRC)/newick_parser.c $(SRC)/rnode.c $(SRC)/rnode_iterator.c \ +- $(SRC)/list.c $(SRC)/hash.c $(SRC)/masprintf.c $(SRC)/link.c +- +-test_newick_parser_SOURCES = test_newick_parser.c $(SRC)/parser.c \ +- $(SRC)/newick_scanner.c $(SRC)/newick_parser.c $(SRC)/list.c \ +- $(SRC)/rnode.c $(SRC)/link.c $(SRC)/hash.c $(SRC)/rnode_iterator.c \ +- $(SRC)/masprintf.c $(SRC)/to_newick.c $(SRC)/concat.c +- +-test_rnode_SOURCES = test_rnode.c $(SRC)/rnode.c $(SRC)/list.c \ +- $(SRC)/rnode_iterator.c $(SRC)/hash.c $(SRC)/masprintf.c \ +- tree_stubs.c $(SRC)/nodemap.c $(SRC)/link.c +- +-test_list_SOURCES = test_list.c $(SRC)/list.c +- +-test_link_SOURCES = test_link.c $(SRC)/link.c $(SRC)/nodemap.c \ +- $(SRC)/list.c $(SRC)/to_newick.c $(SRC)/rnode.c \ +- $(SRC)/concat.c $(SRC)/hash.c tree_stubs.c \ +- $(SRC)/rnode_iterator.c $(SRC)/masprintf.c ++test_newick_scanner_SOURCES = test_newick_scanner.c ++ ++test_newick_parser_SOURCES = test_newick_parser.c ++ ++test_rnode_SOURCES = test_rnode.c tree_stubs.c ++ ++test_list_SOURCES = test_list.c ++ ++test_link_SOURCES = test_link.c tree_stubs.c + + test_canvas_SOURCES = test_canvas.c $(SRC)/canvas.c + +-test_concat_SOURCES = test_concat.c $(SRC)/concat.c ++test_concat_SOURCES = test_concat.c ++ ++test_hash_SOURCES = test_hash.c ++ ++test_lca_SOURCES = test_lca.c tree_stubs.c ++ ++test_nodemap_SOURCES = test_nodemap.c tree_stubs.c + +-test_hash_SOURCES = test_hash.c $(SRC)/hash.c $(SRC)/list.c $(SRC)/masprintf.c ++test_to_newick_SOURCES = test_to_newick.c tree_stubs.c + +-test_lca_SOURCES = test_lca.c $(SRC)/lca.c $(SRC)/list.c $(SRC)/nodemap.c \ +- $(SRC)/link.c $(SRC)/rnode.c $(SRC)/hash.c \ +- $(SRC)/rnode_iterator.c tree_stubs.c $(SRC)/masprintf.c \ +- $(SRC)/error.c +- +-test_nodemap_SOURCES = test_nodemap.c $(SRC)/nodemap.c \ +- $(SRC)/rnode.c $(SRC)/list.c $(SRC)/hash.c $(SRC)/link.c \ +- $(SRC)/rnode_iterator.c $(SRC)/masprintf.c tree_stubs.c +- +-test_to_newick_SOURCES = test_to_newick.c $(SRC)/to_newick.c \ +- $(SRC)/rnode.c $(SRC)/link.c $(SRC)/concat.c \ +- $(SRC)/list.c $(SRC)/rnode_iterator.c $(SRC)/hash.c \ +- $(SRC)/masprintf.c $(SRC)/parser.c $(SRC)/newick_scanner.c \ +- $(SRC)/newick_parser.c tree_stubs.c +- +-test_tree_SOURCES = test_tree.c $(SRC)/tree.c $(SRC)/rnode.c $(SRC)/list.c \ +- $(SRC)/to_newick.c $(SRC)/nodemap.c $(SRC)/link.c $(SRC)/concat.c \ +- $(SRC)/hash.c tree_stubs.c $(SRC)/rnode_iterator.c \ +- $(SRC)/masprintf.c +- +-test_node_set_SOURCES = test_node_set.c tree_stubs.c $(SRC)/node_set.c \ +- $(SRC)/hash.c $(SRC)/rnode.c $(SRC)/list.c $(SRC)/link.c \ +- $(SRC)/rnode_iterator.c $(SRC)/masprintf.c +- +-test_enode_SOURCES = test_enode.c $(SRC)/enode.c $(SRC)/rnode.c \ +- $(SRC)/link.c $(SRC)/list.c $(SRC)/rnode_iterator.c \ +- $(SRC)/hash.c $(SRC)/masprintf.c +- +-test_rnode_iterator_SOURCES = test_rnode_iterator.c $(SRC)/rnode_iterator.c \ +- $(SRC)/list.c $(SRC)/link.c $(SRC)/rnode.c $(SRC)/to_newick.c \ +- $(SRC)/hash.c $(SRC)/nodemap.c tree_stubs.c $(SRC)/masprintf.c \ +- $(SRC)/parser.c $(SRC)/newick_scanner.c $(SRC)/newick_parser.c \ +- $(SRC)/concat.c ++test_tree_SOURCES = test_tree.c tree_stubs.c ++ ++test_node_set_SOURCES = test_node_set.c tree_stubs.c $(SRC)/node_set.c ++ ++test_enode_SOURCES = test_enode.c $(SRC)/enode.c ++ ++test_rnode_iterator_SOURCES = test_rnode_iterator.c tree_stubs.c + + test_readline_SOURCES = test_readline.c $(SRC)/readline.c + +-test_tree_models_SOURCES = test_tree_models.c $(SRC)/tree_models.c \ +- $(SRC)/rnode.c $(SRC)/list.c $(SRC)/to_newick.c $(SRC)/link.c \ +- $(SRC)/concat.c $(SRC)/rnode_iterator.c \ +- $(SRC)/hash.c $(SRC)/masprintf.c +- +-test_xml_utils_SOURCES = test_xml_utils.c $(SRC)/xml_utils.c \ +- $(SRC)/masprintf.c +- +-test_masprintf_SOURCES = test_masprintf.c $(SRC)/masprintf.c +- +-test_error_SOURCES = test_error.c $(SRC)/error.c +- +-test_order_tree_SOURCES = test_order_tree.c $(SRC)/order_tree.c tree_stubs.c \ +- $(SRC)/link.c $(SRC)/to_newick.c $(SRC)/rnode.c $(SRC)/list.c \ +- $(SRC)/masprintf.c $(SRC)/concat.c $(SRC)/hash.c $(SRC)/nodemap.c \ +- $(SRC)/rnode_iterator.c +- +-test_graph_common_SOURCES = test_graph_common.c $(SRC)/graph_common.c \ +- tree_stubs.c $(SRC)/link.c $(SRC)/list.c $(SRC)/tree.c \ +- $(SRC)/rnode_iterator.c $(SRC)/hash.c $(SRC)/masprintf.c \ +- $(SRC)/rnode.c $(SRC)/nodemap.c ++test_tree_models_SOURCES = test_tree_models.c $(SRC)/tree_models.c ++ ++test_xml_utils_SOURCES = test_xml_utils.c $(SRC)/xml_utils.c ++ ++test_masprintf_SOURCES = test_masprintf.c ++ ++test_error_SOURCES = test_error.c ++ ++test_order_tree_SOURCES = test_order_tree.c tree_stubs.c $(SRC)/order_tree.c ++ ++test_graph_common_SOURCES = test_graph_common.c tree_stubs.c $(SRC)/graph_common.c + + test_svg_graph_radial_SOURCES = test_svg_graph_radial.c \ +- $(SRC)/svg_graph_radial.c $(SRC)/tree.c $(SRC)/svg_graph.c \ +- $(SRC)/rnode.c $(SRC)/hash.c $(SRC)/list.c $(SRC)/masprintf.c \ +- $(SRC)/rnode_iterator.c $(SRC)/svg_graph_ortho.c $(SRC)/error.c \ ++ $(SRC)/svg_graph_radial.c $(SRC)/svg_graph.c \ ++ $(SRC)/svg_graph_ortho.c \ + $(SRC)/readline.c $(SRC)/xml_utils.c $(SRC)/graph_common.c \ +- $(SRC)/node_pos_alloc.c $(SRC)/nodemap.c $(SRC)/lca.c $(SRC)/link.c ++ $(SRC)/node_pos_alloc.c + +-test_subtree_SOURCES = test_subtree.c $(SRC)/subtree.c $(SRC)/rnode.c \ +- $(SRC)/list.c $(SRC)/hash.c $(SRC)/link.c $(SRC)/rnode_iterator.c \ +- $(SRC)/masprintf.c $(SRC)/nodemap.c ++test_subtree_SOURCES = test_subtree.c $(SRC)/subtree.c + + clean-local: + $(RM) *.out diff --git a/sci-biology/newick-utils/files/newick-utils-1.6-fno-common.patch b/sci-biology/newick-utils/files/newick-utils-1.6-fno-common.patch new file mode 100644 index 000000000000..15847a52c480 --- /dev/null +++ b/sci-biology/newick-utils/files/newick-utils-1.6-fno-common.patch @@ -0,0 +1,41 @@ +--- a/src/address_parser.c ++++ b/src/address_parser.c +@@ -83,6 +83,8 @@ + #include "enode.h" + #include "address_parser_status.h" + ++enum address_parser_status_type address_parser_status; ++ + extern int adslex (void); + + /* The root of the expression (when represented as a parse tree) */ +--- a/src/address_parser_status.h ++++ b/src/address_parser_status.h +@@ -13,4 +13,4 @@ + * returns either \c NULL or the top-level enode of the address, so we need to + * use an extern variable to convey its status. */ + +-enum address_parser_status_type address_parser_status; ++extern enum address_parser_status_type address_parser_status; +--- a/tests/test_newick_parser.c ++++ b/tests/test_newick_parser.c +@@ -11,7 +11,7 @@ + int nwslex (void); + struct rnode *root; + struct llist *nodes_in_order; +-enum parser_status_type newick_parser_status; ++extern enum parser_status_type newick_parser_status; + void newick_scanner_set_string_input(char *); + + /* NOTE: we can use to_newick() to check the parser's output because this +--- a/tests/test_newick_scanner.c ++++ b/tests/test_newick_scanner.c +@@ -20,7 +20,7 @@ + int nwslex (void); + struct rnode *root; + struct llist *nodes_in_order; +-enum parser_status_type newick_parser_status; ++extern enum parser_status_type newick_parser_status; + void newick_scanner_set_string_input(char *); + void newick_scanner_set_file_input(FILE *); + diff --git a/sci-biology/newick-utils/metadata.xml b/sci-biology/newick-utils/metadata.xml index 959160fe46b1..d9bc91509874 100644 --- a/sci-biology/newick-utils/metadata.xml +++ b/sci-biology/newick-utils/metadata.xml @@ -1,8 +1,11 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> - <maintainer type="project"> - <email>sci-biology@gentoo.org</email> - <name>Gentoo Biology Project</name> - </maintainer> + <maintainer type="project"> + <email>sci-biology@gentoo.org</email> + <name>Gentoo Biology Project</name> + </maintainer> + <use> + <flag name="xml">Uses <pkg>dev-libs/libxml2</pkg> to handle ornaments</flag> + </use> </pkgmetadata> diff --git a/sci-biology/newick-utils/newick-utils-1.6-r1.ebuild b/sci-biology/newick-utils/newick-utils-1.6-r1.ebuild new file mode 100644 index 000000000000..3dcb438832a2 --- /dev/null +++ b/sci-biology/newick-utils/newick-utils-1.6-r1.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools + +DESCRIPTION="Tools for processing phylogenetic trees" +HOMEPAGE="http://cegg.unige.ch/newick_utils" +SRC_URI="http://cegg.unige.ch/pub/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="xml" + +DEPEND=" + xml? ( dev-libs/libxml2 )" +RDEPEND=" + ${DEPEND} + !dev-games/libnw" + +PATCHES=( + "${FILESDIR}"/${P}-deduplicate-libnw.patch + "${FILESDIR}"/${P}-fno-common.patch +) + +src_prepare() { + default + eautoreconf +} + +src_configure() { + econf \ + --disable-static \ + --without-guile \ + --without-lua \ + $(use_with xml libxml) +} + +src_install() { + default + find "${ED}" -name '*.la' -delete || die +} diff --git a/sci-biology/newick-utils/newick-utils-1.6.ebuild b/sci-biology/newick-utils/newick-utils-1.6.ebuild deleted file mode 100644 index 845bc0116205..000000000000 --- a/sci-biology/newick-utils/newick-utils-1.6.ebuild +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright 1999-2016 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -DESCRIPTION="Tools for processing phylogenetic trees" -HOMEPAGE="http://cegg.unige.ch/newick_utils" -SRC_URI="http://cegg.unige.ch/pub/${P}.tar.gz" - -LICENSE="BSD" -SLOT="0" -IUSE="" -KEYWORDS="~amd64 ~x86" - -DEPEND="" -RDEPEND="!dev-games/libnw" - -src_test() { - emake -C tests check-TESTS -} |