rjw | 1f88458 | 2022-01-06 17:20:42 +0800 | [diff] [blame^] | 1 | #Basic Configuration |
| 2 | DESCRIPTION = "This module is used to provide a library for libaudio_plugin." |
| 3 | SECTION = "base" |
| 4 | LICENSE = "MediaTekProprietary" |
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=e1696b147d49d491bcb4da1a57173fff" |
| 6 | MTK_SRC = "${BACH_SRC}/libmodem-afe-ctrl" |
| 7 | MODEMINIT_OUT = "${WORKDIR}/out" |
| 8 | CROSS = "${TARGET_PREFIX}" |
| 9 | PROJECT = "${PROJ_NAME}" |
| 10 | WORKONSRC = "${MTK_SRC}" |
| 11 | |
| 12 | DEPENDS="alsa-lib audio-mixer-ctrl bachinit" |
| 13 | |
| 14 | INCLUDE_ADD = "-I${STAGING_DIR_HOST}/usr/include -I${STAGING_DIR_HOST}/usr/include/logger " |
| 15 | CFLAGS = "--sysroot ${STAGING_DIR_HOST} -lasound -lmtk_audio_mixer_ctrl" |
| 16 | LDFLAGS = "--sysroot ${STAGING_DIR_HOST}" |
| 17 | |
| 18 | |
| 19 | inherit deploy workonsrc |
| 20 | |
| 21 | FILES_${PN} = "${base_libdir}/libmodemafectrl.so \ |
| 22 | ${base_libdir}/*.so" |
| 23 | |
| 24 | FILES_${PN}-doc = "/doc" |
| 25 | |
| 26 | FILES_${PN}-dbg = "${base_libdir}/.debug \ |
| 27 | /usr/src/debug \ |
| 28 | ${base_libdir}/.debug" |
| 29 | |
| 30 | FILES_${PN}-dev = "/test \ |
| 31 | /bin \ |
| 32 | /test \ |
| 33 | ${includedir}" |
| 34 | |
| 35 | |
| 36 | #Skip strip check in QA test. |
| 37 | INSANE_SKIP_${PN} += "already-stripped" |
| 38 | |
| 39 | |
| 40 | EXTRA_OEMAKE = "'CROSS=${CROSS}'\ |
| 41 | 'ROOT=${STAGING_DIR_HOST}'\ |
| 42 | 'PREFIX=${BACH_PREFIX}'\ |
| 43 | 'PACKAGE_ARCH=${PACKAGE_ARCH}'\ |
| 44 | 'BB_INCLUDE_ADD=${INCLUDE_ADD}'\ |
| 45 | 'BB_LDFLAGS_ADD=${LDFLAGS}'\ |
| 46 | 'BB_CFLAGS_ADD=${CFLAGS}'\ |
| 47 | 'TARGET_PLATFORM=${TARGET_PLATFORM}'" |
| 48 | |
| 49 | do_install () { |
| 50 | oe_runmake install ROOT=${D} |
| 51 | |
| 52 | if [ -d "${D}/include" ]; then |
| 53 | install -d ${D}${includedir} |
| 54 | cp -af ${D}/include/* ${D}${includedir} |
| 55 | rm -rf ${D}/include |
| 56 | fi |
| 57 | install -d ${D}${includedir} |
| 58 | install -m 0644 ${S}/include/modem_afe_ctrl.h ${D}${includedir}/ |
| 59 | |
| 60 | } |
| 61 | |
| 62 | addtask bachclean |
| 63 | do_bachclean() { |
| 64 | oe_runmake clean |
| 65 | } |
| 66 | |
| 67 | |
| 68 | |