re-enable -D_FORTIFY_SOURCE=2 for all platforms #2376

pull Diapolo wants to merge 1 commits into bitcoin:master from Diapolo:pro-file changing 1 files +3 −3
  1. Diapolo commented at 5:57 PM on March 17, 2013: none

    IMHO, this is no Linux specific switch.

  2. BitcoinPullTester commented at 6:56 PM on March 17, 2013: none

    Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/774ce679856378ae2bf83a2ba71e26a889c0640a for binaries and test log.

  3. laanwj commented at 6:01 AM on March 18, 2013: member

    That link says that _FORTIFY_SOURCE is a glibc feature; and glibc library is only used on Linux.

    So this is pretty much a no-op.

  4. Diapolo commented at 6:41 AM on March 18, 2013: none

    Really? I tried to websearch it and found it in quite a few obviously Windows based open-source programs.

  5. Diapolo commented at 11:14 PM on March 18, 2013: none

    http://man7.org/linux/man-pages/man7/feature_test_macros.7.html

    Use of this macro requires compiler support, available with gcc(1) since version 4.0. Hmm...

  6. gavinandresen commented at 11:35 PM on March 18, 2013: contributor

    gcc header files on my mac do have #if _FORTIFY_SOURCE .... so it is gcc, I think, not just gcc on Linux.

    So ACK from me on pullling this; an extra #define won't hurt if you're compiling with something other than gcc. Would be nice to add a comment explaining that _FORTIFY_SOURCE is a gcc-compiler-specific thing so we don't have this discussion again.

  7. re-enable -D_FORTIFY_SOURCE=2 for all platforms 86b9c4aa67
  8. Diapolo commented at 6:36 AM on March 19, 2013: none

    I updated the comment to reflect it's GCC compiler-specific.

  9. laanwj referenced this in commit db725e64b2 on Mar 19, 2013
  10. laanwj merged this on Mar 19, 2013
  11. laanwj closed this on Mar 19, 2013

  12. laudney referenced this in commit 597825fb5c on Mar 19, 2014
  13. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:16 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me