The gsl_rng.h file is in the directory E:\SoftwareDev\mingw-w64-x86_64-gsl-2.6-1-any.pkg\mingw64\include\gsl.
I tried various combinations of project settings and global compiler settings, to no avail.
In the log, we can see that the -I directives are present in the g++ lines but missing in the gcc lines.
Seems g++ and gcc are picking up the parameters from different places, and the project settings are only impacting the g++ settings.
(Hope I have posted the log correctly this time. A little new to this forum.)
g++.exe -Wall -fexceptions -g -std=gnu++17 -IE:\SoftwareDev\mingw-w64-x86_64-gsl-2.6-1-any.pkg\mingw64\include\gsl -IE:\SoftwareDev\mingw-w64-x86_64-gsl-2.6-1-any.pkg\mingw64\include\gsl[/color] -IE:\SoftwareDev\mingw-w64-x86_64-gsl-2.6-1-any.pkg\mingw64\include\gsl -c E:\SoftwareDev\dealer\fnscpp.cpp -o obj\Debug\fnscpp.o
gcc -Wall -fexceptions -g -c E:\SoftwareDev\dealer\random.c -o obj\Debug\random.o
...
E:\SoftwareDev\dealer\random.c:6:10: fatal error: gsl_rng.h: No such file or directory
#include "gsl_rng.h"