* [ptxdist] [PATCH] Add sp-oops-extract package
@ 2012-03-21 15:24 bernhard
2012-03-24 9:50 ` Michael Olbrich
0 siblings, 1 reply; 3+ messages in thread
From: bernhard @ 2012-03-21 15:24 UTC (permalink / raw)
To: ptxdist; +Cc: Bernhard Walle
From: Bernhard Walle <walle@corscience.de>
sp-oops-extract is a simple userspace program to extract kernel oopses
saved on raw MTD with the CONFIG_MTD_OOPS driver. See the comment in
Kconfig for more information on how to use the driver/the tool.
Signed-off-by: Bernhard Walle <walle@corscience.de>
---
...the-Makefile-more-cross-compiler-friendly.patch | 19 +++++++
| 4 ++
| 15 ++++++
| 56 ++++++++++++++++++++
4 files changed, 94 insertions(+)
create mode 100644 patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
create mode 100644 patches/sp-oops-extract-0.0.7/series
create mode 100644 rules/sp-oops-extract.in
create mode 100644 rules/sp-oops-extract.make
diff --git a/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
new file mode 100644
index 0000000..df363f7
--- /dev/null
+++ b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
@@ -0,0 +1,19 @@
+From: Bernhard Walle <walle@corscience.de>
+Date: Wed, 21 Mar 2012 15:55:06 +0100
+Subject: [PATCH] Make the Makefile more cross-compiler friendly
+
+Signed-off-by: Bernhard Walle <walle@corscience.de>
+---
+ src/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index cf5b550..c221c83 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -9,4 +9,4 @@ distclean: clean
+ $(RM) $(TARGETS)
+
+ sp-oops-extract: oopslog.c
+- gcc -Wall -s -o $@ $^
++ $(CROSS_COMPILE)$(CC) -Wall -s -o $@ $^
--git a/patches/sp-oops-extract-0.0.7/series b/patches/sp-oops-extract-0.0.7/series
new file mode 100644
index 0000000..6053a64
--- /dev/null
+++ b/patches/sp-oops-extract-0.0.7/series
@@ -0,0 +1,4 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-Make-the-Makefile-more-cross-compiler-friendly.patch
+# 1e23689ed7181ffae1913ee9c0c2db54 - git-ptx-patches magic
--git a/rules/sp-oops-extract.in b/rules/sp-oops-extract.in
new file mode 100644
index 0000000..fea83a5
--- /dev/null
+++ b/rules/sp-oops-extract.in
@@ -0,0 +1,15 @@
+## SECTION=debug_tools
+
+config SP_OOPS_EXTRACT
+ tristate
+ prompt "sp-oops-extract"
+ help
+ Tool to extract oopses generated with mtd-oops.ko driver.
+
+ To use that mechanism, just select CONFIG_MTD_OOPS in the kernel
+ configuration and add 'mtdoops.mtddev=<devno>' to your boot command
+ line where '<devno>' is the MTD device number you want to use to save
+ kernel oopses. Alternatively, load the 'mtdoops' module with
+ 'mtddev=<devno>' as module parameter. To extract that oops, just use
+ 'sp-oops-extract /dev/mtd<devno>'.
+
--git a/rules/sp-oops-extract.make b/rules/sp-oops-extract.make
new file mode 100644
index 0000000..265bcdf
--- /dev/null
+++ b/rules/sp-oops-extract.make
@@ -0,0 +1,56 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2012 by Bernhard Walle <walle@corscience.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_SP_OOPS_EXTRACT) += sp-oops-extract
+
+#
+# Paths and names
+#
+SP_OOPS_EXTRACT_VERSION := 0.0.7
+SP_OOPS_EXTRACT_MD5 := b4e3ff7716c249e3446758582a1cae12
+SP_OOPS_EXTRACT := sp-oops-extract-$(SP_OOPS_EXTRACT_VERSION)
+SP_OOPS_EXTRACT_SUFFIX := tar.gz
+SP_OOPS_EXTRACT_ARCHIVE := sp-oops-extract_$(SP_OOPS_EXTRACT_VERSION)-1.$(SP_OOPS_EXTRACT_SUFFIX)
+SP_OOPS_EXTRACT_URL := http://repository.maemo.org/pool/fremantle/free/s/sp-oops-extract/$(SP_OOPS_EXTRACT_ARCHIVE)
+SP_OOPS_EXTRACT_SOURCE := $(SRCDIR)/$(SP_OOPS_EXTRACT_ARCHIVE)
+SP_OOPS_EXTRACT_DIR := $(BUILDDIR)/$(SP_OOPS_EXTRACT)
+SP_OOPS_EXTRACT_LICENSE := unknown
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+SP_OOPS_EXTRACT_CONF_TOOL := NO
+SP_OOPS_EXTRACT_MAKE_ENV := $(CROSS_ENV)
+SP_OOPS_EXTRACT_MAKEVARS := $(CROSS_ENV)
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/sp-oops-extract.targetinstall:
+ @$(call targetinfo)
+
+ @$(call install_init, sp-oops-extract)
+ @$(call install_fixup, sp-oops-extract,PRIORITY,optional)
+ @$(call install_fixup, sp-oops-extract,SECTION,base)
+ @$(call install_fixup, sp-oops-extract,AUTHOR,"Bernhard Walle <walle@corscience.de>")
+ @$(call install_fixup, sp-oops-extract,DESCRIPTION,missing)
+
+ @$(call install_copy, sp-oops-extract, 0, 0, 0755, -, /usr/bin/sp-oops-extract)
+
+ @$(call install_finish, sp-oops-extract)
+
+ @$(call touch)
+
+# vim: syntax=make
--
1.7.9.4
--
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [ptxdist] [PATCH] Add sp-oops-extract package
2012-03-21 15:24 [ptxdist] [PATCH] Add sp-oops-extract package bernhard
@ 2012-03-24 9:50 ` Michael Olbrich
2012-03-26 10:49 ` [ptxdist] [PATCH v2] " Bernhard Walle
0 siblings, 1 reply; 3+ messages in thread
From: Michael Olbrich @ 2012-03-24 9:50 UTC (permalink / raw)
To: ptxdist
On Wed, Mar 21, 2012 at 04:24:06PM +0100, bernhard@bwalle.de wrote:
> From: Bernhard Walle <walle@corscience.de>
>
> sp-oops-extract is a simple userspace program to extract kernel oopses
> saved on raw MTD with the CONFIG_MTD_OOPS driver. See the comment in
> Kconfig for more information on how to use the driver/the tool.
>
> Signed-off-by: Bernhard Walle <walle@corscience.de>
> ---
> ...the-Makefile-more-cross-compiler-friendly.patch | 19 +++++++
> patches/sp-oops-extract-0.0.7/series | 4 ++
> rules/sp-oops-extract.in | 15 ++++++
> rules/sp-oops-extract.make | 56 ++++++++++++++++++++
> 4 files changed, 94 insertions(+)
> create mode 100644 patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
> create mode 100644 patches/sp-oops-extract-0.0.7/series
> create mode 100644 rules/sp-oops-extract.in
> create mode 100644 rules/sp-oops-extract.make
>
> diff --git a/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
> new file mode 100644
> index 0000000..df363f7
> --- /dev/null
> +++ b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
> @@ -0,0 +1,19 @@
> +From: Bernhard Walle <walle@corscience.de>
> +Date: Wed, 21 Mar 2012 15:55:06 +0100
> +Subject: [PATCH] Make the Makefile more cross-compiler friendly
> +
> +Signed-off-by: Bernhard Walle <walle@corscience.de>
> +---
> + src/Makefile | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/src/Makefile b/src/Makefile
> +index cf5b550..c221c83 100644
> +--- a/src/Makefile
> ++++ b/src/Makefile
> +@@ -9,4 +9,4 @@ distclean: clean
> + $(RM) $(TARGETS)
> +
> + sp-oops-extract: oopslog.c
> +- gcc -Wall -s -o $@ $^
> ++ $(CROSS_COMPILE)$(CC) -Wall -s -o $@ $^
sp-oops-extract: oopslog.o
$(CC) $(LDFLAGS) -Wall -o $@ $^
CROSS_COMPILE is not defined and CC already is the cross-compiler. And by
depending on oopslog.o CFLAGS etc. are used correctly.
> diff --git a/patches/sp-oops-extract-0.0.7/series b/patches/sp-oops-extract-0.0.7/series
> new file mode 100644
> index 0000000..6053a64
> --- /dev/null
> +++ b/patches/sp-oops-extract-0.0.7/series
> @@ -0,0 +1,4 @@
> +# generated by git-ptx-patches
> +#tag:base --start-number 1
> +0001-Make-the-Makefile-more-cross-compiler-friendly.patch
> +# 1e23689ed7181ffae1913ee9c0c2db54 - git-ptx-patches magic
> diff --git a/rules/sp-oops-extract.in b/rules/sp-oops-extract.in
> new file mode 100644
> index 0000000..fea83a5
> --- /dev/null
> +++ b/rules/sp-oops-extract.in
> @@ -0,0 +1,15 @@
> +## SECTION=debug_tools
> +
> +config SP_OOPS_EXTRACT
> + tristate
> + prompt "sp-oops-extract"
> + help
> + Tool to extract oopses generated with mtd-oops.ko driver.
> +
> + To use that mechanism, just select CONFIG_MTD_OOPS in the kernel
> + configuration and add 'mtdoops.mtddev=<devno>' to your boot command
> + line where '<devno>' is the MTD device number you want to use to save
> + kernel oopses. Alternatively, load the 'mtdoops' module with
> + 'mtddev=<devno>' as module parameter. To extract that oops, just use
> + 'sp-oops-extract /dev/mtd<devno>'.
> +
> diff --git a/rules/sp-oops-extract.make b/rules/sp-oops-extract.make
> new file mode 100644
> index 0000000..265bcdf
> --- /dev/null
> +++ b/rules/sp-oops-extract.make
> @@ -0,0 +1,56 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2012 by Bernhard Walle <walle@corscience.de>
> +#
> +# See CREDITS for details about who has contributed to this project.
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_SP_OOPS_EXTRACT) += sp-oops-extract
> +
> +#
> +# Paths and names
> +#
> +SP_OOPS_EXTRACT_VERSION := 0.0.7
> +SP_OOPS_EXTRACT_MD5 := b4e3ff7716c249e3446758582a1cae12
> +SP_OOPS_EXTRACT := sp-oops-extract-$(SP_OOPS_EXTRACT_VERSION)
> +SP_OOPS_EXTRACT_SUFFIX := tar.gz
> +SP_OOPS_EXTRACT_ARCHIVE := sp-oops-extract_$(SP_OOPS_EXTRACT_VERSION)-1.$(SP_OOPS_EXTRACT_SUFFIX)
> +SP_OOPS_EXTRACT_URL := http://repository.maemo.org/pool/fremantle/free/s/sp-oops-extract/$(SP_OOPS_EXTRACT_ARCHIVE)
> +SP_OOPS_EXTRACT_SOURCE := $(SRCDIR)/$(SP_OOPS_EXTRACT_ARCHIVE)
> +SP_OOPS_EXTRACT_DIR := $(BUILDDIR)/$(SP_OOPS_EXTRACT)
> +SP_OOPS_EXTRACT_LICENSE := unknown
> +
> +# ----------------------------------------------------------------------------
> +# Prepare
> +# ----------------------------------------------------------------------------
> +
> +SP_OOPS_EXTRACT_CONF_TOOL := NO
> +SP_OOPS_EXTRACT_MAKE_ENV := $(CROSS_ENV)
> +SP_OOPS_EXTRACT_MAKEVARS := $(CROSS_ENV)
this line is unnecessary.
> +
> +# ----------------------------------------------------------------------------
> +# Target-Install
> +# ----------------------------------------------------------------------------
> +
> +$(STATEDIR)/sp-oops-extract.targetinstall:
> + @$(call targetinfo)
> +
> + @$(call install_init, sp-oops-extract)
> + @$(call install_fixup, sp-oops-extract,PRIORITY,optional)
> + @$(call install_fixup, sp-oops-extract,SECTION,base)
> + @$(call install_fixup, sp-oops-extract,AUTHOR,"Bernhard Walle <walle@corscience.de>")
> + @$(call install_fixup, sp-oops-extract,DESCRIPTION,missing)
> +
> + @$(call install_copy, sp-oops-extract, 0, 0, 0755, -, \
/usr/bin/sp-oops-extract)
break
Michael
> +
> + @$(call install_finish, sp-oops-extract)
> +
> + @$(call touch)
> +
> +# vim: syntax=make
> --
> 1.7.9.4
>
>
> --
> ptxdist mailing list
> ptxdist@pengutronix.de
>
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
--
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* [ptxdist] [PATCH v2] Add sp-oops-extract package
2012-03-24 9:50 ` Michael Olbrich
@ 2012-03-26 10:49 ` Bernhard Walle
0 siblings, 0 replies; 3+ messages in thread
From: Bernhard Walle @ 2012-03-26 10:49 UTC (permalink / raw)
To: ptxdist; +Cc: Bernhard Walle
From: Bernhard Walle <walle@corscience.de>
sp-oops-extract is a simple userspace program to extract kernel oopses
saved on raw MTD with the CONFIG_MTD_OOPS driver. See the comment in
Kconfig for more information on how to use the driver/the tool.
Signed-off-by: Bernhard Walle <walle@corscience.de>
---
v1->v2:
- Remove whitespace in rules/sp-oops-extract.in
- Add line break in rules/sp-oops-extract.make
- Remove $(CROSS_COMPILE) in patches/sp-oops-extract-0.0.7/0001*
- Add $(LDFLAGS) in patches/sp-oops-extract-0.0.7/0001*
...the-Makefile-more-cross-compiler-friendly.patch | 19 +++++++
| 4 ++
| 15 ++++++
| 56 ++++++++++++++++++++
4 files changed, 94 insertions(+)
create mode 100644 patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
create mode 100644 patches/sp-oops-extract-0.0.7/series
create mode 100644 rules/sp-oops-extract.in
create mode 100644 rules/sp-oops-extract.make
diff --git a/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
new file mode 100644
index 0000000..b5b963c
--- /dev/null
+++ b/patches/sp-oops-extract-0.0.7/0001-Make-the-Makefile-more-cross-compiler-friendly.patch
@@ -0,0 +1,19 @@
+From: Bernhard Walle <walle@corscience.de>
+Date: Wed, 21 Mar 2012 15:55:06 +0100
+Subject: [PATCH] Make the Makefile more cross-compiler friendly
+
+Signed-off-by: Bernhard Walle <walle@corscience.de>
+---
+ src/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index cf5b550..e05eb1f 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -9,4 +9,4 @@ distclean: clean
+ $(RM) $(TARGETS)
+
+ sp-oops-extract: oopslog.c
+- gcc -Wall -s -o $@ $^
++ $(CC) $(LDFLAGS) -Wall -s -o $@ $^
--git a/patches/sp-oops-extract-0.0.7/series b/patches/sp-oops-extract-0.0.7/series
new file mode 100644
index 0000000..6053a64
--- /dev/null
+++ b/patches/sp-oops-extract-0.0.7/series
@@ -0,0 +1,4 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-Make-the-Makefile-more-cross-compiler-friendly.patch
+# 1e23689ed7181ffae1913ee9c0c2db54 - git-ptx-patches magic
--git a/rules/sp-oops-extract.in b/rules/sp-oops-extract.in
new file mode 100644
index 0000000..e37b511
--- /dev/null
+++ b/rules/sp-oops-extract.in
@@ -0,0 +1,15 @@
+## SECTION=debug_tools
+
+config SP_OOPS_EXTRACT
+ tristate
+ prompt "sp-oops-extract"
+ help
+ Tool to extract oopses generated with mtd-oops.ko driver.
+
+ To use that mechanism, just select CONFIG_MTD_OOPS in the kernel
+ configuration and add 'mtdoops.mtddev=<devno>' to your boot command
+ line where '<devno>' is the MTD device number you want to use to save
+ kernel oopses. Alternatively, load the 'mtdoops' module with
+ 'mtddev=<devno>' as module parameter. To extract that oops, just use
+ 'sp-oops-extract /dev/mtd<devno>'.
+
--git a/rules/sp-oops-extract.make b/rules/sp-oops-extract.make
new file mode 100644
index 0000000..b08a496
--- /dev/null
+++ b/rules/sp-oops-extract.make
@@ -0,0 +1,56 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2012 by Bernhard Walle <walle@corscience.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_SP_OOPS_EXTRACT) += sp-oops-extract
+
+#
+# Paths and names
+#
+SP_OOPS_EXTRACT_VERSION := 0.0.7
+SP_OOPS_EXTRACT_MD5 := b4e3ff7716c249e3446758582a1cae12
+SP_OOPS_EXTRACT := sp-oops-extract-$(SP_OOPS_EXTRACT_VERSION)
+SP_OOPS_EXTRACT_SUFFIX := tar.gz
+SP_OOPS_EXTRACT_ARCHIVE := sp-oops-extract_$(SP_OOPS_EXTRACT_VERSION)-1.$(SP_OOPS_EXTRACT_SUFFIX)
+SP_OOPS_EXTRACT_URL := http://repository.maemo.org/pool/fremantle/free/s/sp-oops-extract/$(SP_OOPS_EXTRACT_ARCHIVE)
+SP_OOPS_EXTRACT_SOURCE := $(SRCDIR)/$(SP_OOPS_EXTRACT_ARCHIVE)
+SP_OOPS_EXTRACT_DIR := $(BUILDDIR)/$(SP_OOPS_EXTRACT)
+SP_OOPS_EXTRACT_LICENSE := unknown
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+SP_OOPS_EXTRACT_CONF_TOOL := NO
+SP_OOPS_EXTRACT_MAKE_ENV := $(CROSS_ENV)
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/sp-oops-extract.targetinstall:
+ @$(call targetinfo)
+
+ @$(call install_init, sp-oops-extract)
+ @$(call install_fixup, sp-oops-extract,PRIORITY,optional)
+ @$(call install_fixup, sp-oops-extract,SECTION,base)
+ @$(call install_fixup, sp-oops-extract,AUTHOR,"Bernhard Walle <walle@corscience.de>")
+ @$(call install_fixup, sp-oops-extract,DESCRIPTION,missing)
+
+ @$(call install_copy, sp-oops-extract, 0, 0, 0755, -, \
+ /usr/bin/sp-oops-extract)
+
+ @$(call install_finish, sp-oops-extract)
+
+ @$(call touch)
+
+# vim: syntax=make
--
1.7.9.4
--
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-03-26 10:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-21 15:24 [ptxdist] [PATCH] Add sp-oops-extract package bernhard
2012-03-24 9:50 ` Michael Olbrich
2012-03-26 10:49 ` [ptxdist] [PATCH v2] " Bernhard Walle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox