Commit Graph

58 Commits

Author SHA1 Message Date
Alexander Kanavin 8c1c392ca3 dnf: move the entire dnf/rpm4 stack to Python 3
[YOCTO #11180]

(From OE-Core rev: bedcdc4cf921b70a8cfb16c6684668d0ac9e1942)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-28 08:43:13 +01:00
Alexander Kanavin da1d23a6d0 expect: resolve string formatting issues
[YOCTO #9542]

(From OE-Core rev: b5fd2874cfe199703e7a5d12fa708e12ff0a2ad1)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-24 23:43:32 +00:00
Jussi Kukkonen f8007417ea kexec-tools: Add patches to enable format-security
Also remove the override from security_flags.inc

(From OE-Core rev: 33d084a66a371fb10e26a0a23c639c69ddd3f1e5)

Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-17 16:53:04 +00:00
Jussi Kukkonen 6dcf5c6e6e cmake: Backport fix to enable -Wformat-security
Backport build fix that removes -Wformat-security for specific tests.
Enable "-Wformat-security" for cmake in security_flags.inc.

(From OE-Core rev: b00f9c77ebd211578ba133c28abcbc5752305e25)

Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-17 16:53:04 +00:00
Alexander Kanavin 3dadb9722e security_flags.inc: update to reflect smart->dnf transition
(From OE-Core rev: 0f3c57e9aca490c0f8d94117c915c075fd112b65)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-14 14:42:18 +00:00
Alexander Kanavin 5765e1981d security_flags.inc: Update for new python modules
(From OE-Core rev: 544d96d37e32a0e08af4d91da48c9f9ef296a515)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-11 16:09:14 +00:00
Robert Yang 4533abfb07 security_flags.inc: let gettext be secure
It has been fixed.

[YOCTO #9544]

(From OE-Core rev: ab711c978ba612a5a636155d703f45365604222c)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-23 12:49:51 -08:00
Ross Burton 00dd77d449 security_flags: disable -pie for gpgme
Otherwise this fails to build the libraries:

relocation R_X86_64_PC32 against undefined hidden symbol `__init_array_start'
can not be used when making a shared object

(From OE-Core rev: 632eee4fbd4627482aae752eb41104b3a848fd58)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-15 20:06:42 -08:00
Chen Qi f5bbeae789 security_flags: enable string formatting check for console tools
As we've fixed the string formatting issue in console-tools, we don't
need to override SECURITY_STRINGFORMAT for console-tools any more.

[YOCTO #9540]

(From OE-Core rev: 3883332f84d9da0792c2c7337e842da34ea1b06c)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-15 20:06:42 -08:00
Khem Raj 33bed1e253 security_flags: Diable PIE for mesa-gl
This creeped in along with rest of the changes in
c999b3d88dfcffbe0fb66406fb0bff1fb66f34bc
even after it was reported a build failure in mesa-gl
This is also showing up on arm architecture now

| /usr/src/debug/glibc/2.24-r0/git/csu/elf-init.c:87: undefined reference to `__init_array_end'
| /usr/src/debug/glibc/2.24-r0/git/csu/elf-init.c:87: undefined reference to `__init_array_start'
| /a/builder/mnt/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/6.2.0/ld: .libs/mesa_dri_drivers.so: hidden symbol `__init_array_end' isn't defined

(From OE-Core rev: 9211fb2a6d6c2d72ec7c2664737aee3a6b6149cf)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-07 16:43:58 +01:00
Alexander Kanavin 94317f52ce source-highlight: add a recipe
gtk-doc relies on this to highlight source code snippets

(From OE-Core rev: 380f449bc1881a6e8592463c7eeda3655efb97ea)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-09-09 12:12:22 +01:00
Alexander Kanavin 310d860262 security_flags.inc: enable PIE for a few recipes
They used to fail with PIE enabled, but no longer do.

(From OE-Core rev: c999b3d88dfcffbe0fb66406fb0bff1fb66f34bc)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-17 10:35:38 +01:00
Robert Yang 91a6f3a375 slang: 2.2.4 -> 2.3.0
* Removed:
  change-char-type-to-signed-char-in-macros.patch
  sprintf-bug-concerning-8-bit-characters.patch
  They are already in the source.

* Updated:
  fix-check-pcre.patch
  fix-check-pcre.patch
  slang-fix-the-iconv-existence-checking.patch

* Use SECURITY_NO_PIE_CFLAGS for SECURITY_CFLAGS, it can't be built with
  "-pie -fpie":
  tmp/sysroots/qemux86-64/usr/lib64/../lib64/Scrt1.o: In function `_start':
  /usr/src/debug/glibc/2.24-r0/git/csu/../sysdeps/x86_64/start.S:104: undefined reference to `main'
  /tmp/ccMFTA8A.o: In function `smg_char_at':
  /usr/src/debug/slang/2.3.0-r0/slang-2.3.0/modules/slsmg-module.c:134: undefined reference to `SLsmg_char_at'
  /tmp/ccMFTA8A.o: In function `smg_resume_smg':

(From OE-Core rev: b2d6e069b9ecc5a13754393200a6fa48cdaaf4c6)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-07-26 08:56:26 +01:00
Alexander Kanavin ec96025bc3 security_flags.inc: add python3-pycairo and libnewt-python to no-pie exception list
(From OE-Core rev: 0bfbc3e901067b0fee09c55d203b850a258fbbe3)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-23 14:26:15 +01:00
Alexander Kanavin 0881208168 security_flags.inc: add SECURITY_NO_PIE_CFLAGS to libgcc and gcc-sanitizers
These recipes no longer seem to need full exclusion from security hardening.

The rest (glibc, gcc-runtime, valgrind, grub, grub-efi, uclibc) still do.

[YOCTO #9489]

(From OE-Core rev: b3d7aae42550fb92bcb82fdee7e518b04bdf49b4)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-23 14:26:15 +01:00
Alexander Kanavin a8cf2ce41a security_flags.inc: add an entry for python3-numpy
The entry is same as for python-numpy and prevents build failures
when extra security flags are in use (e.g. in poky-lsb).

(From OE-Core rev: 4a95989848df62b34e3115c7e81d4f005de74119)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-03 13:13:30 +01:00
Alexander Kanavin 68cea00205 python-imaging: remove unused recipe
(From OE-Core rev: b03ebfaee278eb98b4bd0e11a682ac0cda192086)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-03 13:13:27 +01:00
Edwin Plauchu 763a3d424b unzip: fix security issues
This patch avoids unzip fails to compile with compiler flags which elevate common string formatting issues into an error (-Wformat -Wformat-security -Werror=format-security).

[YOCTO #9551]

(From OE-Core rev: 2dd1c02fbc7492002df9030f50710e242369e8b2)

Signed-off-by: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-01 12:38:43 +01:00
Edwin Plauchu b00282fd20 makedevs: fix security issues
This avoids makedevs failure to compile with compiler flags
which elevate common string formatting issues into an error
(-Wformat -Wformat-security -Werror=format-security).

[YOCTO #9549]

(From OE-Core rev: f6b0dd13ac90bb431bb51e0cbf1681a4d9fbea14)

Signed-off-by: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:20 +01:00
Edwin Plauchu c676d5dd6f zip: fix security issues
This patch avoids zip recipe fails to compile with compiler
flags which elevate common string formatting issues into an
error (-Wformat -Wformat-security -Werror=format-security).

[YOCTO #9552]

(From OE-Core rev: f63a36360b7e138d2a63c84b5b1a8287ffe3d2ae)

Signed-off-by: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:20 +01:00
Edwin Plauchu 8ed25517a9 stat: fix security issues
This patch avoids stat fails to compile with compiler flags which
elevate common string formatting issues into an error (-Wformat
-Wformat-security -Werror=format-security).

[YOCTO #9550]

(From OE-Core rev: f03c1f41933e9997a01a8b1dcdf9fb18579de1d1)

Signed-off-by: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:20 +01:00
Aníbal Limón 45da72bb53 security_flags: Enable security flags on leafpad, ltp and libuser.
Now we have patches that solves the security formatting issues into
those packages.

(From OE-Core rev: 901cfa5a217f78464f8b81a990039fe60810650f)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-15 09:06:00 +01:00
Joshua Lock 30f9a5072d security_flags: turn potential string format security issues into an error
Add "-Wformat -Wformat-security -Werror=format-security" to the default
SECURITY_CFLAGS to catch potential security vulnerabilities due to the
misuse of various string formatting functions.

These flags are widely used in distributions such as Fedora and Ubuntu,
however we have 15 recipes in OE-Core which fail to build with these
flags included and thus the flags are removed for:
- busybox
- console-tools
- cmake
- expect
- gcc
- gettext
- kexec-tools
- leafpad
- libuser
- ltp
- makedevs
- oh-puzzles
- stat
- unzip
- zip

[YOCTO #9488]

(From OE-Core rev: f335f8e744fb312b3eb599c331d08a9a6e5a8ff8)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-06 10:31:12 +01:00
Mark Hatle 59a4d99c20 security_flags.inc: Special flags are needed for RPM
RPM interally has support to build and work with the stack protector.
This is disabled by default in the RPM package, and the proper settings
should be specified in the security_flags.  Using the default setting of
stack-protector-strong causes linking problems due to issues with libtool
selecting the wrong GCC objections to link against.

Falling back to the RPM values of stack-protector will permit linking to
work properly, and some level of protection.

(From OE-Core rev: 98b5f1ef188965f0116ebbe00be746dceb96936e)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-09 17:00:28 +00:00
Khem Raj aab39005b3 security_flags: Disable ssp when compiling uclibc
(From OE-Core rev: 208fbdbff17f19a23944a62f1b9ff380f1bc8ac8)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-22 20:42:48 +00:00
Khem Raj ef5b8b4656 security_flags: Add SECURITY_CFLAGS to TARGET_CC_ARCH for binutils
libtool decides to
filter out -fstack-protector-strong on its own and its documented here

https://www.gnu.org/software/libtool/manual/html_node/Stripped-link-flags.html

this causes linking errors when linking libbfd.so since objects (.o) are
compiled using -fstack-protector-strong so they are expecting to link
with libssp but the option goes missing in linker flags.

With this patch the security flags are hoisted upto CC itself and
libtool thankfully does not touch CC.

Adding to CC also means that we can now remove it from LDFLAGS since
when gcc driver is used to do linking then we have LD = CC and this
option makes to linker cmdline

Since CC is used without CFLAGS in configure tests, some tests fail
complaining that -Olevel is not used while using _FORTIFY_SOURCE
therefore added SELECTED_OPTIMIZATION to TARGET_CC_ARCH as well

(From OE-Core rev: 9349f28531619a4ff15c382dacc460d61e3ec7af)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-16 09:04:22 +00:00
Khem Raj 281bd41d0b security_flags: wipe security flags for gcc/glibc and related libraries
It causes a catch-22 situation where we build libssp in gcc-runtime but also
pass -fstack-protector flags which require libssp

(From OE-Core rev: 61ef8212cc6880f502f1e05e2683d232ea782ae4)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-07 17:29:59 +00:00
Khem Raj 61a58752f4 security_flags: use -fstack-protector-strong
This is a better version of -fstack-protector-all with reduced stack usage and
better performance yet giving same amount of coverage.  It's available in gcc
4.9 onwards.

https://outflux.net/blog/archives/2014/01/27/fstack-protector-strong/ has more
details.

(From OE-Core rev: 4ca946c029f04ba3991ed0f1f65355a7a7840ff4)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-07 17:29:59 +00:00
Khem Raj a07f2fddbc security_flags: ensure security flags only apply to target builds
As otherwise the security flags can leak into target builds.  This can result in
flags that the host compiler doesn't support, causing build failures.

(From OE-Core rev: ff2c8af73046f55aa733ce8289b6236c88300290)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-07 17:29:59 +00:00
Ross Burton 1df1ac9f3f security_flags.inc: don't do -pie for syslinux
sysroots/x86_64-linux/usr/libexec/x86_64-poky-linux/gcc/x86_64-poky-linux/5.3.0/ld:
  syslinux.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used
  when making a shared object; recompile with -fPIC

(From OE-Core rev: b87a9c82663446fa8c002e144de57127e8902b54)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-07 17:29:58 +00:00
Andre McCurdy 77fde15551 security_flags.inc: remove obsolete workarounds for curl
The curl configure script contains sanity checks for unexpected
options being passed via CFLAGS, LDFLAGS, etc. environment variables.

These sanity checks catch -Dxxx options in CFLAGS, which clashes with
OE's approach of using CFLAGS to pass -D_FORTIFY_SOURCE (curl's
configure script suggests, quite correctly, that -Dxxx options should
be passed via CPPFLAGS instead).

These sanity checks previously generated fatal errors, but have been
downgraded to warnings since curl v7.32. Therefore the workaround of
avoiding -D_FORTIFY_SOURCE for curl is obsolete and can be removed.

  5d3cbde72e

(From OE-Core rev: d0dfd7bf9b2d6fb269f4d9b62263fd7ccc805fde)

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-19 17:37:34 +00:00
Andre McCurdy 3d19a1e10c security_flags.inc: disable -fstack-protector-XXX for valgrind
Valgrind (v3.11.0) expects to build with stack protection disabled
and includes -fno-stack-protector in its default CFLAGS. However, the
CFLAGS provided by OE are included on the compiler command line after
the defaults so any -fstack-protector-all / -fstack-protector-strong
option provided by security_flags.inc will cause problems.

 | .../build-bcm97425vms/tmp/work/mips32el-rdk-linux/valgrind/3.11.0-r0/valgrind-3.11.0/coregrind/m_mallocfree.c:892: undefined reference to `__stack_chk_guard'
 | .../build-bcm97425vms/tmp/work/mips32el-rdk-linux/valgrind/3.11.0-r0/valgrind-3.11.0/coregrind/m_mallocfree.c:947: undefined reference to `__stack_chk_fail'

(From OE-Core rev: ff4f46700a4810fcb49c58978b17af4f52fa9925)

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-07 13:40:15 +00:00
Alexander Kanavin e552b25530 webkit-gtk: remove the recipe for the obsolete version 1.8.3
webkitgtk 2.8.3 is provided instead and midori browser is replaced by epiphany in
separate commits.

(From OE-Core rev: 1a72dc9c44c7806c869c3b3afcd5d31bcf2da979)

(From OE-Core rev: 68a1e346751c4d644a14035b0d7acf01d212f38c)

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-09-14 20:46:37 +01:00
Topi Kuutela ad841dbb66 security_flags.inc: disable -pie and -fpie from Python3 compilation.
If security_flags.inc is 'required' to the image, -pie and -fpie options
are added to CFLAGS. These are not compatible with -shared GCC option.
The result is several errors of following form and missing Python3
modules in the image:

    *.o In function `_start': *.S undefined reference to `main'
    collect2: error: ld returned 1 exit status

(From OE-Core rev: 94818c5240b793464700945d0cf057bffb9e1008)

Signed-off-by: Topi Kuutela <topi.kuutela@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-08-09 00:14:03 -07:00
Richard Purdie 997893e928 security-flags: Disable PIE for coreutils, elfutils, gcc, iptables
With gcc 5, we need to disable the PIE flags for more recipes in order
to have successful builds.

(From OE-Core rev: ec2f1b5af102ab6a8fcc23bf115c8f0451ab7eb8)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-27 23:29:15 +01:00
Joe Slater abe6459c28 security_flags: eliminate FORTIFY_SOURCE for debug builds
If -D_FORTIFY_SOURCE=2 is included in CFLAGS for debug builds,
many warnings will be generated and some packages will fail to
build.  So, only conditionally include it.

(From OE-Core rev: 1b576012a6a2b2ebc2c507cdaebd62174810b191)

Signed-off-by: Joe Slater <jslater@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-08 00:01:23 +01:00
Andre McCurdy de18f7595f security_flags.inc: remove duplicated over-rides
The following over-rides were both defined twice:

  SECURITY_CFLAGS_pn-grub-efi-x86-64-native
  SECURITY_CFLAGS_pn-ltp

(From OE-Core rev: dfae10889ab0fce2bae94294a78f4ea0aaf1b81e)

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-06-23 11:46:56 +01:00
Richard Purdie 1c5e37acb9 security_flags: Add comment about what it does and who uses it
It was pointed out that people couldn't easily see who used this or
why so add some comments about that.

(From OE-Core rev: 67f09e9086b8fb1c0c8a1dd19419afb1a5af8daf)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-05-30 22:26:12 +01:00
Richard Purdie d6507726bf security_flags: Add python-numpy to pie incompatible list
With poky-lsb (security flags enabled), python-numpy doesn't build
with pie flags.

(From OE-Core rev: d4694ac5e18db1d0db314d0d8b1104c073037a60)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-05-03 11:43:52 +01:00
Denys Dmytriyenko 7c63dc263f security_flags.inc: elfutils on ARM fails with PIE flags
The error messages look like this:
R_ARM_TLS_LE32 relocation not permitted in shared object

(From OE-Core rev: a915adfd1eaad9a0d65dffe9da92811284e491c8)

Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-09 07:43:50 +01:00
Ross Burton bf59b22d14 security_flags: remove PIE flags from flex and gstreamer1.0-plugins-bad
These recipes both fail to build with "relocation R_X86_64_PC32 against
undefined hidden symbol `__init_array_start' can not be used when making a
shared object" when using PIE.

(From OE-Core rev: 37e6e62f0faae3fa16421b051599aea0e03a5825)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-03-02 18:04:27 +00:00
Ross Burton 08c64b5af6 security_flags: disable PIE on expect
Disable PIE in expect as otherwise it tries to link the shared library as an
executable.

(From OE-Core rev: fe1f5c90eede593100fe57630d39cf329e59ef8f)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-29 15:36:52 +00:00
Dan McGregor 166015c809 gcc-sanitizers: Enable GCC sanitizers
AddressSanitizer is a fast memory error detector.
ThreadSanitizer detects data races.
UBSanitizer detectes undefined behaviour.

All consist of compiler instrumentation and a run-time library.
The compiler instrumentation was already enabled, this builds
the run-time library component.

(From OE-Core rev: 1709bf0c3a84bb04bc52e9104ad8e09fba6c6f91)

Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23 11:36:29 +00:00
Saul Wold 85326e2baa security_flags: disable pie support for libaio, blktrace and ltp
libaio when built with pie and fpie does not link correctly with blktrace or ltp
so we need to disable those flags until a better solution comes along.

(From OE-Core rev: 4fbf13a6c28fc1170a4defbf50032546a14eaa59)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-16 23:08:21 +00:00
Richard Purdie 2059a6607d security_flags: Fix typo for cups
(From OE-Core rev: 146b1ea632294b2830e2cfe2d1258d48cd0c0e85)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-19 18:08:03 +00:00
Khem Raj 00f33ffc80 distro: TCLIBC now defines glibc instead of eglibc
Adjust naming conventions to reflect eglibc->glibc move

(From OE-Core rev: ce3f296ec9021d207cb80cb2c697932b83fd0e81)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-09-01 18:02:21 +01:00
Saul Wold 4df2d018a1 security_flags: Update to correctly link X modules
Remove the -z,now flag from linking

[YOCTO #5885]

(From OE-Core rev: 545986bfbfe20f2b6e8a46e88e2cc3007ca344e6)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-05 15:50:22 +00:00
Richard Purdie 5ab9d7e28f security-flags: Avoid lttng-tools issue on arm
(From OE-Core rev: 010d5b437413156c3f4dc90a14698231bb195c2e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-26 13:48:21 +00:00
Richard Purdie 4f976b8fa9 security-flags: Deal with powerpc build issues
Building powerpc machines with the standard security flags generated numerous
build failures. Use a reduced set of flags for now to avoid linker issues
and other compile failures.

(From OE-Core rev: 4ef8f658874282ead0c46352474fdb03ad1f1038)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-26 13:48:21 +00:00
Saul Wold 8117e01147 security_flags: disable PIE flags for cups builds
(From OE-Core rev: c564bffe7a32470578a22b70e868e7bec2da0a69)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-26 13:48:20 +00:00