summaryrefslogtreecommitdiffstats
path: root/external/meta-openembedded/meta-oe/classes/breakpad.bbclass
diff options
context:
space:
mode:
authorToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp>2020-03-30 09:24:26 +0900
committerToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp>2020-03-30 09:24:26 +0900
commit5b80bfd7bffd4c20d80b7c70a7130529e9a755dd (patch)
treeb4bb18dcd1487dbf1ea8127e5671b7bb2eded033 /external/meta-openembedded/meta-oe/classes/breakpad.bbclass
parent706ad73eb02caf8532deaf5d38995bd258725cb8 (diff)
agl-basesystem
Diffstat (limited to 'external/meta-openembedded/meta-oe/classes/breakpad.bbclass')
-rw-r--r--external/meta-openembedded/meta-oe/classes/breakpad.bbclass33
1 files changed, 33 insertions, 0 deletions
diff --git a/external/meta-openembedded/meta-oe/classes/breakpad.bbclass b/external/meta-openembedded/meta-oe/classes/breakpad.bbclass
new file mode 100644
index 00000000..36f11ff4
--- /dev/null
+++ b/external/meta-openembedded/meta-oe/classes/breakpad.bbclass
@@ -0,0 +1,33 @@
+# Class to inherit when you want to build against Breakpad.
+# Apart from inheriting this class, you need to set BREAKPAD_BIN in
+# your recipe, and make sure that you link against libbreakpad_client.a.
+
+DEPENDS += "breakpad breakpad-native"
+
+CFLAGS += "-I${STAGING_DIR_TARGET}${includedir}/breakpad "
+CXXFLAGS += "-I${STAGING_DIR_TARGET}${includedir}/breakpad "
+
+BREAKPAD_BIN ?= ""
+
+python () {
+ breakpad_bin = d.getVar("BREAKPAD_BIN")
+
+ if not breakpad_bin:
+ PN = d.getVar("PN")
+ FILE = os.path.basename(d.getVar("FILE"))
+ bb.error("To build %s, see breakpad.bbclass for instructions on \
+ setting up your Breakpad configuration" % PN)
+ raise ValueError('BREAKPAD_BIN not defined in %s' % PN)
+}
+
+# Add creation of symbols here
+PACKAGE_PREPROCESS_FUNCS += "breakpad_package_preprocess"
+breakpad_package_preprocess () {
+ mkdir -p ${PKGD}/usr/share/breakpad-syms
+ find ${D} -name ${BREAKPAD_BIN} -exec sh -c "dump_syms {} > ${PKGD}/usr/share/breakpad-syms/${BREAKPAD_BIN}.sym" \;
+}
+
+PACKAGES =+ "${PN}-breakpad"
+
+FILES_${PN}-breakpad = "/usr/share/breakpad-syms"
+