git: 2c0b2c08a023 - main - biology/sra-tools: Update to 3.1.1

From: Jason W. Bacon <jwb_at_FreeBSD.org>
Date: Sun, 17 Nov 2024 23:43:59 UTC
The branch main has been updated by jwb:

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

commit 2c0b2c08a0233e1ad880540f7bbb38edafcaffe8
Author:     Jason W. Bacon <jwb@FreeBSD.org>
AuthorDate: 2024-11-17 23:41:17 +0000
Commit:     Jason W. Bacon <jwb@FreeBSD.org>
CommitDate: 2024-11-17 23:41:17 +0000

    biology/sra-tools: Update to 3.1.1
    
    Numerous fixes and enhancements since 3.0.6
    Changes: https://github.com/ncbi/sra-tools/commits/master/
    
    All previous patches upstreamed
    Rewrote pkg-descr to be more introductory
---
 biology/sra-tools/Makefile                         | 34 ++++-----
 biology/sra-tools/distinfo                         | 10 +--
 biology/sra-tools/files/byteswap.h                 | 15 ----
 biology/sra-tools/files/endian.h                   |  2 -
 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-libs_ascp_CMakeLists.txt | 27 --------
 .../patch-libs_general-writer_general-writer.cpp   | 10 ---
 .../sra-tools/files/patch-ncbi-vdb_build_env.cmake | 47 -------------
 .../patch-ncbi-vdb_libs_align_samextract-lib.cpp   | 11 ---
 .../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         | 31 ---------
 .../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  | 16 -----
 .../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   | 10 ---
 .../files/patch-ncbi-vdb_libs_kproc_CMakeLists.txt | 21 ------
 .../files/patch-ncbi-vdb_libs_ktst_CMakeLists.txt  | 18 -----
 .../files/patch-ncbi-vdb_libs_vfs_CMakeLists.txt   | 25 -------
 .../files/patch-ncbi-vdb_test_kapp_run-sig-core.sh | 49 -------------
 .../files/patch-ncbi-vdb_test_kfg_kfgtest.cpp      | 11 ---
 .../files/patch-ncbi-vdb_test_klib_printf-test.c   | 11 ---
 ...h-ncbi-vdb_test_vdb_test-dependencies__dflt.cpp | 12 ----
 ...-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 ------
 ...tch-tools_loaders_fastq-loader_spot-assembler.c | 17 -----
 biology/sra-tools/pkg-descr                        | 20 ++----
 biology/sra-tools/pkg-plist                        | 80 +++++++++++-----------
 36 files changed, 70 insertions(+), 760 deletions(-)

diff --git a/biology/sra-tools/Makefile b/biology/sra-tools/Makefile
index 5ee287444dc0..c774f64a5159 100644
--- a/biology/sra-tools/Makefile
+++ b/biology/sra-tools/Makefile
@@ -1,6 +1,5 @@
 PORTNAME=	sra-tools
-DISTVERSION=	3.0.6
-PORTREVISION=	1
+DISTVERSION=	3.1.1
 CATEGORIES=	biology java
 
 MAINTAINER=	jwb@FreeBSD.org
@@ -12,15 +11,12 @@ LICENSE_COMB=		multi
 LICENSE_FILE_PD=	${WRKSRC}/LICENSE
 LICENSE_DISTFILES_LGPL21+ =
 
-# Untested on other platforms, aarch64 support was recently added upstream
 ONLY_FOR_ARCHS=		aarch64 amd64
 ONLY_FOR_ARCHS_REASON=	Upstream explicitly supports specific platforms
 
+# hdf5 is dynamically loaded by some tools, but nothing links to it
 BUILD_DEPENDS=	bash:shells/bash
-LIB_DEPENDS=	libxml2.so:textproc/libxml2 \
-		libhdf5.so:science/hdf5 \
-		libepoll-shim.so:devel/libepoll-shim \
-		libzstd.so:archivers/zstd
+RUN_DEPENDS=	hdf5>0:science/hdf5
 
 USES=		bison cmake shebangfix
 USE_GITHUB=	yes
@@ -34,32 +30,38 @@ OPTIONS_DEFINE=	EXAMPLES
 
 SHEBANG_GLOB=	*.sh
 GH_ACCOUNT=	ncbi
+# FIXME: At the time this was added, sra-tools build required access to the
+# ncbi-vdb source tree.  Use a separate dependent port if that is no
+# longer the case.  CMakeLists.txt still looks for ../ncbi-vdb in 3.1.1.
 GH_TUPLE+=	ncbi:ncbi-vdb:${DISTVERSION}:vdb/ncbi-vdb
 
 CMAKE_ARGS+=	-DVDB_LIBDIR:STRING=${WRKSRC}/ncbi-vdb/build/lib
 
-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:
-	# 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' \
+	# Reinplaces may follow static patches.  Run "make clean patch"
+	# before updating those patches so reinplaces do not get added to them.
+	@${REINPLACE_CMD} -e 's|"/etc/ncbi"|"${PREFIX}/etc/ncbi"|g' \
 		${WRKSRC}/ncbi-vdb/libs/kfg/config.c
