From eb8dc40360f0cfef56fb6947cc817a547d6d9bc6 Mon Sep 17 00:00:00 2001 From: Dave Cobbley Date: Tue, 14 Aug 2018 10:05:37 -0700 Subject: [Subtree] Removing import-layers directory As part of the move to subtrees, need to bring all the import layers content to the top level. Change-Id: I4a163d10898cbc6e11c27f776f60e1a470049d8f Signed-off-by: Dave Cobbley Signed-off-by: Brad Bishop --- .../lsof/files/lsof-remove-host-information.patch | 76 ++++++++++++++++++++++ poky/meta/recipes-extended/lsof/lsof_4.89.bb | 64 ++++++++++++++++++ 2 files changed, 140 insertions(+) create mode 100644 poky/meta/recipes-extended/lsof/files/lsof-remove-host-information.patch create mode 100644 poky/meta/recipes-extended/lsof/lsof_4.89.bb (limited to 'poky/meta/recipes-extended/lsof') diff --git a/poky/meta/recipes-extended/lsof/files/lsof-remove-host-information.patch b/poky/meta/recipes-extended/lsof/files/lsof-remove-host-information.patch new file mode 100644 index 000000000..b7d2323dc --- /dev/null +++ b/poky/meta/recipes-extended/lsof/files/lsof-remove-host-information.patch @@ -0,0 +1,76 @@ +Remove host information from version.h + +make lsof not include host information + +Upstream-Status: Inappropriate [embedded specific] + +Signed-off-by: Li Wang +--- + dialects/linux/Makefile | 50 +++++++++-------------------------------------- + 1 file changed, 9 insertions(+), 41 deletions(-) + +diff --git a/dialects/linux/Makefile b/dialects/linux/Makefile +index 2bea108..792142b 100644 +--- a/dialects/linux/Makefile ++++ b/dialects/linux/Makefile +@@ -76,48 +76,16 @@ version.h: FRC + @echo Constructing version.h + @rm -f version.h + @echo '#define LSOF_BLDCMT "${LSOF_BLDCMT}"' > version.h; +- @echo '#define LSOF_CC "${CC}"' >> version.h +- @echo '#define LSOF_CCV "${CCV}"' >> version.h +- @echo '#define LSOF_CCDATE "'`date`'"' >> version.h +- @echo '#define LSOF_CCFLAGS "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h ++ @echo '#define LSOF_CC ""' >> version.h ++ @echo '#define LSOF_CCV ""' >> version.h ++ @echo '#define LSOF_CCDATE ""' >> version.h ++ @echo '#define LSOF_CCFLAGS ""' >> version.h + @echo '#define LSOF_CINFO "${CINFO}"' >> version.h +- @if [ "X${LSOF_HOST}" = "X" ]; then \ +- echo '#define LSOF_HOST "'`uname -n`'"' >> version.h; \ +- else \ +- if [ "${LSOF_HOST}" = "none" ]; then \ +- echo '#define LSOF_HOST ""' >> version.h; \ +- else \ +- echo '#define LSOF_HOST "${LSOF_HOST}"' >> version.h; \ +- fi \ +- fi +- @echo '#define LSOF_LDFLAGS "${CFGL}"' >> version.h +- @if [ "X${LSOF_LOGNAME}" = "X" ]; then \ +- echo '#define LSOF_LOGNAME "${LOGNAME}"' >> version.h; \ +- else \ +- if [ "${LSOF_LOGNAME}" = "none" ]; then \ +- echo '#define LSOF_LOGNAME ""' >> version.h; \ +- else \ +- echo '#define LSOF_LOGNAME "${LSOF_LOGNAME}"' >> version.h; \ +- fi; \ +- fi +- @if [ "X${LSOF_SYSINFO}" = "X" ]; then \ +- echo '#define LSOF_SYSINFO "'`uname -a`'"' >> version.h; \ +- else \ +- if [ "${LSOF_SYSINFO}" = "none" ]; then \ +- echo '#define LSOF_SYSINFO ""' >> version.h; \ +- else \ +- echo '#define LSOF_SYSINFO "${LSOF_SYSINFO}"' >> version.h; \ +- fi \ +- fi +- @if [ "X${LSOF_USER}" = "X" ]; then \ +- echo '#define LSOF_USER "${USER}"' >> version.h; \ +- else \ +- if [ "${LSOF_USER}" = "none" ]; then \ +- echo '#define LSOF_USER ""' >> version.h; \ +- else \ +- echo '#define LSOF_USER "${LSOF_USER}"' >> version.h; \ +- fi \ +- fi ++ @echo '#define LSOF_HOST ""' >> version.h; ++ @echo '#define LSOF_LDFLAGS ""' >> version.h ++ @echo '#define LSOF_LOGNAME ""' >> version.h; ++ @echo '#define LSOF_SYSINFO ""' >> version.h; ++ @echo '#define LSOF_USER ""' >> version.h; + @sed '/VN/s/.ds VN \(.*\)/#define LSOF_VERSION "\1"/' < version >> version.h + + FRC: +-- +1.7.9.5 + diff --git a/poky/meta/recipes-extended/lsof/lsof_4.89.bb b/poky/meta/recipes-extended/lsof/lsof_4.89.bb new file mode 100644 index 000000000..14546db23 --- /dev/null +++ b/poky/meta/recipes-extended/lsof/lsof_4.89.bb @@ -0,0 +1,64 @@ +SUMMARY = "LiSt Open Files tool" +DESCRIPTION = "Lsof is a Unix-specific diagnostic tool. \ +Its name stands for LiSt Open Files, and it does just that." +HOMEPAGE = "http://people.freebsd.org/~abe/" +SECTION = "devel" +LICENSE = "BSD" +LIC_FILES_CHKSUM = "file://00README;beginline=645;endline=679;md5=964df275d26429ba3b39dbb9f205172a" + +# Upstream lsof releases are hosted on an ftp server which times out download +# attempts from hosts for which it can not perform a DNS reverse-lookup (See: +# https://people.freebsd.org/~abe/ ). http://www.mirrorservice.org seems to be +# the most commonly used alternative. + +SRC_URI = "http://www.mirrorservice.org/sites/lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_${PV}.tar.bz2 \ + file://lsof-remove-host-information.patch \ + " + +SRC_URI[md5sum] = "1b9cd34f3fb86856a125abbf2be3a386" +SRC_URI[sha256sum] = "81ac2fc5fdc944793baf41a14002b6deb5a29096b387744e28f8c30a360a3718" + +LOCALSRC = "file://${WORKDIR}/lsof_${PV}/lsof_${PV}_src.tar" + +S = "${WORKDIR}/lsof_${PV}_src" + +python do_unpack () { + # temporarily change S for unpack + # of lsof_${PV} + s = d.getVar('S', False) + d.setVar('S', '${WORKDIR}/lsof_${PV}') + bb.build.exec_func('base_do_unpack', d) + # temporarily change SRC_URI for unpack + # of lsof_${PV}_src + src_uri = d.getVar('SRC_URI', False) + d.setVar('SRC_URI', '${LOCALSRC}') + d.setVar('S', s) + bb.build.exec_func('base_do_unpack', d) + d.setVar('SRC_URI', src_uri) +} + +export LSOF_INCLUDE = "${STAGING_INCDIR}" + +do_configure () { + export LSOF_AR="${AR} cr" + export LSOF_RANLIB="${RANLIB}" + if [ "x${GLIBCVERSION}" != "x" ]; then + LINUX_CLIB=`echo ${GLIBCVERSION} |sed -e 's,\.,,g'` + LINUX_CLIB="-DGLIBCV=${LINUX_CLIB}" + export LINUX_CLIB + fi + yes | ./Configure linux +} + +export I = "${STAGING_INCDIR}" +export L = "${STAGING_INCDIR}" + +do_compile () { + oe_runmake 'CC=${CC}' 'CFGL=${LDFLAGS} -L./lib -llsof' 'DEBUG=' 'INCL=${CFLAGS}' +} + +do_install () { + install -d ${D}${sbindir} ${D}${mandir}/man8 + install -m 0755 lsof ${D}${sbindir}/lsof + install -m 0644 lsof.8 ${D}${mandir}/man8/lsof.8 +} -- cgit v1.2.3