Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workaround for GCC 10 #121

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

zeroheure
Copy link

@zeroheure zeroheure commented Jun 19, 2021

GCC 10 default to -fno-common which force use of extern with global variable.
This revert the flag. See https://gcc.gnu.org/gcc-10/porting_to.html

Fix #119

GCC 10 default to -fno-common which force use of extern with global variable. 
This disable the option. See https://gcc.gnu.org/gcc-10/porting_to.html
Makefile Outdated Show resolved Hide resolved
Co-authored-by: Ivan Kuchin <[email protected]>
@gdarko
Copy link

gdarko commented Apr 26, 2022

As of April 2022 this is a problem on Ubuntu 22.04

cc -std=c99 -Wall -O3 -I/opt/mozjpeg/include -o jpeg-recompress jpeg-recompress.c src/util.o src/edit.o src/smallfry.o src/iqa/build/release/libiqa.a /opt/mozjpeg/lib64/libjpeg.a -lm
/usr/bin/ld: src/util.o:(.bss+0x8): multiple definition of `VERSION'; /tmp/cc3e1HIE.o:(.bss+0x28): first defined here
/usr/bin/ld: src/util.o:(.bss+0x0): multiple definition of `progname'; /tmp/cc3e1HIE.o:(.bss+0x20): first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:42: jpeg-recompress] Error 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update to GCC 10 changes
3 participants