Error in taglib_set_picture (taglib.go)
Opened this issue · 3 comments
eamador commented
Error in taglib_set_picture (taglib.go)
I am running make linux-amd64
and i getting the following error.
$ make linux-amd64
Building for Linux AMD64
go clean -cache
CGO_ENABLED=1 \
GOOS=linux \
GOARCH=amd64 \
CC="zig cc -target x86_64-linux-gnu -I/usr/local/include/taglib -L/usr/local/lib -DTAGLIB_STATIC" \
CXX="zig c++ -target x86_64-linux-gnu -I/usr/local/include/taglib -L/usr/local/lib -DTAGLIB_STATIC -fno-exceptions -stdlib=libc++ -L/usr/lib/gcc/x86_64-linux-gnu/11 -L/usr/lib/x86_64-linux-gnu -lc++ -lc++abi -lm -lpthread -ldl" \
go build -ldflags="-w -s" -o=./bin/beatportdl-linux-amd64 ./cmd/beatportdl
# unspok3n/beatportdl/internal/taglib
internal/taglib/taglib.go:125:11: could not determine kind of name for C.TagLib_Complex_Property_Picture_Data
internal/taglib/taglib.go:124:8: could not determine kind of name for C.taglib_complex_property_free
internal/taglib/taglib.go:156:8: could not determine kind of name for C.taglib_complex_property_free_keys
internal/taglib/taglib.go:120:14: could not determine kind of name for C.taglib_complex_property_get
internal/taglib/taglib.go:152:11: could not determine kind of name for C.taglib_complex_property_keys
internal/taglib/taglib.go:126:2: could not determine kind of name for C.taglib_picture_from_complex_property
internal/taglib/taglib.go:92:8: could not determine kind of name for C.taglib_property_free
internal/taglib/taglib.go:73:12: could not determine kind of name for C.taglib_property_get
internal/taglib/taglib.go:88:11: could not determine kind of name for C.taglib_property_keys
internal/taglib/taglib.go:84:2: could not determine kind of name for C.taglib_property_set
cgo:
zig errors for preamble:
internal/taglib/taglib.go:11:3: error: call to undeclared function 'TAGLIB_COMPLEX_PROPERTY_PICTURE'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
11 | TAGLIB_COMPLEX_PROPERTY_PICTURE(props, data, size, desc, mime, typ);
| ^
internal/taglib/taglib.go:11:35: error: use of undeclared identifier 'props'
11 | TAGLIB_COMPLEX_PROPERTY_PICTURE(props, data, size, desc, mime, typ);
| ^
internal/taglib/taglib.go:12:3: error: call to undeclared function 'taglib_complex_property_set'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
12 | taglib_complex_property_set(file, "PICTURE", props);
| ^
internal/taglib/taglib.go:12:48: error: use of undeclared identifier 'props'
12 | taglib_complex_property_set(file, "PICTURE", props);
| ^
4 errors generated.
make: *** [Makefile:42: linux-amd64] Error 1
Any ideas what can be wrong? 🙏
Thanks in advance
cheesetosti commented
And if you use LINUX_AMD64_LIB_PATH="-L/usr/lib -I/usr/include/taglib -L/lib/x86_64-linux-gnu" make linux-amd64
?
unspok3n commented
You are probably using an incompatible version of taglib, properties were added in 2.0
eamador commented
And if you use
LINUX_AMD64_LIB_PATH="-L/usr/lib -I/usr/include/taglib -L/lib/x86_64-linux-gnu" make linux-amd64
?
Thank you, tried but unfortunatelly I get the following error:
/snap/go/10743/pkg/tool/linux_amd64/link: running zig failed: exit status 1
/snap/bin/zig cc -target x86_64-linux-gnu -L/usr/lib -I/usr/local/include/taglib -L/lib/x86_64-linux-gnu -DTAGLIB_STATIC -m64 -s -o $WORK/b001/exe/a.out -rdynamic /tmp/go-link-2857471273/go.o /tmp/go-link-2857471273/000000.o /tmp/go-link-2857471273/000001.o /tmp/go-link-2857471273/000002.o /tmp/go-link-2857471273/000003.o /tmp/go-link-2857471273/000004.o /tmp/go-link-2857471273/000005.o /tmp/go-link-2857471273/000006.o /tmp/go-link-2857471273/000007.o /tmp/go-link-2857471273/000008.o /tmp/go-link-2857471273/000009.o /tmp/go-link-2857471273/000010.o /tmp/go-link-2857471273/000011.o /tmp/go-link-2857471273/000012.o /tmp/go-link-2857471273/000013.o /tmp/go-link-2857471273/000014.o /tmp/go-link-2857471273/000015.o /tmp/go-link-2857471273/000016.o /tmp/go-link-2857471273/000017.o /tmp/go-link-2857471273/000018.o /tmp/go-link-2857471273/000019.o /tmp/go-link-2857471273/000020.o /tmp/go-link-2857471273/000021.o /tmp/go-link-2857471273/000022.o -O2 -g -L/usr/local/lib -ltag -lz -ltag_c -ltag -lz -ltag_c -O2 -g -lpthread -O2 -g -lresolv
ld.lld: error: undefined symbol: operator new(unsigned long)
>>> referenced by tag_c.cpp
>>> tag_c.cpp.o:(TagLib::List<char*>::detach() (.part.0)) in archive /usr/local/lib/libtag_c.a