You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Building error]: /usr/bin/ld: CMakeFiles/zimg.dir/zaccess.c.o:(.bss+0x0): multiple definition of `settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here
#268
Open
gadefox opened this issue
Sep 14, 2021
· 4 comments
I'm trying to build the lib from the source (make in the root) and I'm getting the following error. Any idea??
/usr/bin/ld: CMakeFiles/zimg.dir/zaccess.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zaccess.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zcache.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zcache.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zdb.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zdb.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zhttpd.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zhttpd.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zimg.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zimg.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zlog.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zlog.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zlscale.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zlscale.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zscale.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zscale.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zspinlock.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zspinlock.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/zutil.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zutil.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/libevhtp/evthr.c.o:(.bss+0x0): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/libevhtp/evhtp.c.o:(.bss+0x0): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
/usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/multipart-parser-c/multipart_parser.c.o:(.bss+0x0): multiple definition of settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/multipart-parser-c/multipart_parser.c.o:(.bss+0xd80): multiple definition of thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here
The text was updated successfully, but these errors were encountered:
The default "-fcommon" flag changed to "-fno-common" in GCC 10.
This problem is fixed by adding -DCMAKE_C_FLAGS=-fcommon into Makefile when running cmake.
I'm trying to build the lib from the source (
make
in the root) and I'm getting the following error. Any idea??/usr/bin/ld: CMakeFiles/zimg.dir/zaccess.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zaccess.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zcache.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zcache.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zdb.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zdb.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zhttpd.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zhttpd.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zimg.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zimg.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zlog.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zlog.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zlscale.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zlscale.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zscale.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zscale.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zspinlock.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zspinlock.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/zutil.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/zutil.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/libevhtp/evthr.c.o:(.bss+0x0): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/libevhtp/evhtp.c.o:(.bss+0x0): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined here/usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/multipart-parser-c/multipart_parser.c.o:(.bss+0x0): multiple definition of
settings'; CMakeFiles/zimg.dir/main.c.o:(.bss+0x20): first defined here /usr/bin/ld: CMakeFiles/zimg.dir/home/fox/.build/zimg-3.1.0/deps/multipart-parser-c/multipart_parser.c.o:(.bss+0xd80): multiple definition of
thread_key'; CMakeFiles/zimg.dir/main.c.o:(.bss+0xda0): first defined hereThe text was updated successfully, but these errors were encountered: