Skip to content

Commit 0cadce2

Browse files
committed
Release 1.20
2 parents 6a7d33a + a67b53c commit 0cadce2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1771
-755
lines changed

INSTALL

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ a development ('-dev' or '-devel') package separate from the main library.
3838
liblzma (required, unless configured with --disable-lzma)
3939
libcurl (optional, but strongly recommended)
4040
libcrypto (optional for Amazon S3 support; not needed on MacOS)
41+
libdeflate (optional, but strongly recommended for faster gzip)
4142

4243
Disabling libbzip2 and liblzma will make some CRAM files unreadable, so
4344
is not recommended.
@@ -252,14 +253,14 @@ Debian / Ubuntu
252253
---------------
253254

254255
sudo apt-get update # Ensure the package list is up to date
255-
sudo apt-get install autoconf automake make gcc perl zlib1g-dev libbz2-dev liblzma-dev libcurl4-gnutls-dev libssl-dev
256+
sudo apt-get install autoconf automake make gcc perl zlib1g-dev libbz2-dev liblzma-dev libcurl4-gnutls-dev libssl-dev libdeflate-dev
256257

257258
Note: libcurl4-openssl-dev can be used as an alternative to libcurl4-gnutls-dev.
258259

259260
RedHat / CentOS
260261
---------------
261262

262-
sudo yum install autoconf automake make gcc perl-Data-Dumper zlib-devel bzip2 bzip2-devel xz-devel curl-devel openssl-devel
263+
sudo yum install autoconf automake make gcc perl-Data-Dumper zlib-devel bzip2 bzip2-devel xz-devel curl-devel openssl-devel libdeflate-devel
263264

264265
Note: On some versions perl FindBin will need to be installed to make the tests work.
265266

@@ -271,13 +272,19 @@ Alpine Linux
271272
doas apk update # Ensure the package list is up to date
272273
doas apk add autoconf automake make gcc musl-dev perl bash zlib-dev bzip2-dev xz-dev curl-dev openssl-dev
273274

275+
Ideally also install a copy of libdeflate-dev for faster (de)compression.
276+
This can be found in the Alpine community repository.
277+
274278
Note: some older Alpine versions use libressl-dev rather than openssl-dev.
275279

276280
OpenSUSE
277281
--------
278282

279283
sudo zypper install autoconf automake make gcc perl zlib-devel libbz2-devel xz-devel libcurl-devel libopenssl-devel
280284

285+
Also install libdeflate-devel, available on OpenSUSE Leap 15.4 onwards
286+
or directly via git releases above.
287+
281288
Windows MSYS2/MINGW64
282289
---------------------
283290

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,8 +150,8 @@ LIBHTS_SOVERSION = 3
150150
# is not strictly necessary and should be removed the next time
151151
# LIBHTS_SOVERSION is bumped (see #1144 and
152152
# https://developer.apple.com/library/archive/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/DynamicLibraryDesignGuidelines.html#//apple_ref/doc/uid/TP40002013-SW23)
153-
MACH_O_COMPATIBILITY_VERSION = 3.1.19
154-
MACH_O_CURRENT_VERSION = 3.1.19
153+
MACH_O_COMPATIBILITY_VERSION = 3.1.20
154+
MACH_O_CURRENT_VERSION = 3.1.20
155155

156156
# Force version.h to be remade if $(PACKAGE_VERSION) has changed.
157157
version.h: $(if $(wildcard version.h),$(if $(findstring "$(PACKAGE_VERSION)",$(shell cat version.h)),,force))

