ffmpeg/libavutil
Andreas Rheinhardt bd50e715a9 avutil/common: Move everything inside inclusion guards
libavutil/common.h is a public header that provides generic math
functions whereas libavutil/intmath.h is a private header that contains
plattform-specific optimized versions of said math functions. common.h
includes intmath.h (when building the FFmpeg libraries) so that the
optimized versions are used for them.

This interdependency sometimes causes trouble: intmath.h once contained
an inlined ff_sqrt function that relied upon av_log2_16bit. In case there
was no optimized logarithm available on this plattform, intmath.h needed
to include common.h to get the generic implementation and this has been
done after the optimized versions (if any) have been provided so that
common.h used the optimized versions; it also needed to be done before
ff_sqrt. Yet when intmath.h was included from common.h and if an ordinary
inclusion guard was used by common.h, the #include "common.h" in intmath.h
was a no-op and therefore av_log2_16bit was still unknown at the end of
intmath.h (and also in ff_sqrt) if no optimized version was available.

Before a955b59658 this was solved by
duplicating the #ifndef av_log2_16bit check after the inclusion of
common.h in intmath.h; said commit instead moved these checks to the
end of common.h, outside the inclusion guards and made common.h include
itself to get these unguarded defines. This is still the current
state of affairs.

Yet this is unnecessary since 9734b8ba56
as said commit removed ff_sqrt as well as the #include "common.h" from
intmath.h. Therefore this commit moves everything inside the inclusion
guards and makes common.h not include itself.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
2021-02-11 09:07:10 +01:00
..
aarch64
arm
avr32
bfin
mips
ppc
sh4
tests
tomi
x86
.gitignore
Makefile
adler32.c
adler32.h
aes.c
aes.h
aes_ctr.c
aes_ctr.h
aes_internal.h
attributes.h
audio_fifo.c
audio_fifo.h
avassert.h
avsscanf.c
avstring.c
avstring.h
avutil.h
avutilres.rc
base64.c
base64.h
blowfish.c
blowfish.h
bprint.c
bprint.h
bswap.h
buffer.c
buffer.h
buffer_internal.h
camellia.c
camellia.h
cast5.c
cast5.h
channel_layout.c
channel_layout.h
color_utils.c
color_utils.h
colorspace.h
common.h
cpu.c
cpu.h
cpu_internal.h
crc.c
crc.h
cuda_check.h
des.c
des.h
dict.c
dict.h
display.c
display.h
dovi_meta.c
dovi_meta.h
downmix_info.c
downmix_info.h
dynarray.h
encryption_info.c
encryption_info.h
error.c
error.h
eval.c
eval.h
ffmath.h
fifo.c
fifo.h
file.c
file.h
file_open.c
film_grain_params.c
film_grain_params.h
fixed_dsp.c
fixed_dsp.h
float_dsp.c
float_dsp.h
frame.c
frame.h
hash.c
hash.h
hdr_dynamic_metadata.c
hdr_dynamic_metadata.h
hmac.c
hmac.h
hwcontext.c
hwcontext.h
hwcontext_cuda.c
hwcontext_cuda.h
hwcontext_cuda_internal.h
hwcontext_d3d11va.c
hwcontext_d3d11va.h
hwcontext_drm.c
hwcontext_drm.h
hwcontext_dxva2.c
hwcontext_dxva2.h
hwcontext_internal.h
hwcontext_mediacodec.c
hwcontext_mediacodec.h
hwcontext_opencl.c
hwcontext_opencl.h
hwcontext_qsv.c
hwcontext_qsv.h
hwcontext_vaapi.c
hwcontext_vaapi.h
hwcontext_vdpau.c
hwcontext_vdpau.h
hwcontext_videotoolbox.c
hwcontext_videotoolbox.h
hwcontext_vulkan.c
hwcontext_vulkan.h
imgutils.c
imgutils.h
imgutils_internal.h
integer.c
integer.h
internal.h
intfloat.h
intmath.c
intmath.h
intreadwrite.h
lfg.c
lfg.h
libavutil.v
libm.h
lls.c
lls.h
log.c
log.h
log2_tab.c
lzo.c
lzo.h
macros.h
mastering_display_metadata.c
mastering_display_metadata.h
mathematics.c
mathematics.h
md5.c
md5.h
mem.c
mem.h
mem_internal.h
motion_vector.h
murmur3.c
murmur3.h
opt.c
opt.h
parseutils.c
parseutils.h
pca.c
pca.h
pixdesc.c
pixdesc.h
pixelutils.c
pixelutils.h
pixfmt.h
qsort.h
random_seed.c
random_seed.h
rational.c
rational.h
rc4.c
rc4.h
replaygain.h
reverse.c
reverse.h
ripemd.c
ripemd.h
samplefmt.c
samplefmt.h
sha.c
sha.h
sha512.c
sha512.h
slicethread.c
slicethread.h
softfloat.h
softfloat_ieee754.h
softfloat_tables.h
spherical.c
spherical.h
stereo3d.c
stereo3d.h
tablegen.h
tea.c
tea.h
thread.h
threadmessage.c
threadmessage.h
time.c
time.h
time_internal.h
timecode.c
timecode.h
timer.h
timestamp.h
tree.c
tree.h
twofish.c
twofish.h
tx.c
tx.h
tx_double.c
tx_float.c
tx_int32.c
tx_priv.h
tx_template.c
utils.c
version.h
video_enc_params.c
video_enc_params.h
wchar_filename.h
xga_font_data.c
xga_font_data.h
xtea.c
xtea.h