ffmpeg library linking errors while compiling in Linux.

Hi I am Rupesh from India and I have pc with i3 10th gen processor and asus prime h510 motherboard and I have installed open suse tumbleweed. I have tried to compile source code of ffmpeg but failed to do so.

First I have cloned ffmpeg from git and after that I have ran ./configure with options like --enable-opencl --enable-libva --enable-libmfx etc. After that I have ran the command “make -j7” and everything worked fine and at last I think that linking or loading failed.

I am providing the output of last few lines of the make command below


LD	ffmpeg_g
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libfreetype.so when searching for -lfreetype
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libfreetype.so when searching for -lfreetype
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libz.so when searching for -lz
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libz.so when searching for -lz
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libgcc_s.so.1 when searching for libgcc_s.so.1
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libc.so when searching for -lc
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libgcc_s.so.1 when searching for libgcc_s.so.1
LD	ffprobe_g
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libfreetype.so when searching for -lfreetype
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libfreetype.so when searching for -lfreetype
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libz.so when searching for -lz
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libz.so when searching for -lz
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libgcc_s.so.1 when searching for libgcc_s.so.1
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libc.so when searching for -lc
/usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libgcc_s.so.1 when searching for libgcc_s.so.1
STRIP	ffmpeg
STRIP	ffprobe

Try to suggest what is the meaning of the above errors and also how to compile source code of ffmpeg successfully.

Is there any need to reinstall gnu toolchain like gcc, g++, libstd, make, cmake, autoconf, automake etc.,. I think that main problem is linker or loader is not working properly.

I last question which is not related to current thread ie., “May I know where is the configuration files for gcc, make, auto conf”. mostly configuration files are found in /etc but I can’t find any files for gcc, make in /etc.

Output from env command is


