GCC error: unrecognized command line option ‘-no-pie’

Input the command GCC - M32 - no-pie - O linkbox main. O Phase1. O to connect the two relocatable nodes. An error is reported: GCC: error: unrecognized command line option '- no-pie'

Reason: CentOS’s default compiled version of GCC is 4:00, so you need to upgrade GCC. Here you use Yum install to install. Enter the following command in turn
sudo Yum install CentOS release SCL RH
sudo Yum install devtoolset-8-build
sudo Yum install devtoolset-8-gdb
source/opt/Rh/devtoolset-8/enable , set the boot to use GCC – V to view the version, and upgrade to version 8.3.1

Read More: