[packages] cups: update to v1.3.10
[openwrt/svn-archive/archive.git] / net / cups / patches / 160-stack-protector.patch
1 --- a/configure
2 +++ b/configure
3 @@ -10146,59 +10146,6 @@ if test -n "$GCC"; then
4 OPTIM="-fPIC $OPTIM"
5 fi
6
7 - # The -fstack-protector option is available with some versions of
8 - # GCC and adds "stack canaries" which detect when the return address
9 - # has been overwritten, preventing many types of exploit attacks.
10 - { echo "$as_me:$LINENO: checking if GCC supports -fstack-protector" >&5
11 -echo $ECHO_N "checking if GCC supports -fstack-protector... $ECHO_C" >&6; }
12 - OLDCFLAGS="$CFLAGS"
13 - CFLAGS="$CFLAGS -fstack-protector"
14 - cat >conftest.$ac_ext <<_ACEOF
15 -/* confdefs.h. */
16 -_ACEOF
17 -cat confdefs.h >>conftest.$ac_ext
18 -cat >>conftest.$ac_ext <<_ACEOF
19 -/* end confdefs.h. */
20 -
21 -int
22 -main ()
23 -{
24 -
25 - ;
26 - return 0;
27 -}
28 -_ACEOF
29 -rm -f conftest.$ac_objext
30 -if { (ac_try="$ac_compile"
31 -case "(($ac_try" in
32 - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33 - *) ac_try_echo=$ac_try;;
34 -esac
35 -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
36 - (eval "$ac_compile") 2>conftest.er1
37 - ac_status=$?
38 - grep -v '^ *+' conftest.er1 >conftest.err
39 - rm -f conftest.er1
40 - cat conftest.err >&5
41 - echo "$as_me:$LINENO: \$? = $ac_status" >&5
42 - (exit $ac_status); } && {
43 - test -z "$ac_c_werror_flag" ||
44 - test ! -s conftest.err
45 - } && test -s conftest.$ac_objext; then
46 - OPTIM="$OPTIM -fstack-protector"
47 - { echo "$as_me:$LINENO: result: yes" >&5
48 -echo "${ECHO_T}yes" >&6; }
49 -else
50 - echo "$as_me: failed program was:" >&5
51 -sed 's/^/| /' conftest.$ac_ext >&5
52 -
53 - { echo "$as_me:$LINENO: result: no" >&5
54 -echo "${ECHO_T}no" >&6; }
55 -fi
56 -
57 -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
58 - CFLAGS="$OLDCFLAGS"
59 -
60 # The -pie option is available with some versions of GCC and adds
61 # randomization of addresses, which avoids another class of exploits
62 # that depend on a fixed address for common functions.