diff --git a/biology/ucsc-userapps/Makefile b/biology/ucsc-userapps/Makefile new file mode 100644 index 000000000000..7a3244c70fcb --- /dev/null +++ b/biology/ucsc-userapps/Makefile @@ -0,0 +1,76 @@ +# Created by: J. Bacon + +PORTNAME= ucsc-userapps +DISTVERSION= 413 +CATEGORIES= biology perl5 python +MASTER_SITES= http://hgdownload.cse.ucsc.edu/admin/exe/userApps.archive/ +DISTNAME= userApps.v${PORTVERSION}.src + +MAINTAINER= jwb@FreeBSD.org +COMMENT= Command line tools from the UCSC Genome Browser project + +LICENSE= UCSC-GB +LICENSE_NAME= UCSC Genome Browser License +LICENSE_TEXT= To the best of our knowledge, all of the tools installed by\ + this port are freely available. However, a license is\ + required for commercial download and installation of some\ + binaries and source code in the UCSC Genome Browser\ + distribution.\n\nContact UCSC directly if you are using these\ + tools for commercial purposes.\n\nSee\ + https://genome.ucsc.edu/license/ for full terms. +LICENSE_PERMS= no-dist-mirror no-dist-sell no-pkg-mirror no-pkg-sell + +ONLY_FOR_ARCHS= amd64 +ONLY_FOR_ARCHS_REASON= _mm_popcnt_u64 + +BUILD_DEPENDS= bash:shells/bash +LIB_DEPENDS= libiconv.so:converters/libiconv \ + libmysqlclient.so:databases/mysql57-client \ + libpng.so:graphics/png +RUN_DEPENDS= bash:shells/bash + +USES= gmake localbase:ldflags shebangfix perl5 python:3.6+ ssl tar:tgz + +RESTRICTED= Redistribution is limited, see license + +SHEBANG_FILES= kent/src/checkUmask.sh \ + kent/src/utils/bigHeat \ + kent/src/utils/chromToUcsc/chromToUcsc \ + kent/src/utils/tdbRename \ + kent/src/utils/tdbSort \ + kent/src/utils/trackDbIndexBb/trackDbIndexBb \ + kent/src/utils/ucscApiClient \ + kent/src/utils/webSync + +WRKSRC= ${WRKDIR}/userApps +CFLAGS+= -fcommon +MAKEFILE= [Mm]akefile +MAKE_ENV= BINDIR=${WRKSRC}/bin + +SUB_FILES= ucsc-shell + +# Build only non-commercial tools +do-build: + @${MV} ${WRKSRC}/kent/src/inc/uuid.h ${WRKSRC}/kent/src/inc/my_uuid.h + @${MKDIR} ${WRKSRC}/bin + @(cd ${WRKSRC}/kent/src/lib && ${DO_MAKE_BUILD}) + @(cd ${WRKSRC}/kent/src/htslib && ${DO_MAKE_BUILD}) + @(cd ${WRKSRC}/kent/src/jkOwnLib && ${DO_MAKE_BUILD}) + @(cd ${WRKSRC}/kent/src/hg/lib && ${DO_MAKE_BUILD}) + @(cd ${WRKSRC}/kent/src/utils && ${DO_MAKE_BUILD}) + +do-install: + @${MKDIR} ${WRKSRC}/scripts ${WRKSRC}/binaries + @${CP} $$(file ${WRKSRC}/bin/* | fgrep ELF | cut -d : -f 1) \ + ${WRKSRC}/binaries + @${CP} $$(file ${WRKSRC}/bin/* | fgrep -v ELF | cut -d : -f 1) \ + ${WRKSRC}/scripts + @${MKDIR} ${STAGEDIR}${PREFIX}/userapps/bin + ${INSTALL_PROGRAM} ${WRKSRC}/binaries/* \ + ${STAGEDIR}${PREFIX}/userapps/bin + ${INSTALL_SCRIPT} ${WRKSRC}/scripts/* \ + ${STAGEDIR}${PREFIX}/userapps/bin + ${INSTALL_SCRIPT} ${WRKDIR}/ucsc-shell \ + ${STAGEDIR}${PREFIX}/bin + +.include diff --git a/biology/ucsc-userapps/distinfo b/biology/ucsc-userapps/distinfo new file mode 100644 index 000000000000..a75f1d9a21b0 --- /dev/null +++ b/biology/ucsc-userapps/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1619366655 +SHA256 (userApps.v413.src.tgz) = 91c51fec26bc61ea0dd9c4d0d13c76ce26e1c7d7f7dddbd3067c70beaec0af19 +SIZE (userApps.v413.src.tgz) = 19186621 diff --git a/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_eap_eapFinish_eapFinish.c b/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_eap_eapFinish_eapFinish.c new file mode 100644 index 000000000000..f97872c005d2 --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_eap_eapFinish_eapFinish.c @@ -0,0 +1,11 @@ +--- kent/src/hg/encode3/eap/eapFinish/eapFinish.c.orig 2021-04-14 11:23:30 UTC ++++ kent/src/hg/encode3/eap/eapFinish/eapFinish.c +@@ -3,7 +3,7 @@ + + /* Copyright (C) 2014 The Regents of the University of California + * See README in this or parent directory for licensing information. */ +-#include ++#include + #include "common.h" + #include "linefile.h" + #include "hash.h" diff --git a/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_encodeDataWarehouse_edwWebRegisterScript_edwWebRegisterScript.c b/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_encodeDataWarehouse_edwWebRegisterScript_edwWebRegisterScript.c new file mode 100644 index 000000000000..cdd532d146eb --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_hg_encode3_encodeDataWarehouse_edwWebRegisterScript_edwWebRegisterScript.c @@ -0,0 +1,11 @@ +--- kent/src/hg/encode3/encodeDataWarehouse/edwWebRegisterScript/edwWebRegisterScript.c.orig 2021-04-14 11:23:12 UTC ++++ kent/src/hg/encode3/encodeDataWarehouse/edwWebRegisterScript/edwWebRegisterScript.c +@@ -2,7 +2,7 @@ + + /* Copyright (C) 2014 The Regents of the University of California + * See README in this or parent directory for licensing information. */ +-#include ++#include + #include "common.h" + #include "linefile.h" + #include "hash.h" diff --git a/biology/ucsc-userapps/files/patch-kent_src_inc_common.mk b/biology/ucsc-userapps/files/patch-kent_src_inc_common.mk new file mode 100644 index 000000000000..b083cbf175c9 --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_inc_common.mk @@ -0,0 +1,13 @@ +--- kent/src/inc/common.mk.orig 2021-04-02 22:47:03 UTC ++++ kent/src/inc/common.mk +@@ -61,6 +61,10 @@ else + endif + endif + ++ifeq ($(UNAME_S),FreeBSD) ++ ICONVLIB=-L${LOCALBASE}/lib -liconv ++endif ++ + # autodetect if openssl is installed + ifeq (${SSLDIR},) + SSLDIR = /usr/include/openssl diff --git a/biology/ucsc-userapps/files/patch-kent_src_inc_uuid.h b/biology/ucsc-userapps/files/patch-kent_src_inc_uuid.h new file mode 100644 index 000000000000..b42058548bed --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_inc_uuid.h @@ -0,0 +1,11 @@ +--- kent/src/inc/uuid.h.orig 2021-04-14 11:17:54 UTC ++++ kent/src/inc/uuid.h +@@ -5,7 +5,7 @@ + * + * If you use this file you need to add -luuid to your link line. */ + +-#include ++#include + + #define UUID_STRING_SIZE 37 + diff --git a/biology/ucsc-userapps/files/patch-kent_src_lib_uuid.c b/biology/ucsc-userapps/files/patch-kent_src_lib_uuid.c new file mode 100644 index 000000000000..e9dcb600fb0c --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_lib_uuid.c @@ -0,0 +1,11 @@ +--- kent/src/lib/uuid.c.orig 2021-04-14 11:22:38 UTC ++++ kent/src/lib/uuid.c +@@ -6,7 +6,7 @@ + * If you use this file you need to add -luuid to your link line. */ + + #include "common.h" +-#include "uuid.h" ++#include "my_uuid.h" + + char *makeUuidString(char buf[37]) + /* Generate a random uuid and put it in the usual hex-plus-dashes form */ diff --git a/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_dnsInfo.c b/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_dnsInfo.c new file mode 100644 index 000000000000..5e2e14e5dab3 --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_dnsInfo.c @@ -0,0 +1,10 @@ +--- kent/src/utils/dnsInfo/dnsInfo.c.orig 2021-04-18 01:19:08 UTC ++++ kent/src/utils/dnsInfo/dnsInfo.c +@@ -7,6 +7,7 @@ + #include + #include + #include ++#include + #include "linefile.h" + #include "hash.h" + #include "options.h" diff --git a/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_makefile b/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_makefile new file mode 100644 index 000000000000..ddb6b1648afb --- /dev/null +++ b/biology/ucsc-userapps/files/patch-kent_src_utils_dnsInfo_makefile @@ -0,0 +1,11 @@ +--- kent/src/utils/dnsInfo/makefile.orig 2021-04-18 01:20:21 UTC ++++ kent/src/utils/dnsInfo/makefile +@@ -1,7 +1,7 @@ + kentSrc = ../.. + include ../../inc/common.mk + +-L += -lm -lresolv ++L += -lm + MYLIBDIR = ../../lib/$(MACHTYPE) + MYLIBS = $(MYLIBDIR)/jkweb.a + diff --git a/biology/ucsc-userapps/files/ucsc-shell.in b/biology/ucsc-userapps/files/ucsc-shell.in new file mode 100755 index 000000000000..fba15c96b047 --- /dev/null +++ b/biology/ucsc-userapps/files/ucsc-shell.in @@ -0,0 +1,28 @@ +#!/bin/sh -e + +ucsc_bin=%%PREFIX%%/userapps/bin +cat << EOM + +Adding $ucsc_bin to \$PATH. + +UCSC kent utils contains commands that conflict with other tools, including +at least "calc", "mktime", and "stringify". + +The other commands with these names may serve entirely different functions +and will not be accessible while running this shell unless you refer to them +by their absolute path name (e.g. /usr/local/bin/calc), which is not portable, +BTW, so don't hard-code such paths into your scripts. + +Type "exit" or "Ctrl+D" to return to your normal shell. + +EOM + +export PATH=${ucsc_bin}:$PATH + +# FIXME: Update shell prompts to include (ucsc-kent)? + +# Invoke the user's chosen shell +if echo $SHELL | egrep -q '/t?csh'; then + args='-f' +fi +exec $SHELL $args diff --git a/biology/ucsc-userapps/pkg-descr b/biology/ucsc-userapps/pkg-descr new file mode 100644 index 000000000000..d2d01a997ea9 --- /dev/null +++ b/biology/ucsc-userapps/pkg-descr @@ -0,0 +1,8 @@ +These are the command-line bioinformatics utilities associated with the UCSC +genome browser. Care has been taken to install only the freely available +tools. However, the license information at https://genome.ucsc.edu/license/ +is not entirely clear and we may add non-free utilities in the future. + +Contact UCSC if you are using this port for commercial purposes. + +WWW: http://hgdownload.cse.ucsc.edu/admin/exe/ diff --git a/biology/ucsc-userapps/pkg-message b/biology/ucsc-userapps/pkg-message new file mode 100644 index 000000000000..3b40fc2039ab --- /dev/null +++ b/biology/ucsc-userapps/pkg-message @@ -0,0 +1,14 @@ +[ +{ type: install + message: <