summaryrefslogtreecommitdiffstats
path: root/meta/classes/distutils-common-base.bbclass
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2018-08-28 10:50:37 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-09-04 11:03:55 +0100
commit7a812523a75266752f0c67f6eb1e4691bc09bd4a (patch)
tree81b6e365f65ea92a404a2a44eb0bc983ecfdf546 /meta/classes/distutils-common-base.bbclass
parent03b6f92245a9f534ba33a69727e15d7084893187 (diff)
downloadpoky-7a812523a75266752f0c67f6eb1e4691bc09bd4a.tar.gz
distutils-common-base.bbclass: Define commonly used compiler variables
This is inspired from https://github.com/python/cpython/blob/master/configure.ac Helps cross compiling python C modules in some cases where they do not respect normal CFLAGS Errors like using gcc to link when compiler is clang is fixed (From OE-Core rev: 0ab1b35172a41021f5e27c5d17d1e131ce5befd7) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/distutils-common-base.bbclass')
-rw-r--r--meta/classes/distutils-common-base.bbclass12
1 files changed, 12 insertions, 0 deletions
diff --git a/meta/classes/distutils-common-base.bbclass b/meta/classes/distutils-common-base.bbclass
index 824a1b68b1..94b5fd426d 100644
--- a/meta/classes/distutils-common-base.bbclass
+++ b/meta/classes/distutils-common-base.bbclass
@@ -1,6 +1,18 @@
1export STAGING_INCDIR 1export STAGING_INCDIR
2export STAGING_LIBDIR 2export STAGING_LIBDIR
3 3
4# LDSHARED is the ld *command* used to create shared library
5export LDSHARED = "${CCLD} -shared"
6# LDXXSHARED is the ld *command* used to create shared library of C++
7# objects
8export LDCXXSHARED = "${CXX} -shared"
9# CCSHARED are the C *flags* used to create objects to go into a shared
10# library (module)
11export CCSHARED = "-fPIC -DPIC"
12# LINKFORSHARED are the flags passed to the $(CC) command that links
13# the python executable
14export LINKFORSHARED = "{SECURITY_CFLAGS} -Xlinker -export-dynamic"
15
4FILES_${PN} += "${libdir}/* ${libdir}/${PYTHON_DIR}/*" 16FILES_${PN} += "${libdir}/* ${libdir}/${PYTHON_DIR}/*"
5 17
6FILES_${PN}-staticdev += "\ 18FILES_${PN}-staticdev += "\