I am trying to compile some C++ code to be used with gprof, and have tried using the -pg flag, but am getting errors regarding multiple definitions for each of my functions. My command is basically g++ -o -pg my_exec my_code.cp -mylib.
Any idea what I'm doing wrong?