Opened 8 months ago

Last modified 8 months ago

#10931 new defect

duplicate symbol with static builds

Reported by: luckysk Owned by:
Priority: normal Component: avformat
Version: git-master Keywords: ffjni duplicate symbol file
Cc: luckysk Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

ld: error: duplicate symbol: ff_jni_get_env

defined at ffjni.c:54 (src/libavcodec/ffjni.c:54)

ffjni.o:(ff_jni_get_env) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:54 (src/libavcodec/ffjni.c:54)

file.o:(.text+0xEB4) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_jstring_to_utf_chars

defined at ffjni.c:100 (src/libavcodec/ffjni.c:100)

ffjni.o:(ff_jni_jstring_to_utf_chars) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:100 (src/libavcodec/ffjni.c:100)

file.o:(.text+0x10EC) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_utf_chars_to_jstring

defined at ffjni.c:130 (src/libavcodec/ffjni.c:130)

ffjni.o:(ff_jni_utf_chars_to_jstring) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:130 (src/libavcodec/ffjni.c:130)

file.o:(.text+0x1244) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_exception_get_summary

defined at ffjni.c:144 (src/libavcodec/ffjni.c:144)

ffjni.o:(ff_jni_exception_get_summary) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:144 (src/libavcodec/ffjni.c:144)

file.o:(.text+0x12E4) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_exception_check

defined at ffjni.c:247 (src/libavcodec/ffjni.c:247)

ffjni.o:(ff_jni_exception_check) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:247 (src/libavcodec/ffjni.c:247)

file.o:(.text+0x182C) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_init_jfields

defined at ffjni.c:280 (src/libavcodec/ffjni.c:280)

ffjni.o:(ff_jni_init_jfields) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:280 (src/libavcodec/ffjni.c:280)

file.o:(.text+0x1964) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

ld: error: duplicate symbol: ff_jni_reset_jfields

defined at ffjni.c:369 (src/libavcodec/ffjni.c:369)

ffjni.o:(ff_jni_reset_jfields) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavcodec.a

defined at ffjni.c:369 (src/libavcodec/ffjni.c:369)

file.o:(.text+0x1E4C) in archive /media/rland/skt7_373/work/src/mpv-android/buildscripts/prefix/armv7l/usr/local/lib/libavformat.a

clang-14: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.

Change History (3)

comment:1 by luckysk, 8 months ago

Component: undeterminedavformat
Keywords: ffjni duplicate symbol file added
Version: unspecifiedgit-master

comment:2 by luckysk, 8 months ago

It seems to be related to the code recently added for the content protocol (lavf/file.c).

https://patchwork.ffmpeg.org/project/ffmpeg/patch/20240324051741.79725-1-leo.izen@gmail.com/

comment:3 by luckysk, 8 months ago

Verified, patch fixed my issue.

Note: See TracTickets for help on using tickets.