I have succeeded to compile and avoid these errors by compiling libdha vidix and vidix/driver without the -fprofile-generate and -fprofile-use options, by replacing the OPTFLAGS sections of these files with the actual flags that do not contain the profile options.