NEWS

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,91 @@
1+
Noteworthy changes in release 1.20 (15th April 2024)
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
Updates
5+
-------
6+
7+
* When working on named files, bgzip now sets the modified and access times
8+
of the output files it makes to match those of the corresponding input.
9+
(PR #1727, feature request #1718. Requested by Gert Hulselmans)
10+
11+
* It's now possible to use a -o option to specify the output file name in
12+
bgzip.
13+
(PR #1747, feature request #1726. Requested by Gert Hulselmans)
14+
15+
* Improved error faidx error messages.
16+
(PR #1743, thanks to Nick Moore)
17+
18+
* Faster reading of SAM array (type "B") tags. These often turn up
19+
in ONT and PacBio data.
20+
(PR #1741)
21+
22+
* Improved validity checking of base modification tags.
23+
(PR #1749)
24+
25+
* mpileup overlap removal now works where one read has a deletion.
26+
(PR #1751, fixes samtools/samtools#1992. Reported by Long Tian)
27+
28+
* The S3 plugin can now find buckets via S3 access point aliases.
29+
(PR #1756, thanks to Matt Pawelczyk;
30+
fixes samtools/samtools#1984. Reported by Albert Li)
31+
32+
* Added a --threads option (and -@ short option) to tabix.
33+
(PR #1755, feature request #1735. Requested by Dan Bolser)
34+
35+
* tabix can now index Graph Alignment Format (GAF) files.
36+
(See https://github.com/lh3/gfatools/blob/master/doc/rGFA.md)
37+
(PR #1763, thanks to Adam Novak)
38+
39+
Bug fixes
40+
---------
41+
42+
* Security fix: Prevent possible heap overflow in cram_encode_aux() on
43+
bad RG:Z tags.
44+
(PR #1737)
45+
46+
* Security fix: Prevent attempts to call a NULL pointer if certain URL
47+
schemes are used in CRAM @SQ UR: tags.
48+
(PR #1757)
49+
50+
* Security fix: Fixed a bug where following certain AWS S3 redirects could
51+
downgrade the connection from TLS (i.e. https://) to unencrypted http://.
52+
This could happen when using path-based URLs and AWS_DEFAULT_REGION
53+
was set to a region other that the one where the data was stored.
54+
(PR #1762, fixes #1760. Reported by andaca)
55+
56+
* Fixed arithmetic overflow when loading very long references for CRAM.
57+
(PR #1738, fixes #1738. Reported by Shane McCarthy)
58+
59+
* Fixed faidx and CRAM reference look-ups on compressed fasta where the .fai
60+
index file was present, but the .gzi index of compressed offsets was not.
61+
(PR #1745, fixes #1744. Reported by Theodore Li)
62+
63+
* Fixed BCF indexing on-the-fly bug which produced invalid indexes when
64+
using multiple compression threads.
65+
(PR #1742, fixes #1740. Reported by graphenn)
66+
67+
* Ensure that pileup destructors are called by bam_plp_destroy(), to
68+
prevent memory leaks.
69+
(PR #1749, PR #1754)
70+
71+
* Ensure on-the-fly index timestamps are always older than the data file.
72+
Previously the files could be closed out of order, leading to warnings
73+
being printed when using the index.
74+
(PR #1753, fixes #1732. Reported by Gert Hulselmans)
75+
76+
* To prevent data corruption when reading (strictly invalid) VCF files
77+
with duplicated FORMAT tags, all but the first copy of the data
78+
associated with the tag are now dropped with a warning.
79+
(PR #1752, PR #1761, fixes #1733. Reported by anthakki)
80+
81+
* Fixed a bug introduced in release 1.19 (PR #1689) which broke variant
82+
record data if it tried to remove an over-long tag.
83+
(PR #1752, PR #1761)
84+
85+
* Changed error to warning when complaining about use of the CG tag
86+
in SAM or CRAM files.
87+
(PR #1758, fixes samtools/samtools#2002)
88+
189
Noteworthy changes in release 1.19.1 (22nd January 2024)
290
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
391

@@ -33,6 +121,7 @@ Updates
33121

34122
In future work, the library will instead convert such tags into their
35123
local alternatives (see https://github.com/samtools/hts-specs/pull/434).
124+
(PR #1689)
36125

37126
* New program. Adds annot-tsv which annotates regions in a destination file with
38127
texts from overlapping regions in a source file.

annot-tsv.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
'\" t
2-
.TH annot-tsv 1 "22 January 2024" "htslib-1.19.1" "Bioinformatics tools"
2+
.TH annot-tsv 1 "15 April 2024" "htslib-1.20" "Bioinformatics tools"
33
.\"
44
.\" Copyright (C) 2015, 2017-2018, 2023 Genome Research Ltd.
55
.\"

bgzf.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
33
Copyright (c) 2008 Broad Institute / Massachusetts Institute of Technology
44
2011, 2012 Attractive Chaos <[email protected]>
5-
Copyright (C) 2009, 2013-2022 Genome Research Ltd
5+
Copyright (C) 2009, 2013-2023 Genome Research Ltd
66
77
Permission is hereby granted, free of charge, to any person obtaining a copy
88
of this software and associated documentation files (the "Software"), to deal
@@ -1959,6 +1959,11 @@ int bgzf_flush(BGZF *fp)
19591959
return ret;
19601960
}
19611961
#endif
1962+
1963+
if (!fp->is_compressed) {
1964+
return hflush(fp->fp);
1965+
}
1966+
19621967
while (fp->block_offset > 0) {
19631968
int block_length;
19641969
if ( fp->idx_build_otf )

bgzip.1

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
.TH bgzip 1 "22 January 2024" "htslib-1.19.1" "Bioinformatics tools"
1+
.TH bgzip 1 "15 April 2024" "htslib-1.20" "Bioinformatics tools"
22
.SH NAME
33
.PP
44
bgzip \- Block compression/decompression utility
55
.\"
66
.\" Copyright (C) 2009-2011 Broad Institute.
7-
.\" Copyright (C) 2018, 2021-2023 Genome Research Limited.
7+
.\" Copyright (C) 2018, 2021-2024 Genome Research Limited.
88
.\"
99
.\" Author: Heng Li <[email protected]>
1010
.\"
@@ -50,6 +50,8 @@ bgzip \- Block compression/decompression utility
5050
.IR index_name ]
5151
.RB [ -l
5252
.IR compression_level ]
53+
.RB [ -o
54+
.IR outfile ]
5355
.RB [ -s
5456
.IR size ]
5557
.RB [ -@
@@ -71,7 +73,9 @@ otherwise when compressing bgzip will write to a new file with a .gz
7173
suffix and remove the original. When decompressing the input file must
7274
have a .gz suffix, which will be removed to make the output name. Again
7375
after decompression completes the input file will be removed. When multiple
74-
files are given as input, the operation is performed on all of them.
76+
files are given as input, the operation is performed on all of them. Access
77+
and modification time of input file from filesystem is set to output file.
78+
Note, access time may get updated by system when it deems appropriate.
7579

7680
.SH OPTIONS
7781
.TP 10
@@ -128,6 +132,10 @@ Do not delete input file during operation.
128132
Compression level to use when compressing.
129133
From 0 to 9, or -1 for the default level set by the compression library. [-1]
130134
.TP
135+
.BI "-o, --output " FILE
136+
Write to a file, keep original files unchanged, will overwrite an existing
137+
file.
138+
.TP
131139
.B "-r, --reindex"
132140
Rebuild the index on an existing compressed file.
133141
.TP
@@ -136,7 +144,7 @@ Decompress INT bytes (uncompressed size) to standard output.
136144
Implies -c.
137145
.TP
138146
.B "-t, --test"
139-
Test the intregrity of the compressed file.
147+
Test the integrity of the compressed file.
140148
.TP
141149
.BI "-@, --threads " INT
142150
Number of threads to use [1].

0 commit comments

Comments
 (0)