plebhash / cgminer-sv2

ASIC/FPGA miner in c for bitcoin (SV2 patch)
https://kano.is/
Other
1 stars 0 forks source link

remove `-Wno-format-security` flag workaround #2

Open plebhash opened 5 months ago

plebhash commented 5 months ago

These were the original build instructions when I forked the repo:

$ ./autogen.sh
$ CFLAGS="-O2 -Wall -march=native -fcommon" ./configure  <options>
$ make

I was getting the following compilation error:

api.c: In function ‘message’:
api.c:1509:49: error: format not a string literal and no format arguments [-Werror=format-security]
 1509 |                                                 );
      |  

As a workaround, I modified the build instructions to add the -Wno-format-security flag to the configure command via https://github.com/plebhash/cgminer-sv2/commit/8e9d0ba38c390230a010af50cdec469a2e16cd0d

I'm not sure about the security implications of this, and therefore a more sustainable solution should be researched for the long term.