[med-svn] [Git][med-team/plink2][upstream] New upstream version 2.00~a3-211125+dfsg
Dylan Aïssi (@daissi)
gitlab at salsa.debian.org
Sat Dec 4 08:33:13 GMT 2021
Dylan Aïssi pushed to branch upstream at Debian Med / plink2
Commits:
ffd32fc5 by Dylan Aïssi at 2021-12-04T09:28:50+01:00
New upstream version 2.00~a3-211125+dfsg
- - - - -
7 changed files:
- Makefile.src
- Python/pgenlib.pyx
- Python/setup.py
- build_dynamic/Makefile
- plink2.cc
- plink2_glm.cc
- plink2_help.cc
Changes:
=====================================
Makefile.src
=====================================
@@ -9,15 +9,25 @@ CSRC = include/SFMT.c libdeflate/lib/adler32.c libdeflate/lib/crc32.c libdeflate
ZCSRC = zstd/lib/common/debug.c zstd/lib/common/entropy_common.c zstd/lib/common/zstd_common.c zstd/lib/common/error_private.c zstd/lib/common/xxhash.c zstd/lib/common/fse_decompress.c zstd/lib/common/pool.c zstd/lib/common/threading.c zstd/lib/compress/fse_compress.c zstd/lib/compress/hist.c zstd/lib/compress/huf_compress.c zstd/lib/compress/zstd_double_fast.c zstd/lib/compress/zstd_fast.c zstd/lib/compress/zstd_lazy.c zstd/lib/compress/zstd_ldm.c zstd/lib/compress/zstd_opt.c zstd/lib/compress/zstd_compress.c zstd/lib/compress/zstd_compress_literals.c zstd/lib/compress/zstd_compress_sequences.c zstd/lib/compress/zstd_compress_superblock.c zstd/lib/compress/zstdmt_compress.c zstd/lib/decompress/huf_decompress.c zstd/lib/decompress/zstd_decompress.c zstd/lib/decompress/zstd_ddict.c zstd/lib/decompress/zstd_decompress_block.c
-CCSRC = include/plink2_base.cc include/plink2_bits.cc include/pgenlib_misc.cc include/pgenlib_read.cc include/pgenlib_write.cc include/plink2_bgzf.cc include/plink2_stats.cc include/plink2_string.cc include/plink2_text.cc include/plink2_thread.cc include/plink2_zstfile.cc plink2.cc plink2_adjust.cc plink2_cmdline.cc plink2_common.cc plink2_compress_stream.cc plink2_data.cc plink2_decompress.cc plink2_export.cc plink2_fasta.cc plink2_filter.cc plink2_glm.cc plink2_help.cc plink2_import.cc plink2_ld.cc plink2_matrix.cc plink2_matrix_calc.cc plink2_merge.cc plink2_misc.cc plink2_psam.cc plink2_pvar.cc plink2_random.cc plink2_set.cc
+PGENLIB_CCSRC = include/plink2_base.cc include/plink2_bits.cc include/pgenlib_misc.cc include/pgenlib_read.cc include/pgenlib_write.cc
+
+PLINK2LIB_CCSRC = $(PGENLIB_CCSRC) include/plink2_bgzf.cc include/plink2_stats.cc include/plink2_string.cc include/plink2_text.cc include/plink2_thread.cc include/plink2_zstfile.cc
+
+CCSRC = $(PLINK2LIB_CCSRC) plink2.cc plink2_adjust.cc plink2_cmdline.cc plink2_common.cc plink2_compress_stream.cc plink2_data.cc plink2_decompress.cc plink2_export.cc plink2_fasta.cc plink2_filter.cc plink2_glm.cc plink2_help.cc plink2_import.cc plink2_ld.cc plink2_matrix.cc plink2_matrix_calc.cc plink2_merge.cc plink2_misc.cc plink2_psam.cc plink2_pvar.cc plink2_random.cc plink2_set.cc
OBJ_NO_ZSTD = $(CSRC:.c=.o) $(CCSRC:.cc=.o)
OBJ = $(CSRC:.c=.o) $(ZCSRC:.c=.o) $(CCSRC:.cc=.o)
+PGENLIB_OBJ = $(PGENLIB_CCSRC:.cc=.o)
+PLINK2LIB_OBJ = $(CSRC:.c=.o) $(ZCSRC:.c=.o) $(PLINK2LIB_CCSRC:.cc=.o)
CSRC2 = $(foreach fname,$(CSRC),../$(fname))
ZCSRC2 = $(foreach fname,$(ZCSRC),../$(fname))
CCSRC2 = $(foreach fname,$(CCSRC),../$(fname))
+PGENLIB_CCSRC2 = $(foreach fname,$(PGENLIB_CCSRC),../$(fname))
+PLINK2LIB_CCSRC2 = $(foreach fname,$(PLINK2LIB_CCSRC),../$(fname))
OBJ2 = $(notdir $(OBJ))
+PGENLIB_OBJ2 = $(notdir $(PGENLIB_OBJ))
+PLINK2LIB_OBJ2 = $(notdir $(PLINK2LIB_OBJ))
OBJ3 = $(CSRC2:.c=.o) $(ZCSRC2:.c=.o) $(CCSRC2:.cc=.o)
@@ -28,7 +38,7 @@ CXXINCLUDE2 = -I../simde
ZSTD_INCLUDE = -Izstd/lib -Izstd/lib/common
ZSTD_INCLUDE2 = -I../zstd/lib -I../zstd/lib/common
-PGCSRC = include/plink2_base.cc include/plink2_bits.cc include/pgenlib_misc.cc include/pgenlib_read.cc include/pgenlib_write.cc pgen_compress.cc
+PGCSRC = $(PGENLIB_CCSRC) pgen_compress.cc
PGCOBJ = $(PGCSRC:.cc=.o)
PGCSRC2 = $(foreach fname,$(PGCSRC),../$(fname))
=====================================
Python/pgenlib.pyx
=====================================
@@ -1130,12 +1130,12 @@ cdef class PgenReader:
CleanupPgfi(self._info_ptr, &reterr)
if self._info_ptr[0].vrtypes:
aligned_free(self._info_ptr[0].vrtypes)
- if self._state_ptr:
- CleanupPgr(self._state_ptr, &reterr)
- if PgrGetFreadBuf(self._state_ptr):
- aligned_free(PgrGetFreadBuf(self._state_ptr))
- PyMem_Free(self._state_ptr)
- self._state_ptr = NULL
+ if self._state_ptr:
+ CleanupPgr(self._state_ptr, &reterr)
+ if PgrGetFreadBuf(self._state_ptr):
+ aligned_free(PgrGetFreadBuf(self._state_ptr))
+ PyMem_Free(self._state_ptr)
+ self._state_ptr = NULL
PyMem_Free(self._info_ptr)
self._info_ptr = NULL
if reterr != kPglRetSuccess:
@@ -1154,11 +1154,11 @@ cdef class PgenReader:
CleanupPgfi(self._info_ptr, &reterr)
if self._info_ptr[0].vrtypes:
aligned_free(self._info_ptr[0].vrtypes)
- if self._state_ptr:
- CleanupPgr(self._state_ptr, &reterr)
- if PgrGetFreadBuf(self._state_ptr):
- aligned_free(PgrGetFreadBuf(self._state_ptr))
- PyMem_Free(self._state_ptr)
+ if self._state_ptr:
+ CleanupPgr(self._state_ptr, &reterr)
+ if PgrGetFreadBuf(self._state_ptr):
+ aligned_free(PgrGetFreadBuf(self._state_ptr))
+ PyMem_Free(self._state_ptr)
PyMem_Free(self._info_ptr)
return
=====================================
Python/setup.py
=====================================
@@ -21,6 +21,6 @@ ext_modules = [
]
setup(name = 'Pgenlib',
- version = '0.75',
+ version = '0.76',
description = "Wrapper for pgenlib's basic reader and writer.",
ext_modules = cythonize(ext_modules))
=====================================
build_dynamic/Makefile
=====================================
@@ -106,6 +106,8 @@ else
LINKFLAGS += -lzstd
endif
+LIBTOOL=ar
+STATIC=rcs
UNAME := $(shell uname)
ifeq ($(UNAME), Darwin)
ifdef FORCE_32BIT
@@ -118,6 +120,8 @@ ifeq ($(UNAME), Darwin)
CFLAGS += -I/usr/local/include
CXXFLAGS += -I/usr/local/include -stdlib=libc++
LINKFLAGS += -L/usr/local/lib
+ LIBTOOL=libtool
+ STATIC=-static
else
ifdef DYNAMIC_MKL
ifdef NO_LAPACK
@@ -159,8 +163,28 @@ plink2$(SFX): $(CSRC2) $(ZCSRC2) $(CCSRC2) ../plink2_cpu.cc
pgen_compress$(SFX): $(PGCSRC2)
$(CXX) $(CXXFLAGS) $(PGCSRC2) -o $@
+pgenlib.a: $(PGENLIB_CCSRC2)
+ $(CXX) $(CXXFLAGS) $(PGENLIB_CCSRC2) -c
+ $(LIBTOOL) $(STATIC) -o $@ $(PGENLIB_OBJ2)
+
+plink2lib.a: $(CSRC2) $(ZCSRC2) $(PLINK2LIB_CCSRC2)
+ $(CC) $(CFLAGS) $(CSRC2) -c
+ $(CC) $(ZCFLAGS) $(ZCSRC2) -c
+ $(CXX) $(CXXFLAGS) $(PLINK2LIB_CCSRC2) -c
+ $(LIBTOOL) $(STATIC) -o $@ $(PLINK2LIB_OBJ2)
+
+static_pgenlib_test: pgenlib.a ../pgen_compress.cc
+ $(CXX) $(CXXFLAGS) -o $@ ../pgen_compress.cc -L. pgenlib.a
+
+static_plink2lib_test: plink2lib.a ../pgen_compress.cc
+ $(CXX) $(CXXFLAGS) -o $@ ../pgen_compress.cc -L. plink2lib.a
+
.PHONY: clean
clean:
rm -f *.o
rm -f plink2
rm -f pgen_compress
+ rm -f pgenlib.a
+ rm -f plink2lib.a
+ rm -f static_pgenlib_test
+ rm -f static_plink2lib_test
=====================================
plink2.cc
=====================================
@@ -71,7 +71,7 @@ static const char ver_str[] = "PLINK v2.00a3"
#ifdef USE_MKL
" Intel"
#endif
- " (11 Oct 2021)";
+ " (25 Nov 2021)";
static const char ver_str2[] =
// include leading space if day < 10, so character length stays the same
""
=====================================
plink2_glm.cc
=====================================
@@ -728,7 +728,7 @@ uint32_t CheckForSeparatedCatCovar(const uintptr_t* pheno_cc, const uintptr_t* c
if (!case_and_ctrl_cat_ct) {
return 2;
}
- if (case_and_ctrl_cat_ct == pheno_by_cat_ct * 2) {
+ if (case_and_ctrl_cat_ct * 2 == pheno_by_cat_ct) {
// all categories contain both cases and controls.
return 0;
}
=====================================
plink2_help.cc
=====================================
@@ -1294,8 +1294,9 @@ PglErr DispHelp(const char* const* argvk, uint32_t param_ct) {
" chrX.)\n"
" * The 'se' modifier causes the input coefficients to be treated as\n"
" independent standard errors; in this case, standard errors for the score\n"
-" average/sum are reported. (Note that this will systematically\n"
-" underestimate standard errors when scored variants are in LD.)\n"
+" average/sum are reported, under a Gaussian approximation. (Note that\n"
+" this will systematically underestimate standard errors when scored\n"
+" variants are in LD.)\n"
" * By default, --score errors out if a variant ID in the input file appears\n"
" multiple times in the main dataset. Use the 'ignore-dup-ids' modifier to\n"
" skip them instead (a warning is still printed if such variants are\n"
View it on GitLab: https://salsa.debian.org/med-team/plink2/-/commit/ffd32fc52a25740848aba72e81fc1f075b08b4b5
--
View it on GitLab: https://salsa.debian.org/med-team/plink2/-/commit/ffd32fc52a25740848aba72e81fc1f075b08b4b5
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20211204/b3e9c971/attachment-0001.htm>
More information about the debian-med-commit
mailing list