From nobody Thu Aug 10 17:20:36 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RMDGD5ytJz4pnGv; Thu, 10 Aug 2023 17:20:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RMDGD5lyJz4PHq; Thu, 10 Aug 2023 17:20:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1691688036; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZTtiXAa1HaRoVxeENxHDnLeYpgq+HbVnfdcbNmrZrio=; b=XHbT0A45GpOXbo4RWvkOhtRxsl1zFKxHznkHtJRneqXR73Tqr2QeNVZiSB8KwWctIB7kR1 LjT+/N0njvg3z6v00SFrtMTA6eeHQMb5Zeh6eVG1oHIZhWTOOa/gar2xcBa56DFyovUxs4 l8WAOcD1cJkIjuFuZr64RDZ1mUf2l66H54j1Mga2EMZEZBz0mR0pwjpaVKkYLq+7Y3Qisz 8g77wrMc6E9l88sLbm6h7ERTLerNnOK5Nh4ptP/CRt0hZ1erYtYoEv6ABypdJ6KMazigsf QjK42OlwwMbayD8vNhGjqF0FiqVBx+lLigSQkZ3pnuNIokFOsdhgF85CI+5SFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1691688036; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZTtiXAa1HaRoVxeENxHDnLeYpgq+HbVnfdcbNmrZrio=; b=AVlC7X8LLLFnf8lYx9KFK7K0oeYrjUfhXspE6G5ofzpR47F59McJjvVK7e9FHzMPGKEPD0 E3FONkjn4cw7/YwP40j5JROPjUpuf5Ya0d4gEcwf1/cS1akSVlbMPdXXG8qAK1MbQbejbn 1kfP4kp28HjTsDookxsGx7fMwn+EFze6JYT8ApCkLBMEBE2n9ACoUi1H58BWc/UeGKtMqZ iOZHVU0M7zsdVGsZC1nDrrcr4ZqGoqmHoDVUbC8vpmwVJrVl3EBcNYl3byWUrvXEZ7HtDq mEgT52IKgbrqS8zaRYnEyx2MA53Oowq6hyueMeHKED/yB0IYIz8nbUQ1T0FQZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1691688036; a=rsa-sha256; cv=none; b=HR45UwiFaAEjRbRUYZEqkGXjSweeMRr4r6jzqrLcjZPe8/XSgldMCnUQ9ZHFESFXodRgld ZBwOwUKmzgz+Tpl7pTK+k0ab+lJuD/rZ8SRxkbnxWXnUmm3z7+z3qVRS5Pp3zZmfJ9Lpu7 bnw+vvWxYP5K6+6jon8HFzwDht7Rxr5bpjBe3e5conjG7lpbh96u8cYw2ycyb5miqpMJct stGZ2wekGPftdBeUD9yw9o+rLPcoExf6hZRSKXZZEp+gXN/ac6JM2Br+eCMhRw3/UagiB0 v5lR3mouxRjXXZt9Mjm2yd4oylZfF7ifW0MeoHocdC8tkVoh+g8QN2PN4KK4IA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RMDGD4q2mz15R2; Thu, 10 Aug 2023 17:20:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 37AHKaQD019779; Thu, 10 Aug 2023 17:20:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 37AHKaX7019776; Thu, 10 Aug 2023 17:20:36 GMT (envelope-from git) Date: Thu, 10 Aug 2023 17:20:36 GMT Message-Id: <202308101720.37AHKaX7019776@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: "Jason W. Bacon" Subject: git: 0f2f80ca3833 - main - biology/sra-tools: Update to 3.0.6 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jwb X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0f2f80ca3833a64ea2d60aa706cf794d5e0ffd63 Auto-Submitted: auto-generated The branch main has been updated by jwb: URL: https://cgit.FreeBSD.org/ports/commit/?id=0f2f80ca3833a64ea2d60aa706cf794d5e0ffd63 commit 0f2f80ca3833a64ea2d60aa706cf794d5e0ffd63 Author: Jason W. Bacon AuthorDate: 2023-08-10 17:17:24 +0000 Commit: Jason W. Bacon CommitDate: 2023-08-10 17:17:24 +0000 biology/sra-tools: Update to 3.0.6 Major code and build system rework since 2.11 Now supports aarch64, unblocking rna-seq and atac-seq metaports Changes: https://github.com/ncbi/sra-tools/commits/master Reported by: portscout --- biology/sra-tools/Makefile | 128 +++----- biology/sra-tools/distinfo | 12 +- biology/sra-tools/files/Makefile.bsd | 72 ----- biology/sra-tools/files/byteswap.h | 37 +-- biology/sra-tools/files/endian.h | 2 + biology/sra-tools/files/ld.bsd.clang.sh | 47 --- biology/sra-tools/files/ld.bsd.cmn.sh | 158 ---------- biology/sra-tools/files/ld.bsd.dlib.sh | 308 ------------------- biology/sra-tools/files/ld.bsd.exe.sh | 326 --------------------- biology/sra-tools/files/ld.bsd.gcc.sh | 47 --- biology/sra-tools/files/ld.bsd.ln.sh | 98 ------- biology/sra-tools/files/ld.bsd.slib.sh | 146 --------- biology/sra-tools/files/os-native.h | 43 +++ biology/sra-tools/files/patch-CMakeLists.txt | 13 + biology/sra-tools/files/patch-build_env.cmake | 56 ++++ .../sra-tools/files/patch-build_ld.linux.exe.sh | 11 - biology/sra-tools/files/patch-hdf5 | 30 -- .../sra-tools/files/patch-libs_ascp_CMakeLists.txt | 27 ++ .../patch-libs_general-writer_general-writer.cpp | 10 + .../files/patch-ncbi-vdb_build_Makefile.clang | 30 -- .../files/patch-ncbi-vdb_build_Makefile.env | 25 -- .../files/patch-ncbi-vdb_build_Makefile.gcc | 35 --- .../files/patch-ncbi-vdb_build_Makefile.install | 11 - .../files/patch-ncbi-vdb_build_Makefile.shell | 31 -- .../sra-tools/files/patch-ncbi-vdb_build_env.cmake | 47 +++ .../patch-ncbi-vdb_interfaces_os_sun_atomic32.h | 85 ------ .../patch-ncbi-vdb_libs_align_samextract-lib.cpp | 11 + .../files/patch-ncbi-vdb_libs_ext_Makefile | 12 - .../files/patch-ncbi-vdb_libs_kapp_CMakeLists.txt | 19 ++ .../files/patch-ncbi-vdb_libs_kapp_mac_ram.c | 17 ++ .../files/patch-ncbi-vdb_libs_kfc_CMakeLists.txt | 25 ++ .../files/patch-ncbi-vdb_libs_kfg_config.c | 33 ++- .../files/patch-ncbi-vdb_libs_kfs_CMakeLists.txt | 35 +++ .../files/patch-ncbi-vdb_libs_kfs_unix_sysdir.c | 11 + .../files/patch-ncbi-vdb_libs_klib_CMakeLists.txt | 18 ++ .../files/patch-ncbi-vdb_libs_klib_hashfile.c | 20 ++ .../files/patch-ncbi-vdb_libs_klib_unix_systime.c | 13 +- .../files/patch-ncbi-vdb_libs_kns_CMakeLists.txt | 20 ++ .../files/patch-ncbi-vdb_libs_kns_manager.c | 11 + .../files/patch-ncbi-vdb_libs_kns_unix_syssock.c | 2 +- .../files/patch-ncbi-vdb_libs_kproc_CMakeLists.txt | 21 ++ .../files/patch-ncbi-vdb_libs_ktst_CMakeLists.txt | 18 ++ .../files/patch-ncbi-vdb_libs_ncbi-vdb_Makefile | 20 -- .../files/patch-ncbi-vdb_libs_search_Makefile | 12 - .../files/patch-ncbi-vdb_libs_vfs_CMakeLists.txt | 25 ++ .../files/patch-ncbi-vdb_setup_konfigure.perl | 243 --------------- .../files/patch-ncbi-vdb_setup_os-arch.prl | 20 -- .../files/patch-ncbi-vdb_test_kfg_kfgtest.cpp | 12 +- .../files/patch-ncbi-vdb_test_klib_printf-test.c | 8 +- .../files/patch-ncbi-vdb_test_kns_Makefile | 19 -- .../patch-ncbi-vdb_test_vdb_test-dependencies.cpp | 11 - ...h-ncbi-vdb_test_vdb_test-dependencies__dflt.cpp | 12 + ...s_redirect-rejected-names-cgi-http-to-https.cpp | 11 - biology/sra-tools/files/patch-setup_install.perl | 13 - biology/sra-tools/files/patch-setup_konfigure.perl | 121 -------- .../files/patch-tools_bam-loader_loader-imp.c | 10 - .../sra-tools/files/patch-tools_copycat_Makefile | 11 - .../files/patch-tools_driver-tool_Makefile | 16 - .../files/patch-tools_driver-tool_cmdline.cpp | 13 - .../patch-tools_driver-tool_utf8proc_Makefile | 11 - ...-tools_external_driver-tool_file-path.posix.cpp | 20 ++ .../patch-tools_external_driver-tool_sratools.cpp | 25 ++ ...ch-tools_external_vdb-config_tui_CMakeLists.txt | 20 ++ .../patch-tools_fastq-loader_spot-assembler.c | 11 - ...tch-tools_loaders_fastq-loader_spot-assembler.c | 17 ++ .../sra-tools/files/patch-tools_sra-sort_Makefile | 13 - .../files/patch-tools_util_validate-names4.c | 13 - biology/sra-tools/pkg-descr | 3 - biology/sra-tools/pkg-plist | 293 +++++++++++++++--- 69 files changed, 898 insertions(+), 2226 deletions(-) diff --git a/biology/sra-tools/Makefile b/biology/sra-tools/Makefile index b7a0da7240bf..39dd02760918 100644 --- a/biology/sra-tools/Makefile +++ b/biology/sra-tools/Makefile @@ -1,109 +1,67 @@ PORTNAME= sra-tools -DISTVERSION= 2.11.0 -PORTREVISION= 4 -CATEGORIES= biology +DISTVERSION= 3.0.6 +CATEGORIES= biology java MAINTAINER= jwb@FreeBSD.org COMMENT= NCBI's toolkit for handling data in INSDC Sequence Read Archives -WWW= https://github.com/ncbi/sra-tools/wiki +WWW= https://github.com/ncbi/sra-tools LICENSE= PD LGPL21+ LICENSE_COMB= multi LICENSE_FILE_PD= ${WRKSRC}/LICENSE LICENSE_DISTFILES_LGPL21+ = -ONLY_FOR_ARCHS= amd64 -ONLY_FOR_ARCHS_REASON= NCBI-VDB requires SSE2 instructions, no 32-bit support +# Untested on other platforms, aarch64 support was recently added upstream +ONLY_FOR_ARCHS= aarch64 amd64 +ONLY_FOR_ARCHS_REASON= Upstream explicitly supports specific platforms -BUILD_DEPENDS= bash:shells/bash \ - ${LOCALBASE}/lib/libngs-c++.a:biology/ngs-sdk +BUILD_DEPENDS= bash:shells/bash LIB_DEPENDS= libxml2.so:textproc/libxml2 \ libhdf5.so:science/hdf5 \ - libepoll-shim.so:devel/libepoll-shim + libepoll-shim.so:devel/libepoll-shim \ + libzstd.so:archivers/zstd -USES= compiler:c11 gmake localbase:ldflags perl5 shebangfix -USE_PERL5= build +USES= bison cmake shebangfix USE_GITHUB= yes +USE_LDCONFIG= ${PREFIX}/lib64 +USE_JAVA= yes -SHEBANG_GLOB= *.sh *.pl -GH_ACCOUNT= ncbi -GH_TUPLE+= ncbi:ngs:${DISTVERSION}:ngs/ngs # ported as biology/ngs-sdk -GH_TUPLE+= ncbi:ncbi-vdb:${DISTVERSION}:vdb/ncbi-vdb - -GNU_CONFIGURE= yes -CONFIGURE_ARGS= --with-ngs-sdk-prefix=${LOCALBASE} \ - --with-ncbi-vdb-sources=${NCBI_VDB_WRKSRC} \ - --with-xml2-prefix=${LOCALBASE} \ - --with-hdf5-prefix=${LOCALBASE} \ - CC="${CC}" CXX="${CXX}" TOOLS="${CHOSEN_COMPILER_TYPE}" \ - --with-ncbi-vdb-build=${NCBI_VDB_WRKSRC}/amd64-portbld-freebsd$$(${FREEBSD_RELEASE}) -MAKE_ARGS= CCNAME=${CC} CXXNAME=${CXX} PKGCFLAGS="${CFLAGS}" \ - INST_ETCDIR=${STAGEDIR}${PREFIX}/etc - -NCBI_VDB_WRKSRC= ${WRKSRC}/ncbi-vdb -NCBI_VDB_FILESDIR= ${FILESDIR} -FREEBSD_RELEASE= uname -r | cut -d - -f 1 - -CFLAGS+= -I${WRKSRC}/interfaces/os/sun -CXXFLAGS+= -I${WRKSRC}/interfaces/os/sun - -CONFLICTS_INSTALL= kget +# Builds with earlier versions, but ngs-doc plist differs if jdk17 is present +JAVA_VERSION= 17+ -BINARY_ALIAS= gcc=${CC} g++=${CXX} +OPTIONS_DEFINE= EXAMPLES -# for port developers, building with these options may fail -OPTIONS_DEFINE= DEBUG OPTIMIZED_CFLAGS TEST -DEBUG_PREVENTS= OPTIMIZED_CFLAGS -DEBUG_CONFIGURE_WITH= debug -OPTIMIZED_CFLAGS_MAKE_ARGS_OFF= OPT="" -TEST_TEST_TARGET= test -TEST_USES= python - -# ncbi-vdb build extras -VDB_CONFIGURE_ARGS= \ - --with-xml2-prefix=${LOCALBASE} \ - --with-hdf5-prefix=${LOCALBASE} \ - --prefix=${PREFIX} \ - --build=amd64-portbld-freebsd$$(${FREEBSD_RELEASE}) \ - CC="${CC}" CXX="${CXX}" TOOLS="${CHOSEN_COMPILER_TYPE}" -VDB_MAKE_ARGS+= -j 1 CCNAME=${CC} CXXNAME=${CXX} PKGCFLAGS="${CFLAGS}" -MAKE_ENV+= CPATH="${LOCALBASE}/include/libepoll-shim" -CFLAGS+= -I${WRKSRC}/lib - -pre-patch: - @${CP} ${FILESDIR}/Makefile.bsd ${NCBI_VDB_WRKSRC}/build/ - @${CP} ${FILESDIR}/ld.bsd.*.sh ${NCBI_VDB_WRKSRC}/build/ - @${MKDIR} ${NCBI_VDB_WRKSRC}/interfaces/os/bsd - @${CP} -p ${NCBI_VDB_WRKSRC}/interfaces/os/mac/endian.h \ - ${NCBI_VDB_WRKSRC}/interfaces/os/bsd/ +SHEBANG_GLOB= *.sh +GH_ACCOUNT= ncbi +GH_TUPLE+= ncbi:ncbi-vdb:${DISTVERSION}:vdb/ncbi-vdb -post-patch: - @${GREP} -q '@@PREFIX@@' ${WRKSRC}/ncbi-vdb/libs/kfg/config.c || (echo "@@PREFIX@@ in file/patch-libs_kfg_config.c is overwritten probably due to using 'make makepatch'"; exit 1) - @${REINPLACE_CMD} -e 's#@@PREFIX@@#"${PREFIX}"#' ${WRKSRC}/ncbi-vdb/libs/kfg/config.c - @${LN} -s ${WRKSRC}/ncbi-vdb/interfaces/cc/gcc/x86_64 ${WRKSRC}/ncbi-vdb/interfaces/cc/gcc/amd64 +WITH_DEBUG= yes +CMAKE_ARGS+= -DVDB_LIBDIR:STRING=${WRKSRC}/ncbi-vdb/build/lib -post-patch-TEST-on: - @${REINPLACE_CMD} -e 's|python|${PYTHON_CMD}|' ${WRKSRC}/test/kget/Makefile +post-extract: + @${MKDIR} ${WRKSRC}/ncbi-vdb/interfaces/os/bsd + @${CP} ${FILESDIR}/*.h ${WRKSRC}/ncbi-vdb/interfaces/os/bsd + # cd ${WRKDIR} && ${LN} -s ${WRKSRC}/ncbi-vdb . pre-configure: - @${CP} ${NCBI_VDB_WRKSRC}/setup/os-arch.prl ${WRKSRC}/setup/os-arch.prl - # same as in biology/ncbi-vdb - @${CP} ${NCBI_VDB_FILESDIR}/Makefile.bsd ${WRKSRC}/build/ - @${CP} ${NCBI_VDB_WRKSRC}/build/ld.bsd.*.sh ${WRKSRC}/build/ - @${MKDIR} ${WRKSRC}/interfaces/override - @${CP} ${NCBI_VDB_WRKSRC}/interfaces/os/sun/atomic32.h ${WRKSRC}/interfaces/override - @${CP} ${FILESDIR}/byteswap.h ${WRKSRC}/interfaces/override - @cd ${WRKSRC}/ncbi-vdb && ./configure ${VDB_CONFIGURE_ARGS} - @${ECHO} ${CHOSEN_COMPILER_TYPE} > ${WRKSRC}/ncbi-vdb/build/COMP - @cd ${WRKSRC}/ncbi-vdb && ${DO_MAKE_BUILD} ${VDB_MAKE_ARGS} - -post-build-TEST-on: do-test - -do-install: - cd ${WRKSRC}/amd64-portbld-freebsd*/sra-tools/bsd/clang/*/rel/bin && \ - for f in `ls *.${PORTVERSION}`; do \ - ${INSTALL_PROGRAM} $${f} \ - ${STAGEDIR}${PREFIX}/bin/`basename $${f%%.${PORTVERSION}}`; \ - done + # This follows a static patch. Run "make clean patch" before + # updating the patch. + ${REINPLACE_CMD} -e 's|/usr/local/etc/ncbi|${PREFIX}/etc/ncbi|g' \ + ${WRKSRC}/ncbi-vdb/libs/kfg/config.c + ${REINPLACE_CMD} -e 's|/usr/local/bin|${PREFIX}/bin|g' \ + ${WRKSRC}/tools/external/driver-tool/file-path.posix.cpp + cd ${WRKSRC}/ncbi-vdb/build && cmake .. && make + +post-stage: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/*.${DISTVERSION} + ${MV} ${STAGEDIR}${PREFIX}/share/examples ${STAGEDIR}${PREFIX}/share/examples-sratools + ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + ${MV} ${STAGEDIR}${PREFIX}/share/examples-sratools/* ${STAGEDIR}${EXAMPLESDIR} + ${RMDIR} ${STAGEDIR}${PREFIX}/share/examples-sratools + ${MV} ${STAGEDIR}${PREFIX}/share/examples-java ${STAGEDIR}${EXAMPLESDIR}/java + ${MV} ${STAGEDIR}${PREFIX}/share/examples-python ${STAGEDIR}${EXAMPLESDIR}/python + +post-stage-EXAMPLES-off: + ${RM} -r ${STAGEDIR}${EXAMPLESDIR} .include diff --git a/biology/sra-tools/distinfo b/biology/sra-tools/distinfo index fa75acf23fe6..db2f69729c91 100644 --- a/biology/sra-tools/distinfo +++ b/biology/sra-tools/distinfo @@ -1,7 +1,5 @@ -TIMESTAMP = 1624382289 -SHA256 (ncbi-sra-tools-2.11.0_GH0.tar.gz) = 10ac0a4d1fafc274bc107de811891d3e803d0713a247581dece4448231883810 -SIZE (ncbi-sra-tools-2.11.0_GH0.tar.gz) = 8966605 -SHA256 (ncbi-ngs-2.11.0_GH0.tar.gz) = 5fde50784760c00b403c2cc42ead15a4e9477697ee439f0a16edb4de3f52dfcc -SIZE (ncbi-ngs-2.11.0_GH0.tar.gz) = 1100365 -SHA256 (ncbi-ncbi-vdb-2.11.0_GH0.tar.gz) = 9a65e3885b9ae1ebecbec871f04ce3162ac3764fb556ecdc8c1e61993e2164aa -SIZE (ncbi-ncbi-vdb-2.11.0_GH0.tar.gz) = 22277539 +TIMESTAMP = 1691599515 +SHA256 (ncbi-sra-tools-3.0.6_GH0.tar.gz) = 9fecfd819ee9beaf8a1d3e4b76a5d49e747bc064525b40416e0730a168986348 +SIZE (ncbi-sra-tools-3.0.6_GH0.tar.gz) = 44957431 +SHA256 (ncbi-ncbi-vdb-3.0.6_GH0.tar.gz) = 4b6f93336bf8664fdcc151d41ea0793f0b0f88cfcb7c2aa049f162a72f905223 +SIZE (ncbi-ncbi-vdb-3.0.6_GH0.tar.gz) = 18972238 diff --git a/biology/sra-tools/files/Makefile.bsd b/biology/sra-tools/files/Makefile.bsd deleted file mode 100644 index 7692ec277948..000000000000 --- a/biology/sra-tools/files/Makefile.bsd +++ /dev/null @@ -1,72 +0,0 @@ -# =========================================================================== -# -# PUBLIC DOMAIN NOTICE -# National Center for Biotechnology Information -# -# This software/database is a "United States Government Work" under the -# terms of the United States Copyright Act. It was written as part of -# the author's official duties as a United States Government employee and -# thus cannot be copyrighted. This software/database is freely available -# to the public for use. The National Library of Medicine and the U.S. -# Government have not placed any restriction on its use or reproduction. -# -# Although all reasonable efforts have been taken to ensure the accuracy -# and reliability of the software and data, the NLM and the U.S. -# Government do not and cannot warrant the performance or results that -# may be obtained by using this software or data. The NLM and the U.S. -# Government disclaim all warranties, express or implied, including -# warranties of performance, merchantability or fitness for any particular -# purpose. -# -# Please cite the author in any work or product based on this material. -# -# =========================================================================== - - -# default compiler -ifeq (,$(COMP)) - COMP = clang -endif - -# handle attempts to set cross-compilation architecture -# note that if your installation is set up for cross compilation, -# you can try to enable it on your own. -ifeq (i386,$(ARCH)) -i386: - @ true -x86_64: - @ echo "FreeBSD builds do not support cross-compilation to this architecture" -endif - -ifeq (x86_64,$(ARCH)) -i386: - @ echo "FreeBSD builds do not support cross-compilation to this architecture" -x86_64: - @ true -endif - -.PHONY: i386 x86_64 - - -# library prefix -LPFX = lib - -# file extensions -OBJX = o -LOBX = pic.o -LIBX = a -SHLX = so - -# compilation defines -DEFINES := -DBSD -DUNIX -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DPKGNAME=bsd$(BITS) - -# FreeBSD is a Unix variant; for most cases, linux sources do well -OS_DAD = linux -OS_GDAD = unix - -# flex+bison: on Mac, use source-controlled generated .c/.h files -YACC = @ true -LEX = @ true - -# build matrix -COMPILERS = CLANG GCC diff --git a/biology/sra-tools/files/byteswap.h b/biology/sra-tools/files/byteswap.h index ef07fe98db64..807bea1289b8 100644 --- a/biology/sra-tools/files/byteswap.h +++ b/biology/sra-tools/files/byteswap.h @@ -1,40 +1,15 @@ -/*=========================================================================== -* -* PUBLIC DOMAIN NOTICE -* National Center for Biotechnology Information -* -* This software/database is a "United States Government Work" under the -* terms of the United States Copyright Act. It was written as part of -* the author's official duties as a United States Government employee and -* thus cannot be copyrighted. This software/database is freely available -* to the public for use. The National Library of Medicine and the U.S. -* Government have not placed any restriction on its use or reproduction. -* -* Although all reasonable efforts have been taken to ensure the accuracy -* and reliability of the software and data, the NLM and the U.S. -* Government do not and cannot warrant the performance or results that -* may be obtained by using this software or data. The NLM and the U.S. -* Government disclaim all warranties, express or implied, including -* warranties of performance, merchantability or fitness for any particular -* purpose. -* -* Please cite the author in any work or product based on this material. -* -* =========================================================================== -* -*/ -#ifndef _h_byteswap_ -#define _h_byteswap_ +#ifndef _freebsd_byteswap_h_ +#define _freebsd_byteswap_h_ -#include #include -/* N.B. Sun's BSWAP seems to be macro-based, - meaning that (x) will be evaluated multiple times */ +#define __BYTE_ORDER _BYTE_ORDER +#define __BIG_ENDIAN _BIG_ENDIAN +#define __LITTLE_ENDIAN _LITTLE_ENDIAN #define bswap_16(x) bswap16 (x) #define bswap_32(x) bswap32 (x) #define bswap_64(x) bswap64 (x) -#endif /* _h_byteswap_ */ +#endif diff --git a/biology/sra-tools/files/endian.h b/biology/sra-tools/files/endian.h new file mode 100644 index 000000000000..c4b8fc49f735 --- /dev/null +++ b/biology/sra-tools/files/endian.h @@ -0,0 +1,2 @@ + +#include diff --git a/biology/sra-tools/files/ld.bsd.clang.sh b/biology/sra-tools/files/ld.bsd.clang.sh deleted file mode 100755 index 61c7779adcf1..000000000000 --- a/biology/sra-tools/files/ld.bsd.clang.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/local/bin/bash -# =========================================================================== -# -# PUBLIC DOMAIN NOTICE -# National Center for Biotechnology Information -# -# This software/database is a "United States Government Work" under the -# terms of the United States Copyright Act. It was written as part of -# the author's official duties as a United States Government employee and -# thus cannot be copyrighted. This software/database is freely available -# to the public for use. The National Library of Medicine and the U.S. -# Government have not placed any restriction on its use or reproduction. -# -# Although all reasonable efforts have been taken to ensure the accuracy -# and reliability of the software and data, the NLM and the U.S. -# Government do not and cannot warrant the performance or results that -# may be obtained by using this software or data. The NLM and the U.S. -# Government disclaim all warranties, express or implied, including -# warranties of performance, merchantability or fitness for any particular -# purpose. -# -# Please cite the author in any work or product based on this material. -# -# =========================================================================== - -# define linker params -LD_EXPORT_GLOBAL="-Wl,--export-dynamic" -LD_MULTIPLE_DEFS="-Wl,-zmuldefs" -LD_STATIC="-Wl,-Bstatic" -LD_DYNAMIC="-Wl,-Bdynamic" -LD_ALL_SYMBOLS="-Wl,-whole-archive" -LD_REF_SYMBOLS="-Wl,-no-whole-archive" - -# build command -DLIB_CMD="$LD -shared" -EXE_CMD="$LD" - -# versioned output -if [ "$VERS" = "" ] -then - DLIB_CMD="$DLIB_CMD -o $TARG" - EXE_CMD="$EXE_CMD -o $TARG" -else - set-vers $(echo $VERS | tr '.' ' ') - DLIB_CMD="$DLIB_CMD -o $OUTDIR/$NAME$DBGAP.so.$VERS -Wl,-soname,$NAME.so.$MAJ" - EXE_CMD="$EXE_CMD -o $OUTDIR/$NAME$DBGAP.$VERS" -fi diff --git a/biology/sra-tools/files/ld.bsd.cmn.sh b/biology/sra-tools/files/ld.bsd.cmn.sh deleted file mode 100755 index a0a65f39884b..000000000000 --- a/biology/sra-tools/files/ld.bsd.cmn.sh +++ /dev/null @@ -1,158 +0,0 @@ -#!/usr/local/bin/bash -# =========================================================================== -# -# PUBLIC DOMAIN NOTICE -# National Center for Biotechnology Information -# -# This software/database is a "United States Government Work" under the -# terms of the United States Copyright Act. It was written as part of -# the author's official duties as a United States Government employee and -# thus cannot be copyrighted. This software/database is freely available -# to the public for use. The National Library of Medicine and the U.S. -# Government have not placed any restriction on its use or reproduction. -# -# Although all reasonable efforts have been taken to ensure the accuracy -# and reliability of the software and data, the NLM and the U.S. -# Government do not and cannot warrant the performance or results that -# may be obtained by using this software or data. The NLM and the U.S. -# Government disclaim all warranties, express or implied, including -# warranties of performance, merchantability or fitness for any particular -# purpose. -# -# Please cite the author in any work or product based on this material. -# -# =========================================================================== - -# script name -SELF_NAME="$(basename $0)" - -# parameters -LD="$1" -ARCH="$2" -BUILD="$3" -shift 3 - -SRCDIR="$1" -BINDIR="$2" -OUTDIR="$3" -TARG="$4" -NAME="$5" -DBGAP="$6" -shift 6 - -VERS="$1" -VERSFILE="$2" -DEPFILE="$3" -shift 3 - -MODE="$1" -SCMFLAGS="$2" -LDFLAGS="$3" -shift 3 - -LDIRS="$1" -XDIRS="$2" -shift 2 - -OBJS="$1" -LIBS="$2" - -# decode MODE -STATIC=$(expr $MODE % 2) -MODE=$(expr $MODE / 2) -DYLD=$(expr $MODE % 2) -MODE=$(expr $MODE / 2) -KPROC=$(expr $MODE % 2) -MODE=$(expr $MODE / 2) -THREADS=$(expr $MODE % 2) -MODE=$(expr $MODE / 2) -HAVE_M=$(expr $MODE % 2) -MODE=$(expr $MODE / 2) -HAVE_XML=$(expr $MODE % 2) - -# decode SCMFLAGS -CHECKSUM=$(expr $SCMFLAGS % 2) -STATICSYSLIBS=$(expr $SCMFLAGS / 2) - -# return parameter for find-lib -LIBPATH='' - -# initial command state -CMD='' -LD_STATIC_STATE=0 -LD_ALL_STATE=0 - -# for breaking out version -set-vers () -{ - MAJ=$1 - MIN=$2 - REL=$3 -} - -# for locating libraries -find-lib () -{ - _lib="lib$1" - _dirs="$2" - - LIBPATH='' - - while [ "$_dirs" != "" ] - do - _dir="${_dirs%%:*}" - - if [ "$_dir" != "" ] - then - if [ -e "$_dir/$_lib" ] - then - while [ -L "$_dir/$_lib" ] - do - _lib=$(readlink -n "$_dir/$_lib") - done - LIBPATH="$_dir/$_lib" - break; - fi - fi - - _dirs="${_dirs#$_dir}" - _dirs="${_dirs#:}" - done -} - -# setting state -load-static () -{ - if [ $LD_STATIC_STATE -eq 0 ] - then - CMD="$CMD $LD_STATIC" - LD_STATIC_STATE=1 - fi -} - -load-dynamic () -{ - if [ $LD_STATIC_STATE -eq 1 ] - then - CMD="$CMD $LD_DYNAMIC" - LD_STATIC_STATE=0 - fi -} - -load-all-symbols () -{ - if [ $LD_ALL_STATE -eq 0 ] - then - CMD="$CMD $LD_ALL_SYMBOLS" - LD_ALL_STATE=1 - fi -} - -load-ref-symbols () -{ - if [ $LD_ALL_STATE -eq 1 ] - then - CMD="$CMD $LD_REF_SYMBOLS" - LD_ALL_STATE=0 - fi -} diff --git a/biology/sra-tools/files/ld.bsd.dlib.sh b/biology/sra-tools/files/ld.bsd.dlib.sh deleted file mode 100755 index a74f2b006818..000000000000 --- a/biology/sra-tools/files/ld.bsd.dlib.sh +++ /dev/null @@ -1,308 +0,0 @@ -#!/usr/local/bin/bash -# =========================================================================== -# -# PUBLIC DOMAIN NOTICE -# National Center for Biotechnology Information -# -# This software/database is a "United States Government Work" under the -# terms of the United States Copyright Act. It was written as part of -# the author's official duties as a United States Government employee and -# thus cannot be copyrighted. This software/database is freely available -# to the public for use. The National Library of Medicine and the U.S. -# Government have not placed any restriction on its use or reproduction. -# -# Although all reasonable efforts have been taken to ensure the accuracy -# and reliability of the software and data, the NLM and the U.S. -# Government do not and cannot warrant the performance or results that -# may be obtained by using this software or data. The NLM and the U.S. -# Government disclaim all warranties, express or implied, including -# warranties of performance, merchantability or fitness for any particular -# purpose. -# -# Please cite the author in any work or product based on this material. -# -# =========================================================================== - - -# =========================================================================== -# input library types, and their handling -# -# normal linkage -# -l : find shared or static -# -s : require static -# -d : require shared -# -# static linkage -# -l : require static -# -s : require static -# -d : ignore -# =========================================================================== - - -# script name -SELF_NAME="$(basename $0)" -BUILD_DIR="$(dirname $0)" - -# parameters and common functions -source "${0%dlib.sh}cmn.sh" - -# discover tool chain -case "$LD" in -g*) - source "${0%dlib.sh}gcc.sh" - ;; -c*) - source "${0%dlib.sh}clang.sh" - ;; - *) - echo "$SELF_NAME: unrecognized ld tool - '$LD'" - exit 5 -esac - -# DLIB_CMD was started in tool-specific source -CMD="$DLIB_CMD $LDFLAGS" - -# tack on object files -CMD="$CMD $OBJS" - -# list of static libraries used to create dynamic lib -SLIBS='' - -# initial dependency upon Makefile and vers file -DEPS="$SRCDIR/Makefile" -if [ "$LIBS" != "" ] -then - # tack on paths - DIRS="$LDIRS:$XDIRS" - while [ "$DIRS" != "" ] - do - DIR="${DIRS%%:*}" - [ "$DIR" != "" ] && CMD="$CMD -L$DIR" - DIRS="${DIRS#$DIR}" - DIRS="${DIRS#:}" - done - - # update LD_LIBRARY_PATH - unset LD_LIBRARY_PATH - export LD_LIBRARY_PATH="$LDIRS:$XDIRS" - - # tack on libraries, finding as we go - for LIB in $LIBS - do - - # strip off switch - LIBNAME="${LIB#-[lsd]}" - - # look at linkage - case "$LIB" in - -ldl|-ddl) - - # always load libdl as shared library - load-ref-symbols - load-dynamic -# CMD="$CMD -ldl" - ;; - - -l*) - - # normal or dynamic linkage - FOUND=0 - if [ $STATIC -eq 0 ] - then - find-lib $LIBNAME.so $LDIRS - if [ "$LIBPATH" != "" ] - then - - # found it - FOUND=1 - - # load normally - load-ref-symbols - load-dynamic - CMD="$CMD -l$LIBNAME" - - fi - fi - - # try static only - if [ $FOUND -eq 0 ] - then - find-lib $LIBNAME.a $LDIRS - if [ "$LIBPATH" != "" ] - then - - # found it - FOUND=1 - - # add it to dependencies - DEPS="$DEPS $LIBPATH" - SLIBS="$SLIBS $(dirname $LIBPATH)/lib$LIBNAME.a" - - # load static - load-static - load-all-symbols - CMD="$CMD -l$LIBNAME" - - fi - fi - - # not found within our directories - if [ $FOUND -eq 0 ] - then - - if [ $STATICSYSLIBS -eq 1 ] - then - case "$LIBNAME" in - z|bz2) - # set load to static - load-static - load-all-symbols - ;; - - *) - # set load to dynamic - load-ref-symbols - load-dynamic - ;; - - esac - else - # set load to normal - load-ref-symbols - load-dynamic - fi - - CMD="$CMD -l$LIBNAME" - fi - ;; - - -s*) - - # force static load - FOUND=0 - find-lib $LIBNAME.a $LDIRS - if [ "$LIBPATH" != "" ] - then - - # found it - FOUND=1 - - # add it to dependencies - DEPS="$DEPS $LIBPATH" - SLIBS="$SLIBS $(dirname $LIBPATH)/lib$LIBNAME.a" - - # load static - load-static - load-all-symbols - CMD="$CMD -l$LIBNAME" - - fi - - # not found within our directories - if [ $FOUND -eq 0 ] - then - - if [ $STATIC -eq 1 ] || [ $STATICSYSLIBS -eq 1 ] - then - # set load to static - load-static - load-all-symbols - else - - case "$LIBNAME" in - z|bz2) - # set load to dynamic - load-ref-symbols - load-dynamic - ;; - - *) - # set load to static - load-static - load-all-symbols - ;; - esac - fi - - CMD="$CMD -l$LIBNAME" - fi - ;; - - -d*) - - # only dynamic linkage - FOUND=0 - if [ $STATIC -eq 0 ] - then - find-lib $LIBNAME.so $LDIRS - if [ "$LIBPATH" != "" ] - then - - # found it - FOUND=1 - - # load normally - load-ref-symbols - load-dynamic - CMD="$CMD -l$LIBNAME" - - fi - fi - - # not found within our directories - if [ $FOUND -eq 0 ] - then - # set load to normal - load-ref-symbols - load-dynamic - CMD="$CMD -l$LIBNAME" - fi - ;; - - esac - - done -fi - -# put state back to normal -load-ref-symbols -load-dynamic - -# add in pthreads -if [ $THREADS -ne 0 ] -then - CMD="$CMD -lpthread" -fi - -# add in xml -if [ $HAVE_XML -ne 0 ] -then - CMD="$CMD -lxml2" -fi - -# add in math library -if [ $HAVE_M -ne 0 ] -then - CMD="$CMD -lm" -fi - -# produce shared library -echo "$CMD" -$CMD || exit $? - -# produce dependencies -if [ "$DEPFILE" != "" ] -then - echo "$TARG: $DEPS" > "$DEPFILE" -fi - -if [ $CHECKSUM -eq 1 ] -then - SCM_DIR="${BUILD_DIR%/*}/scm" - LOGFILE="$SCM_DIR/scm.log" - MSG=">>>>> scm: calling the collect script from ld.linux.dlib.sh <<<<<<" - #echo "$MSG" - echo "$MSG" >> $LOGFILE - - "$BUILD_DIR/scm-collect.sh" "$OBJS" "$SLIBS" | sort -u > "$TARG.md5" -fi diff --git a/biology/sra-tools/files/ld.bsd.exe.sh b/biology/sra-tools/files/ld.bsd.exe.sh deleted file mode 100755 index 650a212780c3..000000000000 --- a/biology/sra-tools/files/ld.bsd.exe.sh +++ /dev/null @@ -1,326 +0,0 @@ -#!/usr/local/bin/bash -# =========================================================================== -# -# PUBLIC DOMAIN NOTICE -# National Center for Biotechnology Information -# -# This software/database is a "United States Government Work" under the -# terms of the United States Copyright Act. It was written as part of -# the author's official duties as a United States Government employee and -# thus cannot be copyrighted. This software/database is freely available -# to the public for use. The National Library of Medicine and the U.S. -# Government have not placed any restriction on its use or reproduction. -# -# Although all reasonable efforts have been taken to ensure the accuracy -# and reliability of the software and data, the NLM and the U.S. -# Government do not and cannot warrant the performance or results that -# may be obtained by using this software or data. The NLM and the U.S. -# Government disclaim all warranties, express or implied, including -# warranties of performance, merchantability or fitness for any particular -# purpose. -# -# Please cite the author in any work or product based on this material. -# -# =========================================================================== - - -# =========================================================================== -# input library types, and their handling -# -# normal linkage -# -l : find shared or static -# -s : require static -# -d : ignore - will be dynamically loaded -# -# static linkage -# -l : require static -# -s : require static -# -d : require static -# =========================================================================== - - -# script name -SELF_NAME="$(basename $0)" -BUILD_DIR="$(dirname $0)" - -# parameters and common functions -source "${0%exe.sh}cmn.sh" - -# discover tool chain *** 2731 LINES SKIPPED ***