close
The Wayback Machine - https://web.archive.org/web/20260418193256/https://github.com/Exiv2/exiv2/pull/1756
Skip to content

add BUILD_WITH_STACK_PROTECTOR option#1756

Merged
kevinbackhouse merged 1 commit intoExiv2:mainfrom
ffontaine:main
Jul 8, 2021
Merged

add BUILD_WITH_STACK_PROTECTOR option#1756
kevinbackhouse merged 1 commit intoExiv2:mainfrom
ffontaine:main

Conversation

@ffontaine
Copy link
Copy Markdown
Contributor

Add BUILD_WITH_STACK_PROTECTOR to avoid the following build failure with toolchains that don't support stack-protector:

/home/buildroot/autobuild/instance-3/output-1/host/opt/ext-toolchain/bin/../lib/gcc/mipsel-buildroot-linux-uclibc/9.3.0/../../../../mipsel-buildroot-linux-uclibc/bin/ld: utils.cpp:(.text._ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag[_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag]+0xd0): undefined reference to __stack_chk_fail'`

Indeed, support for -fstack-protector-strong can't be detected through check_cxx_compiler_flag as some toolchains need to link with -lssp to enable SSP support

Fixes:

Signed-off-by: Fabrice Fontaine [email protected]

Add BUILD_WITH_STACK_PROTECTOR to avoid the following build failure with
toolchains that don't support stack-protector:

/home/buildroot/autobuild/instance-3/output-1/host/opt/ext-toolchain/bin/../lib/gcc/mipsel-buildroot-linux-uclibc/9.3.0/../../../../mipsel-buildroot-linux-uclibc/bin/ld: utils.cpp:(.text._ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag[_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag]+0xd0): undefined reference to `__stack_chk_fail'

Indeed, support for -fstack-protector-strong can't be detected through
check_cxx_compiler_flag as some toolchains need to link with -lssp to
enable SSP support

Fixes:
 - http://autobuild.buildroot.org/results/ae4635899124c602c70d2b342a76f95c34aa4a3d

Signed-off-by: Fabrice Fontaine <[email protected]>
@codecov
Copy link
Copy Markdown

codecov bot commented Jul 5, 2021

Codecov Report

Merging #1756 (f31c0eb) into main (d30c95d) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1756   +/-   ##
=======================================
  Coverage   67.22%   67.22%           
=======================================
  Files         151      151           
  Lines       20787    20787           
=======================================
  Hits        13975    13975           
  Misses       6812     6812           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d30c95d...f31c0eb. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants