From 7cfa1d52ddb12b2d65f6857bffc6b471c9810d7c Mon Sep 17 00:00:00 2001 From: Ting Liu Date: Fri, 14 Dec 2012 17:14:30 +0000 Subject: [PATCH] fmlib: add recipe Signed-off-by: Ting Liu --- ...he-library-install-path-configurable.patch | 43 +++++++++++++++++++ meta-fsl-ppc/recipes-ucode/fmlib/fmlib_git.bb | 39 +++++++++++++++++ 2 files changed, 82 insertions(+) create mode 100644 meta-fsl-ppc/recipes-ucode/fmlib/files/0001-fm-lib-make-the-library-install-path-configurable.patch create mode 100644 meta-fsl-ppc/recipes-ucode/fmlib/fmlib_git.bb diff --git a/meta-fsl-ppc/recipes-ucode/fmlib/files/0001-fm-lib-make-the-library-install-path-configurable.patch b/meta-fsl-ppc/recipes-ucode/fmlib/files/0001-fm-lib-make-the-library-install-path-configurable.patch new file mode 100644 index 00000000..4894ce3b --- /dev/null +++ b/meta-fsl-ppc/recipes-ucode/fmlib/files/0001-fm-lib-make-the-library-install-path-configurable.patch @@ -0,0 +1,43 @@ +From 67b539d256520f95f3c8101f4605ea6d496982df Mon Sep 17 00:00:00 2001 +From: Zhenhua Luo +Date: Thu, 18 Oct 2012 17:28:00 +0300 +Subject: [PATCH] fm-lib: make the library install path configurable + +currently library for both 32bit target and 64bit target +is installed in /usr/lib folder, add a variable to make the +install path configurable + +Signed-off-by: Zhenhua Luo +--- + Makefile | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/Makefile b/Makefile +index 06fe930..d59f44a 100644 +--- a/Makefile ++++ b/Makefile +@@ -59,6 +59,8 @@ endif + + INSTALL?=install + ++LIB_DEST_DIR?=$(PREFIX)/lib ++ + # Don't forget to increment .version before doing a new release! + FM_LIB_VERSION:=$(shell cat .version) + +@@ -118,9 +120,9 @@ archive: all .version + + install-%: %.a + @(echo "Installing...") +- @($(INSTALL) -d $(DESTDIR)$(PREFIX)/lib) +- @($(INSTALL) $< $(DESTDIR)$(PREFIX)/lib) +- @(ln -s $(DESTDIR)$(PREFIX)/lib/$< $(DESTDIR)$(PREFIX)/lib/libfm.a) ++ @($(INSTALL) -d $(DESTDIR)$(LIB_DEST_DIR)) ++ @($(INSTALL) $< $(DESTDIR)$(LIB_DEST_DIR)) ++ @(ln -s $(DESTDIR)$(LIB_DEST_DIR)/$< $(DESTDIR)$(LIB_DEST_DIR)/libfm.a) + @(cp -r -p ./include $(DESTDIR)$(PREFIX)) + @($(INSTALL) -d $(DESTDIR)$(PREFIX)/share/doc/fm-lib-$(FM_LIB_VERSION)) + @($(INSTALL) $(FM_LIB_DOCFILES) $(DESTDIR)$(PREFIX)/share/doc/fm-lib-$(FM_LIB_VERSION)) +-- +1.7.9.5 + diff --git a/meta-fsl-ppc/recipes-ucode/fmlib/fmlib_git.bb b/meta-fsl-ppc/recipes-ucode/fmlib/fmlib_git.bb new file mode 100644 index 00000000..74eb2047 --- /dev/null +++ b/meta-fsl-ppc/recipes-ucode/fmlib/fmlib_git.bb @@ -0,0 +1,39 @@ +DESCRIPTION = "Frame Manager User Space Library" +SECTION = "fman" +LICENSE = "BSD & GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=3f16fa8e677e45af3127c5c4bafc3c00" + +DEPENDS = "linux-libc-headers" +DEPENDS_virtclass-native = "" + +SRC_URI = "git://git.freescale.com/ppc/sdk/fmlib.git" +SRCREV = "5ebbf75c3108404b513198c9fd9b955b123680af" + +S = "${WORKDIR}/git" + +TARGET_ARCH_FMLIB = "${DEFAULTTUNE}" +TARGET_ARCH_FMLIB_e5500 = "ppc32e5500" +TARGET_ARCH_FMLIB_e6500 = "ppc32e6500" + +EXTRA_OEMAKE = "DESTDIR=${D} PREFIX=${prefix} LIB_DEST_DIR=${libdir} \ + CROSS_COMPILE=${TARGET_PREFIX} KERNEL_SRC=${STAGING_EXECPREFIXDIR}" + +do_compile () { + oe_runmake libfm-${TARGET_ARCH_FMLIB}.a +} + +do_compile_virtclass-native () { +} + +do_install () { + oe_runmake install-libfm-${TARGET_ARCH_FMLIB} +} + +do_install_virtclass-native () { + install -d ${D}/${includedir} + cp -rf ${S}/include/* ${D}/${includedir} +} + +ALLOW_EMPTY = "1" + +BBCLASSEXTEND = "native" -- 2.40.1