Fail to build torchvision from source on linux

NAME=“CentOS Linux”
VERSION=“7 (Core)”
CUDA=11.4
cuDNN=8.4.1
cmake=3.23.4
g++=9.3.0
torch=1.14.0a0+git4dc5798

Command I used is:
python setup.py install

``
/bin/ld: /usr/local/contrib/lib/libswscale.a(scale.o): relocation R_X86_64_32 against `.rodata’ can not be used when making a shared object; recompile with -fPIC

/bin/ld: /usr/local/contrib/lib/libswscale.a(yuv2rgb.o): relocation R_X86_64_32S against symbol `ff_dither8’ can not be used when making a shared object; recompile with -fPIC

/bin/ld: /usr/local/contrib/lib/libswscale.a(gamma.o): relocation R_X86_64_32S against `.text’ can not be used when making a shared object; recompile with -fPIC

/bin/ld: /usr/local/contrib/lib/libswscale.a(hscale.o): relocation R_X86_64_32S against `.text’ can not be used when making a shared object; recompile with -fPIC

/bin/ld: final link failed: Nonrepresentable section on output
collect2: error: ld returned 1 exit status
error: command ‘/afs/usr0/home/GCC9/bin/g++’ failed with exit code 1
``

Is there anyone had this issue before?

Best
Max