* [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl
@ 2017-06-09 6:40 jackie.huang
2017-06-09 6:40 ` [meta-oe][PATCH 1/4] agent-proxy: add new recipe jackie.huang
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: jackie.huang @ 2017-06-09 6:40 UTC (permalink / raw)
To: openembedded-devel
From: Jackie Huang <jackie.huang@windriver.com>
--
The following changes since commit 41cf832cc9abd6f2293a6d612463a34a53a9a52a:
Revert "rrdtool: add gettext-native dependency" (2017-06-05 11:13:09 +0200)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib.git jhuang0/r_up_agent-enscript-logwarn-microcode_170609_0
http://git.pokylinux.org/cgit.cgi//log/?h=jhuang0/r_up_agent-enscript-logwarn-microcode_170609_0
Jackie Huang (4):
agent-proxy: add new recipe
enscript: add new recipe
logwarn: add new recipe
microcode-ctl: add new recipe
.../0001-add-support-for-other-distributions.patch | 27 +++++
.../files/0001-fix-the-help-return-code.patch | 57 ++++++++++
.../files/fix-No-GNU_HASH-in-the-elf-binary.patch | 30 ++++++
.../microcode-ctl/files/microcode_ctl.service | 11 ++
.../recipes-bsp/microcode-ctl/microcode-ctl_git.bb | 62 +++++++++++
.../enscript/enscript/enscript-autoconf.patch | 118 +++++++++++++++++++++
.../recipes-extended/enscript/enscript_1.6.6.bb | 22 ++++
.../recipes-kernel/agent-proxy/agent-proxy_git.bb | 25 +++++
.../files/0001-Makefile-Add-LDFLAGS-variable.patch | 43 ++++++++
meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb | 46 ++++++++
10 files changed, 441 insertions(+)
create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch
create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch
create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch
create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service
create mode 100755 meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb
create mode 100644 meta-oe/recipes-extended/enscript/enscript/enscript-autoconf.patch
create mode 100644 meta-oe/recipes-extended/enscript/enscript_1.6.6.bb
create mode 100644 meta-oe/recipes-kernel/agent-proxy/agent-proxy_git.bb
create mode 100644 meta-oe/recipes-kernel/agent-proxy/files/0001-Makefile-Add-LDFLAGS-variable.patch
create mode 100644 meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb
--
2.11.0
^ permalink raw reply [flat|nested] 7+ messages in thread* [meta-oe][PATCH 1/4] agent-proxy: add new recipe 2017-06-09 6:40 [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl jackie.huang @ 2017-06-09 6:40 ` jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 2/4] enscript: " jackie.huang ` (2 subsequent siblings) 3 siblings, 0 replies; 7+ messages in thread From: jackie.huang @ 2017-06-09 6:40 UTC (permalink / raw) To: openembedded-devel From: Jackie Huang <jackie.huang@windriver.com> agent-proxy is a simple, small proxy which is intended for use with kgdb, or gdbserver type connections where you want to share a text console and a debug session. Signed-off-by: Jackie Huang <jackie.huang@windriver.com> --- .../recipes-kernel/agent-proxy/agent-proxy_git.bb | 25 +++++++++++++ .../files/0001-Makefile-Add-LDFLAGS-variable.patch | 43 ++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 meta-oe/recipes-kernel/agent-proxy/agent-proxy_git.bb create mode 100644 meta-oe/recipes-kernel/agent-proxy/files/0001-Makefile-Add-LDFLAGS-variable.patch diff --git a/meta-oe/recipes-kernel/agent-proxy/agent-proxy_git.bb b/meta-oe/recipes-kernel/agent-proxy/agent-proxy_git.bb new file mode 100644 index 000000000..8e370f962 --- /dev/null +++ b/meta-oe/recipes-kernel/agent-proxy/agent-proxy_git.bb @@ -0,0 +1,25 @@ +SUMMARY = "Proxy for UDP/TCP debug connections" +DESCRIPTION = "The agent-proxy will forward tcp or udp connections as well as allow for script multiplexing of terminal sessions." +HOMEPAGE = "http://kgdb.wiki.kernel.org/" +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a" + +SECTION = "devel" + +EXTRA_OEMAKE = "'CC=${CC}'" + +SRCREV = "e6c9d3d996bd55e7ab14dbd74deb7841e0c3a4f1" +PV = "1.96+git${SRCPV}" + +SRC_URI = "git://git.kernel.org/pub/scm/utils/kernel/kgdb/agent-proxy.git;protocol=git \ + file://0001-Makefile-Add-LDFLAGS-variable.patch \ +" + +BBCLASSEXTEND = "native nativesdk" + +S = "${WORKDIR}/git" + +do_install () { + install -d ${D}${bindir} + install -m 0755 agent-proxy ${D}${bindir} +} diff --git a/meta-oe/recipes-kernel/agent-proxy/files/0001-Makefile-Add-LDFLAGS-variable.patch b/meta-oe/recipes-kernel/agent-proxy/files/0001-Makefile-Add-LDFLAGS-variable.patch new file mode 100644 index 000000000..5eec91d72 --- /dev/null +++ b/meta-oe/recipes-kernel/agent-proxy/files/0001-Makefile-Add-LDFLAGS-variable.patch @@ -0,0 +1,43 @@ +From 1beb0dad6f8b99eb3bf1b9982e0b49e81ff77bbc Mon Sep 17 00:00:00 2001 +From: Jackie Huang <jackie.huang@windriver.com> +Date: Wed, 23 Nov 2016 19:17:31 +0800 +Subject: [PATCH] Makefile: Add LDFLAGS variable + +Add LDFLAGS variable to make sure the extra linkder +flags can be passed. + +Upstream-Status: Pending + +Signed-off-by: Jackie Huang <jackie.huang@windriver.com> +--- + Makefile | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/Makefile b/Makefile +index e20918f..25d92d3 100644 +--- a/Makefile ++++ b/Makefile +@@ -51,7 +51,7 @@ $(CROSS_COMPILE)agent-proxy: $(OBJS) + $(CC) -DAGENT_VER=$(AGENTVER) $(LINKFLAGS) $(CFLAGS) -o $(extpath)$@ $(OBJS) wsock32.lib + else + $(CROSS_COMPILE)agent-proxy: $(OBJS) +- $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) -o $(extpath)$@ $(OBJS) $(LDLIBS) ++ $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) $(LDFLAGS) -o $(extpath)$@ $(OBJS) $(LDLIBS) + endif + + +@@ -61,9 +61,9 @@ clean: + rm -f $(extpath)$(CROSS_COMPILE)agent-proxy $(extpath)agent-proxy $(extpath)*.o $(extpath)*.obj $(extpath)*.exp $(extpath)*.exe $(extpath)*.ilk $(extpath)*.pdb *~ + + $(extpath)$(CROSS_COMPILE)%.o::%.c +- $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) -c $< -o $@ ++ $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) $(LDFLAGS) -c $< -o $@ + + $(extpath)%.obj:%.c +- $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) -c -Fo$@ $(TLSPATH_INC) $< ++ $(CC) -DAGENT_VER=$(AGENTVER) $(CFLAGS) $(LDFLAGS) -c -Fo$@ $(TLSPATH_INC) $< + + +-- +2.8.3 + -- 2.11.0 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [meta-oe][PATCH 2/4] enscript: add new recipe 2017-06-09 6:40 [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 1/4] agent-proxy: add new recipe jackie.huang @ 2017-06-09 6:40 ` jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 3/4] logwarn: " jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 4/4] microcode-ctl: " jackie.huang 3 siblings, 0 replies; 7+ messages in thread From: jackie.huang @ 2017-06-09 6:40 UTC (permalink / raw) To: openembedded-devel From: Jackie Huang <jackie.huang@windriver.com> enscript is a plain ASCII to PostScript converter. Signed-off-by: Jackie Huang <jackie.huang@windriver.com> --- .../enscript/enscript/enscript-autoconf.patch | 118 +++++++++++++++++++++ .../recipes-extended/enscript/enscript_1.6.6.bb | 22 ++++ 2 files changed, 140 insertions(+) create mode 100644 meta-oe/recipes-extended/enscript/enscript/enscript-autoconf.patch create mode 100644 meta-oe/recipes-extended/enscript/enscript_1.6.6.bb diff --git a/meta-oe/recipes-extended/enscript/enscript/enscript-autoconf.patch b/meta-oe/recipes-extended/enscript/enscript/enscript-autoconf.patch new file mode 100644 index 000000000..d3bb5c03a --- /dev/null +++ b/meta-oe/recipes-extended/enscript/enscript/enscript-autoconf.patch @@ -0,0 +1,118 @@ +autoconf no longer supports AM_C_PROTOTYPES + +| configure.ac:14: error: automatic de-ANSI-fication support has been removed +| /bitbake_build/tmp/sysroots/x86_64-linux/usr/share/aclocal-1.12/protos.m4:10: AM_C_PROTOTYPES is expanded from... + +Upstream-Status: Pending + +Author: Mark Hatle <mark.hatle@windriver.com> +Signed-off-by: Jackie Huang <jackie.huang@windriver.com> + +Index: enscript-1.6.6/configure.ac +=================================================================== +--- enscript-1.6.6.orig/configure.ac ++++ enscript-1.6.6/configure.ac +@@ -11,7 +11,6 @@ AC_PROG_INSTALL + AC_PROG_CC + + AC_USE_SYSTEM_EXTENSIONS +-AM_C_PROTOTYPES + + AC_C_CONST + AC_FUNC_ALLOCA +Index: enscript-1.6.6/afmlib/afm.h +=================================================================== +--- enscript-1.6.6.orig/afmlib/afm.h ++++ enscript-1.6.6/afmlib/afm.h +@@ -24,11 +24,7 @@ + #define AFM_H + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + /********************************************************************** +Index: enscript-1.6.6/afmlib/afmint.h +=================================================================== +--- enscript-1.6.6.orig/afmlib/afmint.h ++++ enscript-1.6.6/afmlib/afmint.h +@@ -34,11 +34,7 @@ + #include <stdio.h> + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + #if STDC_HEADERS +Index: enscript-1.6.6/afmlib/strhash.h +=================================================================== +--- enscript-1.6.6.orig/afmlib/strhash.h ++++ enscript-1.6.6/afmlib/strhash.h +@@ -24,11 +24,7 @@ + #define STRHASH_H + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + typedef struct stringhash_st *StringHashPtr; +Index: enscript-1.6.6/compat/xalloc.h +=================================================================== +--- enscript-1.6.6.orig/compat/xalloc.h ++++ enscript-1.6.6/compat/xalloc.h +@@ -28,11 +28,7 @@ + #define XALLOC_H + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + void *xmalloc ___P ((size_t size)); +Index: enscript-1.6.6/src/gsint.h +=================================================================== +--- enscript-1.6.6.orig/src/gsint.h ++++ enscript-1.6.6/src/gsint.h +@@ -39,11 +39,7 @@ + #include <sys/stat.h> + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + #if STDC_HEADERS +Index: enscript-1.6.6/states/defs.h +=================================================================== +--- enscript-1.6.6.orig/states/defs.h ++++ enscript-1.6.6/states/defs.h +@@ -37,11 +37,7 @@ + #include <ctype.h> + + #ifndef ___P +-#if PROTOTYPES + #define ___P(protos) protos +-#else /* no PROTOTYPES */ +-#define ___P(protos) () +-#endif /* no PROTOTYPES */ + #endif + + #if STDC_HEADERS diff --git a/meta-oe/recipes-extended/enscript/enscript_1.6.6.bb b/meta-oe/recipes-extended/enscript/enscript_1.6.6.bb new file mode 100644 index 000000000..96129880a --- /dev/null +++ b/meta-oe/recipes-extended/enscript/enscript_1.6.6.bb @@ -0,0 +1,22 @@ +SUMMARY = "A plain ASCII to PostScript converter" +DESCRIPTION = "GNU enscript is a free replacement for Adobe''s Enscript \ +program. Enscript converts ASCII files to PostScript(TM) and spools generated \ +PostScript output to the specified printer or saves it to a file. Enscript can \ +be extended to handle different output media and includes many options for \ +customizing printouts." +HOMEPAGE = "http://www.gnu.org/software/enscript/" +SECTION = "console/utils" + +LICENSE = "GPLv3+" +LIC_FILES_CHKSUM = "file://COPYING;md5=f27defe1e96c2e1ecd4e0c9be8967949" + +SRC_URI = "${GNU_MIRROR}/${BPN}/${BP}.tar.gz \ + file://enscript-autoconf.patch \ +" + +inherit autotools gettext + +SRC_URI[md5sum] = "3acc242b829adacabcaf28533f049afd" +SRC_URI[sha256sum] = "6d56bada6934d055b34b6c90399aa85975e66457ac5bf513427ae7fc77f5c0bb" + +RDEPENDS_${PN} = "perl" -- 2.11.0 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [meta-oe][PATCH 3/4] logwarn: add new recipe 2017-06-09 6:40 [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 1/4] agent-proxy: add new recipe jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 2/4] enscript: " jackie.huang @ 2017-06-09 6:40 ` jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 4/4] microcode-ctl: " jackie.huang 3 siblings, 0 replies; 7+ messages in thread From: jackie.huang @ 2017-06-09 6:40 UTC (permalink / raw) To: openembedded-devel From: Jackie Huang <jackie.huang@windriver.com> logwarn is a utility for finding interesting messages in log files. Signed-off-by: Jackie Huang <jackie.huang@windriver.com> --- meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb | 46 +++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb diff --git a/meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb b/meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb new file mode 100644 index 000000000..00e5d497b --- /dev/null +++ b/meta-oe/recipes-support/logwarn/logwarn_1.0.14.bb @@ -0,0 +1,46 @@ +SUMMARY = "A utility for finding interesting messages in log files" +DESCRIPTION = "Logwarn searches for interesting messages in log files, \ + where 'interesting' is defined by a user-supplied list of positive and \ + negative extended regular expressions. \ +" +HOMEPAGE = "https://github.com/archiecobbs/logwarn/wiki" +SECTION = "console/utils" + +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://COPYING;md5=3b83ef96387f14655fc854ddc3c6bd57" + +SRC_URI = "https://s3.amazonaws.com/archie-public/${BPN}/${BP}.tar.gz" + +SRC_URI[md5sum] = "e544a6230673ea54f7430bf817bb39d8" +SRC_URI[sha256sum] = "8dbfcf9b28c782ab3bddd6a620d4fb95d1b0ffcbe93276996cdc4800aa9aebd1" + +inherit autotools-brokensep + +# This directory is NOT volatile. +# +lcl_default_state_dir = "${localstatedir}/lib/logwarn" + +CFLAGS += '-DDEFAULT_STATE_DIR=\""${lcl_default_state_dir}\""' + + +# Make sure some files exist for autoreconf. +# +do_configure_prepend () { + touch ${S}/NEWS + touch ${S}/ChangeLog + touch ${S}/README +} + +# Create a directory for logfile state info, usually under /var/lib. +# +do_install_append () { + install -d ${D}${lcl_default_state_dir} +} + +# Make a package for the nagios plug-in (script). +# +PACKAGES += "${PN}-nagios" + +FILES_${PN}-nagios = "${nonarch_libdir}/nagios" + +RDEPENDS_${PN}-nagios += "bash" -- 2.11.0 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [meta-oe][PATCH 4/4] microcode-ctl: add new recipe 2017-06-09 6:40 [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl jackie.huang ` (2 preceding siblings ...) 2017-06-09 6:40 ` [meta-oe][PATCH 3/4] logwarn: " jackie.huang @ 2017-06-09 6:40 ` jackie.huang 2017-06-13 5:14 ` Martin Jansa 3 siblings, 1 reply; 7+ messages in thread From: jackie.huang @ 2017-06-09 6:40 UTC (permalink / raw) To: openembedded-devel From: Jackie Huang <jackie.huang@windriver.com> The microcode_ctl utility is a companion to the IA32 microcode driver. Signed-off-by: Jackie Huang <jackie.huang@windriver.com> --- .../0001-add-support-for-other-distributions.patch | 27 ++++++++++ .../files/0001-fix-the-help-return-code.patch | 57 ++++++++++++++++++++ .../files/fix-No-GNU_HASH-in-the-elf-binary.patch | 30 +++++++++++ .../microcode-ctl/files/microcode_ctl.service | 11 ++++ .../recipes-bsp/microcode-ctl/microcode-ctl_git.bb | 62 ++++++++++++++++++++++ 5 files changed, 187 insertions(+) create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service create mode 100755 meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch new file mode 100644 index 000000000..fe5428493 --- /dev/null +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch @@ -0,0 +1,27 @@ +Subject: [PATCH] add support for other distributions + +Upstream-Status: Inappropriate [OE specific] + +Signed-off-by: Jackie Huang <jackie.huang@windriver.com> +--- + microcode_ctl.start | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/microcode_ctl.start b/microcode_ctl.start +index 6fa9d72..e9321d0 100755 +--- a/microcode_ctl.start ++++ b/microcode_ctl.start +@@ -47,8 +47,8 @@ elif [ -f /etc/slackware-version ]; then + END=slack_end + fi + else +- echo "$0: Can't guess distribution, aborting!" +- exit 1 ++ START= ++ END= + fi + + # Lets just be sure we have a device file... +-- +2.11.0 + diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch new file mode 100644 index 000000000..cbe7755e9 --- /dev/null +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch @@ -0,0 +1,57 @@ +[PATCH] fix the help return code + +Upstream-Status: Pending + +not always return 1 when call usage(), differ the return code by user action; +if a use wants to get help information, it is normal action, should be +return 0; +if input parameter is wrong, and microcode_ctl prompts the help information, +it should be return 1; + +Signed-off-by: Roy Li <rongqing.li@windriver.com> +--- + microcode_ctl.c | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +diff --git a/microcode_ctl.c b/microcode_ctl.c +index 3f9c151..cdcdc10 100644 +--- a/microcode_ctl.c ++++ b/microcode_ctl.c +@@ -40,7 +40,6 @@ static void usage(void) + " -u upload microcode (default filename:\"%s\"\n" + " -f upload microcode from named Intel formatted file\n\n", + progname, MICROCODE_FILE_DEFAULT); +- exit(1); + } + + /* +@@ -141,6 +140,7 @@ int main(int argc, char *argv[]) + switch(c) { + case 'h': + usage(); ++ return 0; + + case 'q': + print_normal_messages=0; +@@ -168,14 +168,17 @@ int main(int argc, char *argv[]) + + case '?': + usage(); ++ return 0; + } + } + + if (upload) { + if((return_code = do_update(device, filename))) + exit(return_code); +- } else ++ } else { + usage(); ++ return 1; ++ } + + return 0; + } +-- +1.9.1 + diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch new file mode 100644 index 000000000..87d8f7dfe --- /dev/null +++ b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch @@ -0,0 +1,30 @@ +From a5d4baf79ee332cf73e5259a2568958babcdbce2 Mon Sep 17 00:00:00 2001 +From: Hongxu Jia <hongxu.jia@windriver.com> +Date: Mon, 1 Aug 2016 07:00:35 -0400 +Subject: [PATCH] fix No GNU_HASH in the elf binary + +Let recipe's LDFLAGS work in Makefile. + +Upstream-Status: Inappropriate [embedded specific] + +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 590ae7e..d4e0610 100644 +--- a/Makefile ++++ b/Makefile +@@ -37,7 +37,7 @@ RCFILETO = $(RCDIR)/$(RCHOMEDIR) + all: microcode_ctl + + microcode_ctl: microcode_ctl.c +- $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c ++ $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c $(LDFLAGS) + mkdir intel-ucode amd-ucode + tar xfz $(MICROCODE_INTEL) -C intel-ucode + tar --strip-components 1 -xf $(MICROCODE_AMD) -C amd-ucode +-- +2.8.1 + diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service new file mode 100644 index 000000000..0658ff378 --- /dev/null +++ b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service @@ -0,0 +1,11 @@ +[Unit] +Description=Apply Cpu Microcode + +[Service] +Type=forking +KillMode=process +RemainAfterExit=yes +ExecStart=@SBINDIR@/microcode_ctl -Qu + +[Install] +WantedBy=multi-user.target diff --git a/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb b/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb new file mode 100755 index 000000000..12fa5f564 --- /dev/null +++ b/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb @@ -0,0 +1,62 @@ +SUMMARY = "Microcode Control Tool" +DESCRIPTION = "The microcode_ctl utility is a companion to the IA32 microcode driver \ + The utility has two uses: \ + a) it decodes and sends new microcode to the kernel driver to be uploaded \ + to Intel IA32 family processors. (Pentium Pro, PII, Celeron, PIII, \ + Xeon, Pentium 4 etc, x86_64) \ + b) it signals the kernel driver to release any buffers it may hold \ +" +HOMEPAGE = "https://pagure.io/microcode_ctl/" +SECTION = "console/utils" + +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6" + +SRC_URI = "git://pagure.io/microcode_ctl.git;protocol=https \ + file://0001-add-support-for-other-distributions.patch \ + file://0001-fix-the-help-return-code.patch \ + file://fix-No-GNU_HASH-in-the-elf-binary.patch \ + file://microcode_ctl.service \ + " + +SRCREV = "8c8ae77e661bdba298f256948867d5a619bf1588" + +# DO NOT use the v2.x which is in the obsolete branch +PV = "v1.34+git${SRCREV}" + +S = "${WORKDIR}/git" + +inherit update-rc.d systemd + +INITSCRIPT_PACKAGES = "microcode-ctl" +INITSCRIPT_NAME_microcode-ctl = "microcode_ctl" +INITSCRIPT_PARAMS_microcode-ctl = "start 80 2 3 4 5 . stop 20 0 1 6 ." + +SYSTEMD_SERVICE_${PN} = "microcode_ctl.service" + +COMPATIBLE_HOST = "(i.86|x86_64).*-linux" + +FIRMWARE_DIR = "${nonarch_base_libdir}/firmware" + +EXTRA_OEMAKE = "'CC=${CC}' \ + 'CFLAGS+=-Wall -I${STAGING_KERNEL_DIR}/include' \ + " + +do_install() { + oe_runmake install DESTDIR=${D} PREFIX=${prefix} + rm -rf ${D}${FIRMWARE_DIR}/amd-ucode + + install -d ${D}${systemd_system_unitdir} + install -D -m 0644 ${WORKDIR}/microcode_ctl.service ${D}${systemd_system_unitdir}/microcode_ctl.service + sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_system_unitdir}/microcode_ctl.service +} + +# do_populate_sysroot is not needed for this package, +# otherwise, it will conflict with the linux-firmware, +do_populate_sysroot[noexec] = "1" + +PACKAGES += "${PN}-firmware" + +FILES_${PN}-firmware = "${FIRMWARE_DIR}/microcode.dat" + +RDEPENDS_${PN} = "${PN}-firmware bash" -- 2.11.0 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [meta-oe][PATCH 4/4] microcode-ctl: add new recipe 2017-06-09 6:40 ` [meta-oe][PATCH 4/4] microcode-ctl: " jackie.huang @ 2017-06-13 5:14 ` Martin Jansa 2017-06-13 7:34 ` Huang, Jie (Jackie) 0 siblings, 1 reply; 7+ messages in thread From: Martin Jansa @ 2017-06-13 5:14 UTC (permalink / raw) To: jackie.huang; +Cc: openembedded-devel [-- Attachment #1: Type: text/plain, Size: 11337 bytes --] On Fri, Jun 09, 2017 at 02:40:33PM +0800, jackie.huang@windriver.com wrote: > From: Jackie Huang <jackie.huang@windriver.com> > > The microcode_ctl utility is a companion to the > IA32 microcode driver. > > Signed-off-by: Jackie Huang <jackie.huang@windriver.com> > --- > .../0001-add-support-for-other-distributions.patch | 27 ++++++++++ > .../files/0001-fix-the-help-return-code.patch | 57 ++++++++++++++++++++ > .../files/fix-No-GNU_HASH-in-the-elf-binary.patch | 30 +++++++++++ > .../microcode-ctl/files/microcode_ctl.service | 11 ++++ > .../recipes-bsp/microcode-ctl/microcode-ctl_git.bb | 62 ++++++++++++++++++++++ > 5 files changed, 187 insertions(+) > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > create mode 100755 meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch > new file mode 100644 > index 000000000..fe5428493 > --- /dev/null > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other-distributions.patch > @@ -0,0 +1,27 @@ > +Subject: [PATCH] add support for other distributions > + > +Upstream-Status: Inappropriate [OE specific] > + > +Signed-off-by: Jackie Huang <jackie.huang@windriver.com> > +--- > + microcode_ctl.start | 4 ++-- > + 1 file changed, 2 insertions(+), 2 deletions(-) > + > +diff --git a/microcode_ctl.start b/microcode_ctl.start > +index 6fa9d72..e9321d0 100755 > +--- a/microcode_ctl.start > ++++ b/microcode_ctl.start > +@@ -47,8 +47,8 @@ elif [ -f /etc/slackware-version ]; then > + END=slack_end > + fi > + else > +- echo "$0: Can't guess distribution, aborting!" > +- exit 1 > ++ START= > ++ END= > + fi > + > + # Lets just be sure we have a device file... > +-- > +2.11.0 > + > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch > new file mode 100644 > index 000000000..cbe7755e9 > --- /dev/null > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return-code.patch > @@ -0,0 +1,57 @@ > +[PATCH] fix the help return code > + > +Upstream-Status: Pending > + > +not always return 1 when call usage(), differ the return code by user action; > +if a use wants to get help information, it is normal action, should be > +return 0; > +if input parameter is wrong, and microcode_ctl prompts the help information, > +it should be return 1; > + > +Signed-off-by: Roy Li <rongqing.li@windriver.com> > +--- > + microcode_ctl.c | 7 +++++-- > + 1 file changed, 5 insertions(+), 2 deletions(-) > + > +diff --git a/microcode_ctl.c b/microcode_ctl.c > +index 3f9c151..cdcdc10 100644 > +--- a/microcode_ctl.c > ++++ b/microcode_ctl.c > +@@ -40,7 +40,6 @@ static void usage(void) > + " -u upload microcode (default filename:\"%s\"\n" > + " -f upload microcode from named Intel formatted file\n\n", > + progname, MICROCODE_FILE_DEFAULT); > +- exit(1); > + } > + > + /* > +@@ -141,6 +140,7 @@ int main(int argc, char *argv[]) > + switch(c) { > + case 'h': > + usage(); > ++ return 0; > + > + case 'q': > + print_normal_messages=0; > +@@ -168,14 +168,17 @@ int main(int argc, char *argv[]) > + > + case '?': > + usage(); > ++ return 0; > + } > + } > + > + if (upload) { > + if((return_code = do_update(device, filename))) > + exit(return_code); > +- } else > ++ } else { > + usage(); > ++ return 1; > ++ } > + > + return 0; > + } > +-- > +1.9.1 > + > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch > new file mode 100644 > index 000000000..87d8f7dfe > --- /dev/null > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf-binary.patch > @@ -0,0 +1,30 @@ > +From a5d4baf79ee332cf73e5259a2568958babcdbce2 Mon Sep 17 00:00:00 2001 > +From: Hongxu Jia <hongxu.jia@windriver.com> > +Date: Mon, 1 Aug 2016 07:00:35 -0400 > +Subject: [PATCH] fix No GNU_HASH in the elf binary > + > +Let recipe's LDFLAGS work in Makefile. > + > +Upstream-Status: Inappropriate [embedded specific] > + > +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> > +--- > + Makefile | 2 +- > + 1 file changed, 1 insertion(+), 1 deletion(-) > + > +diff --git a/Makefile b/Makefile > +index 590ae7e..d4e0610 100644 > +--- a/Makefile > ++++ b/Makefile > +@@ -37,7 +37,7 @@ RCFILETO = $(RCDIR)/$(RCHOMEDIR) > + all: microcode_ctl > + > + microcode_ctl: microcode_ctl.c > +- $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c > ++ $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c $(LDFLAGS) > + mkdir intel-ucode amd-ucode > + tar xfz $(MICROCODE_INTEL) -C intel-ucode > + tar --strip-components 1 -xf $(MICROCODE_AMD) -C amd-ucode > +-- > +2.8.1 > + > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > new file mode 100644 > index 000000000..0658ff378 > --- /dev/null > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > @@ -0,0 +1,11 @@ > +[Unit] > +Description=Apply Cpu Microcode > + > +[Service] > +Type=forking > +KillMode=process > +RemainAfterExit=yes > +ExecStart=@SBINDIR@/microcode_ctl -Qu > + > +[Install] > +WantedBy=multi-user.target > diff --git a/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb b/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb > new file mode 100755 > index 000000000..12fa5f564 > --- /dev/null > +++ b/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb > @@ -0,0 +1,62 @@ > +SUMMARY = "Microcode Control Tool" > +DESCRIPTION = "The microcode_ctl utility is a companion to the IA32 microcode driver \ > + The utility has two uses: \ > + a) it decodes and sends new microcode to the kernel driver to be uploaded \ > + to Intel IA32 family processors. (Pentium Pro, PII, Celeron, PIII, \ > + Xeon, Pentium 4 etc, x86_64) \ > + b) it signals the kernel driver to release any buffers it may hold \ > +" > +HOMEPAGE = "https://pagure.io/microcode_ctl/" > +SECTION = "console/utils" > + > +LICENSE = "GPLv2" > +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6" There is no indication about the license in the repository? > +SRC_URI = "git://pagure.io/microcode_ctl.git;protocol=https \ > + file://0001-add-support-for-other-distributions.patch \ > + file://0001-fix-the-help-return-code.patch \ > + file://fix-No-GNU_HASH-in-the-elf-binary.patch \ > + file://microcode_ctl.service \ > + " > + > +SRCREV = "8c8ae77e661bdba298f256948867d5a619bf1588" > + > +# DO NOT use the v2.x which is in the obsolete branch > +PV = "v1.34+git${SRCREV}" > + > +S = "${WORKDIR}/git" > + > +inherit update-rc.d systemd > + > +INITSCRIPT_PACKAGES = "microcode-ctl" > +INITSCRIPT_NAME_microcode-ctl = "microcode_ctl" > +INITSCRIPT_PARAMS_microcode-ctl = "start 80 2 3 4 5 . stop 20 0 1 6 ." > + > +SYSTEMD_SERVICE_${PN} = "microcode_ctl.service" > + > +COMPATIBLE_HOST = "(i.86|x86_64).*-linux" > + > +FIRMWARE_DIR = "${nonarch_base_libdir}/firmware" > + > +EXTRA_OEMAKE = "'CC=${CC}' \ > + 'CFLAGS+=-Wall -I${STAGING_KERNEL_DIR}/include' \ > + " I don't see kernel in DEPENDS and this MACHINE specific variable causes: === Comparing signatures for task do_configure.sigdata between qemux86copy and qemux86 === ERROR: microcode-ctl different signature for task do_configure.sigdata between qemux86copy and qemux86 basehash changed from 9d921f4621d8cd18acd74d559a452755 to 9d45e86d0e1b32712658581b752e0e8c Variable MACHINE value changed from 'qemux86copy' to 'qemux86' ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate-diff/1497333018/signatures.qemux86.do_configure.sigdata.log === Comparing signatures for task do_populate_sysroot.sigdata between qemux86copy and qemux86 === ERROR: microcode-ctl different signature for task do_populate_sysroot.sigdata between qemux86copy and qemux86 runtaskdeps changed: microcode-ctl/microcode-ctl_git.bb.do_install with hash e21ec08f024dad0c8c16f78d5f3e7677 changed to microcode-ctl/microcode-ctl_git.bb.do_install with hash f86df62ab78761dcb0bbcb94c45c6872 Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_install changed from e21ec08f024dad0c8c16f78d5f3e7677 to f86df62ab78761dcb0bbcb94c45c6872 ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate-diff/1497333018/signatures.qemux86.do_populate_sysroot.sigdata.log === Comparing signatures for task do_package_write_ipk.sigdata between qemux86copy and qemux86 === ERROR: microcode-ctl different signature for task do_package_write_ipk.sigdata between qemux86copy and qemux86 runtaskdeps changed: microcode-ctl/microcode-ctl_git.bb.do_package with hash 98d64d16e53c5f53e53299f55b5667ae changed to microcode-ctl/microcode-ctl_git.bb.do_package with hash c3d694be45ffd4fdb8c5a617f4cdeb5d microcode-ctl/microcode-ctl_git.bb.do_packagedata with hash 57a09030b203208086363b7d4f88735e changed to microcode-ctl/microcode-ctl_git.bb.do_packagedata with hash 87f202cce6bacbcf0c7128ab55d7c6c5 Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_package changed from 98d64d16e53c5f53e53299f55b5667ae to c3d694be45ffd4fdb8c5a617f4cdeb5d Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_packagedata changed from 57a09030b203208086363b7d4f88735e to 87f202cce6bacbcf0c7128ab55d7c6c5 ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate-diff/1497333018/signatures.qemux86.do_package_write_ipk.sigdata.log > + > +do_install() { > + oe_runmake install DESTDIR=${D} PREFIX=${prefix} > + rm -rf ${D}${FIRMWARE_DIR}/amd-ucode > + > + install -d ${D}${systemd_system_unitdir} > + install -D -m 0644 ${WORKDIR}/microcode_ctl.service ${D}${systemd_system_unitdir}/microcode_ctl.service > + sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_system_unitdir}/microcode_ctl.service > +} > + > +# do_populate_sysroot is not needed for this package, > +# otherwise, it will conflict with the linux-firmware, > +do_populate_sysroot[noexec] = "1" > + > +PACKAGES += "${PN}-firmware" > + > +FILES_${PN}-firmware = "${FIRMWARE_DIR}/microcode.dat" > + > +RDEPENDS_${PN} = "${PN}-firmware bash" > -- > 2.11.0 > > -- > _______________________________________________ > Openembedded-devel mailing list > Openembedded-devel@lists.openembedded.org > http://lists.openembedded.org/mailman/listinfo/openembedded-devel -- Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 201 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [meta-oe][PATCH 4/4] microcode-ctl: add new recipe 2017-06-13 5:14 ` Martin Jansa @ 2017-06-13 7:34 ` Huang, Jie (Jackie) 0 siblings, 0 replies; 7+ messages in thread From: Huang, Jie (Jackie) @ 2017-06-13 7:34 UTC (permalink / raw) To: Martin Jansa; +Cc: openembedded-devel@lists.openembedded.org > -----Original Message----- > From: Martin Jansa [mailto:martin.jansa@gmail.com] > Sent: Tuesday, June 13, 2017 13:14 > To: Huang, Jie (Jackie) > Cc: openembedded-devel@lists.openembedded.org > Subject: Re: [oe] [meta-oe][PATCH 4/4] microcode-ctl: add new recipe > > On Fri, Jun 09, 2017 at 02:40:33PM +0800, jackie.huang@windriver.com wrote: > > From: Jackie Huang <jackie.huang@windriver.com> > > > > The microcode_ctl utility is a companion to the > > IA32 microcode driver. > > > > Signed-off-by: Jackie Huang <jackie.huang@windriver.com> > > --- > > .../0001-add-support-for-other-distributions.patch | 27 ++++++++++ > > .../files/0001-fix-the-help-return-code.patch | 57 ++++++++++++++++++++ > > .../files/fix-No-GNU_HASH-in-the-elf-binary.patch | 30 +++++++++++ > > .../microcode-ctl/files/microcode_ctl.service | 11 ++++ > > .../recipes-bsp/microcode-ctl/microcode-ctl_git.bb | 62 > ++++++++++++++++++++++ > > 5 files changed, 187 insertions(+) > > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-add- > support-for-other-distributions.patch > > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the- > help-return-code.patch > > create mode 100644 meta-oe/recipes-bsp/microcode-ctl/files/fix-No- > GNU_HASH-in-the-elf-binary.patch > > create mode 100644 meta-oe/recipes-bsp/microcode- > ctl/files/microcode_ctl.service > > create mode 100755 meta-oe/recipes-bsp/microcode-ctl/microcode- > ctl_git.bb > > > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for- > other-distributions.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add- > support-for-other-distributions.patch > > new file mode 100644 > > index 000000000..fe5428493 > > --- /dev/null > > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-add-support-for-other- > distributions.patch > > @@ -0,0 +1,27 @@ > > +Subject: [PATCH] add support for other distributions > > + > > +Upstream-Status: Inappropriate [OE specific] > > + > > +Signed-off-by: Jackie Huang <jackie.huang@windriver.com> > > +--- > > + microcode_ctl.start | 4 ++-- > > + 1 file changed, 2 insertions(+), 2 deletions(-) > > + > > +diff --git a/microcode_ctl.start b/microcode_ctl.start > > +index 6fa9d72..e9321d0 100755 > > +--- a/microcode_ctl.start > > ++++ b/microcode_ctl.start > > +@@ -47,8 +47,8 @@ elif [ -f /etc/slackware-version ]; then > > + END=slack_end > > + fi > > + else > > +- echo "$0: Can't guess distribution, aborting!" > > +- exit 1 > > ++ START= > > ++ END= > > + fi > > + > > + # Lets just be sure we have a device file... > > +-- > > +2.11.0 > > + > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return- > code.patch b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help- > return-code.patch > > new file mode 100644 > > index 000000000..cbe7755e9 > > --- /dev/null > > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/0001-fix-the-help-return- > code.patch > > @@ -0,0 +1,57 @@ > > +[PATCH] fix the help return code > > + > > +Upstream-Status: Pending > > + > > +not always return 1 when call usage(), differ the return code by user action; > > +if a use wants to get help information, it is normal action, should be > > +return 0; > > +if input parameter is wrong, and microcode_ctl prompts the help information, > > +it should be return 1; > > + > > +Signed-off-by: Roy Li <rongqing.li@windriver.com> > > +--- > > + microcode_ctl.c | 7 +++++-- > > + 1 file changed, 5 insertions(+), 2 deletions(-) > > + > > +diff --git a/microcode_ctl.c b/microcode_ctl.c > > +index 3f9c151..cdcdc10 100644 > > +--- a/microcode_ctl.c > > ++++ b/microcode_ctl.c > > +@@ -40,7 +40,6 @@ static void usage(void) > > + " -u upload microcode (default filename:\"%s\"\n" > > + " -f upload microcode from named Intel formatted > file\n\n", > > + progname, MICROCODE_FILE_DEFAULT); > > +- exit(1); > > + } > > + > > + /* > > +@@ -141,6 +140,7 @@ int main(int argc, char *argv[]) > > + switch(c) { > > + case 'h': > > + usage(); > > ++ return 0; > > + > > + case 'q': > > + print_normal_messages=0; > > +@@ -168,14 +168,17 @@ int main(int argc, char *argv[]) > > + > > + case '?': > > + usage(); > > ++ return 0; > > + } > > + } > > + > > + if (upload) { > > + if((return_code = do_update(device, filename))) > > + exit(return_code); > > +- } else > > ++ } else { > > + usage(); > > ++ return 1; > > ++ } > > + > > + return 0; > > + } > > +-- > > +1.9.1 > > + > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in- > the-elf-binary.patch b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No- > GNU_HASH-in-the-elf-binary.patch > > new file mode 100644 > > index 000000000..87d8f7dfe > > --- /dev/null > > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/fix-No-GNU_HASH-in-the-elf- > binary.patch > > @@ -0,0 +1,30 @@ > > +From a5d4baf79ee332cf73e5259a2568958babcdbce2 Mon Sep 17 00:00:00 > 2001 > > +From: Hongxu Jia <hongxu.jia@windriver.com> > > +Date: Mon, 1 Aug 2016 07:00:35 -0400 > > +Subject: [PATCH] fix No GNU_HASH in the elf binary > > + > > +Let recipe's LDFLAGS work in Makefile. > > + > > +Upstream-Status: Inappropriate [embedded specific] > > + > > +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> > > +--- > > + Makefile | 2 +- > > + 1 file changed, 1 insertion(+), 1 deletion(-) > > + > > +diff --git a/Makefile b/Makefile > > +index 590ae7e..d4e0610 100644 > > +--- a/Makefile > > ++++ b/Makefile > > +@@ -37,7 +37,7 @@ RCFILETO = $(RCDIR)/$(RCHOMEDIR) > > + all: microcode_ctl > > + > > + microcode_ctl: microcode_ctl.c > > +- $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c > > ++ $(CC) $(CFLAGS) -o $(PROGRAM) microcode_ctl.c $(LDFLAGS) > > + mkdir intel-ucode amd-ucode > > + tar xfz $(MICROCODE_INTEL) -C intel-ucode > > + tar --strip-components 1 -xf $(MICROCODE_AMD) -C amd-ucode > > +-- > > +2.8.1 > > + > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > > new file mode 100644 > > index 000000000..0658ff378 > > --- /dev/null > > +++ b/meta-oe/recipes-bsp/microcode-ctl/files/microcode_ctl.service > > @@ -0,0 +1,11 @@ > > +[Unit] > > +Description=Apply Cpu Microcode > > + > > +[Service] > > +Type=forking > > +KillMode=process > > +RemainAfterExit=yes > > +ExecStart=@SBINDIR@/microcode_ctl -Qu > > + > > +[Install] > > +WantedBy=multi-user.target > > diff --git a/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb b/meta- > oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb > > new file mode 100755 > > index 000000000..12fa5f564 > > --- /dev/null > > +++ b/meta-oe/recipes-bsp/microcode-ctl/microcode-ctl_git.bb > > @@ -0,0 +1,62 @@ > > +SUMMARY = "Microcode Control Tool" > > +DESCRIPTION = "The microcode_ctl utility is a companion to the IA32 > microcode driver \ > > + The utility has two uses: \ > > + a) it decodes and sends new microcode to the kernel driver to be uploaded \ > > + to Intel IA32 family processors. (Pentium Pro, PII, Celeron, PIII, \ > > + Xeon, Pentium 4 etc, x86_64) \ > > + b) it signals the kernel driver to release any buffers it may hold \ > > +" > > +HOMEPAGE = "https://pagure.io/microcode_ctl/" > > +SECTION = "console/utils" > > + > > +LICENSE = "GPLv2" > > +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL- > 2.0;md5=801f80980d171dd6425610833a22dbe6" > > There is no indication about the license in the repository? Sorry I didn't check that when I moved it from our internal layer and sent here. Yes, there is license info in the source repo, I will fix it soon and send v2. > > > +SRC_URI = "git://pagure.io/microcode_ctl.git;protocol=https \ > > + file://0001-add-support-for-other-distributions.patch \ > > + file://0001-fix-the-help-return-code.patch \ > > + file://fix-No-GNU_HASH-in-the-elf-binary.patch \ > > + file://microcode_ctl.service \ > > + " > > + > > +SRCREV = "8c8ae77e661bdba298f256948867d5a619bf1588" > > + > > +# DO NOT use the v2.x which is in the obsolete branch > > +PV = "v1.34+git${SRCREV}" > > + > > +S = "${WORKDIR}/git" > > + > > +inherit update-rc.d systemd > > + > > +INITSCRIPT_PACKAGES = "microcode-ctl" > > +INITSCRIPT_NAME_microcode-ctl = "microcode_ctl" > > +INITSCRIPT_PARAMS_microcode-ctl = "start 80 2 3 4 5 . stop 20 0 1 6 ." > > + > > +SYSTEMD_SERVICE_${PN} = "microcode_ctl.service" > > + > > +COMPATIBLE_HOST = "(i.86|x86_64).*-linux" > > + > > +FIRMWARE_DIR = "${nonarch_base_libdir}/firmware" > > + > > +EXTRA_OEMAKE = "'CC=${CC}' \ > > + 'CFLAGS+=-Wall -I${STAGING_KERNEL_DIR}/include' \ > > + " > > I don't see kernel in DEPENDS and this MACHINE specific variable causes: Thanks for pointing this out, I will investigate and fix it in v2. Thanks, Jackie > > === Comparing signatures for task do_configure.sigdata between qemux86copy > and qemux86 === > ERROR: microcode-ctl different signature for task do_configure.sigdata > between qemux86copy and qemux86 > basehash changed from 9d921f4621d8cd18acd74d559a452755 to > 9d45e86d0e1b32712658581b752e0e8c > Variable MACHINE value changed from 'qemux86copy' to 'qemux86' > > ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate- > diff/1497333018/signatures.qemux86.do_configure.sigdata.log > > > === Comparing signatures for task do_populate_sysroot.sigdata between > qemux86copy and qemux86 === > ERROR: microcode-ctl different signature for task do_populate_sysroot.sigdata > between qemux86copy and qemux86 > runtaskdeps changed: > microcode-ctl/microcode-ctl_git.bb.do_install with hash > e21ec08f024dad0c8c16f78d5f3e7677 > changed to > microcode-ctl/microcode-ctl_git.bb.do_install with hash > f86df62ab78761dcb0bbcb94c45c6872 > Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_install changed > from e21ec08f024dad0c8c16f78d5f3e7677 to > f86df62ab78761dcb0bbcb94c45c6872 > > ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate- > diff/1497333018/signatures.qemux86.do_populate_sysroot.sigdata.log > > > === Comparing signatures for task do_package_write_ipk.sigdata between > qemux86copy and qemux86 === > ERROR: microcode-ctl different signature for task > do_package_write_ipk.sigdata between qemux86copy and qemux86 > runtaskdeps changed: > microcode-ctl/microcode-ctl_git.bb.do_package with hash > 98d64d16e53c5f53e53299f55b5667ae > changed to > microcode-ctl/microcode-ctl_git.bb.do_package with hash > c3d694be45ffd4fdb8c5a617f4cdeb5d > microcode-ctl/microcode-ctl_git.bb.do_packagedata with hash > 57a09030b203208086363b7d4f88735e > changed to > microcode-ctl/microcode-ctl_git.bb.do_packagedata with hash > 87f202cce6bacbcf0c7128ab55d7c6c5 > Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_package > changed from 98d64d16e53c5f53e53299f55b5667ae to > c3d694be45ffd4fdb8c5a617f4cdeb5d > Hash for dependent task microcode-ctl/microcode-ctl_git.bb.do_packagedata > changed from 57a09030b203208086363b7d4f88735e to > 87f202cce6bacbcf0c7128ab55d7c6c5 > > ERROR: 1 errors found in /home/jenkins/oe/world/shr-core/tmp-glibc/sstate- > diff/1497333018/signatures.qemux86.do_package_write_ipk.sigdata.log > > > + > > +do_install() { > > + oe_runmake install DESTDIR=${D} PREFIX=${prefix} > > + rm -rf ${D}${FIRMWARE_DIR}/amd-ucode > > + > > + install -d ${D}${systemd_system_unitdir} > > + install -D -m 0644 ${WORKDIR}/microcode_ctl.service > ${D}${systemd_system_unitdir}/microcode_ctl.service > > + sed -i -e 's,@SBINDIR@,${sbindir},g' > ${D}${systemd_system_unitdir}/microcode_ctl.service > > +} > > + > > +# do_populate_sysroot is not needed for this package, > > +# otherwise, it will conflict with the linux-firmware, > > +do_populate_sysroot[noexec] = "1" > > + > > +PACKAGES += "${PN}-firmware" > > + > > +FILES_${PN}-firmware = "${FIRMWARE_DIR}/microcode.dat" > > + > > +RDEPENDS_${PN} = "${PN}-firmware bash" > > -- > > 2.11.0 > > > > -- > > _______________________________________________ > > Openembedded-devel mailing list > > Openembedded-devel@lists.openembedded.org > > http://lists.openembedded.org/mailman/listinfo/openembedded-devel > > -- > Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2017-06-13 7:34 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-06-09 6:40 [meta-oe][PATCH 0/4] add new recipes: agent-proxy, enscript, logwarn and microcode-ctl jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 1/4] agent-proxy: add new recipe jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 2/4] enscript: " jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 3/4] logwarn: " jackie.huang 2017-06-09 6:40 ` [meta-oe][PATCH 4/4] microcode-ctl: " jackie.huang 2017-06-13 5:14 ` Martin Jansa 2017-06-13 7:34 ` Huang, Jie (Jackie)
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox