build fails on inline function. Relevant output when using ccache: ccache cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../.. -I../../../include -I../../../include -I../../../src -I../../../src/xine-engine -I../../../src/xine-engine -I../../../src/xine-utils -I../../../src/input -I../../../src/input -I../../../lib -I../../../lib -DSIMPLE_IDCT -DHAVE_AV_CONFIG_H -DRUNTIME_CPUDETECT -DUSE_FASTMEMCPY -DCONFIG_RISKY -DCONFIG_DECODERS -DXINE_MPEG_ENCODER -DCONFIG_ZLIB -DCONFIG_GPL -I../../../src/libffmpeg/libavutil -I/usr/local/include -I/usr/X11R6/include -I/usr/local/include -D_THREAD_SAFE -fno-strict-aliasing -mtune=i386 -O3 -pipe -fomit-frame-pointer -falign-functions=4 -falign-loops=4 -falign-jumps=4 -mpreferred-stack-boundary=2 -fexpensive-optimizations -fschedule-insns2 -ffast-math -fno-inline-functions -Wall -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -DNDEBUG -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE -DENABLE_IPV6 -O -pipe -fno-force-addr -I/usr/local/include -I/usr/local/include/dvd read -I/usr/X11R6/include -Wformat=2 -Wno-format-zero-length -Wmissing-format-attribute -Wstrict-aliasing=2 -MT h263.lo -MD -MP -MF .deps/h263.Tpo -c h263.c -fPIC -DPIC -o .libs/h263.o h263.c: In function `mpeg4_decode_partition_a': h263.c:69: sorry, unimplemented: inlining failed in call to 'mpeg4_decode_dc': function body not available h263.c:3447: sorry, unimplemented: called from here h263.c: At top level: h263.c:73: warning: 'mpeg4_get_block_length' declared `static' but never defined gmake[5]: *** [h263.lo] Error 1 gmake[5]: Leaving directory `/usr/ports/multimedia/libxine/work/xine-lib-1.1.2/src/libffmpeg/libavcodec' gmake[4]: *** [all-recursive] Error 1 and cat config.log | grep inline .. | #define inline inline __attribute__ ((__always_inline__)) configure:51927: checking if ccache cc supports "-fno-inline-functions" flags configure:51952: ccache cc -c -fno-inline-functions -I/usr/local/include -I/usr/X11R6/include -I/usr/local/include -D_THREAD_SAFE conftest.c >&5 | #define inline inline __attribute__ ((__always_inline__)) configure:52284: result: no - assuming bugginess in -finline-functions However, when not using ccache, after make clean && make: cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../.. -I../../../include -I../../../include -I../../../src -I../../../src/xine-engine -I../../../src/xine-engine -I../../../src/xine-utils -I../../../src/input -I../../../src/input -I../../../lib -I../../../lib -DSIMPLE_IDCT -DHAVE_AV_CONFIG_H -DRUNTIME_CPUDETECT -DUSE_FASTMEMCPY -DCONFIG_RISKY -DCONFIG_DECODERS -DXINE_MPEG_ENCODER -DCONFIG_ZLIB -DCONFIG_GPL -I../../../src/libffmpeg/libavutil -I/usr/local/include -I/usr/X11R6/include -I/usr/local/include -D_THREAD_SAFE -fno-strict-aliasing -mtune=i386 -O3 -pipe -fomit-frame-pointer -falign-functions=4 -falign-loops=4 -falign-jumps=4 -mpreferred-stack-boundary=2 -fexpensive-optimizations -fschedule-insns2 -ffast-math -finline-functions -Wall -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -DNDEBUG -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE -DENABLE_IPV6 -O -pipe -fno-force-addr -I/usr/local/include -I/usr/local/include/dvdread -I/us r/X11R6/include -Wformat=2 -Wno-format-zero-length -Wmissing-format-attribute -Wstrict-aliasing=2 -MT h263.lo -MD -MP -MF .deps/h263.Tpo -c h263.c -fPIC -DPIC -o .libs/h263.o h263.c: In function `mpeg4_decode_partition_a': h263.c:69: sorry, unimplemented: inlining failed in call to 'mpeg4_decode_dc': function body not available h263.c:3447: sorry, unimplemented: called from here h263.c: At top level: h263.c:73: warning: 'mpeg4_get_block_length' declared `static' but never defined gmake[5]: *** [h263.lo] Error 1 gmake[5]: Leaving directory `/usr/ports/multimedia/libxine/work/xine-lib-1.1.2/src/libffmpeg/libavcodec' and different output in config.log: | #define inline inline __attribute__ ((__always_inline__)) configure:51927: checking if cc supports "-fno-inline-functions" flags configure:51952: cc -c -fno-inline-functions -I/usr/local/include -I/usr/X11R6/include -I/usr/local/include -D_THREAD_SAFE conftest.c >&5 | #define inline inline __attribute__ ((__always_inline__)) ac_cv_always_inline=yes ac_cv_c___inline__='' ac_cv_c_inline=inline CFLAGS='-mtune=i386 -O3 -pipe -fomit-frame-pointer -falign-functions=4 -falign-loops=4 -falign-jumps=4 -mpreferred-stack-boundary=2 -fexpensive-optimizations -fschedule-insns2 -ffast-math -finline-functions -Wall -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -DNDEBUG -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE $(MULTIPASS_CFLAGS) -DENABLE_IPV6 -O -pipe -fno-force-addr -I/usr/local/include -I/usr/local/include/dvdread -I/usr/X11R6/include -Wformat=2 -Wno-format-zero-length -Wmissing-format-attribute -Wstrict-aliasing=2' Note -finline-functions in the second build and -fno-inline-functions in the first build. However the compile fails either way with the same error message. How-To-Repeat: make clean && make
After some experimentation, I removed CFLAGS = -O -pipe from /etc/make.conf Notice in the original PR that these flags are added after -finline-functions and therefore must override it. Is there any way to make the build ignore CFLAGS in make.conf?
Responsible Changed From-To: freebsd-ports-bugs->nobutaka Over to maintainer
State Changed From-To: open->closed Fixed, thanks!