Open romk1n opened 1 month ago
Please check the path where zstd is installed, I expect something like /opt/homebrew/lib, which is not in library path. Export the path using 'export LIBRARY_PATH=$LIBRARY_PATH:<path to required library's libpath>'. I expect this to solve the issue.
Additionally you may have to add path to icu4c as well with this.
i tried this but it didn't work
~/Downloads/vcf/ which zstd
/opt/homebrew/bin/zstd
~/Downloads/vcf/ export LIBRARY_PATH=$LIBRARY_PATH:/opt/homebrew/lib
~/Downloads/vcf/ ./vcf_validator_macos -i 41211052306254.filtered.snp.vcf
dyld[1919]: Library not loaded: /usr/local/opt/zstd/lib/libzstd.1.dylib
Referenced from: <0F365E6F-B9D9-3442-963D-5A8BAEA154EC> <redacted>Downloads/vcf/vcf_validator_macos
Reason: tried: '/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/usr/local/lib/libzstd.1.dylib' (no such file), '/usr/lib/libzstd.1.dylib' (no such file, not in dyld cache)
[1] 1919 abort ./vcf_validator_macos -i 41211052306254.filtered.snp.vcf
~/Downloads/vcf/
Sorry! I read incorrectly, as a build issue which I have faced earlier and suggested the above. On re-read I see that it is clearly mentioned as execution issue. As the error mentions, zstd is not found in expected path.
Could you please share more information, was it built locally or binary copied from somewhere, processor of built machine and execute machine, output of below commands etc.
brew info zstd otool -L vcf_validator otool -l vcf_validator dyld_info vcf_validator Environment variable details - env
sure plase find below
==> zstd: stable 1.5.6 (bottled), HEAD
Zstandard is a real-time compression algorithm
https://facebook.github.io/zstd/
Installed
/opt/homebrew/Cellar/zstd/1.5.6 (31 files, 2.2MB) *
Poured from bottle using the formulae.brew.sh API on 2024-05-10 at 10:36:42
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/z/zstd.rb
License: BSD-3-Clause
-L
vcf_validator_macos:
/usr/lib/libcurl.4.dylib (compatibility version 7.0.0, current version 9.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1319.0.0)
/usr/lib/libbz2.1.0.dylib (compatibility version 1.0.0, current version 1.0.8)
/usr/local/opt/xz/lib/liblzma.5.dylib (compatibility version 10.0.0, current version 10.5.0)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
/usr/local/opt/zstd/lib/libzstd.1.dylib (compatibility version 1.0.0, current version 1.5.5)
/usr/local/opt/icu4c/lib/libicudata.73.dylib (compatibility version 73.0.0, current version 73.2.0)
/usr/local/opt/icu4c/lib/libicui18n.73.dylib (compatibility version 73.0.0, current version 73.2.0)
/usr/local/opt/icu4c/lib/libicuuc.73.dylib (compatibility version 73.0.0, current version 73.2.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 1300.36.0)
-l
cf_validator_macos:
Load command 0
cmd LC_SEGMENT_64
cmdsize 72
segname __PAGEZERO
vmaddr 0x0000000000000000
vmsize 0x0000000100000000
fileoff 0
filesize 0
maxprot 0x00000000
initprot 0x00000000
nsects 0
flags 0x0
Load command 1
cmd LC_SEGMENT_64
cmdsize 632
segname __TEXT
vmaddr 0x0000000100000000
vmsize 0x000000000036c000
fileoff 0
filesize 3588096
maxprot 0x00000005
initprot 0x00000005
nsects 7
flags 0x0
Section
sectname __text
segname __TEXT
addr 0x0000000100005370
size 0x000000000031dc93
offset 21360
align 2^4 (16)
reloff 0
nreloc 0
flags 0x80000400
reserved1 0
reserved2 0
Section
sectname __stubs
segname __TEXT
addr 0x0000000100323004
size 0x0000000000000870
offset 3289092
align 2^1 (2)
reloff 0
nreloc 0
flags 0x80000408
reserved1 0 (index into indirect symbol table)
reserved2 6 (size of stubs)
Section
sectname __stub_helper
segname __TEXT
addr 0x0000000100323874
size 0x0000000000000d08
offset 3291252
align 2^2 (4)
reloff 0
nreloc 0
flags 0x80000400
reserved1 0
reserved2 0
Section
sectname __gcc_except_tab
segname __TEXT
addr 0x000000010032457c
size 0x0000000000024194
offset 3294588
align 2^2 (4)
reloff 0
nreloc 0
flags 0x00000000
reserved1 0
reserved2 0
Section
sectname __const
segname __TEXT
addr 0x0000000100348710
size 0x000000000000e430
offset 3442448
align 2^4 (16)
reloff 0
nreloc 0
flags 0x00000000
reserved1 0
reserved2 0
Section
sectname __cstring
segname __TEXT
addr 0x0000000100356b40
size 0x000000000000d3ca
offset 3500864
align 2^4 (16)
reloff 0
nreloc 0
flags 0x00000002
reserved1 0
reserved2 0
Section
sectname __unwind_info
segname __TEXT
addr 0x0000000100363f0c
size 0x00000000000080ec
offset 3555084
align 2^2 (4)
reloff 0
nreloc 0
flags 0x00000000
reserved1 0
reserved2 0
Load command 2
cmd LC_SEGMENT_64
cmdsize 312
segname __DATA_CONST
vmaddr 0x000000010036c000
vmsize 0x0000000000010000
fileoff 3588096
filesize 65536
maxprot 0x00000003
initprot 0x00000003
nsects 3
flags 0x10
Section
sectname __got
segname __DATA_CONST
addr 0x000000010036c000
size 0x0000000000001270
offset 3588096
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000006
reserved1 360 (index into indirect symbol table)
reserved2 0
Section
sectname __mod_init_func
segname __DATA_CONST
addr 0x000000010036d270
size 0x00000000000000d0
offset 3592816
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000009
reserved1 0
reserved2 0
Section
sectname __const
segname __DATA_CONST
addr 0x000000010036d340
size 0x000000000000be40
offset 3593024
align 2^4 (16)
reloff 0
nreloc 0
flags 0x00000000
reserved1 0
reserved2 0
Load command 3
cmd LC_SEGMENT_64
cmdsize 552
segname __DATA
vmaddr 0x000000010037c000
vmsize 0x0000000000010000
fileoff 3653632
filesize 16384
maxprot 0x00000003
initprot 0x00000003
nsects 6
flags 0x0
Section
sectname __la_symbol_ptr
segname __DATA
addr 0x000000010037c000
size 0x0000000000000b40
offset 3653632
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000007
reserved1 950 (index into indirect symbol table)
reserved2 0
Section
sectname __data
segname __DATA
addr 0x000000010037cb40
size 0x0000000000002770
offset 3656512
align 2^4 (16)
reloff 0
nreloc 0
flags 0x00000000
reserved1 0
reserved2 0
Section
sectname __thread_vars
segname __DATA
addr 0x000000010037f2b0
size 0x0000000000000018
offset 3666608
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000013
reserved1 0
reserved2 0
Section
sectname __thread_bss
segname __DATA
addr 0x000000010037f2c8
size 0x0000000000000008
offset 0
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000012
reserved1 0
reserved2 0
Section
sectname __bss
segname __DATA
addr 0x000000010037f2d0
size 0x0000000000009548
offset 0
align 2^4 (16)
reloff 0
nreloc 0
flags 0x00000001
reserved1 0
reserved2 0
Section
sectname __common
segname __DATA
addr 0x0000000100388818
size 0x00000000000005a0
offset 0
align 2^3 (8)
reloff 0
nreloc 0
flags 0x00000001
reserved1 0
reserved2 0
Load command 4
cmd LC_SEGMENT_64
cmdsize 72
segname __LINKEDIT
vmaddr 0x000000010038c000
vmsize 0x0000000000210000
fileoff 3670016
filesize 2152200
maxprot 0x00000001
initprot 0x00000001
nsects 0
flags 0x0
Load command 5
cmd LC_DYLD_INFO_ONLY
cmdsize 48
rebase_off 3670016
rebase_size 2720
bind_off 3672736
bind_size 7256
weak_bind_off 3679992
weak_bind_size 84816
lazy_bind_off 3764808
lazy_bind_size 13592
export_off 3778400
export_size 121784
Load command 6
cmd LC_SYMTAB
cmdsize 24
symoff 3908912
nsyms 38328
stroff 4527400
strsize 1294816
Load command 7
cmd LC_DYSYMTAB
cmdsize 80
ilocalsym 0
nlocalsym 35198
iextdefsym 35198
nextdefsym 2684
iundefsym 37882
nundefsym 446
tocoff 0
ntoc 0
modtaboff 0
nmodtab 0
extrefsymoff 0
nextrefsyms 0
indirectsymoff 4522160
nindirectsyms 1310
extreloff 0
nextrel 0
locreloff 0
nlocrel 0
Load command 8
cmd LC_LOAD_DYLINKER
cmdsize 32
name /usr/lib/dyld (offset 12)
Load command 9
cmd LC_UUID
cmdsize 24
uuid 0F365E6F-B9D9-3442-963D-5A8BAEA154EC
Load command 10
cmd LC_BUILD_VERSION
cmdsize 32
platform 1
minos 12.7
sdk 13.1
ntools 1
tool 3
version 820.1
Load command 11
cmd LC_SOURCE_VERSION
cmdsize 16
version 0.0
Load command 12
cmd LC_MAIN
cmdsize 24
entryoff 23952
stacksize 0
Load command 13
cmd LC_LOAD_DYLIB
cmdsize 56
name /usr/lib/libcurl.4.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 9.0.0
compatibility version 7.0.0
Load command 14
cmd LC_LOAD_DYLIB
cmdsize 56
name /usr/lib/libSystem.B.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 1319.0.0
compatibility version 1.0.0
Load command 15
cmd LC_LOAD_DYLIB
cmdsize 56
name /usr/lib/libbz2.1.0.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 1.0.8
compatibility version 1.0.0
Load command 16
cmd LC_LOAD_DYLIB
cmdsize 64
name /usr/local/opt/xz/lib/liblzma.5.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 10.5.0
compatibility version 10.0.0
Load command 17
cmd LC_LOAD_DYLIB
cmdsize 48
name /usr/lib/libz.1.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 1.2.11
compatibility version 1.0.0
Load command 18
cmd LC_LOAD_DYLIB
cmdsize 64
name /usr/local/opt/zstd/lib/libzstd.1.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 1.5.5
compatibility version 1.0.0
Load command 19
cmd LC_LOAD_DYLIB
cmdsize 72
name /usr/local/opt/icu4c/lib/libicudata.73.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 73.2.0
compatibility version 73.0.0
Load command 20
cmd LC_LOAD_DYLIB
cmdsize 72
name /usr/local/opt/icu4c/lib/libicui18n.73.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 73.2.0
compatibility version 73.0.0
Load command 21
cmd LC_LOAD_DYLIB
cmdsize 72
name /usr/local/opt/icu4c/lib/libicuuc.73.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 73.2.0
compatibility version 73.0.0
Load command 22
cmd LC_LOAD_DYLIB
cmdsize 48
name /usr/lib/libc++.1.dylib (offset 24)
time stamp 2 Thu Jan 1 01:00:02 1970
current version 1300.36.0
compatibility version 1.0.0
Load command 23
cmd LC_FUNCTION_STARTS
cmdsize 16
dataoff 3900184
datasize 7968
Load command 24
cmd LC_DATA_IN_CODE
cmdsize 16
dataoff 3908152
datasize 760
dyld_info
vcf_validator_macos [x86_64]:
-platform:
platform minOS sdk
macOS 12.7 13.1
-segments:
load-offset segment section sect-size seg-size perm
0x00000000 __TEXT 3504KB r.x
0x00005370 __text 3267731
0x00323004 __stubs 2160
0x00323874 __stub_helper 3336
0x0032457C __gcc_except_tab 147860
0x00348710 __const 58416
0x00356B40 __cstring 54218
0x00363F0C __unwind_info 33004
0x0036C000 __DATA_CONST 64KB rw.
0x0036C000 __got 4720
0x0036D270 __mod_init_func 208
0x0036D340 __const 48704
0x0037C000 __DATA 64KB rw.
0x0037C000 __la_symbol_ptr 2880
0x0037CB40 __data 10096
0x0037F2B0 __thread_vars 24
0x0037F2C8 __thread_bss 8
0x0037F2D0 __bss 38216
0x00388818 __common 1440
-dependents:
attributes load path
/usr/lib/libcurl.4.dylib
/usr/lib/libSystem.B.dylib
/usr/lib/libbz2.1.0.dylib
/usr/local/opt/xz/lib/liblzma.5.dylib
/usr/lib/libz.1.dylib
/usr/local/opt/zstd/lib/libzstd.1.dylib
/usr/local/opt/icu4c/lib/libicudata.73.dylib
/usr/local/opt/icu4c/lib/libicui18n.73.dylib
/usr/local/opt/icu4c/lib/libicuuc.73.dylib
/usr/lib/libc++.1.dylib
my env has too many senstivie varbible if there is anything specific you looking for let me know
HOMEBREW_PREFIX=/opt/homebrew
HOMEBREW_CELLAR=/opt/homebrew/Cellar
HOMEBREW_REPOSITORY=/opt/homebrew
LIBRARY_PATH=:/opt/homebrew/bin/zstd:/opt/homebrew/lib
Thanks for the info. From home-brew path, you might be using arm based Mac, please correct if not. The binary is made for intel processor and that could be the reason for error. They have libraries in different locations. For now, the way would be either to use Intel Mac or build it locally on your arm mac. Meanwhile we will try to generate binaries which work with arm as well.
it is an arm - yes.
getting the following error if I trying to get latest binary on Sonoma 14.4.1 ( I did try brew install zstd which was successful)
Reason: tried: '/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/usr/local/opt/zstd/lib/libzstd.1.dylib' (no such file), '/usr/local/lib/libzstd.1.dylib' (no such file), '/usr/lib/libzstd.1.dylib' (no such file, not in dyld cache)