Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 24 Apr 2021 23:41:10 GMT
From:      "Jason W. Bacon" <jwb@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: ab50f8435a78 - main - biology/ncbi-entrez-direct: Access to the NCBI's interconnected databases
Message-ID:  <202104242341.13ONfAJV015117@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by jwb:

URL: https://cgit.FreeBSD.org/ports/commit/?id=ab50f8435a78a574ac5ce683004b078c5baf209d

commit ab50f8435a78a574ac5ce683004b078c5baf209d
Author:     Jason W. Bacon <jwb@FreeBSD.org>
AuthorDate: 2021-04-24 23:40:16 +0000
Commit:     Jason W. Bacon <jwb@FreeBSD.org>
CommitDate: 2021-04-24 23:40:16 +0000

    biology/ncbi-entrez-direct: Access to the NCBI's interconnected databases
    
    Entrez Direct (EDirect) provides access to the NCBI's suite of interconnected
    databases (publication, sequence, structure, gene, variation, expression, etc.)
    from a UNIX terminal window.
---
 biology/Makefile                                 |  1 +
 biology/ncbi-entrez-direct/Makefile              | 81 ++++++++++++++++++++++++
 biology/ncbi-entrez-direct/distinfo              | 23 +++++++
 biology/ncbi-entrez-direct/files/edirect-test.sh | 33 ++++++++++
 biology/ncbi-entrez-direct/files/go-build        |  7 ++
 biology/ncbi-entrez-direct/files/modules.txt     | 33 ++++++++++
 biology/ncbi-entrez-direct/files/patch-rchive    | 10 +++
 biology/ncbi-entrez-direct/files/patch-transmute | 10 +++
 biology/ncbi-entrez-direct/files/patch-xtract    | 10 +++
 biology/ncbi-entrez-direct/pkg-descr             |  5 ++
 biology/ncbi-entrez-direct/pkg-plist             | 55 ++++++++++++++++
 11 files changed, 268 insertions(+)

diff --git a/biology/Makefile b/biology/Makefile
index 53c31ac00b77..e04fd0d1775a 100644
--- a/biology/Makefile
+++ b/biology/Makefile
@@ -84,6 +84,7 @@
     SUBDIR += muscle
     SUBDIR += ncbi-blast+
     SUBDIR += ncbi-cxx-toolkit
+    SUBDIR += ncbi-entrez-direct
     SUBDIR += ncbi-toolkit
     SUBDIR += ncbi-vdb
     SUBDIR += ngs-sdk