-	${REINPLACE_CMD} -e 's|/usr/local/bin|${PREFIX}/bin|g' \
+	@${REINPLACE_CMD} -e 's|/usr/local/bin|${PREFIX}/bin|g' \
 		${WRKSRC}/tools/external/driver-tool/file-path.posix.cpp
+	@${REINPLACE_CMD} -e 's|/../ncbi-vdb|/ncbi-vdb|g' \
+		${WRKSRC}/CMakeLists.txt
 	cd ${WRKSRC}/ncbi-vdb/build && cmake .. && make
 
+# FIXME: Unsure where the jquery version comes from and it differs on
+# amd64 (jquery-3.7.1.min.js) and aarch64 (jquery-3.6.1.min.js).
+# Just hack the version out for now.  Not sure we even need javadoc installed.
 post-stage:
 	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/*.${DISTVERSION}
+	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib64/*.${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
+	${MV} ${STAGEDIR}${JAVASHAREDIR}doc/ngs-doc/script-dir/jquery-[0-9]*.min.js \
+		${STAGEDIR}${JAVASHAREDIR}doc/ngs-doc/script-dir/jquery.min.js
 
 post-stage-EXAMPLES-off:
 	${RM} -r ${STAGEDIR}${EXAMPLESDIR}
diff --git a/biology/sra-tools/distinfo b/biology/sra-tools/distinfo
index db2f69729c91..b69d1654ef45 100644
--- a/biology/sra-tools/distinfo
+++ b/biology/sra-tools/distinfo
@@ -1,5 +1,5 @@
-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
+TIMESTAMP = 1731806177
+SHA256 (ncbi-sra-tools-3.1.1_GH0.tar.gz) = 96b110bd5a30ad312e2f02552062b48a77d40c763e6aba5bb84e83662a505cf1
+SIZE (ncbi-sra-tools-3.1.1_GH0.tar.gz) = 45754110
+SHA256 (ncbi-ncbi-vdb-3.1.1_GH0.tar.gz) = e9766f259853c696be48e289b08cb5ae6e198d82d7ffee79f09ce7f720487991
+SIZE (ncbi-ncbi-vdb-3.1.1_GH0.tar.gz) = 19055901
diff --git a/biology/sra-tools/files/byteswap.h b/biology/sra-tools/files/byteswap.h
deleted file mode 100644
index 807bea1289b8..000000000000
--- a/biology/sra-tools/files/byteswap.h
+++ /dev/null
@@ -1,15 +0,0 @@
-
-#ifndef _freebsd_byteswap_h_
-#define _freebsd_byteswap_h_
-
-#include <sys/endian.h>
-
-#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
diff --git a/biology/sra-tools/files/endian.h b/biology/sra-tools/files/endian.h
deleted file mode 100644
index c4b8fc49f735..000000000000
--- a/biology/sra-tools/files/endian.h
+++ /dev/null
@@ -1,2 +0,0 @@
-
-#include <sys/endian.h>
diff --git a/biology/sra-tools/files/os-native.h b/biology/sra-tools/files/os-native.h
deleted file mode 100644
index 7dc63e85c167..000000000000
--- a/biology/sra-tools/files/os-native.h
+++ /dev/null
@@ -1,43 +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.
-*
-* ===========================================================================
-*
-*/
-
-#ifndef _h_os_native_
-#define _h_os_native_
-
-#ifndef _h_unix_native_
-#include "../unix/unix-native.h"
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _h_os_native_ */
diff --git a/biology/sra-tools/files/patch-CMakeLists.txt b/biology/sra-tools/files/patch-CMakeLists.txt
deleted file mode 100644
index 7c864a522b85..000000000000
--- a/biology/sra-tools/files/patch-CMakeLists.txt
+++ /dev/null
@@ -1,13 +0,0 @@
---- CMakeLists.txt.orig	2023-02-01 20:26:19 UTC
-+++ CMakeLists.txt
-@@ -54,8 +54,8 @@ set(CMAKE_MODULE_PATH
-     "${CMAKE_CURRENT_SOURCE_DIR}/build"
- )
- 
--set( VDB_BINDIR "${CMAKE_BINARY_DIR}/../ncbi-vdb" CACHE PATH "Location of NCBI VDB build directory" )
--set( VDB_INCDIR "${CMAKE_SOURCE_DIR}/../ncbi-vdb/interfaces" CACHE PATH "Location of NCBI VDB include directory" )
-+set( VDB_BINDIR "${CMAKE_BINARY_DIR}/ncbi-vdb" CACHE PATH "Location of NCBI VDB build directory" )
-+set( VDB_INCDIR "${CMAKE_SOURCE_DIR}/ncbi-vdb/interfaces" CACHE PATH "Location of NCBI VDB include directory" )
- 
- include(CTest)
- enable_testing()
diff --git a/biology/sra-tools/files/patch-build_env.cmake b/biology/sra-tools/files/patch-build_env.cmake
deleted file mode 100644
index be1423fb24c2..000000000000
--- a/biology/sra-tools/files/patch-build_env.cmake
+++ /dev/null
@@ -1,56 +0,0 @@
---- build/env.cmake.orig	2023-07-10 16:23:35 UTC
-+++ build/env.cmake
-@@ -69,11 +69,21 @@ if ( ${CMAKE_HOST_SYSTEM_NAME} STREQUAL  "Darwin" )
-     set(LIBPFX "lib")
-     set(SHLX "dylib")
-     set(STLX "a")
-+elseif ( ${CMAKE_HOST_SYSTEM_NAME} STREQUAL  "FreeBSD" )
-+    set(OS "bsd")
-+    set(LIBPFX "lib")
-+    set(SHLX "so")
-+    set(STLX "a")
- elseif ( ${CMAKE_HOST_SYSTEM_NAME} STREQUAL  "Linux" )
-     set(OS "linux")
-     set(LIBPFX "lib")
-     set(SHLX "so")
-     set(STLX "a")
-+elseif ( ${CMAKE_HOST_SYSTEM_NAME} STREQUAL  "NetBSD" )
-+    set(OS "bsd")
-+    set(LIBPFX "lib")
-+    set(SHLX "so")
-+    set(STLX "a")
- elseif ( ${CMAKE_HOST_SYSTEM_NAME} STREQUAL  "Windows" )
-     set(OS "windows")
-     set(LIBPFX "")
-@@ -91,6 +101,8 @@ elseif ( ${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "aarc
-     set(ARCH "arm64")
- elseif ( ${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "x86_64")
-     set(ARCH "x86_64")
-+elseif ( ${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "amd64")
-+    set(ARCH "x86_64")
- elseif ( ${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "AMD64")
-     set(ARCH "x86_64")
- else()
-@@ -98,7 +110,11 @@ else()
- endif ()
- 
- # create variables based entirely upon OS
--if ( "mac" STREQUAL ${OS} )
-+if ( "bsd" STREQUAL ${OS} )
-+    add_compile_definitions( BSD UNIX )
-+    set( LMCHECK "" )
-+    set( EXE "" )
-+elseif ( "mac" STREQUAL ${OS} )
-     add_compile_definitions( MAC BSD UNIX )
-     set( LMCHECK "" )
-     set( EXE "" )
-@@ -380,6 +396,9 @@ endif()
- 
- if ( "mac" STREQUAL ${OS} )
-     include_directories(${VDB_INTERFACES_DIR}/os/mac)
-+    include_directories(${VDB_INTERFACES_DIR}/os/unix)
-+elseif( "bsd" STREQUAL ${OS} )
-+    include_directories(${VDB_INTERFACES_DIR}/os/bsd)
-     include_directories(${VDB_INTERFACES_DIR}/os/unix)
- elseif( "linux" STREQUAL ${OS} )
-     include_directories(${VDB_INTERFACES_DIR}/os/linux)
diff --git a/biology/sra-tools/files/patch-libs_ascp_CMakeLists.txt b/biology/sra-tools/files/patch-libs_ascp_CMakeLists.txt
deleted file mode 100644
index 25801b4ed932..000000000000
--- a/biology/sra-tools/files/patch-libs_ascp_CMakeLists.txt
+++ /dev/null
@@ -1,27 +0,0 @@
---- libs/ascp/CMakeLists.txt.orig	2023-07-10 16:23:35 UTC
-+++ libs/ascp/CMakeLists.txt
-@@ -23,12 +23,17 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/connect.c )
-+# FIXME: Add BSD-specific ascp-path.c
-+# Aspera can be installed and run with linux compat
-+set ( BSD_SRC ${UNIX_SRC} linux/ascp-path.c )
- set ( LINUX_SRC ${UNIX_SRC} linux/ascp-path.c )
- set ( MAC_SRC ${UNIX_SRC} mac/ascp-path.c )
- set ( WIN_SRC win/connect.c win/ascp-path.c )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
-@@ -49,4 +54,4 @@ GenerateStaticLibs(ascp
- )
- 
- add_compile_definitions( __mod__="libs/ascp" )
--include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
-\ No newline at end of file
-+include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
diff --git a/biology/sra-tools/files/patch-libs_general-writer_general-writer.cpp b/biology/sra-tools/files/patch-libs_general-writer_general-writer.cpp
deleted file mode 100644
index b16584ab8dbf..000000000000
--- a/biology/sra-tools/files/patch-libs_general-writer_general-writer.cpp
+++ /dev/null
@@ -1,10 +0,0 @@
---- libs/general-writer/general-writer.cpp.orig	2023-05-11 11:57:33 UTC
-+++ libs/general-writer/general-writer.cpp
-@@ -39,6 +39,7 @@
- #include <string.h>
- 
- #define PROGRESS_EVENT 0
-+#define	UNUSED(x)	((void)(x))
- 
- namespace ncbi
- {
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_build_env.cmake b/biology/sra-tools/files/patch-ncbi-vdb_build_env.cmake
deleted file mode 100644
index ead9978585e2..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_build_env.cmake
+++ /dev/null
@@ -1,47 +0,0 @@
---- ncbi-vdb/build/env.cmake.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/build/env.cmake
-@@ -75,9 +75,15 @@ set(CMAKE_CXX_EXTENSIONS OFF)
- if ( ${CMAKE_SYSTEM_NAME} STREQUAL  "Darwin" )
-     set(OS "mac")
-     set(SHLX "dylib")
-+elseif ( ${CMAKE_SYSTEM_NAME} STREQUAL  "FreeBSD" )
-+    set(OS "bsd")
-+    set(SHLX "so")
- elseif ( ${CMAKE_SYSTEM_NAME} STREQUAL  "Linux" )
-     set(OS "linux")
-     set(SHLX "so")
-+elseif ( ${CMAKE_SYSTEM_NAME} STREQUAL  "NetBSD" )
-+    set(OS "bsd")
-+    set(SHLX "so")
- elseif ( ${CMAKE_SYSTEM_NAME} STREQUAL  "Windows" )
-     set(OS "windows")
- else()
-@@ -99,6 +105,8 @@ elseif ( ${_system_processor} STREQUAL "x86_64")
-     set(ARCH "x86_64")
- elseif ( ${_system_processor} STREQUAL "AMD64")
-     set(ARCH "x86_64")
-+elseif ( ${_system_processor} STREQUAL "amd64")
-+    set(ARCH "x86_64")
- else ()
-     message ( FATAL_ERROR "unknown architecture " ${_system_processor})
- endif ()
-@@ -110,6 +118,9 @@ if ( "mac" STREQUAL ${OS} )
-     set(CMAKE_CXX_ARCHIVE_CREATE "<CMAKE_AR> Scr <TARGET> <LINK_FLAGS> <OBJECTS>")
-     set(CMAKE_C_ARCHIVE_FINISH   "<CMAKE_RANLIB> -no_warning_for_no_symbols -c <TARGET>")
-     set(CMAKE_CXX_ARCHIVE_FINISH "<CMAKE_RANLIB> -no_warning_for_no_symbols -c <TARGET>")
-+elseif( "bsd" STREQUAL ${OS} )
-+    add_compile_definitions( BSD UNIX )
-+    set( LMCHECK "" )
- elseif( "linux" STREQUAL ${OS} )
-     add_compile_definitions( LINUX UNIX )
-     set( LMCHECK -lmcheck )
-@@ -241,6 +252,9 @@ endif()
- 
- if ( "mac" STREQUAL ${OS} )
-     include_directories(interfaces/os/mac)
-+    include_directories(interfaces/os/unix)
-+elseif( "bsd" STREQUAL ${OS} )
-+    include_directories(interfaces/os/bsd)
-     include_directories(interfaces/os/unix)
- elseif( "linux" STREQUAL ${OS} )
-     include_directories(interfaces/os/linux)
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_align_samextract-lib.cpp b/biology/sra-tools/files/patch-ncbi-vdb_libs_align_samextract-lib.cpp
deleted file mode 100644
index 69973928e80f..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_align_samextract-lib.cpp
+++ /dev/null
@@ -1,11 +0,0 @@
---- ncbi-vdb/libs/align/samextract-lib.cpp.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/align/samextract-lib.cpp
-@@ -48,7 +48,7 @@
- #include <stdlib.h>
- #include <string.h>
- 
--#if LINUX
-+#if BSD || LINUX
- #include <unistd.h>
- #define DFL_THREAD_COUNT ((int)sysconf( _SC_NPROCESSORS_ONLN ) - 1)
- #else
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_CMakeLists.txt
deleted file mode 100644
index 4815ee9bdcbd..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_CMakeLists.txt
+++ /dev/null
@@ -1,19 +0,0 @@
---- ncbi-vdb/libs/kapp/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kapp/CMakeLists.txt
-@@ -23,12 +23,16 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/args-conv-os.c unix/sysmain.c )
-+# Must patch hw.memsize -> hw.usermem
-+set ( BSD_SRC ${UNIX_SRC} mac/ram.c )
- set ( LINUX_SRC ${UNIX_SRC} linux/ram.c )
- set ( MAC_SRC ${UNIX_SRC} mac/ram.c )
- set ( WIN_SRC win/args-conv-os.c win/ram.c win/sysmain.c )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_mac_ram.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_mac_ram.c
deleted file mode 100644
index 67d836a71d38..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kapp_mac_ram.c
+++ /dev/null
@@ -1,17 +0,0 @@
---- ncbi-vdb/libs/kapp/mac/ram.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kapp/mac/ram.c
-@@ -46,7 +46,14 @@ rc_t KAppGetTotalRam ( uint64_t * totalRam )
- 
-     assert ( totalRam != 0 );
- 
-+// FIXME: This file should probably be moved to bsd/ram.c
-+#if defined(__APPLE__)
-     ret = sysctlbyname("hw.memsize", totalRam, &len, NULL, 0 );
-+#elif defined(__FreeBSD__) || defined(__NetBSD__)
-+    ret = sysctlbyname("hw.usermem", totalRam, &len, NULL, 0 );
-+#else
-+    #error "You need to add a sysctl for this platform."
-+#endif
-     if ( ret < 0 )
-     {
- 		int status = errno;
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfc_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_kfc_CMakeLists.txt
deleted file mode 100644
index 05d204e31147..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfc_CMakeLists.txt
+++ /dev/null
@@ -1,25 +0,0 @@
---- ncbi-vdb/libs/kfc/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kfc/CMakeLists.txt
-@@ -23,12 +23,15 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/sysctx.c unix/sysrsrc.c )
-+set ( BSD_SRC ${UNIX_SRC} )
- set ( LINUX_SRC ${UNIX_SRC} )
- set ( MAC_SRC ${UNIX_SRC} )
- set ( WIN_SRC win/sysctx.c win/sysrsrc.c )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
-@@ -48,4 +51,4 @@ set( SRC
- GenerateStaticLibs( kfc "${SRC}" )
- 
- add_compile_definitions (__mod__="libs/kfc")
--include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
-\ No newline at end of file
-+include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfg_config.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_kfg_config.c
deleted file mode 100644
index 8d9268922948..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfg_config.c
+++ /dev/null
@@ -1,31 +0,0 @@
---- ncbi-vdb/libs/kfg/config.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kfg/config.c
-@@ -2574,7 +2574,7 @@ bool load_from_std_location ( KConfig *self, const KDi
-     const char * std_locs [] =
-     {
- #if ! WINDOWS
--        "/etc/ncbi",
-+        "/usr/local/etc/ncbi",
- #else
-         "/c/ncbi",
- #endif
-@@ -2588,7 +2588,7 @@ bool load_from_std_location ( KConfig *self, const KDi
-         NCBI_VDB_NO_ETC_NCBI_KFG[0] != '\0')
-     {
-         DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG),
--            ("KFG: load from std. location /etc/ncbi is disabled. "
-+            ("KFG: load from std. location /usr/local/etc/ncbi is disabled. "
-                 "NCBI_VDB_NO_ETC_NCBI_KFG='%s'\n", NCBI_VDB_NO_ETC_NCBI_KFG));
-         return loaded;
-     }
-@@ -2839,7 +2839,9 @@ void add_predefined_nodes ( KConfig * self, const char
-     update_node ( self, "kfg/arch/bits", buf, true );
- 
-     /* *OS */
--#if LINUX
-+#if BSD
-+    #define OS "bsd"
-+#elif LINUX
-     #define OS "linux"
- #elif MAC
-     #define OS "mac"
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_CMakeLists.txt
deleted file mode 100644
index c6b4801f527d..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_CMakeLists.txt
+++ /dev/null
@@ -1,35 +0,0 @@
---- ncbi-vdb/libs/kfs/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kfs/CMakeLists.txt
-@@ -23,6 +23,7 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/sysdir.c unix/sysdll.c unix/sysfile.c unix/syslockfile.c unix/sysmmap.c )
-+set ( BSD_SRC ${UNIX_SRC} )
- set ( LINUX_SRC ${UNIX_SRC} )
- set ( MAC_SRC ${UNIX_SRC} )
- set ( WIN_SRC win/directory-path.c win/sysdir.c win/sysdll.c win/sysfile.c win/syslockfile.c win/sysmmap.c
-@@ -30,6 +31,7 @@ set ( WIN_SRC win/directory-path.c win/sysdir.c win/sy
- )
- 
- set ( UNIX_SRC_V2 unix/sysfile-v2.c )
-+set ( BSD_SRC_V2 ${UNIX_SRC_V2} )
- set ( LINUX_SRC_V2 ${UNIX_SRC_V2} )
- set ( MAC_SRC_V2 ${UNIX_SRC_V2} )
- set ( WIN_SRC_V2 win/sysfile-v2.c )
-@@ -37,6 +39,9 @@ set ( WIN_SRC_V2 win/sysfile-v2.c )
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-     include_directories( win )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
-+    include_directories( unix )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
-     include_directories( unix )
-@@ -106,4 +111,4 @@ GenerateStaticLibsWithDefs( kfs-nommap ${KFS_NOMMAP_SR
- GenerateStaticLibs( kfs "${KFS_SRC}" )
- 
- add_compile_definitions (__mod__="libs/kfs")
--include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
-\ No newline at end of file
-+include_directories( BEFORE ${CMAKE_CURRENT_SOURCE_DIR} )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_unix_sysdir.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_unix_sysdir.c
deleted file mode 100644
index b128f98c29eb..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kfs_unix_sysdir.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ncbi-vdb/libs/kfs/unix/sysdir.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kfs/unix/sysdir.c
-@@ -2291,6 +2291,8 @@ rc_t KSysDirOpenDirRead_v1 ( const KSysDir_v1 * self,
-     rc_t rc;
- 
-     rc = KSysDirMakePath_v1 ( self, rcOpening, true, full, sizeof full, path, args );
-+    // FIXME: Remove this debug statement
-+    // fprintf(stderr, "path = %s  full = %s\n", path, full);
-     if ( rc == 0 )
-     {
-         int t;
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_CMakeLists.txt
deleted file mode 100644
index a854e97d5480..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
---- ncbi-vdb/libs/klib/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/klib/CMakeLists.txt
-@@ -24,12 +24,15 @@
- 
- set ( UNIX_BASE_SRC unix/misc.c unix/syslog.c unix/systime.c unix/syswriter.c )
- set ( UNIX_SRC ${UNIX_BASE_SRC} unix/syserrcode.c )
-+set ( BSD_SRC ${UNIX_SRC} )
- set ( LINUX_SRC ${UNIX_BASE_SRC} linux/syserrcode.c )
- set ( MAC_SRC ${UNIX_SRC} )
- set ( WIN_SRC win/misc.c win/sysalloc.c win/syserrcode.c win/syslog.c win/systime.c win/syswriter.c )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_hashfile.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_hashfile.c
deleted file mode 100644
index 205569c40a3e..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_hashfile.c
+++ /dev/null
@@ -1,20 +0,0 @@
---- ncbi-vdb/libs/klib/hashfile.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/klib/hashfile.c
-@@ -35,7 +35,7 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
--#if LINUX
-+#if BSD || LINUX
- #include <sys/mman.h>
- #endif
- 
-@@ -346,7 +346,7 @@ static void * map_calloc( KHashFile * self, size_t siz
-                 KLockUnlock( self->alloc_lock );
-                 return NULL;
-             }
--#if LINUX
-+#if BSD || LINUX
-             /* Not sure this helps */
-             madvise( (void *)self->alloc_base, req, MADV_RANDOM );
- #endif
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_unix_systime.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_unix_systime.c
deleted file mode 100644
index 193f584e41fe..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_klib_unix_systime.c
+++ /dev/null
@@ -1,16 +0,0 @@
---- ncbi-vdb/libs/klib/unix/systime.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/klib/unix/systime.c
-@@ -142,7 +142,13 @@ LIB_EXPORT KTime_t CC KTimeMakeTime ( const KTime *sel
-         t . tm_isdst = self -> dst;
- 
-         ts = mktime ( &t );
-+#ifdef __FreeBSD__
-+	// This might be portable to all platforms
-+	ts += localtime(&ts)->tm_gmtoff;
-+#else
-+	// extern global in sys/time.h on Linux and some other platforms
-         ts -= timezone;
-+#endif
-     }
- 
-     return ts;
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_CMakeLists.txt
deleted file mode 100644
index c85b1b6631ca..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_CMakeLists.txt
+++ /dev/null
@@ -1,20 +0,0 @@
---- ncbi-vdb/libs/kns/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kns/CMakeLists.txt
-@@ -23,6 +23,7 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/sysmgr.c unix/syssock.c unix/sysstream.c )
-+set ( BSD_SRC ${UNIX_SRC} mac/sysendpoint.c mac/syspoll.c )
- set ( LINUX_SRC ${UNIX_SRC} linux/sysendpoint.c linux/syspoll.c )
- set ( MAC_SRC ${UNIX_SRC} mac/sysendpoint.c mac/syspoll.c )
- set ( WIN_SRC win/sysendpoint.c win/sysmgr.c win/syssock.c win/sysstream.c )
-@@ -30,6 +31,9 @@ set ( WIN_SRC win/sysendpoint.c win/sysmgr.c win/sysso
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-     include_directories( win )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
-+    include_directories( unix )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
-     include_directories( unix )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_manager.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_manager.c
deleted file mode 100644
index 816454bea102..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_manager.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ncbi-vdb/libs/kns/manager.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kns/manager.c
-@@ -58,7 +58,7 @@
- #if HAVE_GNU_LIBC_VERSION_H
- #include <gnu/libc-version.h>
- #endif
--#if LINUX
-+#if BSD || LINUX
- #include <arpa/inet.h>
- #include <netinet/in.h>
- #endif
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_unix_syssock.c b/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_unix_syssock.c
deleted file mode 100644
index 313461f90846..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kns_unix_syssock.c
+++ /dev/null
@@ -1,10 +0,0 @@
---- ncbi-vdb/libs/kns/unix/syssock.c.orig	2023-08-07 20:34:54 UTC
-+++ ncbi-vdb/libs/kns/unix/syssock.c
-@@ -66,6 +66,7 @@
- #include <sys/types.h>
- #include <sys/socket.h>
- #include <sys/un.h>
-+#include <netinet/in.h>
- #include <netinet/tcp.h>
- #include <poll.h>
- #include <unistd.h>
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_kproc_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_kproc_CMakeLists.txt
deleted file mode 100644
index 2f4e808e2d65..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_kproc_CMakeLists.txt
+++ /dev/null
@@ -1,21 +0,0 @@
---- ncbi-vdb/libs/kproc/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/kproc/CMakeLists.txt
-@@ -23,6 +23,7 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/syscond.c unix/systhread.c unix/systimeout.c )
-+set ( BSD_SRC ${UNIX_SRC} bsd/syslock.c bsd/sysmgr.c)
- set ( LINUX_SRC ${UNIX_SRC} linux/sysbarrier.c linux/syslock.c linux/sysmgr.c )
- set ( MAC_SRC ${UNIX_SRC} bsd/syslock.c bsd/sysmgr.c)
- set ( WIN_SRC win/syscond.c win/syslock.c win/sysmgr.c win/systhread.c win/systimeout.c )
-@@ -30,6 +31,10 @@ set ( WIN_SRC win/syscond.c win/syslock.c win/sysmgr.c
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-     include_directories( win )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
-+    include_directories( bsd )
-+    include_directories( unix )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
-     include_directories( linux )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_ktst_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_ktst_CMakeLists.txt
deleted file mode 100644
index 78926849f124..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_ktst_CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
---- ncbi-vdb/libs/ktst/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/ktst/CMakeLists.txt
-@@ -23,12 +23,15 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/systestenv )
-+set ( BSD_SRC ${UNIX_SRC} )
- set ( LINUX_SRC ${UNIX_SRC} )
- set ( MAC_SRC ${UNIX_SRC} )
- set ( WIN_SRC win/systestenv )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_libs_vfs_CMakeLists.txt b/biology/sra-tools/files/patch-ncbi-vdb_libs_vfs_CMakeLists.txt
deleted file mode 100644
index 5d670acdbe4b..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_libs_vfs_CMakeLists.txt
+++ /dev/null
@@ -1,25 +0,0 @@
---- ncbi-vdb/libs/vfs/CMakeLists.txt.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/libs/vfs/CMakeLists.txt
-@@ -23,12 +23,15 @@
- # ===========================================================================
- 
- set ( UNIX_SRC unix/syskeyring.c unix/syspath.c )
-+set ( BSD_SRC ${UNIX_SRC} )
- set ( LINUX_SRC ${UNIX_SRC} )
- set ( MAC_SRC ${UNIX_SRC} )
- set ( WIN_SRC win/syskeyring.c win/syspath.c )
- 
- if ( "windows" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${WIN_SRC} )
-+elseif( "bsd" STREQUAL ${OS} )
-+    set ( OS_SPECIFIC_SRC ${BSD_SRC} )
- elseif( "linux" STREQUAL ${OS} )
-     set ( OS_SPECIFIC_SRC ${LINUX_SRC} )
- elseif( "mac" STREQUAL ${OS} )
-@@ -54,4 +57,4 @@ set( SRC
- GenerateStaticLibs( vfs "${SRC}" )
- 
- add_compile_definitions (__mod__="libs/vfs")
--include_directories(${CMAKE_CURRENT_SOURCE_DIR})
-\ No newline at end of file
-+include_directories(${CMAKE_CURRENT_SOURCE_DIR})
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_test_kapp_run-sig-core.sh b/biology/sra-tools/files/patch-ncbi-vdb_test_kapp_run-sig-core.sh
deleted file mode 100644
index ebc81bd3fc5b..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_test_kapp_run-sig-core.sh
+++ /dev/null
@@ -1,49 +0,0 @@
---- ncbi-vdb/test/kapp/run-sig-core.sh.orig	2017-10-27 07:23:08 UTC
-+++ ncbi-vdb/test/kapp/run-sig-core.sh
-@@ -29,12 +29,12 @@ BUILD_TYPE="$3"
- 
- SIGQUIT=3
- 
--function killFromBackground ()
-+killFromBackground ()
- {
-     PARENT_PID=$1
-     for I in 1 2 3 4 5
-     do
--        COMMAND="ps -ef|awk '\$3==${PARENT_PID} && \$8==\"${BINARY_PATH}\"  {print \$2}'"
-+        COMMAND="ps awwo pid,ppid,command|awk '\$2==${PARENT_PID} && \$3==\"${BINARY_PATH}\"  {print \$1}'"
-         eval PID=\`${COMMAND}\`
-         if [ "$PID" = "" ]; then
-             sleep 1
-@@ -44,7 +44,7 @@ function killFromBackground ()
-     done
- 
-     if [ "$PID" != "" ]; then
--        kill -s $SIGQUIT $PID
-+        kill -s QUIT $PID
-     fi
- 
-     echo $PID > killed.pid
-@@ -63,6 +63,13 @@ if [ "$HOST_OS" = "mac" ]; then
-    fi
- 
-    CORE_FOLDER="/core/"
-+elif [ "$HOST_OS" = "bsd" ]; then
-+   if [ "`ulimit -c`" = "0" ] || [ "`/sbin/sysctl -n kern.coredump`" != "1" ]; then
-+       echo "Core files are disabled. Skipping core file tests"
-+       exit 0
-+   fi
-+
-+   CORE_FOLDER="./"
- elif [ "$HOST_OS" = "linux" ]; then
-    if [ "`ulimit -c`" = "0" ]; then
-        echo "Core files are disabled. Skipping core file tests"
-@@ -92,7 +99,7 @@ wait
- BINARY_PID=`cat killed.pid`
- rm killed.pid
- 
--CORE_FILE="${CORE_FOLDER}core.${BINARY_PID}"
-+CORE_FILE="${CORE_FOLDER}${BINARY_PATH##*/}.core"
- 
- if [ "$BUILD_TYPE" = "dbg" ]; then
-    if [ -f $CORE_FILE ]; then
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_test_kfg_kfgtest.cpp b/biology/sra-tools/files/patch-ncbi-vdb_test_kfg_kfgtest.cpp
deleted file mode 100644
index ce1bb1b02508..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_test_kfg_kfgtest.cpp
+++ /dev/null
@@ -1,11 +0,0 @@
---- ncbi-vdb/test/kfg/kfgtest.cpp.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/test/kfg/kfgtest.cpp
-@@ -282,6 +282,8 @@ FIXTURE_TEST_CASE(predef_ARCHBITS, KfgFixture)
- FIXTURE_TEST_CASE(predef_OS, KfgFixture)
- {
-     CreateAndLoad(GetName(), "var=$(OS)\n");
-+    #if BSD
-+        #define OS "bsd"
-     #if LINUX
-         #define OS "linux"
-     #elif SUN
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_test_klib_printf-test.c b/biology/sra-tools/files/patch-ncbi-vdb_test_klib_printf-test.c
deleted file mode 100644
index 0ce58974e6ed..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_test_klib_printf-test.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ncbi-vdb/test/klib/printf-test.c.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/test/klib/printf-test.c
-@@ -504,7 +504,7 @@ rc_t run ( const char *progname )
-         if ( rc == 0 )
-         {
-             rc = make_initial_test ( field_width, precision, " ", "s", "Kurt is having a fit" );
--#if !defined(__SunOS)  &&  !defined(__sun__)
-+#if !defined(__SunOS)  &&  !defined(__sun__) && !defined(__FreeBSD__)
-             /* Solaris printf doesn't cope with NULLs */
- #if 0
-             /* The standard says this result is undefined, we shouldn't test for it, it is not consistent */
diff --git a/biology/sra-tools/files/patch-ncbi-vdb_test_vdb_test-dependencies__dflt.cpp b/biology/sra-tools/files/patch-ncbi-vdb_test_vdb_test-dependencies__dflt.cpp
deleted file mode 100644
index b063ef020502..000000000000
--- a/biology/sra-tools/files/patch-ncbi-vdb_test_vdb_test-dependencies__dflt.cpp
+++ /dev/null
@@ -1,12 +0,0 @@
---- ncbi-vdb/test/vdb/test-dependencies_dflt.cpp.orig	2023-07-10 16:13:36 UTC
-+++ ncbi-vdb/test/vdb/test-dependencies_dflt.cpp
-@@ -139,6 +139,9 @@ class EmptyFixture : public DepFixture { (public)
- 
- class RefseqFixture : public DepFixture {
- 
-+  #if BSD
-+    // FIXME: Should there be a separate kfg/freebsd?
-+    #define PATH "kfg/linux"
-   #if LINUX
-     #define PATH "kfg/linux"
-   #elif MAC
diff --git a/biology/sra-tools/files/patch-tools_external_driver-tool_file-path.posix.cpp b/biology/sra-tools/files/patch-tools_external_driver-tool_file-path.posix.cpp
deleted file mode 100644
index 9c995dcdbc51..000000000000
--- a/biology/sra-tools/files/patch-tools_external_driver-tool_file-path.posix.cpp
+++ /dev/null
@@ -1,20 +0,0 @@
---- tools/external/driver-tool/file-path.posix.cpp.orig	2023-07-10 16:23:35 UTC
-+++ tools/external/driver-tool/file-path.posix.cpp
-@@ -193,7 +193,16 @@ static char const *find_executable_path(char const *co
- FilePath FilePath::fullPathToExecutable(char const *const *const argv, char const *const *const envp, char const *const *const extra)
- {
-     char const *path;
--#if LINUX
-+// Assume sra-tools is installed by FreeBSD ports.  FreeBSD users
-+// don't often install software by other means.  Default prefix
-+// is /usr/local, but this can be overridden by the user building
-+// the port.  The port can replace /usr/local using sed if that's the
-+// case.
-+#if BSD
-+    char full_path[PATH_MAX];
-+    snprintf(full_path, PATH_MAX, "/usr/local/bin/%s", argv[0]);
-+    path = full_path;
-+#elif LINUX
-     path = "/proc/self/exe";
- #elif MAC
-     path = find_executable_path(extra, argv[0]);
diff --git a/biology/sra-tools/files/patch-tools_external_driver-tool_sratools.cpp b/biology/sra-tools/files/patch-tools_external_driver-tool_sratools.cpp
deleted file mode 100644
index bea51c07e42e..000000000000
--- a/biology/sra-tools/files/patch-tools_external_driver-tool_sratools.cpp
+++ /dev/null
@@ -1,25 +0,0 @@
---- tools/external/driver-tool/sratools.cpp.orig	2023-07-10 16:23:35 UTC
-+++ tools/external/driver-tool/sratools.cpp
-@@ -420,6 +420,7 @@ static int main(CommandLine const &argv)
-     enableLogging(argv.toolName.c_str());
- #endif
-     LOG(7) << "executable path: " << (std::string)argv.fullPathToExe << std::endl;
-+    // std::cerr << "executable path: " << (std::string)argv.fullPathToExe << std::endl;
- 
-     config = new Config();
-     struct Defer { ~Defer() { delete config; config = nullptr; } } freeConfig;
-@@ -576,6 +577,14 @@ static int main(CommandLine const &argv)
- }
- 
- } // namespace sratools
-+
-+#if BSD
-+int main(int argc, char *argv[], char *envp[])
-+{
-+    auto const invocation = CommandLine(argc, argv, envp, nullptr);
-+    return sratools::main(invocation);
-+}
-+#endif
- 
- #if MAC
- int main(int argc, char *argv[], char *envp[], char *apple[])
diff --git a/biology/sra-tools/files/patch-tools_external_vdb-config_tui_CMakeLists.txt b/biology/sra-tools/files/patch-tools_external_vdb-config_tui_CMakeLists.txt
deleted file mode 100644
index d3627cbbc42a..000000000000
--- a/biology/sra-tools/files/patch-tools_external_vdb-config_tui_CMakeLists.txt
+++ /dev/null
@@ -1,20 +0,0 @@
---- tools/external/vdb-config/tui/CMakeLists.txt.orig	2023-07-10 16:23:35 UTC
-+++ tools/external/vdb-config/tui/CMakeLists.txt
*** 232 LINES SKIPPED ***