localhost:~ # env
SHELL=/bin/bash
SESSION_MANAGER=local/localhost.localdomain:@/tmp/.ICE-unix/1721,unix/localhost.localdomain:/tmp/.ICE-unix/1721
WINDOWID=1
COLORTERM=truecolor
SDK_HOME=/usr/lib64/jvm/java
XDG_CONFIG_DIRS=/root/.config/kdedefaults:/etc/xdg:/usr/etc/xdg
GDK_DPI_SCALE=1
LESS=-M -I -R
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session1
JDK_HOME=/usr/lib64/jvm/java
MACHTYPE=x86_64-suse-linux
GTK2_MODULES=unity-gtk-module
G_BROKEN_FILENAMES=1
HOSTNAME=localhost.localdomain
HISTSIZE=1000
LANGUAGE=
FROM_HEADER=
MINICOM=-c on
JAVA_ROOT=/usr/lib64/jvm/java
JAVA_HOME=/usr/lib64/jvm/java
AUDIODRIVER=pulseaudio
JRE_HOME=/usr/lib64/jvm/java/jre
XDG_DATA_HOME=/root/.local/share
CPU=x86_64
SHELL_SESSION_ID=a98a383be9d64ea6872d1d2924342432
XDG_CONFIG_HOME=/root/.config
JAVA_BINDIR=/usr/lib64/jvm/java/bin
LIBVA_DRIVER_NAME=iHD
DESKTOP_SESSION=/usr/share/wayland-sessions/plasmawayland
GTK_RC_FILES=/etc/gtk/gtkrc:/root/.gtkrc:/root/.config/gtkrc
XCURSOR_SIZE=24
GPG_TTY=/dev/pts/1
XDG_SEAT=seat0
PWD=/root
QEMU_AUDIO_DRV=pa
XDG_SESSION_DESKTOP=KDE
LOGNAME=root
XDG_SESSION_TYPE=wayland
MANPATH=/usr/share/man:/usr/local/man:/usr/local/share/man
SYSTEMD_EXEC_PID=1601
XAUTHORITY=/run/user/0/xauth_vfyldC
LS_OPTIONS=-A -N --color=tty -T 0
XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
GTK2_RC_FILES=/etc/gtk-2.0/gtkrc:/root/.gtkrc-2.0:/root/.config/gtkrc-2.0
XNLSPATH=/usr/share/X11/nls
HOME=/root
LANG=POSIX
LS_COLORS=no=00:fi=00:di=01;34:ln=00;36:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=41;33;01:ex=00;32:*.cmd=00;32:*.exe=01;32:*.com=01;32:*.bat=01;32:*.btm=01;32:*.dll=01;32:*.tar=00;31:*.tbz=00;31:*.tgz=00;31:*.rpm=00;31:*.deb=00;31:*.arj=00;31:*.taz=00;31:*.lzh=00;31:*.lzma=00;31:*.zip=00;31:*.zoo=00;31:*.z=00;31:*.Z=00;31:*.gz=00;31:*.bz2=00;31:*.tb2=00;31:*.tz2=00;31:*.tbz2=00;31:*.xz=00;31:*.avi=01;35:*.bmp=01;35:*.dl=01;35:*.fli=01;35:*.gif=01;35:*.gl=01;35:*.jpg=01;35:*.jpeg=01;35:*.mkv=01;35:*.mng=01;35:*.mov=01;35:*.mp4=01;35:*.mpg=01;35:*.pcx=01;35:*.pbm=01;35:*.pgm=01;35:*.png=01;35:*.ppm=01;35:*.svg=01;35:*.tga=01;35:*.tif=01;35:*.webm=01;35:*.webp=01;35:*.wmv=01;35:*.xbm=01;35:*.xcf=01;35:*.xpm=01;35:*.aiff=00;32:*.ape=00;32:*.au=00;32:*.flac=00;32:*.m4a=00;32:*.mid=00;32:*.mp3=00;32:*.mpc=00;32:*.ogg=00;32:*.voc=00;32:*.wav=00;32:*.wma=00;32:*.wv=00;32:
XDG_CURRENT_DESKTOP=KDE
KONSOLE_DBUS_SERVICE=:1.92
PYTHONSTARTUP=/etc/pythonstart
WAYLAND_DISPLAY=wayland-0
KONSOLE_DBUS_SESSION=/Sessions/1
PROFILEHOME=
OSTYPE=linux
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
LESS_ADVANCED_PREPROCESSOR=no
KONSOLE_VERSION=211203
KDE_SESSION_UID=0
XDG_CACHE_HOME=/root/.cache
XKB_DEFAULT_LAYOUT=us
XDG_ACTIVATION_TOKEN=localhost.localdomain;1647251025;868404;1730_TIME0
LESSCLOSE=lessclose.sh %s %s
XDG_SESSION_CLASS=user
TERM=xterm-256color
HOST=localhost.localdomain
XAUTHLOCALHOSTNAME=localhost.localdomain
LESSOPEN=lessopen.sh %s
USER=root
COLORFGBG=15;0
PLASMA_USE_QT_SCALING=1
KDE_SESSION_VERSION=5
MORE=-sl
QT_WAYLAND_FORCE_DPI=96
CSHEDIT=emacs
DISPLAY=:1
SHLVL=1
WINDOWMANAGER=/usr/bin/startplasma-x11
PAGER=less
CVS_RSH=ssh
XDG_VTNR=2
UBUNTU_MENUPROXY=1
XDG_SESSION_ID=2
LC_CTYPE=en_US.UTF-8
XDG_RUNTIME_DIR=/run/user/0
DEBUGINFOD_URLS=https://debuginfod.opensuse.org/ 
QT_AUTO_SCREEN_SCALE_FACTOR=0
MANPATHISSET=yes
XCURSOR_THEME=breeze_cursors
GTK3_MODULES=unity-gtk-module
XDG_DATA_DIRS=/root/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/share:/var/lib/snapd/desktop
KDE_FULL_SESSION=true
CONFIG_SITE=/usr/share/site/x86_64-unknown-linux-gnu
PATH=/sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin:/snap/bin
GDK_SCALE=1
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/0/bus
PROFILEREAD=true
KDE_APPLICATIONS_AS_SCOPE=1
MAIL=/var/spool/mail/root
HOSTTYPE=x86_64
LESSKEY=/usr/etc/lesskey.bin
KONSOLE_DBUS_WINDOW=/Windows/1
BASH_FUNC_mc%%=() {  . /usr/share/mc/mc-wrapper.sh
}
OLDPWD=/root/soft/temp/ffmpeg
_=/usr/bin/env

Unusual thing is I can’t find entries for compiler_path, library_path etc.,.

Try to suggest how to set environment variables for gcc which is specific to my x86_64 pc and compile ffmpeg normally.