generic-poky/meta/recipes-support/attr/ea-acl.inc
Robert Yang 5ddf8570a1 recipes-support: replace virtclass-native(sdk) with class-native(sdk)
The overrides virtclass-native and virtclass-nativesdk are deprecated,
which should be replaced by class-native and class-nativesdk.

NOTE:
There were 2 errors in libcap.inc, the BUILD_LDFLAGS_virtclass_native
should be BUILD_LDFLAGS_virtclass-native (the "_" should be "-"),
otherwise it doesn't work, and the value was: "-Wl,rpath=...", this is
incorrect, it shoudl be: "-Wl,-rpath=..." (lacked a - ), but we don't
need this line, since it is already in the default BUILD_LDFLAGS. Remove
it and we don't need to bump the PR since we just removed a unused line.

[YOCTO #3297]

(From OE-Core rev: cafb550fe9034754933f1708446dde155dcc3d51)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-11-02 16:18:28 +00:00

59 lines
2 KiB
PHP

# this build system is mostly shared by attr and acl
SRC_URI += "file://relative-libdir.patch;striplevel=0 \
"
inherit autotools gettext
# the package comes with a custom config.h.in, it cannot be
# overwritten by autoheader
export AUTOHEADER = "true"
EXTRA_OECONF = "INSTALL_USER=root INSTALL_GROUP=root"
EXTRA_OECONF_append_class-native = " --enable-gettext=no"
EXTRA_OEMAKE = "PKG_LIB_DIR=${base_libdir} PKG_DEVLIB_DIR=${libdir}"
do_install () {
oe_runmake install install-lib install-dev DIST_ROOT="${D}"
}
PACKAGES =+ "lib${BPN} lib${BPN}-dev lib${BPN}-staticdev lib${BPN}-doc"
FILES_lib${BPN} = "${base_libdir}/lib*${SOLIBS}"
FILES_lib${BPN}-dev = "${includedir} \
${libdir}/lib*${SOLIBSDEV} \
${libdir}/lib*.la \
${base_libdir}/lib*${SOLIBSDEV} \
${base_libdir}/lib*.la"
FILES_lib${BPN}-staticdev = "${libdir}/*.a ${base_libdir}/*.a"
FILES_lib${BPN}-doc = "${mandir}/man2 \
${mandir}/man3"
BBCLASSEXTEND = "native"
# Only append ldflags for target recipe and if USE_NLS is enabled
LDFLAGS_append_libc-uclibc = "${@['', ' -lintl '][(d.getVar('PN', True) == d.getVar('BPN', True)) and (d.getVar('USE_NLS', True) == 'yes')]}"
EXTRA_OECONF_append_libc-uclibc = "${@['', ' --disable-gettext '][(d.getVar('PN', True) == d.getVar('BPN', True)) and (d.getVar('USE_NLS', True) == 'no')]}"
fix_symlink () {
if test "${libdir}" = "${base_libdir}" ; then
return
fi
# Remove bad symlinks & create the correct symlinks
if test -L ${libdir}/lib${BPN}.so ; then
rm -rf ${libdir}/lib${BPN}.so
ln -sf ${base_libdir}/lib${BPN}.so ${libdir}/lib${BPN}.so
fi
if test -L ${base_libdir}/lib${BPN}.a ; then
rm -rf ${base_libdir}/lib${BPN}.a
ln -sf ${libdir}/lib${BPN}.a ${base_libdir}/lib${BPN}.a
fi
if test -L ${base_libdir}/lib${BPN}.la ; then
rm -rf ${base_libdir}/lib${BPN}.la
ln -sf ${libdir}/lib${BPN}.la ${base_libdir}/lib${BPN}.la
fi
}
SSTATEPOSTINSTFUNCS_class-native += "fix_symlink"