Patchwork ltp: Add patch to correct failing build

login
register
mail settings
Submitter Cristian Iorga
Date June 5, 2012, 6:51 p.m.
Message ID <1338922277-26222-1-git-send-email-cristian.iorga@intel.com>
Download mbox | patch
Permalink /patch/29243/
State Accepted
Commit 13e52fafae0fb06b26d179a5cac6898babbadc51
Headers show

Comments

Cristian Iorga - June 5, 2012, 6:51 p.m.
ltp makefile does not interpret correctly the result of git describe
command and assumes that it is working with a git repo, while in fact
working with a source code archive.
Added a patch to corect makefile system.

Signed-off-by: Cristian Iorga <cristian.iorga@intel.com>
---
 .../ltp/ltp/fix_building_fom_archive.patch         |   13 +++++++++++++
 meta/recipes-extended/ltp/ltp_20120401.bb          |    4 ++--
 2 files changed, 15 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-extended/ltp/ltp/fix_building_fom_archive.patch
Richard Purdie - June 5, 2012, 10:01 p.m.
On Tue, 2012-06-05 at 21:51 +0300, Cristian Iorga wrote:
> ltp makefile does not interpret correctly the result of git describe
> command and assumes that it is working with a git repo, while in fact
> working with a source code archive.
> Added a patch to corect makefile system.
> 
> Signed-off-by: Cristian Iorga <cristian.iorga@intel.com>
> ---
>  .../ltp/ltp/fix_building_fom_archive.patch         |   13 +++++++++++++
>  meta/recipes-extended/ltp/ltp_20120401.bb          |    4 ++--
>  2 files changed, 15 insertions(+), 2 deletions(-)
>  create mode 100644 meta/recipes-extended/ltp/ltp/fix_building_fom_archive.patch

Merged to master, thanks.

Richard

Patch

diff --git a/meta/recipes-extended/ltp/ltp/fix_building_fom_archive.patch b/meta/recipes-extended/ltp/ltp/fix_building_fom_archive.patch
new file mode 100644
index 0000000..a8064cf
--- /dev/null
+++ b/meta/recipes-extended/ltp/ltp/fix_building_fom_archive.patch
@@ -0,0 +1,13 @@ 
+Index: ltp-20120401/Makefile
+===================================================================
+--- ltp-20120401.orig/Makefile
++++ ltp-20120401/Makefile
+@@ -173,7 +173,7 @@ SRCDIR_INSTALL_TARGETS	:= $(SRCDIR_INSTA
+ #
+ .PHONY: Version
+ Version:
+-	if git describe &> /dev/null; then \
++	if git describe > /dev/null 2>&1; then \
+ 		git describe > "$@"; \
+ 	else \
+ 		cp VERSION "$@"; \
diff --git a/meta/recipes-extended/ltp/ltp_20120401.bb b/meta/recipes-extended/ltp/ltp_20120401.bb
index 912d6d9..563bd58 100644
--- a/meta/recipes-extended/ltp/ltp_20120401.bb
+++ b/meta/recipes-extended/ltp/ltp_20120401.bb
@@ -21,10 +21,10 @@  LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
 
 DEPENDS = "attr"
 
-PR = "r3"
+PR = "r4"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/ltp/ltp-full-${PV}.bz2 \
-          "
+           file://fix_building_fom_archive.patch"
 
 SRC_URI[md5sum] = "e1d0acf1a6b6da0cb30dc1b0dcf5f26d"
 SRC_URI[sha256sum] = "f0f5845f9666f61332fdf0b7e396fc647f9372db0902a829af2cf9402b807bd1"