diff --git a/biology/ncbi-entrez-direct/Makefile b/biology/ncbi-entrez-direct/Makefile
new file mode 100644
index 000000000000..858e4734786c
--- /dev/null
+++ b/biology/ncbi-entrez-direct/Makefile
@@ -0,0 +1,81 @@
+PORTNAME=	ncbi-entrez-direct
+DISTVERSION=	14.9.20210423
+CATEGORIES=	biology perl5
+MASTER_SITES=	ftp://ftp.ncbi.nlm.nih.gov/entrez/entrezdirect/versions/${PORTVERSION}/
+DISTFILES=	edirect.tar.gz
+DIST_SUBDIR=	edirect-${PORTVERSION}
+
+MAINTAINER=	jwb@FreeBSD.org
+COMMENT=	Access to the NCBI's suite of interconnected databases
+
+LICENSE=	PD
+
+BUILD_DEPENDS=	bash:shells/bash
+RUN_DEPENDS=	p5-libwww>=0:www/p5-libwww \
+		p5-LWP-Protocol-https>=0:www/p5-LWP-Protocol-https \
+		p5-XML-Simple>=0:textproc/p5-XML-Simple
+
+USES=		go:modules perl5 shebangfix
+USE_GITHUB=	nodefault
+
+# Dependency versions:
+#	make clean extract
+# 	cd ${WRKSRC}/cmd
+#	rm -r vendor
+#	../../../files/go-build
+# files/modules.txt: cd ${WRKSRC}/cmd && go mod vendor
+GHSD=		vendor/github.com
+GLSD=		vendor/golang.org
+GH_TUPLE=	fatih:color:v1.10.0:a/${GHSD}/fatih/color \
+		surgebase:porter2:56e4718818e8:b/${GHSD}/surgebase/porter2 \
+		gedex:inflector:16278e9db813:c/${GHSD}/gedex/inflector \
+		klauspost:cpuid:v1.3.1:d/${GHSD}/klauspost/cpuid \
+		pbnjay:memory:b12e5d931931:e/${GHSD}/pbnjay/memory \
+		mattn:go-colorable:v0.1.8:f/${GHSD}/mattn/go-colorable \
+		mattn:go-isatty:v0.0.12:g/${GHSD}/mattn/go-isatty \
+		fiam:gounidecode:8deddbd03fec:h/${GHSD}/fiam/gounidecode \
+		golang:text:v0.3.5:i/${GLSD}/x/text \
+		golang:sys:d5e6a3e2c0ae:j/${GLSD}/x/sys
+
+SHEBANG_FILES=	nquire edirect.pl word-at-a-time accn-at-a-time \
+		amino-acid-composition between-two-genes exclude-uid-lists \
+		filter-stop-words intersect-uid-lists phrase-search \
+		skip-if-file-exists theme-aliases
+
+PSCRIPTS=	efetch efilter einfo elink epost esearch esummary nquire
+SCRIPTS=	accn-at-a-time amino-acid-composition archive-pubmed \
+		between-two-genes download-ncbi-data download-pubmed \
+		download-sequence efetch efilter einfo elink epost \
+		esample esearch esummary exclude-uid-lists expand-current \
+		fetch-pubmed filter-stop-words gbf2xml index-extras \
+		index-pubmed intersect-uid-lists join-into-groups-of \
+		nquire phrase-search pm-collect pm-index pm-invert pm-merge \
+		pm-prepare pm-promote pm-refresh pm-stash rchive \
+		reorder-columns run-ncbi-converter skip-if-file-exists \
+		ecommon.sh sort-uniq-count sort-uniq-count-rank stream-pubmed \
+		theme-aliases transmute word-at-a-time xml2tbl xtract xy-plot \
+		hlp-xtract.txt transmute xml2json xtract
+
+post-extract:
+	@${MV} ${WRKDIR}/edirect/* ${WRKSRC}
+	@${RMDIR} ${WRKDIR}/edirect
+	@${MV} ${WRKSRC}/vendor ${WRKSRC}/cmd
+
+pre-configure:
+	@cd ${WRKSRC} && ${REINPLACE_CMD} \
+		-e 's|$$PATH:$$pth|$$PATH:${PREFIX}/bin|g' \
+		-e 's|"$$pth"|${PREFIX}/bin|g' \
+		${PSCRIPTS}
+
+do-build:
+	@${CP} ${FILESDIR}/modules.txt ${WRKSRC}/cmd/vendor
+	@${CP} -R ${WRKSRC}/eutils ${WRKSRC}/cmd/vendor
+	@cd ${WRKSRC}/cmd && ${FILESDIR}/go-build
+
+do-install:
+	cd ${WRKSRC} && ${INSTALL_SCRIPT} ${SCRIPTS} ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_SCRIPT} ${WRKSRC}/edirect.pl ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/cmd/*.FreeBSD ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_SCRIPT} ${FILESDIR}/edirect-test.sh ${STAGEDIR}${PREFIX}/bin
+
+.include <bsd.port.mk>
diff --git a/biology/ncbi-entrez-direct/distinfo b/biology/ncbi-entrez-direct/distinfo
new file mode 100644
index 000000000000..be93ed84e5a1
--- /dev/null
+++ b/biology/ncbi-entrez-direct/distinfo
@@ -0,0 +1,23 @@
+TIMESTAMP = 1619301195
+SHA256 (edirect-14.9.20210423/edirect.tar.gz) = 9d6534226164fc5dfae7abcf25bfdbd08db068b27f1c13b8a3c4681cda5b0cea
+SIZE (edirect-14.9.20210423/edirect.tar.gz) = 829737
+SHA256 (edirect-14.9.20210423/fatih-color-v1.10.0_GH0.tar.gz) = a00342a7ffb8b119346dce56e152a111cbb9eab3970c429cc2ed4272aec2858e
+SIZE (edirect-14.9.20210423/fatih-color-v1.10.0_GH0.tar.gz) = 1267532
+SHA256 (edirect-14.9.20210423/surgebase-porter2-56e4718818e8_GH0.tar.gz) = d06994daa4d561c2ab477a7072bb7e40a8d39904c88ebf649a1b89105aabdf35
+SIZE (edirect-14.9.20210423/surgebase-porter2-56e4718818e8_GH0.tar.gz) = 156593
+SHA256 (edirect-14.9.20210423/gedex-inflector-16278e9db813_GH0.tar.gz) = d872f3fb5fcc8d8ff25e915670f7ce867a035cfd7a38a2e01ef1550f8770331b
+SIZE (edirect-14.9.20210423/gedex-inflector-16278e9db813_GH0.tar.gz) = 6784
+SHA256 (edirect-14.9.20210423/klauspost-cpuid-v1.3.1_GH0.tar.gz) = 3bf2da7358c8ed33c05bac2ca733749ade03eadf184d81cc7b16fcbe2e230f1d
+SIZE (edirect-14.9.20210423/klauspost-cpuid-v1.3.1_GH0.tar.gz) = 367144
+SHA256 (edirect-14.9.20210423/pbnjay-memory-b12e5d931931_GH0.tar.gz) = 8903a451771edca578c2aa09848f23027dc02df2c67f675f4dd1aae257a71ad6
+SIZE (edirect-14.9.20210423/pbnjay-memory-b12e5d931931_GH0.tar.gz) = 3076
+SHA256 (edirect-14.9.20210423/mattn-go-colorable-v0.1.8_GH0.tar.gz) = 1027954f9abbe06b6e117e3047af70204dd0eb4f8c27fcd459fb2574b279755f
+SIZE (edirect-14.9.20210423/mattn-go-colorable-v0.1.8_GH0.tar.gz) = 9571
+SHA256 (edirect-14.9.20210423/mattn-go-isatty-v0.0.12_GH0.tar.gz) = addbdc341d7685ed4cc8d2d8a8fd2bd9b784bde00d0ea99fb251039fc10c611c
+SIZE (edirect-14.9.20210423/mattn-go-isatty-v0.0.12_GH0.tar.gz) = 4548
+SHA256 (edirect-14.9.20210423/fiam-gounidecode-8deddbd03fec_GH0.tar.gz) = b763f4eb0d0f130821b52484565b32bae1585c4cb0edc57adb94f13b67765176
+SIZE (edirect-14.9.20210423/fiam-gounidecode-8deddbd03fec_GH0.tar.gz) = 190666
+SHA256 (edirect-14.9.20210423/golang-text-v0.3.5_GH0.tar.gz) = f85d1185ba116cd40ef8cf702fe1d960ed41d039c08fd314dbeb5866f3166f27
+SIZE (edirect-14.9.20210423/golang-text-v0.3.5_GH0.tar.gz) = 8348127
+SHA256 (edirect-14.9.20210423/golang-sys-d5e6a3e2c0ae_GH0.tar.gz) = 6cd44aa33cb0fc4caedadde44b3a943bece0aa67d803c00bfb09b03222845f19
+SIZE (edirect-14.9.20210423/golang-sys-d5e6a3e2c0ae_GH0.tar.gz) = 1539001
diff --git a/biology/ncbi-entrez-direct/files/edirect-test.sh b/biology/ncbi-entrez-direct/files/edirect-test.sh
new file mode 100755
index 000000000000..26da1db4ce88
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/edirect-test.sh
@@ -0,0 +1,33 @@
+#!/bin/sh -ex
+
+##########################################################################
+#   Function description:
+#       Pause until user presses return
+##########################################################################
+
+pause()
+{
+    local junk
+    
+    printf "Press return to continue..."
+    read junk
+}
+
+esearch -db pubmed -query "opsin gene conversion" | \
+  elink -related | \
+  elink -target protein
+pause
+
+esearch -db pubmed -query "lycopene cyclase" | efetch -format abstract
+pause
+
+esearch -db protein -query "lycopene cyclase" | efetch -format fasta
+pause
+
+esearch -db pubmed -query "opsin gene conversion" | \
+  elink -related | efilter -query "tetrachromacy"
+pause
+
+efilter -days 60 -datetype PDAT
+efilter -mindate 1990 -maxdate 1999 -datetype PDAT
+
diff --git a/biology/ncbi-entrez-direct/files/go-build b/biology/ncbi-entrez-direct/files/go-build
new file mode 100755
index 000000000000..d108b7da6209
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/go-build
@@ -0,0 +1,7 @@
+#!/bin/sh -ex
+
+platform=`uname -s`
+export HOME=$(pwd)
+go build -o xtract."$platform" xtract.go
+go build -o transmute."$platform" transmute.go
+go build -o rchive."$platform" rchive.go
diff --git a/biology/ncbi-entrez-direct/files/modules.txt b/biology/ncbi-entrez-direct/files/modules.txt
new file mode 100644
index 000000000000..bf713fd9c42b
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/modules.txt
@@ -0,0 +1,33 @@
+# eutils v0.0.0-00010101000000-000000000000 => ../eutils
+## explicit
+eutils
+# github.com/fatih/color v1.10.0
+## explicit
+github.com/fatih/color
+# github.com/fiam/gounidecode v0.0.0-20150629112515-8deddbd03fec
+## explicit
+github.com/fiam/gounidecode/unidecode
+# github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813
+github.com/gedex/inflector
+# github.com/klauspost/cpuid v1.3.1
+github.com/klauspost/cpuid
+# github.com/mattn/go-colorable v0.1.8
+github.com/mattn/go-colorable
+# github.com/mattn/go-isatty v0.0.12
+github.com/mattn/go-isatty
+# github.com/pbnjay/memory v0.0.0-20201129165224-b12e5d931931
+github.com/pbnjay/memory
+# github.com/stretchr/testify v1.7.0
+## explicit
+# github.com/surge/glog v0.0.0-20141108051140-2578deb2b95c
+## explicit
+# github.com/surgebase/porter2 v0.0.0-20150829210152-56e4718818e8
+## explicit
+github.com/surgebase/porter2
+# golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae
+golang.org/x/sys/unix
+# golang.org/x/text v0.3.5
+golang.org/x/text/runes
+golang.org/x/text/transform
+golang.org/x/text/unicode/norm
+# eutils => ../eutils
diff --git a/biology/ncbi-entrez-direct/files/patch-rchive b/biology/ncbi-entrez-direct/files/patch-rchive
new file mode 100644
index 000000000000..1d3657707136
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/patch-rchive
@@ -0,0 +1,10 @@
+--- rchive.orig	2021-03-04 06:50:29 UTC
++++ rchive
+@@ -43,6 +43,7 @@ case "$osname-$cputype" in
+   Darwin-*arm* )           platform=Darwin ;;
+   CYGWIN_NT-* | MINGW*-* ) platform=CYGWIN_NT ;;
+   Linux-*arm* )            platform=ARM ;;
++  FreeBSD-* )              platform=FreeBSD ;;
+   * )                      platform=UNSUPPORTED ;;
+ esac
+ compiled=$0."$platform"
diff --git a/biology/ncbi-entrez-direct/files/patch-transmute b/biology/ncbi-entrez-direct/files/patch-transmute
new file mode 100644
index 000000000000..198e79551270
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/patch-transmute
@@ -0,0 +1,10 @@
+--- transmute.orig	2021-03-04 06:50:29 UTC
++++ transmute
+@@ -329,6 +329,7 @@ case "$osname-$cputype" in
+   Darwin-*arm* )           platform=Darwin ;;
+   CYGWIN_NT-* | MINGW*-* ) platform=CYGWIN_NT ;;
+   Linux-*arm* )            platform=ARM ;;
++  FreeBSD-* )              platform=FreeBSD ;;
+   * )                      platform=UNSUPPORTED ;;
+ esac
+ compiled=$0."$platform"
diff --git a/biology/ncbi-entrez-direct/files/patch-xtract b/biology/ncbi-entrez-direct/files/patch-xtract
new file mode 100644
index 000000000000..45e2837e7277
--- /dev/null
+++ b/biology/ncbi-entrez-direct/files/patch-xtract
@@ -0,0 +1,10 @@
+--- xtract.orig	2018-04-02 18:50:22 UTC
++++ xtract
+@@ -8,6 +8,7 @@ case "$osname-$cputype" in
+   Darwin-x86_64 )          platform=Darwin ;;
+   CYGWIN_NT-* | MINGW*-* ) platform=CYGWIN_NT ;;
+   Linux-*arm* )            platform=ARM ;;
++  FreeBSD-* )              platform=FreeBSD ;;
+   * )                      platform=UNSUPPORTED ;;
+ esac
+ compiled=$0."$platform"
diff --git a/biology/ncbi-entrez-direct/pkg-descr b/biology/ncbi-entrez-direct/pkg-descr
new file mode 100644
index 000000000000..b8215012904c
--- /dev/null
+++ b/biology/ncbi-entrez-direct/pkg-descr
@@ -0,0 +1,5 @@
+Entrez Direct (EDirect) provides access to the NCBI's suite of interconnected
+databases (publication, sequence, structure, gene, variation, expression, etc.)
+from a UNIX terminal window.
+
+WWW: https://www.ncbi.nlm.nih.gov/books/NBK179288/
diff --git a/biology/ncbi-entrez-direct/pkg-plist b/biology/ncbi-entrez-direct/pkg-plist
new file mode 100644
index 000000000000..536ba728e03f
--- /dev/null
+++ b/biology/ncbi-entrez-direct/pkg-plist
@@ -0,0 +1,55 @@
+bin/accn-at-a-time
+bin/amino-acid-composition
+bin/archive-pubmed
+bin/between-two-genes
+bin/download-ncbi-data
+bin/download-pubmed
+bin/download-sequence
+bin/ecommon.sh
+bin/edirect-test.sh
+bin/edirect.pl
+bin/efetch
+bin/efilter
+bin/einfo
+bin/elink
+bin/epost
+bin/esample
+bin/esearch
+bin/esummary
+bin/exclude-uid-lists
+bin/expand-current
+bin/fetch-pubmed
+bin/filter-stop-words
+bin/gbf2xml
+bin/hlp-xtract.txt
+bin/index-extras
+bin/index-pubmed
+bin/intersect-uid-lists
+bin/join-into-groups-of
+bin/nquire
+bin/phrase-search
+bin/pm-collect
+bin/pm-index
+bin/pm-invert
+bin/pm-merge
+bin/pm-prepare
+bin/pm-promote
+bin/pm-refresh
+bin/pm-stash
+bin/rchive
+bin/rchive.FreeBSD
+bin/reorder-columns
+bin/run-ncbi-converter
+bin/skip-if-file-exists
+bin/sort-uniq-count
+bin/sort-uniq-count-rank
+bin/stream-pubmed
+bin/theme-aliases
+bin/transmute
+bin/transmute.FreeBSD
+bin/word-at-a-time
+bin/xml2json
+bin/xml2tbl
+bin/xtract
+bin/xtract.FreeBSD
+bin/xy-plot



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202104242341.13ONfAJV015117>