[ptxdist] [PATCH 1/2] fontconfig: Fix Darwin build
Upstream solved it completely different http://cgit.freedesktop.org/fontconfig/commit/?id=2a6b235ff6d2750171e8dff7cfdfe3bccb0f630e now, so after updating fontconfig the patch will be obsolete. Applying that patch is not possible, however, since I would need to re-create the tarball. However, I don't want to update fontconfig since it touches the whole Xorg stack and I have no possibility to test that. Signed-off-by: Bernhard Walle --- .../0001-Fix-build-on-Darwin.patch | 68 patches/fontconfig-2.6.0/autogen.sh|1 + patches/fontconfig-2.6.0/series|4 ++ 3 files changed, 73 insertions(+) create mode 100644 patches/fontconfig-2.6.0/0001-Fix-build-on-Darwin.patch create mode 12 patches/fontconfig-2.6.0/autogen.sh create mode 100644 patches/fontconfig-2.6.0/series diff --git a/patches/fontconfig-2.6.0/0001-Fix-build-on-Darwin.patch b/patches/fontconfig-2.6.0/0001-Fix-build-on-Darwin.patch new file mode 100644 index 000..89320dd --- /dev/null +++ b/patches/fontconfig-2.6.0/0001-Fix-build-on-Darwin.patch @@ -0,0 +1,68 @@ +From 4b0e469be28dc539dac7ec9eb504b6add37dd85a Mon Sep 17 00:00:00 2001 +From: Bernhard Walle +Date: Sun, 8 Apr 2012 17:38:20 +0200 +Subject: [PATCH] Fix build on Darwin + +The problem is the -rpath-link that is used even on host CC but this +option is not available on Mac OS. + +Signed-off-by: Bernhard Walle +--- + fc-arch/Makefile.am |2 +- + fc-case/Makefile.am |2 +- + fc-glyphname/Makefile.am |2 +- + fc-lang/Makefile.am |2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/fc-arch/Makefile.am b/fc-arch/Makefile.am +index 7e1dd3e..802c999 100644 +--- a/fc-arch/Makefile.am b/fc-arch/Makefile.am +@@ -24,7 +24,7 @@ + + CC = @CC_FOR_BUILD@ + EXEEXT = @EXEEXT_FOR_BUILD@ +-LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ ++LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) -o $@ + + INCLUDES=-I${top_srcdir}/src -I${top_srcdir} $(WARN_CFLAGS) + +diff --git a/fc-case/Makefile.am b/fc-case/Makefile.am +index d4fa12d..9ea539f 100644 +--- a/fc-case/Makefile.am b/fc-case/Makefile.am +@@ -24,7 +24,7 @@ + + CC = @CC_FOR_BUILD@ + EXEEXT = @EXEEXT_FOR_BUILD@ +-LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ ++LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) -o $@ + + INCLUDES=-I${top_srcdir}/src -I${top_srcdir} $(WARN_CFLAGS) + +diff --git a/fc-glyphname/Makefile.am b/fc-glyphname/Makefile.am +index 412d663..bd91007 100644 +--- a/fc-glyphname/Makefile.am b/fc-glyphname/Makefile.am +@@ -24,7 +24,7 @@ + + CC = @CC_FOR_BUILD@ + EXEEXT = @EXEEXT_FOR_BUILD@ +-LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ ++LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) -o $@ + + INCLUDES=-I${top_srcdir}/src -I${top_srcdir} $(WARN_CFLAGS) + +diff --git a/fc-lang/Makefile.am b/fc-lang/Makefile.am +index 60e4f31..73ff946 100644 +--- a/fc-lang/Makefile.am b/fc-lang/Makefile.am +@@ -24,7 +24,7 @@ + + CC = @CC_FOR_BUILD@ + EXEEXT = @EXEEXT_FOR_BUILD@ +-LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ ++LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) -o $@ + + INCLUDES=-I${top_srcdir}/src -I${top_srcdir} $(WARN_CFLAGS) + diff --git a/patches/fontconfig-2.6.0/autogen.sh b/patches/fontconfig-2.6.0/autogen.sh new file mode 12 index 000..9f8a4cb --- /dev/null +++ b/patches/fontconfig-2.6.0/autogen.sh @@ -0,0 +1 @@ +../autogen.sh \ No newline at end of file diff --git a/patches/fontconfig-2.6.0/series b/patches/fontconfig-2.6.0/series new file mode 100644 index 000..d9df7e0 --- /dev/null +++ b/patches/fontconfig-2.6.0/series @@ -0,0 +1,4 @@ +# generated by git-ptx-patches +#tag:base --start-number 1 +0001-Fix-build-on-Darwin.patch +# e4c948951d2fafee17a83f484c126a7e - git-ptx-patches magic -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] Darwin fixes: fontconfig and libcap
I just tested fbterm now and discovered that fontconfig doesn't build. Quite easy to fix and as mentioned in the patch it should be already solved. I think it's also not really Darwin-specific: Using linker flags of the target when building a hosttool is always a bad idea. libcap needs a host tool to generate a header file with the capability names in it. That fix is also quite trivial and I already sent something upstream. BTW: I have all pending patches at https://bitbucket.org/bwalle/ptxdist.git in the 'for-mol' branch, so you can also pick them from there if it's easier for you. -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH v3] rules: Add fbterm
Hi, * Michael Olbrich [2012-04-08 10:15]: > > This is wrong. Now the whole package is only built on x86 > > PACKAGES-$(PTXCONF_FBTERM) += fbterm Of course, that's right. > > +# > > > > +# Prepare > > +# > > > > + > > ifndef PTXCONF_ARCH_X86 > undefine PTXCONF_FBTERM_VESA > endif That yields me to the question if it wouldn't be better to omit that check at all. If we can't get Kconfig right, what gives us the check? It disables VESA support even when enabled where it's not available, but that's the same as configure does automatically. But during testing, I discovered another problem: If the option is selected, libx86 is built: PACKAGES-$(PTXCONF_ARCH_X86)-$(PTXCONF_LIBX86) doesn't help here because the dependency is resolved by kconfig before the makefiles get executed. Do you see a problem to solve that? Otherwise I would either just omit that VESA option (I don't need it) or leave it to the user to select libx86 when FBTERM_VESA is selected. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] localedef: Build fixes for Darwin
Hi, * Michael Olbrich [2012-04-08 10:10]: > > > For LLVM GCC [2] which is used in new XCode versions (the old gcc can > > still be installed as gcc-apple-4.2 with MacPorts), a small fix is > > needed, I'll send a patch afterwards. > > > > So if you could apply that patch and queue it for future releases that > > would be awesome. I guess that this issue has nothing to do with MacOS > > but that LLVM GCC on Linux yields to the same results. However, I also > > guess that nobody out there uses LLVM GCC on Linux to build such > > tools... > > I've applied the patch. I suppose, for this one patch I wouldn't mind > having it in ptxdist as well. I'll just drop it when I create the next > localedef package. So if you create a patch I'll apply it. Fine, see the next mail. > Btw, what's the overall status with ptxdist on MacOS? Quite good. I don't build with all packages enabled, but my Beagleboard SDK [1] builds without problems. The same for my weather station [2] which uses Dockstar hardware (Marvell Kirkwood) and a NSLU2 (Intel IXP) as the second one. The only exception is the creation of an ubifs image, i.e. host-mtd-utils. I have something working in [3] but I want to push that mainline first. If they don't accept it, I can put a large number of required headers in my elf-h-compat (which I would rename in that case) so that the changes in mtd-utils are minimal. Kernel 3.4 should build without any additional patches as Andreas' changes [4] got accepted and my printf/echo fix [5] now also is included. I hope I have some time in the next weeks to provide a small Howto for ptxdist on Mac OS. Thanks for accepting all the patches and the feedback on them, BTW. Regards, Bernhard [1] https://bitbucket.org/bwalle/ptxdist-arm-boards [2] https://bitbucket.org/bwalle/ptxdist-vetero [3] https://bitbucket.org/bwalle/mtd-utils [4] http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=dd2a3acaecd7abb2d43b09a823cf2e4c967fa2ac [5] http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=875de98623fa2b29f0cb19915fe3292ab6daa1cb -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] host-localedef: Fix build with LLVM GCC
See description of the patch that is added in localedef-eglibc-* in patches. Signed-off-by: Bernhard Walle --- ...eam.h-Force-inlining-of-extern-inline-fun.patch | 38 patches/localedef-eglibc-2.14.1-r17443-ptx1/series |4 +++ 2 files changed, 42 insertions(+) create mode 100644 patches/localedef-eglibc-2.14.1-r17443-ptx1/0001-argp-fmtstream.h-Force-inlining-of-extern-inline-fun.patch create mode 100644 patches/localedef-eglibc-2.14.1-r17443-ptx1/series diff --git a/patches/localedef-eglibc-2.14.1-r17443-ptx1/0001-argp-fmtstream.h-Force-inlining-of-extern-inline-fun.patch b/patches/localedef-eglibc-2.14.1-r17443-ptx1/0001-argp-fmtstream.h-Force-inlining-of-extern-inline-fun.patch new file mode 100644 index 000..11c9e2c --- /dev/null +++ b/patches/localedef-eglibc-2.14.1-r17443-ptx1/0001-argp-fmtstream.h-Force-inlining-of-extern-inline-fun.patch @@ -0,0 +1,38 @@ +From e363247cae85b8c43d5d4cc8b0e188ff090942b1 Mon Sep 17 00:00:00 2001 +From: Bernhard Walle +Date: Sun, 8 Apr 2012 16:25:09 +0200 +Subject: [PATCH] argp-fmtstream.h: Force inlining of 'extern inline' + functions + +LLVM GCC (at least i686-apple-darwin11-llvm-gcc-4.2) doesn't generate a +non-inlined version of argp_fmtstream_putc (even if compiled with -O2), +so linking the final program fails: + +-- +Undefined symbols for architecture x86_64: + "_argp_fmtstream_putc", referenced from: + _usage_argful_short_opt in argp-help.o + _argp_args_usage in argp-help.o +ld: symbol(s) not found for architecture x86_64 +-- + +FSF GCC doesn't have the problem, BTW. + +Signed-off-by: Bernhard Walle +--- + eglibc/argp/argp-fmtstream.h |2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/eglibc/argp/argp-fmtstream.h b/eglibc/argp/argp-fmtstream.h +index f94207a..67d1ea2 100644 +--- a/eglibc/argp/argp-fmtstream.h b/eglibc/argp/argp-fmtstream.h +@@ -203,7 +203,7 @@ extern int __argp_fmtstream_ensure (argp_fmtstream_t __fs, size_t __amount); + #endif + + #ifndef ARGP_FS_EI +-#define ARGP_FS_EI extern inline ++#define ARGP_FS_EI extern inline __attribute__ ((always_inline)) + #endif + + ARGP_FS_EI size_t diff --git a/patches/localedef-eglibc-2.14.1-r17443-ptx1/series b/patches/localedef-eglibc-2.14.1-r17443-ptx1/series new file mode 100644 index 000..59bd8c4 --- /dev/null +++ b/patches/localedef-eglibc-2.14.1-r17443-ptx1/series @@ -0,0 +1,4 @@ +# generated by git-ptx-patches +#tag:base --start-number 1 +0001-argp-fmtstream.h-Force-inlining-of-extern-inline-fun.patch +# d34ba91ca41689721674ab991d6febfc - git-ptx-patches magic -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] configure.ac: Check for GNU find
One of the specialities of GNU find over BSD find is that you can omit the path before providing options. This means that "find -name bla" is equivalent with "find . -name bla". Busybox exposes that behaviour. So check for GNU find to be on the safe side, and also add the symlink in the installation directory once we found it. Signed-off-by: Bernhard Walle --- Makefile.in |1 + configure.ac |1 + 2 files changed, 2 insertions(+) diff --git a/Makefile.in b/Makefile.in index 17a6ce6..8382402 100644 --- a/Makefile.in +++ b/Makefile.in @@ -54,6 +54,7 @@ environment: @ln -sf @GNU_stat@ "$(abs_srcdir)/bin/stat" @ln -sf @GNU_mknod@ "$(abs_srcdir)/bin/mknod" @ln -sf @GNU_tar@ "$(abs_srcdir)/bin/tar" + @ln -sf @GNU_find@ "$(abs_srcdir)/bin/find" @ln -sf @GNU_readlink@ "$(abs_srcdir)/bin/readlink" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" diff --git a/configure.ac b/configure.ac index 78597cc..44c2448 100755 --- a/configure.ac +++ b/configure.ac @@ -148,6 +148,7 @@ GNU_TOOL(stat, coreutils) GNU_TOOL(mknod, coreutils) GNU_TOOL(readlink, coreutils) GNU_TOOL(tar, tar) +GNU_TOOL(find, findutils) dnl Check for egrep AC_PROG_EGREP -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] argp-fmtstream.h: Force inlining of 'extern inline' functions
LLVM GCC (at least i686-apple-darwin11-llvm-gcc-4.2) doesn't generate a non-inlined version of argp_fmtstream_putc (even if compiled with -O2), so linking the final program fails: -- Undefined symbols for architecture x86_64: "_argp_fmtstream_putc", referenced from: _usage_argful_short_opt in argp-help.o _argp_args_usage in argp-help.o ld: symbol(s) not found for architecture x86_64 -- FSF GCC doesn't have the problem, BTW. Signed-off-by: Bernhard Walle --- NOTE: This patch applies to ptx branch of mol/localedef, not to PTXdist. eglibc/argp/argp-fmtstream.h |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eglibc/argp/argp-fmtstream.h b/eglibc/argp/argp-fmtstream.h index f94207a..67d1ea2 100644 --- a/eglibc/argp/argp-fmtstream.h +++ b/eglibc/argp/argp-fmtstream.h @@ -203,7 +203,7 @@ extern int __argp_fmtstream_ensure (argp_fmtstream_t __fs, size_t __amount); #endif #ifndef ARGP_FS_EI -#define ARGP_FS_EI extern inline +#define ARGP_FS_EI extern inline __attribute__ ((always_inline)) #endif ARGP_FS_EI size_t -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] localedef: Build fixes for Darwin
Hi Michael, * Michael Olbrich [2012-03-24 13:15]: > On Sun, Feb 12, 2012 at 04:44:52PM +0100, Bernhard Walle wrote: > > This patch series against the ptx branch in mol/localedef.git makes > > localedef compiling on Darwin. Tested on Mac OS 10.7 (Lion). > > > > I know you suggested using host-gettext-dummy, but that didn't work out of > > the > > box. Creating the host-gettext-dummy rules was easy and it worked, but the > > files copied from eglibc didn't compile; fixing that would be much more work > > than just defining two macros, so I took the easy way. > > I finally managed to work on this again. I've merged the patches, created a > release and pushed an update to ptxdist. Please test. Sorry for my late feedback on this. The good news is that host-localedef builds with FSF GCC 4.2 [1] (and that was the compiler that I tested on my old MacBook when I created the patches). For LLVM GCC [2] which is used in new XCode versions (the old gcc can still be installed as gcc-apple-4.2 with MacPorts), a small fix is needed, I'll send a patch afterwards. So if you could apply that patch and queue it for future releases that would be awesome. I guess that this issue has nothing to do with MacOS but that LLVM GCC on Linux yields to the same results. However, I also guess that nobody out there uses LLVM GCC on Linux to build such tools... Regards, Bernhard [1] i686-apple-darwin11-gcc-apple-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3) [2] i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.9.00) -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] mtd-utils: Fix build of UBI tools when mkfs.ubifs is not enabled
From: Bernhard Walle This problem has been introduced in d4ba37630767095330ddc5cdc3c154cd2e4f757d. See http://thread.gmane.org/gmane.comp.embedded.ptxdist.devel/9087. Reported-by: Alexander Dahl Signed-off-by: Bernhard Walle --- .../mtd-utils-1.4.9/0001-make-ubifs-optional.patch |9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch b/patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch index 8160648..2cbce09 100644 --- a/patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch +++ b/patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch @@ -5,20 +5,19 @@ Subject: [PATCH] make ubifs optional Signed-off-by: Bernhard Walle --- Makefile |2 ++ - 1 files changed, 2 insertions(+), 0 deletions(-) + 1 file changed, 2 insertions(+) diff --git a/Makefile b/Makefile -index 17a1216..000dc86 100644 +index 17a1216..5e1692f 100644 --- a/Makefile +++ b/Makefile -@@ -30,8 +30,10 @@ UBI_BINS = \ +@@ -30,7 +30,9 @@ UBI_BINS = \ ubidetach ubinize ubiformat ubirename mtdinfo ubirsvol BINS = $(MTD_BINS) +ifneq ($(WITHOUT_MKUBIFS), 1) BINS += mkfs.ubifs/mkfs.ubifs - BINS += $(addprefix ubi-utils/,$(UBI_BINS)) +endif + BINS += $(addprefix ubi-utils/,$(UBI_BINS)) SCRIPTS = flash_eraseall - TARGETS = $(BINS) -- 1.7.9.6 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] ubi utils in package mtd-utils broken
Hi, * Bart van der Meulen [2012-04-05 11:20]: > 2012/4/4 Alexander Dahl : > > Hei hei, > > > > I was just migrating our BSP from ptxdist 2012.03.0 to 2012.04.0 and > > the build fails in targetinstall stage of package mtd-utils like this: > > > > make: *** > > [/home/adahl/Work/src/BSP/platform-at91sam9g20XXX/state/mtd-utils.targetinstall] > > Error 1 > > > > No suitable file '/usr/sbin/ubiattach' could be found in any of these > > locations: > > > > /home/adahl/Work/src/BSP/platform-at91sam9g20XXX/packages/mtd-utils-1.4.9/usr/sbin/ubiattach.at91sam9g20XXX > > > > /home/adahl/Work/src/BSP/platform-at91sam9g20XXX/packages/mtd-utils-1.4.9/usr/sbin/ubiattach > > > > A little look to the output of the previous stages showed: ubiattach > > and all the other UBI tools are not compiled. Can anyone reproduce this? > > How can it be fixed? > > > > I thinks it is caused by the patch > patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch, Sorry, yes, my fault. > If PTXCONF_MTD_UTILS_MKFS_UBIFS is not set then all ubi-utils are not > build, I think > that this must be PTXCONF_MTD_UTILS_UBI_UTILS. While that fixes the problem, it builds too much (and we need liblzo if any ubi tool is selected). I think the right fix is to fix the patch that patches the Makefile, see next mail. @Alexander: Can you try that out? Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] ubi utils in package mtd-utils broken
Hi Alexander, * Alexander Dahl [2012-04-04 18:59]: > > I was just migrating our BSP from ptxdist 2012.03.0 to 2012.04.0 and > the build fails in targetinstall stage of package mtd-utils like this: > > make: *** > [/home/adahl/Work/src/BSP/platform-at91sam9g20XXX/state/mtd-utils.targetinstall] > Error 1 > > No suitable file '/usr/sbin/ubiattach' could be found in any of these > locations: > > /home/adahl/Work/src/BSP/platform-at91sam9g20XXX/packages/mtd-utils-1.4.9/usr/sbin/ubiattach.at91sam9g20XXX > > /home/adahl/Work/src/BSP/platform-at91sam9g20XXX/packages/mtd-utils-1.4.9/usr/sbin/ubiattach Maybe this is my fault because I sent some patches regarding mtd-utils between 2012.03 and 2012.04. Can you provide the ptxconfig/platformconfig? Could it be the case that busybox ubi tools are enabled and the patch http://git.pengutronix.de/?p=ptxdist.git;a=commitdiff;h=92f8312b8c404ce8d2e2f77ad5e09911444db6c4 broke it at your site? Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH v3] rules: Add fbterm
From: Bernhard Walle This is a nice framebuffer terminal with support for Unicode and nice font rendering. Signed-off-by: Bernhard Walle --- v2->v3: o Check ARCH_X86 in the Makefile and not in kconfig. v1->v2: o Remove the space in "GPL v2" o Add FBTERM_GPM and FBTERM_VESA. rules/fbterm.in | 33 + rules/fbterm.make | 61 + 2 files changed, 94 insertions(+) create mode 100644 rules/fbterm.in create mode 100644 rules/fbterm.make diff --git a/rules/fbterm.in b/rules/fbterm.in new file mode 100644 index 000..5a2553a --- /dev/null +++ b/rules/fbterm.in @@ -0,0 +1,33 @@ +## SECTION=multimedia_framebuffer + +menuconfig FBTERM + tristate + prompt "fbterm" + select FREETYPE + select FONTCONFIG + select GPMif FBTERM_GPM + select LIBX86 if FBTERM_VESA + help + Framebuffer terminal. Supports unicode and uses fontconfig and Freetype + for font rendering. Thus is has support for anti-aliased fonts. + +if FBTERM + +config FBTERM_GPM + bool + prompt "Build fbterm with gpm support" + help + If enabled, fbterm is built with console mouse support. The required + 'gpm' package is automatically selected. + +config FBTERM_VESA + bool + prompt "Build fbterm with VESA support" + help + If enabled, fbterm is built with VESA graphics support. The required + 'libx86' package is automatically selected. Only available on x86 + platforms. + +endif + +# vim: set ts=8 sw=8 noet ft=kconfig: diff --git a/rules/fbterm.make b/rules/fbterm.make new file mode 100644 index 000..3171ca6 --- /dev/null +++ b/rules/fbterm.make @@ -0,0 +1,61 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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_ARCH_X86)-$(PTXCONF_FBTERM) += fbterm + +# +# Paths and names +# +FBTERM_VERSION := 1.7.0 +FBTERM_MD5 := c36bae75a450df0519b4527cccaf7572 +FBTERM := fbterm-$(FBTERM_VERSION) +FBTERM_SUFFIX := tar.gz +FBTERM_URL := http://fbterm.googlecode.com/files/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_SOURCE := $(SRCDIR)/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_DIR := $(BUILDDIR)/$(FBTERM) +FBTERM_LICENSE := GPLv2 + +# +# Prepare +# + +# +# autoconf +# +FBTERM_CONF_TOOL := autoconf +FBTERM_AUTOCONF:= \ + $(CROSS_AUTOCONF_USR) \ + --$(call ptx/endis, PTXCONF_FBTERM_GPM)-gpm \ + --$(call ptx/endis, PTXCONF_FBTERM_VESA)-vesa + +# +# Target-Install +# + +$(STATEDIR)/fbterm.targetinstall: + @$(call targetinfo) + + @$(call install_init, fbterm) + @$(call install_fixup, fbterm,PRIORITY,optional) + @$(call install_fixup, fbterm,SECTION,base) + @$(call install_fixup, fbterm,AUTHOR,"Bernhard Walle ") + @$(call install_fixup, fbterm,DESCRIPTION,missing) + + @$(call install_copy, fbterm, 0, 0, 0755, \ + -, /usr/bin/fbterm) + + @$(call install_finish, fbterm) + + @$(call touch) + +# vim: syntax=make -- 1.7.9.6 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] qt4: version bump 4.8.0 -> 4.8.1
From: Bernhard Walle Just a bugfix release. Signed-off-by: Bernhard Walle --- .../0001-mkspec-for-ptxdist.patch | 123 .../0002-disable-ordered-compiling.patch | 79 - .../0003-Hack-hide-cursor-during-startup.patch | 27 - .../0004-add-missing-subdirs.patch | 85 -- .../0005-Fix-dnd-issue-on-QWS.patch| 64 -- ...e-make-sure-local-include-dirs-come-first.patch | 39 --- ...non-fix-colors-for-video-on-qgraphicsview.patch | 36 -- .../0008-don-t-build-webkit-tests.patch| 33 -- patches/qt-everywhere-opensource-src-4.8.0/series | 11 -- .../0001-mkspec-for-ptxdist.patch | 123 .../0002-disable-ordered-compiling.patch | 79 + .../0003-Hack-hide-cursor-during-startup.patch | 27 + .../0004-add-missing-subdirs.patch | 85 ++ .../0005-Fix-dnd-issue-on-QWS.patch| 64 ++ ...e-make-sure-local-include-dirs-come-first.patch | 39 +++ ...non-fix-colors-for-video-on-qgraphicsview.patch | 36 ++ .../0008-don-t-build-webkit-tests.patch| 33 ++ patches/qt-everywhere-opensource-src-4.8.1/series | 11 ++ rules/qt4.make |4 +- 19 files changed, 499 insertions(+), 499 deletions(-) delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0001-mkspec-for-ptxdist.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0002-disable-ordered-compiling.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0003-Hack-hide-cursor-during-startup.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0004-add-missing-subdirs.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0005-Fix-dnd-issue-on-QWS.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0006-qmake-make-sure-local-include-dirs-come-first.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0007-phonon-fix-colors-for-video-on-qgraphicsview.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/0008-don-t-build-webkit-tests.patch delete mode 100644 patches/qt-everywhere-opensource-src-4.8.0/series create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0001-mkspec-for-ptxdist.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0002-disable-ordered-compiling.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0003-Hack-hide-cursor-during-startup.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0004-add-missing-subdirs.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0005-Fix-dnd-issue-on-QWS.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0006-qmake-make-sure-local-include-dirs-come-first.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0007-phonon-fix-colors-for-video-on-qgraphicsview.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/0008-don-t-build-webkit-tests.patch create mode 100644 patches/qt-everywhere-opensource-src-4.8.1/series diff --git a/patches/qt-everywhere-opensource-src-4.8.0/0001-mkspec-for-ptxdist.patch b/patches/qt-everywhere-opensource-src-4.8.0/0001-mkspec-for-ptxdist.patch deleted file mode 100644 index f018211..000 --- a/patches/qt-everywhere-opensource-src-4.8.0/0001-mkspec-for-ptxdist.patch +++ /dev/null @@ -1,123 +0,0 @@ -From: Michael Olbrich -Date: Fri, 8 Oct 2010 20:13:39 +0200 -Subject: [PATCH] mkspec for ptxdist - -Add a mkspec for ptxdist: -- qplatformdefs.h -Include the generic qplatformdefs.h -- qmake.conf.in -Used to generate qmake.conf with the correct toolchain. - -Signed-off-by: Michael Olbrich - mkspecs/linux-ptx-g++/qmake.conf.in | 41 + - mkspecs/linux-ptx-g++/qplatformdefs.h |2 + - mkspecs/qws/linux-ptx-g++/qmake.conf.in | 32 ++ - mkspecs/qws/linux-ptx-g++/qplatformdefs.h |2 + - 4 files changed, 77 insertions(+), 0 deletions(-) - create mode 100644 mkspecs/linux-ptx-g++/qmake.conf.in - create mode 100644 mkspecs/linux-ptx-g++/qplatformdefs.h - create mode 100644 mkspecs/qws/linux-ptx-g++/qmake.conf.in - create mode 100644 mkspecs/qws/linux-ptx-g++/qplatformdefs.h - -diff --git a/mkspecs/linux-ptx-g++/qmake.conf.in b/mkspecs/linux-ptx-g++/qmake.conf.in -new file mode 100644 -index 000..c3e0150 /dev/null -+++ b/mkspecs/linux-ptx-g++/qmake.conf.in -@@ -0,0 +1,41 @@ -+# -+# qmake configuration for linux-ptx-g++ -+# -+ -+ -+include(../common/gcc-base-unix.conf) -+include(../common/g++-unix.conf) -+include(../common/linux.conf) -+ -+MAKEFILE_GENERATOR = UNIX -+TEMPLATE= app -+CONFIG += qt warn_on release incremental link_prl -+QT += core gui network
[ptxdist] [PATCH v2] rules: Add fbterm
From: Bernhard Walle This is a nice framebuffer terminal with support for Unicode and nice font rendering. Signed-off-by: Bernhard Walle --- v1->v2: o Remove the space in "GPL v2" o Add FBTERM_GPM and FBTERM_VESA. rules/fbterm.in | 34 + rules/fbterm.make | 61 + 2 files changed, 95 insertions(+) create mode 100644 rules/fbterm.in create mode 100644 rules/fbterm.make diff --git a/rules/fbterm.in b/rules/fbterm.in new file mode 100644 index 000..cb326e8 --- /dev/null +++ b/rules/fbterm.in @@ -0,0 +1,34 @@ +## SECTION=multimedia_framebuffer + +menuconfig FBTERM + tristate + prompt "fbterm" + select FREETYPE + select FONTCONFIG + select GPMif FBTERM_GPM + select LIBX86 if FBTERM_VESA + help + Framebuffer terminal. Supports unicode and uses fontconfig and Freetype + for font rendering. Thus is has support for anti-aliased fonts. + +if FBTERM + +config FBTERM_GPM + bool + prompt "Build fbterm with gpm support" + help + If enabled, fbterm is built with console mouse support. The required + 'gpm' package is automatically selected. + +config FBTERM_VESA + bool + prompt "Build fbterm with VESA support" + depends on ARCH_X86 + help + If enabled, fbterm is built with VESA graphics support. The required + 'libx86' package is automatically selected. Only available on x86 + platforms. + +endif + +# vim: set ts=8 sw=8 noet ft=kconfig: diff --git a/rules/fbterm.make b/rules/fbterm.make new file mode 100644 index 000..8af3e87 --- /dev/null +++ b/rules/fbterm.make @@ -0,0 +1,61 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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_FBTERM) += fbterm + +# +# Paths and names +# +FBTERM_VERSION := 1.7.0 +FBTERM_MD5 := c36bae75a450df0519b4527cccaf7572 +FBTERM := fbterm-$(FBTERM_VERSION) +FBTERM_SUFFIX := tar.gz +FBTERM_URL := http://fbterm.googlecode.com/files/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_SOURCE := $(SRCDIR)/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_DIR := $(BUILDDIR)/$(FBTERM) +FBTERM_LICENSE := GPLv2 + +# +# Prepare +# + +# +# autoconf +# +FBTERM_CONF_TOOL := autoconf +FBTERM_AUTOCONF:= \ + $(CROSS_AUTOCONF_USR) \ + --$(call ptx/endis, PTXCONF_FBTERM_GPM)-gpm \ + --$(call ptx/endis, PTXCONF_FBTERM_VESA)-vesa + +# +# Target-Install +# + +$(STATEDIR)/fbterm.targetinstall: + @$(call targetinfo) + + @$(call install_init, fbterm) + @$(call install_fixup, fbterm,PRIORITY,optional) + @$(call install_fixup, fbterm,SECTION,base) + @$(call install_fixup, fbterm,AUTHOR,"Bernhard Walle ") + @$(call install_fixup, fbterm,DESCRIPTION,missing) + + @$(call install_copy, fbterm, 0, 0, 0755, \ + -, /usr/bin/fbterm) + + @$(call install_finish, fbterm) + + @$(call touch) + +# vim: syntax=make -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] rules: Add fbterm
From: Bernhard Walle This is a nice framebuffer terminal with support for Unicode and nice font rendering. Signed-off-by: Bernhard Walle --- rules/fbterm.in | 12 +++ rules/fbterm.make | 57 + 2 files changed, 69 insertions(+) create mode 100644 rules/fbterm.in create mode 100644 rules/fbterm.make diff --git a/rules/fbterm.in b/rules/fbterm.in new file mode 100644 index 000..68013c0 --- /dev/null +++ b/rules/fbterm.in @@ -0,0 +1,12 @@ +## SECTION=multimedia_framebuffer + +config FBTERM + tristate + prompt "fbterm" + select FREETYPE + select FONTCONFIG + help + Framebuffer terminal. Supports unicode and uses fontconfig and Freetype + for font rendering. Thus is has support for anti-aliased fonts. + +# vim: set ts=8 sw=8 noet ft=kconfig: diff --git a/rules/fbterm.make b/rules/fbterm.make new file mode 100644 index 000..2737c41 --- /dev/null +++ b/rules/fbterm.make @@ -0,0 +1,57 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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_FBTERM) += fbterm + +# +# Paths and names +# +FBTERM_VERSION := 1.7.0 +FBTERM_MD5 := c36bae75a450df0519b4527cccaf7572 +FBTERM := fbterm-$(FBTERM_VERSION) +FBTERM_SUFFIX := tar.gz +FBTERM_URL := http://fbterm.googlecode.com/files/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_SOURCE := $(SRCDIR)/$(FBTERM).$(FBTERM_SUFFIX) +FBTERM_DIR := $(BUILDDIR)/$(FBTERM) +FBTERM_LICENSE := GPL v2 + +# +# Prepare +# + +# +# autoconf +# +FBTERM_CONF_TOOL := autoconf + +# +# Target-Install +# + +$(STATEDIR)/fbterm.targetinstall: + @$(call targetinfo) + + @$(call install_init, fbterm) + @$(call install_fixup, fbterm,PRIORITY,optional) + @$(call install_fixup, fbterm,SECTION,base) + @$(call install_fixup, fbterm,AUTHOR,"Bernhard Walle ") + @$(call install_fixup, fbterm,DESCRIPTION,missing) + + @$(call install_copy, fbterm, 0, 0, 0755, \ + -, /usr/bin/fbterm) + + @$(call install_finish, fbterm) + + @$(call touch) + +# vim: syntax=make -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 2/2] Allow creation of bootable SD card for OMAP CPUs
With the new option IMAGE_OMAPSD it's possible to create an image for OMAP-bootable SD cards. Tested with a devkit8000 and a virtual beagle board (qemu). See the comment in platforms/image_omapsd.in for more information. Signed-off-by: Bernhard Walle --- platforms/image_omapsd.in| 48 + rules/post/image_omapsd.make | 32 + scripts/genomapsdimg | 160 ++ 3 files changed, 240 insertions(+) create mode 100644 platforms/image_omapsd.in create mode 100644 rules/post/image_omapsd.make create mode 100755 scripts/genomapsdimg diff --git a/platforms/image_omapsd.in b/platforms/image_omapsd.in new file mode 100644 index 000..ef6c5e4 --- /dev/null +++ b/platforms/image_omapsd.in @@ -0,0 +1,48 @@ +## SECTION=image + +menuconfig IMAGE_OMAPSD + bool + select IMAGE_VFAT_TOOLS + select HOST_PARTED + select IMAGE_EXT2 + depends on ARCH_ARM + prompt "Generate OMAP bootable SD card" + help + Creates an bootable SD card for OMAP CPUs, for example for the beagle board. + The resulting image is called "omap_sd.img". You can copy it with "dd" + on a raw SD card, without partitioning. + + The SD card contains two file systems: + 1) A FAT file system that contains MLO, a bootloader and a Linux kernel + (plus additional files like an initramfs). + 2) The root file system as ext3 file system. + + OMAP has special requirements regarding the geometry of partition table, + and the location of MLO, that's why a fixed image makes more sense here + than copying the files manually. + +if IMAGE_OMAPSD + +config IMAGE_OMAPSD_BOOTLOADER + string + default "u-boot.img" + prompt "Bootloader file" + help + The name of the bootloader that should be copied to the SD card. If you use + u-boot SPL, then "u-boot.img" is the right choice here. If you still use + x-loader, then "u-boot.bin" should be copied. Also barebox can be used + with its MLO. The file must reside in the images directory of the platform. + +config IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES + string + default "" + prompt "Additional files for the boot partition" + help + A (whitespace separated) list of additional files can be specified here. + The files get copied in the boot partition (1st FAT partition). They must + be in the images/ directory of the platform that is built. One example is + a uRamdisk that gets loaded by the bootloader. + +endif + +# vim: set sw=8 ts=8 noet ft=kconfig: diff --git a/rules/post/image_omapsd.make b/rules/post/image_omapsd.make new file mode 100644 index 000..3741106 --- /dev/null +++ b/rules/post/image_omapsd.make @@ -0,0 +1,32 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by the ptxdist project +# +# 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. +# + +SEL_ROOTFS-$(PTXCONF_IMAGE_OMAPSD) += $(IMAGEDIR)/omap_sd.img + +# preprend the $(IMAGEDIR) if PTXCONF_IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES is not +# empty +ifneq ($(PTXCONF_IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES),"") +PTXCONF_IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES_FULL := \ + $(addprefix $(IMAGEDIR)/, $(PTXCONF_IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES)) +endif + +$(IMAGEDIR)/omap_sd.img: $(IMAGEDIR)/root.ext2 + @ln -sf $(IMAGEDIR)/linuximage $(IMAGEDIR)/uImage + @echo "Creating bootable SD card for OMAP"; \ + PATH=$(PTXCONF_SYSROOT_HOST)/bin:$$PATH $(PTXDIST_TOPDIR)/scripts/genomapsdimg \ +-m $(IMAGEDIR)/MLO \ +-b $(IMAGEDIR)/u-boot.img \ +-k $(IMAGEDIR)/uImage \ +-f $(IMAGEDIR)/root.ext2 \ +-a "$(PTXCONF_IMAGE_OMAPSD_ADDITIONAL_BOOT_FILES_FULL)" \ +-o $@ + @echo "done." + +# vim: syntax=make diff --git a/scripts/genomapsdimg b/scripts/genomapsdimg new file mode 100755 index 000..9c87e45 --- /dev/null +++ b/scripts/genomapsdimg @@ -0,0 +1,160 @@ +#!/bin/bash + +# Creates a OMAP bootable SD card. +# The image has a PC-style partition table with two partitions: +# +# 1) a FAT partition with MLO, bootloader and a Linux kernel +# 2) a ext3 partition with the root file system. +# +# That's a bit tricky because the OMAP needs a special partition table +# (therefore, genpart cannot be used). +# +# Parts of the script hav
[ptxdist] [PATCH 1/2] Add host-parted
Signed-off-by: Bernhard Walle --- platforms/hosttools.in |1 + rules/host-parted.in |8 rules/host-parted.make | 38 ++ 3 files changed, 47 insertions(+) create mode 100644 rules/host-parted.in create mode 100644 rules/host-parted.make diff --git a/platforms/hosttools.in b/platforms/hosttools.in index e9ce0fc..10d05e8 100644 --- a/platforms/hosttools.in +++ b/platforms/hosttools.in @@ -18,6 +18,7 @@ source "rules/host-mkelfImage.in" source "rules/host-mtd-utils.in" source "rules/host-mtools.in" source "rules/host-openssl.in" +source "rules/host-parted.in" source "rules/host-squashfs-tools.in" source "rules/host-u-boot-tools.in" source "rules/host-util-linux-ng.in" diff --git a/rules/host-parted.in b/rules/host-parted.in new file mode 100644 index 000..d150ffd --- /dev/null +++ b/rules/host-parted.in @@ -0,0 +1,8 @@ +## SECTION=hosttools_noprompt + +config HOST_PARTED + bool + default ALLYES + help + The well-known parted program + diff --git a/rules/host-parted.make b/rules/host-parted.make new file mode 100644 index 000..9655f5d --- /dev/null +++ b/rules/host-parted.make @@ -0,0 +1,38 @@ +# -*-makefile-*- +# +# Copyright (C) 2006 by Robert Schwebel +# 2009 by Marc Kleine-Budde +# +# 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 +# +HOST_PACKAGES-$(PTXCONF_HOST_PARTED) += host-parted + +# +# Paths and names +# +HOST_PARTED= $(PARTED) +HOST_PARTED_DIR= $(HOST_BUILDDIR)/$(HOST_PARTED) + +# +# Prepare +# + +HOST_PARTED_ENV:= $(HOST_ENV) + +# +# autoconf +# +HOST_PARTED_AUTOCONF := $(HOST_AUTOCONF) \ + --disable-device-mapper \ + --disable-Werror + +HOST_PARTED_INSTALL_OPT := install + +# vim: syntax=make -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH v2] Add sp-oops-extract package
From: Bernhard Walle 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 --- 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 +++ 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 000..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 +Date: Wed, 21 Mar 2012 15:55:06 +0100 +Subject: [PATCH] Make the Makefile more cross-compiler friendly + +Signed-off-by: Bernhard Walle +--- + 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 $@ $^ 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 000..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 000..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=' to your boot command + line where '' is the MTD device number you want to use to save + kernel oopses. Alternatively, load the 'mtdoops' module with + 'mtddev=' as module parameter. To extract that oops, just use + 'sp-oops-extract /dev/mtd'. + diff --git a/rules/sp-oops-extract.make b/rules/sp-oops-extract.make new file mode 100644 index 000..b08a496 --- /dev/null +++ b/rules/sp-oops-extract.make @@ -0,0 +1,56 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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,PR
Re: [ptxdist] [PATCH 2/2] os: Add execinfo::backtrace()
* bernh...@bwalle.de [2012-03-22 13:49]: > From: Bernhard Walle > > Signed-off-by: Bernhard Walle Sorry, that are patches that I wanted to post on an internal list. Damn command line history. Should take some vacation... Just ignore the mail. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] flashbench: Fix error when flashbench is not selected
When flashbench is not selected in "ptxdist menuconfig", then $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) is undefined. In that case, the expr call fails. Fix the problem by delaying the evaluation of FLASHBENCH_MAKE_OPT until it's really needed, i.e. when flashbench has been selected. Signed-off-by: Bernhard Walle --- Don't sign off my own patch twice with multiple email addresses. rules/flashbench.make |5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rules/flashbench.make b/rules/flashbench.make index fcb669e..39bdfb6 100644 --- a/rules/flashbench.make +++ b/rules/flashbench.make @@ -31,7 +31,10 @@ FLASHBENCH_LICENSE := GPL v2 FLASHBENCH_CONF_TOOL := NO FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) -FLASHBENCH_MAKE_OPT:= CC=$(CROSS_CC) \ + +# Use '=' instaed of ':=' because $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) is not defined +# when flashbench is not selected to be built. +FLASHBENCH_MAKE_OPT= CC=$(CROSS_CC) \ EXTRA_CFLAGS=-DMAX_BUFSIZE=$(shell expr 1024 \* 1024 \* $(PTXCONF_FLASHBENCH_MAX_BUFSIZE)) # -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] flashbench: Fix error when flashbench is not selected
When flashbench is not selected in "ptxdist menuconfig", then $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) is undefined. In that case, the expr call fails. Fix the problem by delaying the evaluation of FLASHBENCH_MAKE_OPT until it's really needed, i.e. when flashbench has been selected. Signed-off-by: Bernhard Walle Signed-off-by: Bernhard Walle --- rules/flashbench.make |5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rules/flashbench.make b/rules/flashbench.make index fcb669e..39bdfb6 100644 --- a/rules/flashbench.make +++ b/rules/flashbench.make @@ -31,7 +31,10 @@ FLASHBENCH_LICENSE := GPL v2 FLASHBENCH_CONF_TOOL := NO FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) -FLASHBENCH_MAKE_OPT:= CC=$(CROSS_CC) \ + +# Use '=' instaed of ':=' because $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) is not defined +# when flashbench is not selected to be built. +FLASHBENCH_MAKE_OPT= CC=$(CROSS_CC) \ EXTRA_CFLAGS=-DMAX_BUFSIZE=$(shell expr 1024 \* 1024 \* $(PTXCONF_FLASHBENCH_MAX_BUFSIZE)) # -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] ptxdist: Don't assume that we have a bashrc
* Alexander Dahl [2012-03-21 09:40]: > Am 21.03.2012 07:17, schrieb Bernhard Walle: > >> I'm using zsh, not bash, but still have ~/.bashrc … what does this code > >> try to do in the first place and how does this affect users of other > >> shells? > > > > It only avoids two error messages when running "ptxdist bash" when the > > files are not present. You can also use bash and have no ~/.bashrc > > although that might be seldom. > > Okay, then let's rephrase this. From `ptxdist help` I got: > > bash enter a ptxdist environment bash shell > bash [args...] execute in ptxdist environment > > What is this environment useful for or what advantages has `ptxdist > bash` over my own shell? Well, I sometimes use it for debugging. For example you have the selected toolchain automatically in $PATH. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] ptxdist: Don't assume that we have a bashrc
Am 20.03.12 23:15, schrieb Alexander Dahl: > > Am 20.03.2012 20:46, schrieb Bernhard Walle: >> Usually there is one, but don't print an error if there is no one. > > I'm using zsh, not bash, but still have ~/.bashrc … what does this code > try to do in the first place and how does this affect users of other shells? It only avoids two error messages when running "ptxdist bash" when the files are not present. You can also use bash and have no ~/.bashrc although that might be seldom. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Fix ptxdist -q kernelconfig without extracted kernel
Normally if the kernel is not extracted when "ptxdist kernelconfig" is called, ptxdist extracts the kernel first. However, when used in quiet mode, that fails with an error like bash: -c: line 0: syntax error near unexpected token `;' bash: -c: line 0: `target="/Users/bwalle/devel/ptxdist-arm-boards/platform-beagle/state/kernel.get"; \ target="${target##*/}"; dep="/Volumes/Daten/src/linux-3.3.tar.bz2"; dep="${dep##*/}"; \ echo "${target} : ${dep}" >> /Users/bwalle/devel/ptxdist-arm-boards/platform-beagle/state/depend.out; \ echo "started : ${target}" >&; target="target: ${target##*/}"; \ echo -e "\n${target//?/-}\n${target}\n${target//?/-}\n"; 'o The problem is also there when calling "ptxdist kernelconfig" from "ptxdist menu". This patch attempts to fix the problem. Signed-off-by: Bernhard Walle --- rules/post/function-targetinfo.make |3 +++ rules/post/function-touch.make |3 +++ 2 files changed, 6 insertions(+) diff --git a/rules/post/function-targetinfo.make b/rules/post/function-targetinfo.make index f8bcebe..40e119a 100644 --- a/rules/post/function-targetinfo.make +++ b/rules/post/function-targetinfo.make @@ -15,6 +15,9 @@ # Print out the targetinfo line on the terminal # ifdef PTXDIST_QUIET +ifndef PTXDIST_FD_STDOUT +PTXDIST_FD_STDOUT := 1 +endif _targetinfo_opt_output := echo "started : $(PTX_COLOR_BLUE)$${target}$(PTX_COLOR_OFF)" >&$(PTXDIST_FD_STDOUT); endif diff --git a/rules/post/function-touch.make b/rules/post/function-touch.make index 0a7919e..4d8fc28 100644 --- a/rules/post/function-touch.make +++ b/rules/post/function-touch.make @@ -13,6 +13,9 @@ # touch # ifdef PTXDIST_QUIET +ifndef PTXDIST_FD_STDOUT +PTXDIST_FD_STDOUT := 1 +endif _touch_opt_output := echo "finished: $(PTX_COLOR_GREEN)$${target}$(PTX_COLOR_OFF)" >&$(PTXDIST_FD_STDOUT); endif -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] ptxdist: Don't assume that we have a bashrc
Usually there is one, but don't print an error if there is no one. Signed-off-by: Bernhard Walle --- bin/ptxdist |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/ptxdist b/bin/ptxdist index 440a7aa..37ab098 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -1656,8 +1656,8 @@ parse_second() if [ ${#} -eq 0 ]; then local bashrc="${PTXDIST_TEMPDIR}/bashrc" cat > "${bashrc}" <
Re: [ptxdist] [PATCH] configure.ac: Check for GNU ar
Hi Andreas, * Andreas Bießmann [2012-03-20 09:37]: > > this is annoying, it will require gnu binutils which is not available on > my mac by default. > Couldn't we use some approach like > http://thread.gmane.org/gmane.comp.embedded.ptxdist.devel/8533 > (pachting ipkg to use toolchain provided ar, which should be GNU > binutils for linux targets). You're right, GNU ar is not needed. I just had an old patches directory for opkg... Forget the patch. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] flashbench: Fix error when flashbench is not selected
When flashbench is not selected in "ptxdist menuconfig", then $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) is undefined. In that case, the expr call fails. Fix the problem by delaying the evaluation of FLASHBENCH_MAKE_OPT until it's really needed, i.e. when flashbench has been selected. Signed-off-by: Bernhard Walle --- rules/flashbench.make |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rules/flashbench.make b/rules/flashbench.make index fcb669e..0ef52d1 100644 --- a/rules/flashbench.make +++ b/rules/flashbench.make @@ -31,7 +31,7 @@ FLASHBENCH_LICENSE:= GPL v2 FLASHBENCH_CONF_TOOL := NO FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) -FLASHBENCH_MAKE_OPT:= CC=$(CROSS_CC) \ +FLASHBENCH_MAKE_OPT= CC=$(CROSS_CC) \ EXTRA_CFLAGS=-DMAX_BUFSIZE=$(shell expr 1024 \* 1024 \* $(PTXCONF_FLASHBENCH_MAX_BUFSIZE)) # -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] [flashbench] Fix syntax error in case FLASHBENCH_MAX_BUFSIZE not defined
Hi Juergen, * Juergen Beisert [2012-03-20 20:28]: > Bernhard Walle wrote: > > * Juergen Beisert [2012-03-20 10:09]: > > > Just delay the evaluation of the expression to the point of time when it > > > is really required. > > > > > > diff --git a/rules/flashbench.make b/rules/flashbench.make > > > index fcb669e..0ef52d1 100644 > > > --- a/rules/flashbench.make > > > +++ b/rules/flashbench.make > > > @@ -31,7 +31,7 @@ FLASHBENCH_LICENSE:= GPL v2 > > > > > > FLASHBENCH_CONF_TOOL := NO > > > FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) > > > -FLASHBENCH_MAKE_OPT:= CC=$(CROSS_CC) \ > > > +FLASHBENCH_MAKE_OPT= CC=$(CROSS_CC) \ > > > EXTRA_CFLAGS=-DMAX_BUFSIZE=$(shell expr 1024 \* 1024 \* > > > $(PTXCONF_FLASHBENCH_MAX_BUFSIZE)) > > > > Did you try it out? It doesn't work here. > > Yes I did. Sorry, I had the old (unpatched) flashbench.make in the rules directory of the project... Will send a patch that uses '=' instead of ':=' which is ready to be applied. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] [flashbench] Fix syntax error in case FLASHBENCH_MAX_BUFSIZE not defined
Hi Juergen, * Juergen Beisert [2012-03-20 10:09]: > > Just delay the evaluation of the expression to the point of time when it is > really required. > > diff --git a/rules/flashbench.make b/rules/flashbench.make > index fcb669e..0ef52d1 100644 > --- a/rules/flashbench.make > +++ b/rules/flashbench.make > @@ -31,7 +31,7 @@ FLASHBENCH_LICENSE:= GPL v2 > > FLASHBENCH_CONF_TOOL := NO > FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) > -FLASHBENCH_MAKE_OPT:= CC=$(CROSS_CC) \ > +FLASHBENCH_MAKE_OPT= CC=$(CROSS_CC) \ > EXTRA_CFLAGS=-DMAX_BUFSIZE=$(shell expr 1024 \* 1024 \* > $(PTXCONF_FLASHBENCH_MAX_BUFSIZE)) > Did you try it out? It doesn't work here. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] [flashbench] Fix syntax error in case FLASHBENCH_MAX_BUFSIZE not defined
Am 20.03.2012 09:43, schrieb Michael Olbrich: On Mon, Mar 19, 2012 at 08:57:50PM +0100, Remy Bohmer wrote: This error occurs in case PTXCONF_FLASHBENCH_MAX_BUFSIZE is not defined: $ ptxdist get expr: syntax error make: Nothing to be done for `get'. Change-Id: I1978d62b8781dbd5090b8a47b8fd8b944e6c79dc Signed-off-by: Remy Bohmer --- rules/flashbench.make |8 +++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/rules/flashbench.make b/rules/flashbench.make index fcb669e..b312979 100644 --- a/rules/flashbench.make +++ b/rules/flashbench.make @@ -31,8 +31,14 @@ FLASHBENCH_LICENSE := GPL v2 FLASHBENCH_CONF_TOOL := NO FLASHBENCH_MAKE_ENV:= $(CROSS_ENV) + +ifdef PTXCONF_FLASHBENCH_MAX_BUFSIZE +FLASHBENCH_MAX_BUFSIZE := $(PTXCONF_FLASHBENCH_MAX_BUFSIZE) +else +FLASHBENCH_MAX_BUFSIZE := 1 +endif I think we should report an error here: ifndef PTXCONF_FLASHBENCH_MAX_BUFSIZE $(error some error message here) endif I think the problem is here that flashbench is not selected, so the PTXCONF_FLASHBENCH_MAX_BUFSIZE option is unset. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] configure.ac: Check for GNU ar
To build the ipk packages, we need the 'f' flag which is a GNU extension: -{ ar(1) }-- f Truncate names in the archive. GNU ar will normally permit file names of any length. This will cause it to create archives which are not compatible with the native ar program on some systems. If this is a concern, the f modifier may be used to truncate file names when putting them in the archive. Signed-off-by: Bernhard Walle --- Makefile.in |1 + configure.ac |1 + 2 files changed, 2 insertions(+) diff --git a/Makefile.in b/Makefile.in index 17a6ce6..11e71c3 100644 --- a/Makefile.in +++ b/Makefile.in @@ -55,6 +55,7 @@ environment: @ln -sf @GNU_mknod@ "$(abs_srcdir)/bin/mknod" @ln -sf @GNU_tar@ "$(abs_srcdir)/bin/tar" @ln -sf @GNU_readlink@ "$(abs_srcdir)/bin/readlink" + @ln -sf @GNU_ar@ "$(abs_srcdir)/bin/ar" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" @ln -sf @XARGS@ "$(abs_srcdir)/bin/xargs" diff --git a/configure.ac b/configure.ac index 78597cc..d51ae4c 100755 --- a/configure.ac +++ b/configure.ac @@ -148,6 +148,7 @@ GNU_TOOL(stat, coreutils) GNU_TOOL(mknod, coreutils) GNU_TOOL(readlink, coreutils) GNU_TOOL(tar, tar) +GNU_TOOL(ar, Binutils) dnl Check for egrep AC_PROG_EGREP -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 2/2] dropbear: Fix build on Darwin
Signed-off-by: Bernhard Walle --- .../0001-Fix-build-on-Darwin.patch | 44 patches/dropbear-2012.55/series|4 ++ 2 files changed, 48 insertions(+) create mode 100644 patches/dropbear-2012.55/0001-Fix-build-on-Darwin.patch create mode 100644 patches/dropbear-2012.55/series diff --git a/patches/dropbear-2012.55/0001-Fix-build-on-Darwin.patch b/patches/dropbear-2012.55/0001-Fix-build-on-Darwin.patch new file mode 100644 index 000..bc0d210 --- /dev/null +++ b/patches/dropbear-2012.55/0001-Fix-build-on-Darwin.patch @@ -0,0 +1,44 @@ +From e96df81ee2364f45724ef91389a567216214 Mon Sep 17 00:00:00 2001 +From: Bernhard Walle +Date: Tue, 20 Mar 2012 08:28:57 +0100 +Subject: [PATCH] Fix build on Darwin + +From +https://dev.openwrt.org/browser/trunk/package/dropbear/patches/200-lcrypt_bsdfix.patch?rev=25891. + +Signed-off-by: Bernhard Walle +--- + Makefile.in |6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/Makefile.in b/Makefile.in +index cec35f1..0c288e4 100644 +--- a/Makefile.in b/Makefile.in +@@ -56,7 +56,7 @@ HEADERS=options.h dbutil.h session.h packet.h algo.h ssh.h buffer.h kex.h \ + loginrec.h atomicio.h x11fwd.h agentfwd.h tcpfwd.h compat.h \ + listener.h fake-rfc2553.h + +-dropbearobjs=$(COMMONOBJS) $(CLISVROBJS) $(SVROBJS) @CRYPTLIB@ ++dropbearobjs=$(COMMONOBJS) $(CLISVROBJS) $(SVROBJS) + dbclientobjs=$(COMMONOBJS) $(CLISVROBJS) $(CLIOBJS) + dropbearkeyobjs=$(COMMONOBJS) $(KEYOBJS) + dropbearconvertobjs=$(COMMONOBJS) $(CONVERTOBJS) +@@ -77,7 +77,7 @@ STRIP=@STRIP@ + INSTALL=@INSTALL@ + CPPFLAGS=@CPPFLAGS@ + CFLAGS+=-I. -I$(srcdir) $(CPPFLAGS) @CFLAGS@ +-LIBS+=@LIBS@ ++LIBS+=@LIBS@ @CRYPTLIB@ + LDFLAGS=@LDFLAGS@ + + EXEEXT=@EXEEXT@ +@@ -169,7 +169,7 @@ scp: $(SCPOBJS) $(HEADERS) Makefile + # multi-binary compilation. + MULTIOBJS= + ifeq ($(MULTI),1) +- MULTIOBJS=dbmulti.o $(sort $(foreach prog, $(PROGRAMS), $($(prog)objs))) @CRYPTLIB@ ++ MULTIOBJS=dbmulti.o $(sort $(foreach prog, $(PROGRAMS), $($(prog)objs))) + CFLAGS+=$(addprefix -DDBMULTI_, $(PROGRAMS)) -DDROPBEAR_MULTI + endif + diff --git a/patches/dropbear-2012.55/series b/patches/dropbear-2012.55/series new file mode 100644 index 000..d9df7e0 --- /dev/null +++ b/patches/dropbear-2012.55/series @@ -0,0 +1,4 @@ +# generated by git-ptx-patches +#tag:base --start-number 1 +0001-Fix-build-on-Darwin.patch +# e4c948951d2fafee17a83f484c126a7e - git-ptx-patches magic -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/2] dropbear: Delete old patches
Seems to have been forgotten in the update (d12c29b0e40e1d3affc0490d18599abaa48fca30). Signed-off-by: Bernhard Walle --- .../0001-libs-must-come-after-object-files.patch | 26 patches/dropbear-0.53.1/series |3 --- 2 files changed, 29 deletions(-) delete mode 100644 patches/dropbear-0.53.1/0001-libs-must-come-after-object-files.patch delete mode 100644 patches/dropbear-0.53.1/series diff --git a/patches/dropbear-0.53.1/0001-libs-must-come-after-object-files.patch b/patches/dropbear-0.53.1/0001-libs-must-come-after-object-files.patch deleted file mode 100644 index eb58d0f..000 --- a/patches/dropbear-0.53.1/0001-libs-must-come-after-object-files.patch +++ /dev/null @@ -1,26 +0,0 @@ -From: Michael Olbrich -Date: Mon, 20 Jun 2011 19:10:16 +0200 -Subject: [PATCH] libs must come after object files - -Signed-off-by: Michael Olbrich - Makefile.in |4 ++-- - 1 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Makefile.in b/Makefile.in -index 8d81647..d72828b 100644 a/Makefile.in -+++ b/Makefile.in -@@ -28,10 +28,10 @@ COMMONOBJS=dbutil.o buffer.o \ - queue.o \ - atomicio.o compat.o fake-rfc2553.o - --SVROBJS=@CRYPTLIB@ svr-kex.o svr-algo.o svr-auth.o sshpty.o \ -+SVROBJS=svr-kex.o svr-algo.o svr-auth.o sshpty.o \ - svr-authpasswd.o svr-authpubkey.o svr-authpubkeyoptions.o svr-session.o svr-service.o \ - svr-chansession.o svr-runopts.o svr-agentfwd.o svr-main.o svr-x11fwd.o\ -- svr-tcpfwd.o svr-authpam.o -+ svr-tcpfwd.o svr-authpam.o @CRYPTLIB@ - - CLIOBJS=cli-algo.o cli-main.o cli-auth.o cli-authpasswd.o cli-kex.o \ - cli-session.o cli-service.o cli-runopts.o cli-chansession.o \ diff --git a/patches/dropbear-0.53.1/series b/patches/dropbear-0.53.1/series deleted file mode 100644 index 5c722bc..000 --- a/patches/dropbear-0.53.1/series +++ /dev/null @@ -1,3 +0,0 @@ -# generated by git-ptx-patches -0001-libs-must-come-after-object-files.patch -# cd06373c86be81f949a6cdf0f13f2b64 - git-ptx-patches magic -- 1.7.9.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH v3] Add flashbench tool
From: Bernhard Walle This patch adds the flashbench tool from Linaro Project git://git.linaro.org/people/arnd/flashbench.git. See also http://lwn.net/Articles/428584/. Because there is no tarball, I exported the current git repo and put it on my server. The default maximum buffer size of 64 MiB (the buffer is allocated 4 times) was too large for my device, so I patched the tool and added an option in the ptxdist menu. Tested with a custom OMAP3 board which is similar to the Devkit8000. Signed-off-by: Bernhard Walle --- v3: - Use menuconfig instead of config. - Change PTXCONF_FLASHBENCH_MAX_BUFSIZE to megabyte. v2: - Correct URL (FIXME) in rules/flashbench.in. ...o-specify-MAX_BUFSIZE-during-compile-time.patch | 37 +++ patches/flashbench-20120222/series |4 ++ rules/flashbench.in| 31 + rules/flashbench.make | 68 4 files changed, 140 insertions(+) create mode 100644 patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch create mode 100644 patches/flashbench-20120222/series create mode 100644 rules/flashbench.in create mode 100644 rules/flashbench.make diff --git a/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch b/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch new file mode 100644 index 000..cc9505b --- /dev/null +++ b/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch @@ -0,0 +1,37 @@ +From: Bernhard Walle +Date: Wed, 14 Mar 2012 16:52:47 +0100 +Subject: [PATCH] Allow to specify MAX_BUFSIZE during compile time + +The default value of 64 MiB is too large for small embedded systems. + +Signed-off-by: Bernhard Walle +--- + Makefile |2 +- + dev.c|2 ++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 8fbd119..01771b0 100644 +--- a/Makefile b/Makefile +@@ -1,5 +1,5 @@ + CC:= gcc +-CFLAGS:= -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -g2 ++CFLAGS:= -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -g2 $(EXTRA_CFLAGS) + LDFLAGS := -lrt + + all: flashbench erase +diff --git a/dev.c b/dev.c +index f1718be..73a9b3f 100644 +--- a/dev.c b/dev.c +@@ -22,7 +22,9 @@ + + #include "dev.h" + ++#ifndef MAX_BUFSIZE + #define MAX_BUFSIZE (64 * 1024 * 1024) ++#endif + + static inline long long time_to_ns(struct timespec *ts) + { diff --git a/patches/flashbench-20120222/series b/patches/flashbench-20120222/series new file mode 100644 index 000..8ac1f19 --- /dev/null +++ b/patches/flashbench-20120222/series @@ -0,0 +1,4 @@ +# generated by git-ptx-patches +#tag:base --start-number 1 +0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch +# 2284485069f201f5dd31c217b70f51e0 - git-ptx-patches magic diff --git a/rules/flashbench.in b/rules/flashbench.in new file mode 100644 index 000..e8f09ef --- /dev/null +++ b/rules/flashbench.in @@ -0,0 +1,31 @@ +## SECTION=test_suites + +menuconfig FLASHBENCH + tristate + prompt "flashbench" + help + Identify characteristics of flash media + + This is the tool used to identify the properties of + SD cards and other media for the Linaro flash memory + survey at [1]. The latest version should be available + at [2]. Please also check out the article on lwn.net [3]. + + [1] https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCardSurvey + [2] git clone git://git.linaro.org/people/arnd/flashbench.git + [3] http://lwn.net/Articles/428584/ + +if FLASHBENCH + +config FLASHBENCH_MAX_BUFSIZE + string + prompt "Maximum flashbench buffer size in megabytes" + default 64 + help + This is the maximum buffer size flashbench uses during operationg. + The buffer gets allocated 4 times, so take that into account when + choosing a buffer. The default is 64 MiB. + +endif + +# vim: set ft=kconfig: diff --git a/rules/flashbench.make b/rules/flashbench.make new file mode 100644 index 000..fcb669e --- /dev/null +++ b/rules/flashbench.make @@ -0,0 +1,68 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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_FLASHBENCH) += flashbench + +# +# Paths and names +# +FLASHBENCH_VERSION := 20120222 +FLASHBENCH_MD5 := 3d99608022b50e891e5f66d7c637d8b1 +FLASHBENCH := flashbench-$(FLASHBENCH_VERSION) +FLASHBENCH_SUFFIX := tar.gz +FLASHBENCH_URL := http://bwalle.de/programme/$(FLASHBENCH).$(FLASHBE
[ptxdist] [PATCH v2] Add flashbench tool
From: Bernhard Walle This patch adds the flashbench tool from Linaro Project git://git.linaro.org/people/arnd/flashbench.git. See also http://lwn.net/Articles/428584/. Because there is no tarball, I exported the current git repo and put it on my server. The default maximum buffer size of 64 MiB (the buffer is allocated 4 times) was too large for my device, so I patched the tool and added an option in the ptxdist menu. Tested with a custom OMAP3 board which is similar to the Devkit8000. Signed-off-by: Bernhard Walle --- v2: Correct URL (FIXME) in rules/flashbench.in. ...o-specify-MAX_BUFSIZE-during-compile-time.patch | 37 +++ patches/flashbench-20120222/series |4 ++ rules/flashbench.in| 31 + rules/flashbench.make | 68 4 files changed, 140 insertions(+) create mode 100644 patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch create mode 100644 patches/flashbench-20120222/series create mode 100644 rules/flashbench.in create mode 100644 rules/flashbench.make diff --git a/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch b/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch new file mode 100644 index 000..cc9505b --- /dev/null +++ b/patches/flashbench-20120222/0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch @@ -0,0 +1,37 @@ +From: Bernhard Walle +Date: Wed, 14 Mar 2012 16:52:47 +0100 +Subject: [PATCH] Allow to specify MAX_BUFSIZE during compile time + +The default value of 64 MiB is too large for small embedded systems. + +Signed-off-by: Bernhard Walle +--- + Makefile |2 +- + dev.c|2 ++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 8fbd119..01771b0 100644 +--- a/Makefile b/Makefile +@@ -1,5 +1,5 @@ + CC:= gcc +-CFLAGS:= -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -g2 ++CFLAGS:= -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -g2 $(EXTRA_CFLAGS) + LDFLAGS := -lrt + + all: flashbench erase +diff --git a/dev.c b/dev.c +index f1718be..73a9b3f 100644 +--- a/dev.c b/dev.c +@@ -22,7 +22,9 @@ + + #include "dev.h" + ++#ifndef MAX_BUFSIZE + #define MAX_BUFSIZE (64 * 1024 * 1024) ++#endif + + static inline long long time_to_ns(struct timespec *ts) + { diff --git a/patches/flashbench-20120222/series b/patches/flashbench-20120222/series new file mode 100644 index 000..8ac1f19 --- /dev/null +++ b/patches/flashbench-20120222/series @@ -0,0 +1,4 @@ +# generated by git-ptx-patches +#tag:base --start-number 1 +0001-Allow-to-specify-MAX_BUFSIZE-during-compile-time.patch +# 2284485069f201f5dd31c217b70f51e0 - git-ptx-patches magic diff --git a/rules/flashbench.in b/rules/flashbench.in new file mode 100644 index 000..6f44015 --- /dev/null +++ b/rules/flashbench.in @@ -0,0 +1,31 @@ +## SECTION=test_suites + +config FLASHBENCH + tristate + prompt "flashbench" + help + Identify characteristics of flash media + + This is the tool used to identify the properties of + SD cards and other media for the Linaro flash memory + survey at [1]. The latest version should be available + at [2]. Please also check out the article on lwn.net [3]. + + [1] https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCardSurvey + [2] git clone git://git.linaro.org/people/arnd/flashbench.git + [3] http://lwn.net/Articles/428584/ + +if FLASHBENCH + +config FLASHBENCH_MAX_BUFSIZE + string + prompt "Maximum flashbench buffer size in bytes" + default 67108864 + help + This is the maximum buffer size flashbench uses during operationg. + The buffer gets allocated 4 times, so take that into account when + choosing a buffer. The default is 64 MiB. + +endif + +# vim: set ft=kconfig: diff --git a/rules/flashbench.make b/rules/flashbench.make new file mode 100644 index 000..f71f0c8 --- /dev/null +++ b/rules/flashbench.make @@ -0,0 +1,68 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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_FLASHBENCH) += flashbench + +# +# Paths and names +# +FLASHBENCH_VERSION := 20120222 +FLASHBENCH_MD5 := 3d99608022b50e891e5f66d7c637d8b1 +FLASHBENCH := flashbench-$(FLASHBENCH_VERSION) +FLASHBENCH_SUFFIX := tar.gz +FLASHBENCH_URL := http://bwalle.de/programme/$(FLASHBENCH).$(FLASHBENCH_SUFFIX) +FLASHBENCH_SOURCE := $(SRCDIR)/$(FLASHBENCH).$(FLASHBENCH_SUFFIX) +FLASHBENCH_DIR := $(BUILDDIR)/$(F
[ptxdist] [PATCH 2/2] mtd-utils.in: Add busybox dependencies
Some tools that mtd-utils provide can be also provided by busybox. Add the dependencies here as done in other configuration files to prevent the user from misconfiguration. Signed-off-by: Bernhard Walle --- rules/mtd-utils.in | 28 1 file changed, 28 insertions(+) diff --git a/rules/mtd-utils.in b/rules/mtd-utils.in index 87396f9..b12d5f9 100644 --- a/rules/mtd-utils.in +++ b/rules/mtd-utils.in @@ -49,9 +49,13 @@ config MTD_UTILS_FLASH_ERASEALL config MTD_UTILS_FLASH_LOCK bool prompt "flash_lock" + depends on !BUSYBOX_FLASH_LOCK || ALLYES help This utility locks one or more sectors of flash device. +comment "busybox' flash_lock is selected!" + depends on BUSYBOX_FLASH_LOCK + config MTD_UTILS_FLASH_OTP_DUMP bool prompt "flash_otp_dump" @@ -67,15 +71,23 @@ config MTD_UTILS_FLASH_OTP_INFO config MTD_UTILS_FLASH_UNLOCK bool prompt "flash_unlock" + depends on !BUSYBOX_FLASH_UNLOCK || ALLYES help This utility unlock all sectors of flash device. +comment "busybox' flash_unlock is selected!" + depends on BUSYBOX_FLASH_UNLOCK + config MTD_UTILS_FLASHCP bool prompt "flashcp" + depends on !BUSYBOX_FLASHCP || ALLYES help Flash Copy - Written by Abraham van der Merwe +comment "busybox' flashcp is selected!" + depends on BUSYBOX_FLASHCP + config MTD_UTILS_FTL_CHECK bool prompt "ftl_check" @@ -120,10 +132,14 @@ config MTD_UTILS_MTDDEBUG config MTD_UTILS_NANDDUMP bool prompt "nanddump" + depends on !BUSYBOX_NANDDUMP || ALLYES help This utility dumps the contents of raw NAND chips or NAND chips contained in DoC devices. +comment "busybox' nanddump is selected!" + depends on BUSYBOX_NANDDUMP + config MTD_UTILS_NANDTEST bool prompt "nandtest" @@ -133,11 +149,15 @@ config MTD_UTILS_NANDTEST config MTD_UTILS_NANDWRITE bool prompt "nandwrite" + depends on !BUSYBOX_NANDWRITE || ALLYES help This utility writes a binary image directly to a NAND flash chip or NAND chips contained in DoC devices. This is the "inverse operation" of nanddump. +comment "busybox' nandwrite is selected!" + depends on BUSYBOX_NANDWRITE + config MTD_UTILS_NFTL_FORMAT bool prompt "nftl_format" @@ -200,9 +220,13 @@ if MTD_UTILS_UBI_UTILS config MTD_UTILS_UBIATTACH bool prompt "ubiattach" + depends on !BUSYBOX_UBIATTACH || ALLYES help Attach an ubi device to a mtd device +comment "busybox' ubiattach is selected!" + depends on BUSYBOX_UBIATTACH + config MTD_UTILS_UBICRC32 bool prompt "ubicrc32" @@ -212,9 +236,13 @@ config MTD_UTILS_UBICRC32 config MTD_UTILS_UBIDETACH bool prompt "ubidetach" + depends on !BUSYBOX_UBIDETACH || ALLYES help Detach an ubi device from a mtd device +comment "busybox' ubidetach is selected!" + depends on BUSYBOX_UBIDETACH + config MTD_UTILS_UBIFORMAT bool select GCCLIBS_GCC_S -- 1.7.9.2 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/2] Update mtd-utils to 1.4.9
I had to rework some patches. Parallel build has been fixed upstream due in commits 5b1cfb9d09a8a40577e79262c6d79dfcde36b1b7 and 05f56bf49ee0de8979c29c11f61a01e30e96, so we should be able to enable it here. flash-info has been dropped and mtdinfo should be used instead. Signed-off-by: Bernhard Walle --- .../0001-make-liblzo-optional.patch| 107 .../0002-make-mkubifs-optional.patch | 26 - patches/mtd-utils-1.4.6/series |2 - .../mtd-utils-1.4.9/0001-make-ubifs-optional.patch | 25 + ...0002-Make-liblzo-optional-for-ubifs-tools.patch | 55 ++ patches/mtd-utils-1.4.9/series |6 ++ rules/host-mtd-utils.make |2 - rules/mtd-utils.in | 10 +- rules/mtd-utils.make |9 +- 9 files changed, 90 insertions(+), 152 deletions(-) delete mode 100644 patches/mtd-utils-1.4.6/0001-make-liblzo-optional.patch delete mode 100644 patches/mtd-utils-1.4.6/0002-make-mkubifs-optional.patch delete mode 100644 patches/mtd-utils-1.4.6/series create mode 100644 patches/mtd-utils-1.4.9/0001-make-ubifs-optional.patch create mode 100644 patches/mtd-utils-1.4.9/0002-Make-liblzo-optional-for-ubifs-tools.patch create mode 100644 patches/mtd-utils-1.4.9/series diff --git a/patches/mtd-utils-1.4.6/0001-make-liblzo-optional.patch b/patches/mtd-utils-1.4.6/0001-make-liblzo-optional.patch deleted file mode 100644 index 00845a1..000 --- a/patches/mtd-utils-1.4.6/0001-make-liblzo-optional.patch +++ /dev/null @@ -1,107 +0,0 @@ -From: Marc Kleine-Budde -Date: Mon, 20 Jul 2009 19:37:09 +0200 -Subject: [PATCH] make liblzo optional - -Signed-off-by: Marc Kleine-Budde - Makefile|3 ++- - compr.h |2 ++ - mkfs.ubifs/Makefile |6 +- - mkfs.ubifs/compr.c | 17 + - 4 files changed, 26 insertions(+), 2 deletions(-) - -Index: mtd-utils-1.4.6/Makefile -=== mtd-utils-1.4.6.orig/Makefile -+++ mtd-utils-1.4.6/Makefile -@@ -10,6 +10,7 @@ ifeq ($(WITHOUT_LZO), 1) - CPPFLAGS += -DWITHOUT_LZO - else - LZOLDLIBS = -llzo2 -+ JFFS2_COMPR_LZO_O := compr_lzo.o - endif - - SUBDIRS = lib ubi-utils mkfs.ubifs -@@ -50,7 +51,7 @@ $(SYMLINKS): - ln -sf ../fs/jffs2/$@ $@ - - $(BUILDDIR)/mkfs.jffs2: $(addprefix $(BUILDDIR)/,\ -- compr_rtime.o mkfs.jffs2.o compr_zlib.o compr_lzo.o \ -+ compr_rtime.o mkfs.jffs2.o compr_zlib.o $(JFFS2_COMPR_LZO_O) \ - compr.o rbtree.o) - LDFLAGS_mkfs.jffs2 = $(ZLIBLDFLAGS) $(LZOLDFLAGS) - LDLIBS_mkfs.jffs2 = -lz $(LZOLDLIBS) -Index: mtd-utils-1.4.6/compr.h -=== mtd-utils-1.4.6.orig/compr.h -+++ mtd-utils-1.4.6/compr.h -@@ -18,7 +18,9 @@ - - #define CONFIG_JFFS2_ZLIB - #define CONFIG_JFFS2_RTIME -+#ifndef WITHOUT_LZO - #define CONFIG_JFFS2_LZO -+#endif - - #define JFFS2_RUBINMIPS_PRIORITY 10 - #define JFFS2_DYNRUBIN_PRIORITY 20 -Index: mtd-utils-1.4.6/mkfs.ubifs/Makefile -=== mtd-utils-1.4.6.orig/mkfs.ubifs/Makefile -+++ mtd-utils-1.4.6/mkfs.ubifs/Makefile -@@ -6,7 +6,11 @@ ALL_SOURCES=*.[ch] hashtable/*.[ch] - - TARGETS = mkfs.ubifs - --LDLIBS_mkfs.ubifs = -lz -llzo2 -lm -luuid -L$(BUILDDIR)/../ubi-utils/ -lubi -+ifneq ($(WITHOUT_LZO), 1) -+mkfs.ubifs_LIBLZO = -llzo2 -+endif -+ -+LDLIBS_mkfs.ubifs = -lz $(mkfs.ubifs_LIBLZO) -lm -luuid -L$(BUILDDIR)/../ubi-utils/ -lubi - LDLIBS_mkfs.ubifs += -L$(BUILDDIR)/../lib -lmtd - LDLIBS_mkfs.ubifs += $(ZLIBLDFLAGS) $(LZOLDFLAGS) - -Index: mtd-utils-1.4.6/mkfs.ubifs/compr.c -=== mtd-utils-1.4.6.orig/mkfs.ubifs/compr.c -+++ mtd-utils-1.4.6/mkfs.ubifs/compr.c -@@ -24,7 +24,11 @@ - #include - #include - #include -+#ifndef WITHOUT_LZO - #include -+#else -+#define LZO1X_999_MEM_COMPRESS0 -+#endif - #include - - #define crc32 __zlib_crc32 -@@ -86,6 +90,8 @@ static int zlib_deflate(void *in_buf, si - return 0; - } - -+ -+#ifndef WITHOUT_LZO - static int lzo_compress(void *in_buf, size_t in_len, void *out_buf, - size_t *out_len) - { -@@ -103,6 +109,17 @@ static int lzo_compress(void *in_buf, si - - return 0; - } -+#else -+static inline int lzo_compress(void *in_buf, size_t in_len, void *out_buf, -+ size_t *out_len) -+{ -+ (void)in_buf; -+ (void)in_len; -+ (void)out_buf; -+ (void)out_len; -+ return -1; -+} -+#endif - - static int no_compress(void *in_buf, size_t in_len, void *out_buf, - size_t *out_len) diff --git a/patches/mtd-utils-1.4.6/0002-make-mkubifs-optional.patch b/patches/mtd-utils-1.4.6/0002-make-mkubifs-optional.patch deleted file mode 100644 index 23d0111..000 --- a/patches/mtd-utils
[ptxdist] [PATCH v2] mtd-utils update / fixes
This is the 2nd/3rd version of the patches. Hopefully the last round. Sorry for the confusion today. Too many machines, branches and too much work at the same time. :( -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH 1/3] Update mtd-utils to 1.4.9
* Michael Olbrich [2012-03-13 10:09]: > > > > flash-info has been dropped in favour to mtdinfo. > > An option for mtdinfo already exists. Indeed, I missed that. But it's in the ubi directory, so I adjusted the dependencies in Kconfig. > > +++ > > b/patches/mtd-utils-1.4.9/0003-Makefile-Use-LZOLDFLAGS-when-building-mkfs.ubifs.patch > > @@ -0,0 +1,24 @@ > > +From: Bernhard Walle > > +Date: Sun, 11 Mar 2012 18:38:20 +0100 > > +Subject: [PATCH] Makefile: Use LZOLDFLAGS when building mkfs.ubifs > > + > > +The LZOLDFLAGS variable is used by jffs2 but not by mkfs.ubifs. > > Please elaborate why this is needed. Indeed, that's for upstream. It's not needed as ptxdist patch. New patch will follow. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] ptxdist: Check for GNU readlink
* Michael Olbrich [2012-03-13 11:14]: > > Not the 'local', the whole function. Getting all corner-cases right for > something like this is not trivial. Ah, ok. Indeed. That's why I started using something from the Internet[tm] and that's also why I only replaced that initial "readlink -f" call to find the ptxdist directory by the Bash implementation. The rest should still be (g)readlink -f. The alternative would be a Perl one-liner or Python. But that would be add additional requirements. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH 2/3] mtd-utils.in: Add busybox dependencies
* Michael Olbrich [2012-03-13 10:12]: > On Mon, Mar 12, 2012 at 03:09:04PM +0100, bernh...@bwalle.de wrote: > > From: Bernhard Walle > > > > Some tools that mtd-utils provide can be also provided by busybox. Add > > the dependencies here as done in other configuration files to prevent > > the user from misconfiguration. > > > > Signed-off-by: Bernhard Walle > > --- > > rules/mtd-utils.in | 32 > > 1 file changed, 32 insertions(+) > > > > diff --git a/rules/mtd-utils.in b/rules/mtd-utils.in > > index bc25ace..30ec133 100644 > > --- a/rules/mtd-utils.in > > +++ b/rules/mtd-utils.in > > @@ -43,9 +43,13 @@ config MTD_UTILS_FLASH_ERASEALL > > bool > > prompt "flash_eraseall (deprecated)" > > select MTD_UTILS_FLASH_ERASE > > + depends on !BUSYBOX_FLASH_ERASEALL > > depends on !BUSYBOX_FLASH_ERASEALL || ALLYES > > For all. Sorry, I missed that in the last review. Only for that one in rules/mtd-utils.in or really for all such Busybox comments? Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 2/2] ptxdist: Check for GNU readlink
ptxdist heavily uses "readlink -f" which only works with GNU readlink. So add the usual check here. However, because "readlink -f" is also used before the symlinks in the ptxdist directory is added to the PATH, that "readlink -f" call is replaced by a bash-only implementation. This one is inspired from http://mailman.archlinux.org/pipermail/pacman-dev/2009-February/008130.html. Tested on Mac OS 10.7. Signed-off-by: Bernhard Walle --- Makefile.in |1 + bin/ptxdist | 22 +- configure.ac |1 + 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/Makefile.in b/Makefile.in index e62a2d9..17a6ce6 100644 --- a/Makefile.in +++ b/Makefile.in @@ -54,6 +54,7 @@ environment: @ln -sf @GNU_stat@ "$(abs_srcdir)/bin/stat" @ln -sf @GNU_mknod@ "$(abs_srcdir)/bin/mknod" @ln -sf @GNU_tar@ "$(abs_srcdir)/bin/tar" + @ln -sf @GNU_readlink@ "$(abs_srcdir)/bin/readlink" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" @ln -sf @XARGS@ "$(abs_srcdir)/bin/xargs" diff --git a/bin/ptxdist b/bin/ptxdist index eb3366a..7636187 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -1843,6 +1843,26 @@ EOF setup stuff only ## +# +# bash implementation of realpath / readlink -f +# arg1 - filename +realpath() +{ + local fname oldfname + + fname=${1%/} # strips trailing '/' + while [ -L "${fname}" ]; do + oldfname="${fname}" + fname="$(readlink ${fname})" + if [ "$fname" = . ] ; then + fname="$(dirname $oldfname)" + elif [ "${fname}" = "${fname#/}" ]; then + fname="$(dirname "${oldfname}")/${fname}" + fi + done + + (cd $(dirname ${fname}); echo $(pwd -P)/$(basename ${fname})) +} # # figure out PTXDIST_TOPDIR @@ -1859,7 +1879,7 @@ EOF setup_topdir() { local ptxdist topdir - ptxdist="$(readlink -f "${0}")" && + ptxdist="$(realpath "${0}")" && topdir="$(cd "$(dirname "${ptxdist}")"/.. && pwd)" || return # diff --git a/configure.ac b/configure.ac index 37a01ae..780bf28 100644 --- a/configure.ac +++ b/configure.ac @@ -155,6 +155,7 @@ GNU_TOOL(mkdir, coreutils) GNU_TOOL(install, coreutils) GNU_TOOL(stat, coreutils) GNU_TOOL(mknod, coreutils) +GNU_TOOL(readlink, coreutils) GNU_TOOL(tar, tar) dnl Check for egrep -- 1.7.9.2 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/2] Makefile.in: Create symlink for xargs
We check for a xargs binary that supports the '-r' flag, so put the usual symlink into the bin directory once we have found a proper implementation. Signed-off-by: Bernhard Walle --- Makefile.in |1 + 1 file changed, 1 insertion(+) diff --git a/Makefile.in b/Makefile.in index b976a3f..e62a2d9 100644 --- a/Makefile.in +++ b/Makefile.in @@ -56,6 +56,7 @@ environment: @ln -sf @GNU_tar@ "$(abs_srcdir)/bin/tar" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" + @ln -sf @XARGS@ "$(abs_srcdir)/bin/xargs" @echo " done" clean: -- 1.7.9.2 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] ptxdist: Check for GNU readlink
Hi Michael, thanks again for the review. * Michael Olbrich [2012-02-14 23:05]: > > +# bash implementation of realpath / readlink -f > > +# arg1 - filename > > +realpath() > > +{ > > + local fname oldfname > > + > > hmmm, scary. What's wrong about 'local'? > Another idea: Is the problem that "readlink -f" does not work or does > "readlink" not exist at all? Any readlink implementations should work here > for fname="$(readlink "${fname}")". You're right. Even Apple adds a working readlink implementation. :) > > + if [ "$fname" = . ] ; then > > + fname="$(dirname $oldfname)" > > + elif echo $fname | grep -vq '^/' - ; then > > elif [ "${fname}" -eq "${fname#/}" ]; then -eq is only for numeric comparison, so it should be '=', right? > ( cd "$(dirname "${fname}")" > > > + fname=$(pwd -P)/$(basename $fname) > > ) Assigning a variable in a subshell has no effect on the outer shell, has it? But echo'ing directly here works. A reworked version will follow. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [ANNOUNCE] PTXdist 2012.03.0 released
* Michael Olbrich [2012-03-12 09:49]: > > I've released PTXdist 2012.03.0. Mostly bugfixes, but be careful when > updating: The udev package was rewritten. The previous 'experimental' > version is now the old version and udev 181 is now the default. > The new udev version requires a mounted devtmpfs. If that's not > possible for you then select the old udev version. And for all people that have a custom fstab in their project: The new udev requires /run to exist and to be writable. Otherwise it exits with an error that it cannot bind a control socket. (If you have the default generic fstab, everything is fine.) Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] How to patch a rule file
Am 24.02.12 18:20, schrieb Robert Palmer: > I've searched the archives (unfortunately "patch" is VERY common) > and I read the "How to become a PTXdist Guru" from the pengutronix > web site. In section 4.1.2 patch series, it gives an overview of > patching and it then list the search order, giving FOUR cases. > The last case is "bug fixing" and it goes on to describe that this > case is intended for patching rules in the PTXdist rule files. > This is EXACTLY what I need to do, unfortunately, that's the last > thing is says about this case. > > specifically, I'm using ptxdist-2010.08.0 and GNU Make v3.82. > I'm trying to build the OSELAS toolchain, so I'm working with > that as the "project" directory > > in the ptxdist rules there is apache2.make which needs to be > patched to run under Make v3.82 (there is a missing line > continuation character) > > I have tried building a patch in my toolchain (project) /patches folder > > a) naming the patch folder (package) 'apache2' >-- matching the rule name found in ptxdist/rules > b) naming the folder 'httpd-2.0.58' >-- matching the package name as described in the rule makefile You can't patch the rules file. Just copy it to your project, it overwrites the default one. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] configure.ac: Check for GNU tar
ptxd_make_world_extract uses the option --remove-files which is a GNU extension to tar. Because GNU tar is not in GNU coreutils, I changed the GNU_COREUTILS macro to GNU_TOOL and added a second parameter: the package where the tool is found. I think that's better than providing a new macro just for GNU tar. Signed-off-by: Bernhard Walle --- Makefile.in |2 +- configure.ac | 41 +++-- 2 files changed, 20 insertions(+), 23 deletions(-) diff --git a/Makefile.in b/Makefile.in index 0c05294..b976a3f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -53,9 +53,9 @@ environment: @ln -sf @GNU_install@ "$(abs_srcdir)/bin/install" @ln -sf @GNU_stat@ "$(abs_srcdir)/bin/stat" @ln -sf @GNU_mknod@ "$(abs_srcdir)/bin/mknod" + @ln -sf @GNU_tar@ "$(abs_srcdir)/bin/tar" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" - @ln -sf @TAR@ "$(abs_srcdir)/bin/tar" @echo " done" clean: diff --git a/configure.ac b/configure.ac index ca06879..37a01ae 100644 --- a/configure.ac +++ b/configure.ac @@ -133,26 +133,29 @@ case "$SED_VERSION" in esac AC_MSG_RESULT([$SED_VERSION]) -dnl check for gnu coreutils -AC_DEFUN([GNU_COREUTILS], - [AC_CACHE_CHECK([for $1 from GNU coreutils], [ac_cv_path_gnu_$1], +dnl check for gnu tools +dnl $1: tool to search for +dnl $2: package where the tool is (e.g. 'coreutils') +AC_DEFUN([GNU_TOOL], + [AC_CACHE_CHECK([for GNU $1], [ac_cv_path_gnu_$1], [AC_PATH_PROGS_FEATURE_CHECK([gnu_$1], [g$1 $1.gnu $1], - [[out=`$ac_path_gnu_$1 --version 2>/dev/null | $SED -ne "s/.*\(GNU\) coreutils.*/\1/p"` + [[out=`$ac_path_gnu_$1 --version 2>/dev/null | $SED -ne "s/.*\(GNU\) $2.*/\1/p"` test "x$out" = xGNU && ac_cv_path_gnu_$1=$ac_path_gnu_$1 ac_path_gnu_$1_found=:]], - [AC_MSG_ERROR([could not find $1 from GNU coreutils])])]) + [AC_MSG_ERROR([could not find GNU $1])])]) AC_SUBST([GNU_$1], [$ac_cv_path_gnu_$1])]) -GNU_COREUTILS(chmod) -GNU_COREUTILS(chown) -GNU_COREUTILS(mv) -GNU_COREUTILS(cp) -GNU_COREUTILS(rm) -GNU_COREUTILS(rmdir) -GNU_COREUTILS(md5sum) -GNU_COREUTILS(mkdir) -GNU_COREUTILS(install) -GNU_COREUTILS(stat) -GNU_COREUTILS(mknod) +GNU_TOOL(chmod, coreutils) +GNU_TOOL(chown, coreutils) +GNU_TOOL(mv, coreutils) +GNU_TOOL(cp, coreutils) +GNU_TOOL(rm, coreutils) +GNU_TOOL(rmdir, coreutils) +GNU_TOOL(md5sum, coreutils) +GNU_TOOL(mkdir, coreutils) +GNU_TOOL(install, coreutils) +GNU_TOOL(stat, coreutils) +GNU_TOOL(mknod, coreutils) +GNU_TOOL(tar, tar) dnl Check for egrep AC_PROG_EGREP @@ -261,12 +264,6 @@ if test -z "$WGET"; then AC_MSG_ERROR([wget could not be found, please install]) fi -dnl Check for tar -AC_PATH_PROGS(TAR, tar,, $PATH) -if test -z "$TAR"; then - AC_MSG_ERROR([tar could not be found, please install]) -fi - dnl Check for dirname AC_PATH_PROGS(DIRNAME, dirname,, $PATH) if test -z "$DIRNAME"; then -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] configure.ac: Check for GNU mknod
We need that because scripts/lib/ptxd_make_xpkg_pkg.sh uses the -m parameter of mknod which doesn't exist in BSD mknod. Signed-off-by: Bernhard Walle --- Makefile.in |1 + configure.ac |1 + 2 files changed, 2 insertions(+), 0 deletions(-) diff --git a/Makefile.in b/Makefile.in index e8544d1..0c05294 100644 --- a/Makefile.in +++ b/Makefile.in @@ -52,6 +52,7 @@ environment: @ln -sf @GNU_mkdir@ "$(abs_srcdir)/bin/mkdir" @ln -sf @GNU_install@ "$(abs_srcdir)/bin/install" @ln -sf @GNU_stat@ "$(abs_srcdir)/bin/stat" + @ln -sf @GNU_mknod@ "$(abs_srcdir)/bin/mknod" @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" @ln -sf @TAR@ "$(abs_srcdir)/bin/tar" diff --git a/configure.ac b/configure.ac index 00c2521..ca06879 100644 --- a/configure.ac +++ b/configure.ac @@ -152,6 +152,7 @@ GNU_COREUTILS(md5sum) GNU_COREUTILS(mkdir) GNU_COREUTILS(install) GNU_COREUTILS(stat) +GNU_COREUTILS(mknod) dnl Check for egrep AC_PROG_EGREP -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] {os-release, rootfs}.make: Don't rely on GNU date
date -Iseconds is a GNU extension. Since that one is only used in two places, don't check for GNU date but use the portable variant (format specifiers). Signed-off-by: Bernhard Walle --- rules/os-release.make |2 +- rules/rootfs.make |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rules/os-release.make b/rules/os-release.make index 3f41374..eb32535 100644 --- a/rules/os-release.make +++ b/rules/os-release.make @@ -46,7 +46,7 @@ $(STATEDIR)/os-release.targetinstall: $(PTXDIST_PTXCONFIG) $(PTXDIST_PLATFORMCON @PTXDIST_VERSION@, $(PTXDIST_VERSION_FULL)) @$(call install_replace, os-release, /etc/os-release, \ - @DATE@, $(shell date -Iseconds)) + @DATE@, $(shell date +%Y-%M-%dT%H:%M:%S%z)) @$(call install_finish,os-release) diff --git a/rules/rootfs.make b/rules/rootfs.make index 13a5f2c..ed30235 100644 --- a/rules/rootfs.make +++ b/rules/rootfs.make @@ -185,7 +185,7 @@ ifdef PTXCONF_ROOTFS_ISSUE @$(call install_replace, rootfs, /etc/issue, \ @EXTRAVERSION@, $(PTXDIST_VERSION_SCM)) @$(call install_replace, rootfs, /etc/issue, \ - @DATE@, $(shell date -Iseconds)) + @DATE@, $(shell date +%Y-%M-%dT%H:%M:%S%z)) @$(call install_replace, rootfs, /etc/issue, \ @VENDOR@, $(PTXCONF_PROJECT_VENDOR)) @$(call install_replace, rootfs, /etc/issue, \ -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Not reproducable bugs on compiling OSELAS Toolchain
Hi, * Andreas Bießmann [2012-02-25 09:21]: > > Next you will need some GNU tools like coreutils [1], gawk [2], sed [3], > tar [4], flex [5] and bison/yacc [6]. Remaining requirements of ptxdist > should be sufficient by OS X delivered software. flex and bison can be used from Apple (at least I have /usr/bin/flex and /usr/bin/bison in my $PATH). You also need 'md5sum' (macports has the 'md5sha1sum' package). And also GNU ar because of the 'f' option, but I want to check if it's really needed before sending a patch to check for GNU ar. > If you got the required tools you can start using ptxdist source to > build it for your host. There comes another requirement to mind while > writing this. You will need ncurses[9] for building the kconf tools in > ptxdist. Ptxdists configure will search the required tools and complain > about missing ones. I'm not sure if the ncurses from Apple is sufficient, but at least /usr/lib/libncuses.dylib is there. Apart from building kconfig, ptxdist uses its own host-ncurses, though. > Bernhard Walle started a generic arm bsp [10] (targeted on beagle-board > and clones). He uses ptxdist with OS X too, therefore this is a good > place to go for OS X adoptions of ptxdist bsp. I would have called it 'playground'. :) I just checked that it builds with ptxdist-2012.02 without any additional patches. The only remaining patch that is in the queue of Michael is the localedef stuff. If you need it now, you can take it from https://bitbucket.org/bwalle/localedef/overview (darwin-fixes branch) or as patch from https://bitbucket.org/bwalle/ptxdist-vetero/src/770a9a83af73/patches/localedef-eglibc-2.11.90-ptx1. Please note that the ptxdist-vetero project doesn't build currently on Mac OS because of the mtd tools. I need to fix that when I have time. ('ptxdist go' works but 'ptxdist images' will fail.) Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] ptxdist: Check for GNU readlink
ptxdist heavily uses "readlink -f" which only works with GNU readlink. So add the usual check here. However, because "readlink -f" is also used before the symlinks in the ptxdist directory is added to the PATH, that "readlink -f" call is replaced by a bash-only implementation. This one is copied from http://mailman.archlinux.org/pipermail/pacman-dev/2009-February/008130.html. Tested on Mac OS 10.7. Signed-off-by: Bernhard Walle --- Makefile.in |1 + bin/ptxdist | 25 - configure.ac |1 + 3 files changed, 26 insertions(+), 1 deletions(-) diff --git a/Makefile.in b/Makefile.in index e8544d1..2181608 100644 --- a/Makefile.in +++ b/Makefile.in @@ -55,6 +55,7 @@ environment: @ln -sf @PYTHON@ "$(abs_srcdir)/bin/python" @ln -sf @SED@ "$(abs_srcdir)/bin/sed" @ln -sf @TAR@ "$(abs_srcdir)/bin/tar" + @ln -sf @READLINK@ "$(abs_srcdir)/bin/readlink" @echo " done" clean: diff --git a/bin/ptxdist b/bin/ptxdist index eb3366a..9355b1f 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -1843,6 +1843,29 @@ EOF setup stuff only ## +# +# bash implementation of realpath / readlink -f +# arg1 - filename +realpath() +{ + local fname oldfname + + fname=${1%/} # strips trailing '/' + while [ -L "$fname" ]; do + oldfname="$fname" + fname="$(command ls -l $fname)" + fname="${fname#*\> }" + if [ "$fname" = . ] ; then + fname="$(dirname $oldfname)" + elif echo $fname | grep -vq '^/' - ; then + fname="$(dirname $oldfname)/$fname" + fi + done + pushd $(dirname $fname) > /dev/null + fname=$(pwd -P)/$(basename $fname) + popd > /dev/null + echo $fname +} # # figure out PTXDIST_TOPDIR @@ -1859,7 +1882,7 @@ EOF setup_topdir() { local ptxdist topdir - ptxdist="$(readlink -f "${0}")" && + ptxdist="$(realpath "${0}")" && topdir="$(cd "$(dirname "${ptxdist}")"/.. && pwd)" || return # diff --git a/configure.ac b/configure.ac index 00c2521..497441c 100644 --- a/configure.ac +++ b/configure.ac @@ -152,6 +152,7 @@ GNU_COREUTILS(md5sum) GNU_COREUTILS(mkdir) GNU_COREUTILS(install) GNU_COREUTILS(stat) +GNU_COREUTILS(readlink) dnl Check for egrep AC_PROG_EGREP -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] lpc21isp: Update to 1.83
* Michael Olbrich [2012-02-14 09:11]: > On Tue, Feb 07, 2012 at 06:00:06PM +0100, bernh...@bwalle.de wrote: > > From: Bernhard Walle > > > > I don't know why the name of the tarball is completely different and I > > also don't know why the tarball doesn't contain a directory. That's > > upstream. > > > > At least the program builds and works correctly. > > I cannot apply this. There are some line-end issues with it. > Please resend. Ah yes, I remember, the line endings. :( Here as gzip'd attachment. Regards, Bernhard 0001-lpc21isp-Update-to-1.83.patch.gz Description: Binary data -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] u-boot: Allow copying of u-boot SPL to images
This patch adds two options: 1) U_BOOT_INSTALL_MLO copies the "MLO" (u-boot SPL which replaces x-loader for OMAP CPUs) to the images directory. 2) U_BOOT_INSTALL_U_BOOT_IMG copies "u-boot.img" in addition to the u-boot binary because u-boot SPL expects the u-boot.img (which contains an additional u-boot header) on a SD card. Because of the file name conflict, U_BOOT_INSTALL_MLO is only selectable when x-loader is not built. Signed-off-by: Bernhard Walle --- platforms/u-boot.in | 19 +++ rules/u-boot.make |6 ++ 2 files changed, 25 insertions(+), 0 deletions(-) diff --git a/platforms/u-boot.in b/platforms/u-boot.in index 86f0703..1cac07b 100644 --- a/platforms/u-boot.in +++ b/platforms/u-boot.in @@ -60,5 +60,24 @@ config U_BOOT_INSTALL_ELF help Installing the U-Boot ELF binary into platform image directory. +config U_BOOT_INSTALL_MLO + prompt "install MLO" +bool + depends on !X_LOAD + help + Installing the U-Boot SPL ("MLO") binary needed for OMAP CPUs into platform + image directory. + +if U_BOOT_INSTALL_MLO + +config U_BOOT_INSTALL_U_BOOT_IMG + prompt "install u-boot.img" +bool + help + Installing the u-boot image with header ("u-boot.img") which is executed + by u-boot SPL ("MLO") into platform image directory. + +endif + endif diff --git a/rules/u-boot.make b/rules/u-boot.make index bee7faf..36760ee 100644 --- a/rules/u-boot.make +++ b/rules/u-boot.make @@ -70,6 +70,12 @@ endif ifdef PTXCONF_U_BOOT_INSTALL_ELF @install -D -m644 $(U_BOOT_DIR)/u-boot $(IMAGEDIR)/u-boot.elf endif +ifdef PTXCONF_U_BOOT_INSTALL_MLO + @install -D -m644 $(U_BOOT_DIR)/MLO $(IMAGEDIR)/MLO +endif +ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_IMG + @install -D -m644 $(U_BOOT_DIR)/u-boot.img $(IMAGEDIR)/u-boot.img +endif @$(call touch) # -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 3/3] Fix build without gettext
The build system checks for gettext and if it doesn't find it, it uses empty definitions for _(). However, localedef.c uses gettext() directly on some places and calls textdomain(). Add two empty definitions in libintl.h so that no liker errors are generated when linking gettext. This patch is useful for systems without gettext in the default installation like Darwin. Signed-off-by: Bernhard Walle --- include/libintl.h |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/include/libintl.h b/include/libintl.h index 096aa8c..a8d33dd 100644 --- a/include/libintl.h +++ b/include/libintl.h @@ -13,3 +13,11 @@ #ifndef _libc_intl_domainname #define _libc_intl_domainname "libc" #endif + +#ifndef gettext +#define gettext(X) (X) +#endif + +#ifndef textdomain +#define textdomain(X) +#endif -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/3] Darwin: Define __nonnull when it's not defined
We could check for gcc here and define __nonnull expanding to the usual __attribute__ stuff. But hey, we're just compiling something on Darwin that has been tested with that macros on other platforms. Make it simple. Signed-off-by: Bernhard Walle --- eglibc/locale/nl_types.h |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/eglibc/locale/nl_types.h b/eglibc/locale/nl_types.h index c1190b5..15988e1 100644 --- a/eglibc/locale/nl_types.h +++ b/eglibc/locale/nl_types.h @@ -21,6 +21,10 @@ #include +#ifndef __nonnull +# define __nonnull(params) +#endif + /* The default message set used by the gencat program. */ #define NL_SETD 1 -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] localedef: Build fixes for Darwin
This patch series against the ptx branch in mol/localedef.git makes localedef compiling on Darwin. Tested on Mac OS 10.7 (Lion). I know you suggested using host-gettext-dummy, but that didn't work out of the box. Creating the host-gettext-dummy rules was easy and it worked, but the files copied from eglibc didn't compile; fixing that would be much more work than just defining two macros, so I took the easy way. -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Update kexec-tools to 2.0.3
The patches are obsolete as they are mainline. Verified on a NSLU2 (xscale-arm) little endian board/configuration. Signed-off-by: Bernhard Walle --- .../0001-revert-toolchain-problem.patch| 313 ...uild-Pass-no-undefined-as-a-linker-option.patch | 29 -- patches/kexec-tools-2.0.2/series |2 - rules/kexec-tools.make |6 +- 4 files changed, 3 insertions(+), 347 deletions(-) delete mode 100644 patches/kexec-tools-2.0.2/0001-revert-toolchain-problem.patch delete mode 100644 patches/kexec-tools-2.0.2/0002-build-Pass-no-undefined-as-a-linker-option.patch delete mode 100644 patches/kexec-tools-2.0.2/series diff --git a/patches/kexec-tools-2.0.2/0001-revert-toolchain-problem.patch b/patches/kexec-tools-2.0.2/0001-revert-toolchain-problem.patch deleted file mode 100644 index fa0702c..000 --- a/patches/kexec-tools-2.0.2/0001-revert-toolchain-problem.patch +++ /dev/null @@ -1,313 +0,0 @@ -commit dbe1163152ef6fca2a1bd22e11e219f58fd40c08 -Author: Maxim Uvarov -Date: Mon Sep 6 19:03:22 2010 +0400 - -Revert "powerpc new toolchains fix (crt.S)" - -This reverts commit 45e8f29639d9f97b74389e5bd28c7a5cccbf3e2a. -purgatory/arch/ppc/crt.S and purgatory/arch/ppc/misc.S are the same -files. -Signed-off-by: Maxim Uvarov -Signed-off-by: Simon Horman - -diff --git a/configure.ac b/configure.ac -index 7f6acc6..2960c25 100644 a/configure.ac -+++ b/configure.ac -@@ -159,15 +159,6 @@ if test "$with_xen" = yes ; then - AC_MSG_NOTICE([Xen support disabled]))) - fi - --dnl new toolchains --if test "$ARCH" = ppc; then --AC_ARG_WITH([oldtoolchain], -- AC_HELP_STRING([--with-oldtoolchain],[compile without crt.S -- required for new toolchains]), -- AC_DEFINE(PPC_OLDTOOLCHAIN, 1, -- [Define to compile with old toolchains])) --fi -- - dnl ---Sanity checks - if test "$CC" = "no"; then AC_MSG_ERROR([cc not found]); fi - if test "$CPP" = "no"; then AC_MSG_ERROR([cpp not found]); fi -diff --git a/purgatory/arch/ppc/Makefile b/purgatory/arch/ppc/Makefile -index 4020778..72289a0 100644 a/purgatory/arch/ppc/Makefile -+++ b/purgatory/arch/ppc/Makefile -@@ -6,7 +6,6 @@ ppc_PURGATORY_SRCS += purgatory/arch/ppc/v2wrap_32.S - ppc_PURGATORY_SRCS += purgatory/arch/ppc/misc.S - ppc_PURGATORY_SRCS += purgatory/arch/ppc/purgatory-ppc.c - ppc_PURGATORY_SRCS += purgatory/arch/ppc/console-ppc.c --ppc_PURGATORY_SRCS += purgatory/arch/ppc/crt.S - - dist += purgatory/arch/ppc/Makefile $(ppc_PURGATORY_SRCS) \ - purgatory/arch/ppc/purgatory-ppc.h purgatory/arch/ppc/ppc_asm.h -diff --git a/purgatory/arch/ppc/crt.S b/purgatory/arch/ppc/crt.S -deleted file mode 100644 -index 70f4d61..000 a/purgatory/arch/ppc/crt.S -+++ /dev/null -@@ -1,263 +0,0 @@ --/* This is from linux-2.6/arch/powerpc/lib/crtsavres.S: -- * -- * Special support for eabi and SVR4 -- * -- * Copyright (C) 1995, 1996, 1998, 2000, 2001 Free Software Foundation, Inc. -- * Copyright 2008 Freescale Semiconductor, Inc. -- * Written By Michael Meissner -- * -- * Based on gcc/config/rs6000/crtsavres.asm from gcc -- * -- * This file is free software; you can redistribute it and/or modify it -- * under the terms of the GNU General Public License as published by the -- * Free Software Foundation; either version 2, or (at your option) any -- * later version. -- * -- * In addition to the permissions in the GNU General Public License, the -- * Free Software Foundation gives you unlimited permission to link the -- * compiled version of this file with other programs, and to distribute -- * those programs without any restriction coming from the use of this -- * file. (The General Public License restrictions do apply in other -- * respects; for example, they cover modification of the file, and -- * distribution when not linked into another program.) -- * -- * This file is distributed in the hope that it will be useful, but -- * WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -- * General Public License for more details. -- * -- * You should have received a copy of the GNU General Public License -- * along with this program; see the file COPYING. If not, write to -- * the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- * Boston, MA 02110-1301, USA. -- * -- *As a special exception, if you link this library with files -- *compiled with GCC to produce an executable, this does not cause -- *the resulting executable to be covered by the GNU General Public License. -- *This exception does not however invalidate any other reasons why -- *the executable file might be covered by the GNU General Public License. -- */ --#include "config.h" -- --/* On PowerPC64 Linux, thes
[ptxdist] [PATCH] lpc21isp: Update to 1.83
I don't know why the name of the tarball is completely different and I also don't know why the tarball doesn't contain a directory. That's upstream. At least the program builds and works correctly. Signed-off-by: Bernhard Walle --- patches/lpc21isp-1.79/lpc21isp-fix-arm.diff | 27 --- patches/lpc21isp-1.79/series|1 - patches/lpc21isp_183/lpc21isp-fix-arm.diff | 27 +++ patches/lpc21isp_183/series |1 + rules/lpc21isp.make |9 + 5 files changed, 33 insertions(+), 32 deletions(-) delete mode 100644 patches/lpc21isp-1.79/lpc21isp-fix-arm.diff delete mode 100644 patches/lpc21isp-1.79/series create mode 100644 patches/lpc21isp_183/lpc21isp-fix-arm.diff create mode 100644 patches/lpc21isp_183/series diff --git a/patches/lpc21isp-1.79/lpc21isp-fix-arm.diff b/patches/lpc21isp-1.79/lpc21isp-fix-arm.diff deleted file mode 100644 index 9751db0..000 --- a/patches/lpc21isp-1.79/lpc21isp-fix-arm.diff +++ /dev/null @@ -1,27 +0,0 @@ -From: Bernhard Walle -Date: Mon, 20 Jun 2011 19:40:37 +0200 -Subject: [PATCH] Fix build on ARM platform with Linux - -The lpc21isp developers think that ARM cannot run Linux. This is false, treat -the ARM/Linux build just as building it on any platform. - -Signed-off-by: Bernhard Walle - lpc21isp.h |4 - 1 files changed, 0 insertions(+), 4 deletions(-) - -diff --git a/lpc21isp.h b/lpc21isp.h -index c9b9320..8190ddb 100644 a/lpc21isp.h -+++ b/lpc21isp.h -@@ -37,10 +37,6 @@ Portions Copyright (c) by Aeolus Development 2004 http://www.aeolusdevelopment.c - #elif defined(__CYGWIN__) - #define COMPILE_FOR_CYGWIN - #define COMPILED_FOR "Cygwin" --#elif defined(__arm__) || defined(__thumb__) --#define COMPILE_FOR_LPC21 --#define COMPILED_FOR "ARM" --#define printf iprintf - #elif defined(__APPLE__) - #define COMPILE_FOR_LINUX - #define COMPILED_FOR "Apple MacOS X" diff --git a/patches/lpc21isp-1.79/series b/patches/lpc21isp-1.79/series deleted file mode 100644 index 23cd858..000 --- a/patches/lpc21isp-1.79/series +++ /dev/null @@ -1 +0,0 @@ -lpc21isp-fix-arm.diff diff --git a/patches/lpc21isp_183/lpc21isp-fix-arm.diff b/patches/lpc21isp_183/lpc21isp-fix-arm.diff new file mode 100644 index 000..9751db0 --- /dev/null +++ b/patches/lpc21isp_183/lpc21isp-fix-arm.diff @@ -0,0 +1,27 @@ +From: Bernhard Walle +Date: Mon, 20 Jun 2011 19:40:37 +0200 +Subject: [PATCH] Fix build on ARM platform with Linux + +The lpc21isp developers think that ARM cannot run Linux. This is false, treat +the ARM/Linux build just as building it on any platform. + +Signed-off-by: Bernhard Walle +--- + lpc21isp.h |4 + 1 files changed, 0 insertions(+), 4 deletions(-) + +diff --git a/lpc21isp.h b/lpc21isp.h +index c9b9320..8190ddb 100644 +--- a/lpc21isp.h b/lpc21isp.h +@@ -37,10 +37,6 @@ Portions Copyright (c) by Aeolus Development 2004 http://www.aeolusdevelopment.c + #elif defined(__CYGWIN__) + #define COMPILE_FOR_CYGWIN + #define COMPILED_FOR "Cygwin" +-#elif defined(__arm__) || defined(__thumb__) +-#define COMPILE_FOR_LPC21 +-#define COMPILED_FOR "ARM" +-#define printf iprintf + #elif defined(__APPLE__) + #define COMPILE_FOR_LINUX + #define COMPILED_FOR "Apple MacOS X" diff --git a/patches/lpc21isp_183/series b/patches/lpc21isp_183/series new file mode 100644 index 000..23cd858 --- /dev/null +++ b/patches/lpc21isp_183/series @@ -0,0 +1 @@ +lpc21isp-fix-arm.diff diff --git a/rules/lpc21isp.make b/rules/lpc21isp.make index 5393c51..2999eae 100644 --- a/rules/lpc21isp.make +++ b/rules/lpc21isp.make @@ -16,13 +16,14 @@ PACKAGES-$(PTXCONF_LPC21ISP) += lpc21isp # # Paths and names # -LPC21ISP_VERSION := 1.79 -LPC21ISP_MD5 := 93cf6b2a35d7e1d96a2887a21a8b2b77 -LPC21ISP := lpc21isp-$(LPC21ISP_VERSION) +LPC21ISP_VERSION := 1.83 +LPC21ISP_MD5 := 4b437a6d6e718afa6d182f0c18f5363f +LPC21ISP_STRIP_LEVEL := 0 +LPC21ISP := lpc21isp_$(subst .,,$(LPC21ISP_VERSION)) LPC21ISP_SUFFIX:= tar.gz LPC21ISP_URL := $(call ptx/mirror, SF, lpc21isp/$(LPC21ISP_VERSION)/$(LPC21ISP).$(LPC21ISP_SUFFIX)) LPC21ISP_SOURCE:= $(SRCDIR)/$(LPC21ISP).$(LPC21ISP_SUFFIX) -LPC21ISP_DIR := $(BUILDDIR)/lpc21isp +LPC21ISP_DIR := $(BUILDDIR)/$(LPC21ISP) LPC21ISP_LICENSE := GPLv3+ # -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] host-localedef: Fix on Darwin
* Michael Olbrich [2012-02-07 15:46]: > On Sun, Jan 22, 2012 at 12:29:48AM +0100, Bernhard Walle wrote: > > This patch is by far the most ugly part of all of the Darwin patches. > > At least the md5sum of a locale-archive when generating a de_DE.UTF-8 > > locale is identical... > > > > A first review, please. > > We're creating the localedef package anyway, so I'd like to create a new > tarball with all the paches included. > I've pushed my current WIP to git://git.pengutronix.de/git/mol/localedef.git > please test. This contains most of your patches (or modified versions). For > the gettext stuff: we already have getttext-dummy package[1]. We can create > a host-getttext-dummy package from that. Ah, ok, thanks. Currently I'm reworking my patches but I didn't have time to finish it and post it... Expect something at the end of the week. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] zlib: Fix build on non-Linux hosts
The build system of zlib uses 'uname' to determine the operating system for which it compiles zlib. However, on non-Linux hosts, this leads to wrong results. Fixes Darwin (tested on Mac OS 10.7 Lion), doesn't break Linux (verified with current Arch Linux on x86_64). Signed-off-by: Bernhard Walle --- I think that one is okay but just got lost, right? rules/zlib.make |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/rules/zlib.make b/rules/zlib.make index 0d437e3..e51fe8a 100644 --- a/rules/zlib.make +++ b/rules/zlib.make @@ -47,7 +47,8 @@ ZLIB_CONF_ENV := \ # autoconf # ZLIB_AUTOCONF := \ - --prefix=/usr + --prefix=/usr \ + --uname=Linux ifdef PTXCONF_ZLIB_STATIC ZLIB_AUTOCONF += --static -- 1.7.9 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] make 3.82: Don't rely on sorted wildcard expansion
Since I switched to make 3.82 on my Mac (from MacPorts), "ptxdist images" didn't produce any images. I compared the output of make --debug=all with a working one (from make 3.81 that comes from Apple) and one difference was the order in reading includes Makefiles. With make 3.82, the wildcard command doesn't sort any more. See https://bugzilla.redhat.com/show_bug.cgi?id=635607. This small fix fixed the issue for me. Don't ask my why this doesn't show up on Linux. Maybe the return values of some library function that is make using internally is already sorted. I have no clue. Signed-off-by: Bernhard Walle --- rules/other/Toplevel.make |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rules/other/Toplevel.make b/rules/other/Toplevel.make index 35c2c27..85ad515 100644 --- a/rules/other/Toplevel.make +++ b/rules/other/Toplevel.make @@ -39,7 +39,7 @@ include $(PTX_MAP_ALL_MAKE) include $(RULESDIR)/other/Namespace.make # might be non existent -include $(wildcard $(addsuffix /*.make,$(call reverse,$(subst :,$(space),$(PTXDIST_PATH_PRERULES) +include $(foreach dir, $(call reverse,$(subst :,$(space),$(PTXDIST_PATH_PRERULES))), $(sort $(wildcard $(dir)/*.make))) include $(PTX_DGEN_DEPS_PRE) include $(PTX_DGEN_RULESFILES_MAKE) @@ -95,7 +95,7 @@ PTX_PACKAGES_INSTALL := \ $(PACKAGES-b) # might be non existent -include $(wildcard $(addsuffix /*.make,$(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES) +include $(foreach dir, $(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES))), $(sort $(wildcard $(dir)/*.make))) # install_alternative and install_copy has some configuration defined # dependencies. include the files specifying these dependencies. include $(wildcard $(STATEDIR)/*.deps) -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] beaglebone
Hi Tim, Am 02.02.12 00:16, schrieb Tim Sander: >>> Does anybody by chance have a beaglebone ptxdist whe (s)he likes to >>> share? >> >> % hg clone https://bitbucket.org/bwalle/ptxdist-arm-boards -r 26030b06fd4a >> >> However, the kernel configuration is not tested to have DVI output. > Thanks! I am not interested in graphical output and i don't have a dvi cape. > The usb-network and -serial stuff as in the original beaglebone software seem > more interesting for me. Ah, ok, but I didn't read carefully. I read "Beagleboard", not "Beaglebone". Unfortunately, I don't (yet) have a Beaglebone. But maybe the configuration helps you a bit anyway. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] beaglebone
Hi, * Tim Sander [2012-02-01 00:53]: > Hi > > Does anybody by chance have a beaglebone ptxdist whe (s)he likes to share? % hg clone https://bitbucket.org/bwalle/ptxdist-arm-boards -r 26030b06fd4a However, the kernel configuration is not tested to have DVI output. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] make 3.82: Don't rely on sorted wildcard expansion
Hi Michael, * Michael Olbrich [2012-01-30 15:06]: > > This is not correct. It will sort all post files and does not honor the > order of PTXDIST_PATH_POSTRULES. This should probably be something like > this (untested): > > $(foreach dir, $(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES))), > include (sort $(wildcard $(dir)/*.make))) I'm not really a make guru like you. Your example doesn't work. Following works: include $(foreach dir, $(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES))), $(sort $(wildcard $(dir)/*.make))) Does that look correct in your eyes? Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] make 3.82: Don't rely on sorted wildcard expansion
Since I switched to make 3.82 on my Mac (from MacPorts), "ptxdist images" didn't produce any images. I compared the output of make --debug=all with a working one (from make 3.81 that comes from Apple) and one difference was the order in reading includes Makefiles. With make 3.82, the wildcard command doesn't sort any more. See https://bugzilla.redhat.com/show_bug.cgi?id=635607. This small fix fixed the issue for me. Don't ask my why this doesn't show up on Linux. Maybe the return values of some library function that is make using internally is already sorted. I have no clue. Signed-off-by: Bernhard Walle --- rules/other/Toplevel.make |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/rules/other/Toplevel.make b/rules/other/Toplevel.make index 35c2c27..0cb7e82 100644 --- a/rules/other/Toplevel.make +++ b/rules/other/Toplevel.make @@ -95,7 +95,7 @@ PTX_PACKAGES_INSTALL := \ $(PACKAGES-b) # might be non existent -include $(wildcard $(addsuffix /*.make,$(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES) +include $(sort $(wildcard $(addsuffix /*.make,$(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES)) # install_alternative and install_copy has some configuration defined # dependencies. include the files specifying these dependencies. include $(wildcard $(STATEDIR)/*.deps) -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 2/2] kernel: Use host-elf-h-compat
Set the host include flags of the Linux kernel so that it finds elf.h in sysroot-host/include. It's required to specify HOST_EXTRACFLAGS in the environment rather than as make argument because otherwise += doesn't work which ends in other build errors (gettext problems). See also http://article.gmane.org/gmane.linux.kbuild.devel/5210 for a discussion about HOST_EXTRACFLAGS. Signed-off-by: Bernhard Walle --- rules/kernel.make |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/rules/kernel.make b/rules/kernel.make index a445182..336b76d 100644 --- a/rules/kernel.make +++ b/rules/kernel.make @@ -43,13 +43,12 @@ KERNEL_SOURCE := $(SRCDIR)/$(KERNEL).$(KERNEL_SUFFIX) # KERNEL_PATH:= PATH=$(CROSS_PATH) -KERNEL_ENV := KCONFIG_NOTIMESTAMP=1 +KERNEL_ENV := KCONFIG_NOTIMESTAMP=1 HOST_EXTRACFLAGS="$(HOST_CPPFLAGS)" KERNEL_MAKEVARS := \ $(PARALLELMFLAGS) \ HOSTCC=$(HOSTCC) \ ARCH=$(PTXCONF_KERNEL_ARCH_STRING) \ CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) \ - \ INSTALL_MOD_PATH=$(KERNEL_PKGDIR) \ PTX_KERNEL_DIR=$(KERNEL_DIR) \ $(call remove_quotes,$(PTXCONF_KERNEL_EXTRA_MAKEVARS)) -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/2] Add host-elf-h-compat package
This package should provide on host operating systems that have no /usr/include/elf.h. The header is copied from glibc, modified a bit to remove GNU dependencies and is sufficient to compile the Linux kernel and module-init-tools. The package itself only checks if elf.h is present. If yes, it does nothing on "make install". If not, it installs its own copy of elf.h in "make install" to the include directory set in autoconf. We add this package as base package so that it gets built before the packages which need it. Also, the package only gets required when ptxdist is executed not on Linux (per uname -s output). This makes maintaining the dependencies easier than requiring it in any packages that need elf.h. Signed-off-by: Bernhard Walle --- rules/host-elf-h-compat.in |5 + rules/host-elf-h-compat.make | 36 2 files changed, 41 insertions(+), 0 deletions(-) create mode 100644 rules/host-elf-h-compat.in create mode 100644 rules/host-elf-h-compat.make diff --git a/rules/host-elf-h-compat.in b/rules/host-elf-h-compat.in new file mode 100644 index 000..9310216 --- /dev/null +++ b/rules/host-elf-h-compat.in @@ -0,0 +1,5 @@ +## SECTION=hosttools_noprompt + +config HOST_ELF_H_COMPAT + default y + bool diff --git a/rules/host-elf-h-compat.make b/rules/host-elf-h-compat.make new file mode 100644 index 000..9bd9a1d --- /dev/null +++ b/rules/host-elf-h-compat.make @@ -0,0 +1,36 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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 +# +LAZY_PACKAGES-$(PTXCONF_HOST_ELF_H_COMPAT) += host-elf-h-compat + +# +# Paths and names +# +HOST_ELF_H_COMPAT_VERSION := 0.2 +HOST_ELF_H_COMPAT_MD5 := a2a21551133c9278014f71cdb983564a +HOST_ELF_H_COMPAT := elf-h-compat-$(HOST_ELF_H_COMPAT_VERSION) +HOST_ELF_H_COMPAT_SUFFIX := tar.bz2 +HOST_ELF_H_COMPAT_URL := http://bwalle.de/programme/$(HOST_ELF_H_COMPAT).$(HOST_ELF_H_COMPAT_SUFFIX) +HOST_ELF_H_COMPAT_SOURCE := $(SRCDIR)/$(HOST_ELF_H_COMPAT).$(HOST_ELF_H_COMPAT_SUFFIX) +HOST_ELF_H_COMPAT_DIR := $(HOST_BUILDDIR)/$(HOST_ELF_H_COMPAT) + +# +# autoconf +# +HOST_ELF_H_COMPAT_CONF_TOOL:= autoconf + +ifneq ($(shell uname -s),Linux) +$(STATEDIR)/base.prepare: $(STATEDIR)/host-elf-h-compat.install.post +endif + +# vim: syntax=make -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] Fix missing elf.h on Darwin (v2)
This is the second version of the patches. The third patch is not needed any more because host-elf-h-compat is now built as base package rather than as dependency. All other remarks of the review have been integrated in the patch series. The package is maintained at https://bitbucket.org/bwalle/elf-h-compat but unfortunately it cannot be downloaded from there automatically because Bitbucket forwards http to https and that gives certificate errors on some hosts (depending which certificates are available to wget). That's why I still have my domain in the source URL of the package. Well, in the past it was much more reliable compared to Berlios, so it shouldn't be a practical problem. -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Support reading number of CPUs on Darwin and BSDs
Tested on Mac OS 10.7 (Lion). Signed-off-by: Bernhard Walle --- v2: Use /usr/sbin/sysctl instead of relying on the $PATH and don't check for the operating system but just try it out. bin/ptxdist |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/bin/ptxdist b/bin/ptxdist index 74a52ad..52e9c76 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -2088,12 +2088,14 @@ setup_config() { local pmf_extern="-j1" local cpus + # this one is for Linux if [ -r /proc/cpuinfo ]; then cpus="$(egrep '^(processor|cpu )' /proc/cpuinfo | wc -l)" if [ ${cpus} -eq 0 ]; then cpus=1 fi - else + # and this one is tested on Darwin and should work on BSDs + elif ! cpus="$(/usr/sbin/sysctl -n hw.ncpu)" 2> /dev/null; then cpus=1 fi local pmf_intern="-j$(( ${cpus} * 2 ))" -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] Support reading number of CPUs on Mac OS X
Hi Michael, Am 24.01.12 10:19, schrieb Michael Olbrich: > > - Is sysctl alwyas in $PATH? On Linux it's in sbin. I think so, but it's in /usr/sbin, so I can use /usr/sbin/syctl to be more safe. > - the value should be quoted. ok. > - Does this _always_ and _only_ work on Mac OS X? Good point. I have no other system than Linux and Mac OS here, but according to http://systhread.net/texts/28sysctl.php it should work on all BSDs, so yes, your solution is better. Will create a new version of the patch later in the evening. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] host-localedef: Fix on Darwin
* Andreas Bießmann [2012-01-23 22:29]: > On 22.01.12 00:29, Bernhard Walle wrote: > > This patch is by far the most ugly part of all of the Darwin patches. > > At least the md5sum of a locale-archive when generating a de_DE.UTF-8 > > locale is identical... > > > > A first review, please. > > I get some warnings and a linker error: Is 'gcc' llvm-gcc (gcc --version)? I'm using gcc-4.2 (FSF gcc) as host compiler, but of course it should be fixed to work with llvm-gcc too as it's the default on Lion (and I think even Snow Leopard). Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH v2] replace umkimage by u-boot sources
* Andreas Bießmann [2012-01-23 14:16]: > > no, you got me wrong here. We have a host-u-boot-tools package which > have the mkimage build for the host (currently only that tool, but maybe > sometimes mkenvimage too?). Here we have the target package build for > the specified target architecture (yes some want to run mkimage ion the > target ;) Yes, sorry. Should have read the whole mail. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH v2] replace umkimage by u-boot sources
* Andreas Bießmann [2012-01-23 13:40]: > > shouldn't we build two different packages (u-boot-tool-mkimage, > u-boot-tool-env) here? I would add that tools as part of the u-boot package. Mixing a host tool with target tools don't sound like a good idea. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Support reading number of CPUs on Mac OS X
Tested on 10.7 (Lion). Signed-off-by: Bernhard Walle --- bin/ptxdist |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/bin/ptxdist b/bin/ptxdist index 74a52ad..4edbac3 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -2093,6 +2093,8 @@ setup_config() { if [ ${cpus} -eq 0 ]; then cpus=1 fi + elif [ "$(uname -s)" = Darwin ] ; then + cpus=$(sysctl -n hw.ncpu) else cpus=1 fi -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH v2] replace umkimage by u-boot sources
* Andreas Bießmann [2012-01-22 15:49]: > > +config ROOTFS_FW_ENV_CONFIG > + bool > + prompt "install /etc/fw_env.config" > + default y Shouldn't this default to "n" if there's no generic fallback file (in the generic/ directory)? Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] sitecopy: Fix build on non-Linux hosts
The build system of sitecopy uses 'uname' to determine the operating system for which it compiles sitecopy. However, on non-Linux hosts, this leads to wrong results. Fixes Darwin (tested on Mac OS 10.7 Lion). Signed-off-by: Bernhard Walle --- v3: Same as v1 but with SITECOPY_CONF_ENV instead of SITECOPY_AUTOCONF and with comment. rules/sitecopy.make |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/rules/sitecopy.make b/rules/sitecopy.make index 44a7b8a..4434fe9 100644 --- a/rules/sitecopy.make +++ b/rules/sitecopy.make @@ -42,6 +42,14 @@ SITECOPY_AUTOCONF := $(CROSS_AUTOCONF_USR) \ --without-socks \ --without-gssapi +# m4/neon/neon.m4 uses uname to check for Darwin and adds some special compiler +# options in that case. sitecopy doesn't build host tools, so anything built +# is for the target. We can force the target operating system to Linux. That's simpler +# than fixing the m4/neon/neon.m4 and doesn't need autoreconf to run. +SITECOPY_CONF_ENV := \ + $(CROSS_ENV) \ + ne_cv_os_uname=Linux + ifdef PTXCONF_SITECOPY_SFTP SITECOPY_AUTOCONF += --enable-sftp else -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 1/3] Add host-elf-h-compat package
This package should provide on host operating systems that have no /usr/include/elf.h. The header is copied from glibc, modified a bit to remove Gnu dependencies and is sufficient to compile the Linux kernel and module-init-tools. The package itself only checks if elf.h is present. If yes, it does nothing on "make install". If not, it installs its own copy of elf.h in "make install" to the include directory set in autoconf. Signed-off-by: Bernhard Walle --- rules/host-elf-h-compat.in |4 rules/host-elf-h-compat.make | 32 2 files changed, 36 insertions(+), 0 deletions(-) create mode 100644 rules/host-elf-h-compat.in create mode 100644 rules/host-elf-h-compat.make diff --git a/rules/host-elf-h-compat.in b/rules/host-elf-h-compat.in new file mode 100644 index 000..8a263ea --- /dev/null +++ b/rules/host-elf-h-compat.in @@ -0,0 +1,4 @@ +## SECTION=hosttools_noprompt + +config HOST_ELF_H_COMPAT + bool diff --git a/rules/host-elf-h-compat.make b/rules/host-elf-h-compat.make new file mode 100644 index 000..7001344 --- /dev/null +++ b/rules/host-elf-h-compat.make @@ -0,0 +1,32 @@ +# -*-makefile-*- +# +# Copyright (C) 2012 by Bernhard Walle +# +# 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 +# +HOST_PACKAGES-$(PTXCONF_HOST_ELF_H_COMPAT) += host-elf-h-compat + +# +# Paths and names +# +HOST_ELF_H_COMPAT_VERSION := 0.1 +HOST_ELF_H_COMPAT_MD5 := dc45cdadcac50a42175f66ffed2d4375 +HOST_ELF_H_COMPAT := elf-h-compat-$(HOST_ELF_H_COMPAT_VERSION) +HOST_ELF_H_COMPAT_SUFFIX := tar.bz2 +HOST_ELF_H_COMPAT_URL := http://bwalle.de/programme//$(HOST_ELF_H_COMPAT).$(HOST_ELF_H_COMPAT_SUFFIX) +HOST_ELF_H_COMPAT_SOURCE := $(SRCDIR)/$(HOST_ELF_H_COMPAT).$(HOST_ELF_H_COMPAT_SUFFIX) +HOST_ELF_H_COMPAT_DIR := $(HOST_BUILDDIR)/$(HOST_ELF_H_COMPAT) + +# +# autoconf +# +HOST_ELF_H_COMPAT_CONF_TOOL:= autoconf + +# vim: syntax=make -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 2/3] kernel: Use host-elf-h-compat
Add a dependency to the host tool and set the include flags properly. Signed-off-by: Bernhard Walle --- platforms/hosttools.in |1 + platforms/kernel.in|1 + rules/kernel.make |1 + 3 files changed, 3 insertions(+), 0 deletions(-) diff --git a/platforms/hosttools.in b/platforms/hosttools.in index 155b30b..0435545 100644 --- a/platforms/hosttools.in +++ b/platforms/hosttools.in @@ -5,6 +5,7 @@ source "rules/host-cmake.in" source "rules/host-cramfs.in" source "rules/host-dosfstools.in" source "rules/host-e2fsprogs.in" +source "rules/host-elf-h-compat.in" source "rules/host-genext2fs.in" source "rules/host-genpart.in" source "rules/host-gettext.in" diff --git a/platforms/kernel.in b/platforms/kernel.in index b601284..4391e79 100644 --- a/platforms/kernel.in +++ b/platforms/kernel.in @@ -2,6 +2,7 @@ menuconfig KERNEL bool default y select IMAGE_KERNEL + select HOST_ELF_H_COMPAT select HOST_UMKIMAGEif KERNEL_IMAGE_U select HOST_XZ if KERNEL_XZ select HOST_LZOPif KERNEL_LZOP diff --git a/rules/kernel.make b/rules/kernel.make index a445182..f125a69 100644 --- a/rules/kernel.make +++ b/rules/kernel.make @@ -47,6 +47,7 @@ KERNEL_ENV:= KCONFIG_NOTIMESTAMP=1 KERNEL_MAKEVARS := \ $(PARALLELMFLAGS) \ HOSTCC=$(HOSTCC) \ + HOSTCFLAGS=$(HOST_CPPFLAGS) $(HOST_CFLAGS) \ ARCH=$(PTXCONF_KERNEL_ARCH_STRING) \ CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) \ \ -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH 3/3] module-init-tools: Depend on HOST_ELF_H_COMPAT
The kernel already depends on it, but module-init-tools may be built earlier and if we don't add it here to the dependency chain, the build order could be module-init-tools -> host-elf-h-compat -> kernel which would not work on systems that have no /usr/include/elf.h. Signed-off-by: Bernhard Walle --- rules/module-init-tools.in |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/rules/module-init-tools.in b/rules/module-init-tools.in index 765de6b..3d98fd0 100644 --- a/rules/module-init-tools.in +++ b/rules/module-init-tools.in @@ -4,6 +4,7 @@ menuconfig MODULE_INIT_TOOLS tristate prompt "module-init-tools " + select HOST_ELF_H_COMPAT help This package contains a set of programs for loading, inserting and removing kernel modules for Linux (versions 2.5.48 and -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] Fix missing elf.h on Darwin
This patch series is an attempt to solve the problem that Darwin has no /usr/include/elf.h. I'm sure that other non-Linux but POSIX-compatible operating systems have no /usr/include/elf.h, so it should not only increase portability for Mac OS but also for *BSD. I think there are various ways to implement an solution, this one is based on a newly created elf-h-compat package that uses autoconf to check if there's already a elf.h present and if yes, it does nothing on "make install". Otherwise, an own copy of elf.h that is sufficient to compile the kernel and module-init-tools is installed, which results in sysroot-host/include/elf.h. The rest of the patches just add the dependencies and set the CFLAGS. Some words on alternatives: I played a bit with libelf to provide the required headers, but they don't have elf.h and even a compat-elf.h that includes gelf.h doesn't bring all required defines. On the other side building libelf just to get a few definitions is overkill. Modifying the kernel build system to use its own copy of elf.h (basically ) isn't easy either and will not help module-init-tools (didn't check kmod). Using the elf.h from the cross-toolchain would involve bringing the include path of the cross toolchain in the include path of the host which I'm sure will generate more problems. Of course I'm open for alternatives, but discussion without suggesting a solution doesn't work in most Open Source projects. ;-) -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Setup vim folding in the logfile automatically
This patch adds the modeline # vim: set fdm=marker fdl=1: to the Logfile. There's already a modeline for Emacs in the file, so it shouldn't be too annoying for users that don't use vim. The first setting tells vim to recognize the fold markers '{{{' and '}}}' in the logfile (which doesn't have any file type in vim). However, with this setting vim automatically closes all folds, including the first '{{{' which only is for Emacs. That's why I add fdl=1, which results in vim opening the file visible one fold per ptxdist run. Signed-off-by: Bernhard Walle --- v2: Use marker, not markers. bin/ptxdist |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/bin/ptxdist b/bin/ptxdist index 73235c4..74a52ad 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -2270,6 +2270,9 @@ setup_logfile() if [ \! -e "${PTX_LOGFILE}" ]; then # let emacs outline mode be compatible to vi's fold mode echo -e "# -*- mode:outline; outline-regexp:\"{""{{\" -*-\n" > "${PTX_LOGFILE}" + # help vim to recognise the fold markers and expand the first level of folding + # which in fact is the Emacs setting above + echo "# vim: set fdm=marker fdl=1:" > "${PTX_LOGFILE}" fi # -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Setup vim folding in the logfile automatically
This patch adds the modeline # vim: set fdm=markers fdl=1: to the Logfile. There's already a modeline for Emacs in the file, so it shouldn't be too annoying for users that don't use vim. The first setting tells vim to recognize the fold markers '{{{' and '}}}' in the logfile (which doesn't have any file type in vim). However, with this setting vim automatically closes all folds, including the first '{{{' which only is for Emacs. That's why I add fdl=1, which results in vim opening the file visible one fold per ptxdist run. Signed-off-by: Bernhard Walle --- bin/ptxdist |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/bin/ptxdist b/bin/ptxdist index 73235c4..5528a14 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -2270,6 +2270,9 @@ setup_logfile() if [ \! -e "${PTX_LOGFILE}" ]; then # let emacs outline mode be compatible to vi's fold mode echo -e "# -*- mode:outline; outline-regexp:\"{""{{\" -*-\n" > "${PTX_LOGFILE}" + # help vim to recognise the fold markers and expand the first level of folding + # which in fact is the Emacs setting above + echo "# vim: set fdm=markers fdl=1:" > "${PTX_LOGFILE}" fi # -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] host-localedef: Fix on Darwin
This patch is by far the most ugly part of all of the Darwin patches. At least the md5sum of a locale-archive when generating a de_DE.UTF-8 locale is identical... A first review, please. Signed-off-by: Bernhard Walle --- ...n-Fix-problem-with-__block-parameter-name.patch | 33 ...ide-dummy-implementation-of-gettext-funct.patch | 45 + ...-some-locale-related-definitions-from-Lin.patch | 182 ...004-Darwin-Compile-with-fnested-functions.patch | 37 ...005-Use-own-implementation-of-__rawmemchr.patch | 40 + patches/localedef-eglibc-2.11.90-ptx1/autogen.sh |1 + patches/localedef-eglibc-2.11.90-ptx1/series |8 + 7 files changed, 346 insertions(+), 0 deletions(-) create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/0001-Darwin-Fix-problem-with-__block-parameter-name.patch create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/0002-Darwin-Provide-dummy-implementation-of-gettext-funct.patch create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/0003-Darwin-Copy-some-locale-related-definitions-from-Lin.patch create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/0004-Darwin-Compile-with-fnested-functions.patch create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/0005-Use-own-implementation-of-__rawmemchr.patch create mode 12 patches/localedef-eglibc-2.11.90-ptx1/autogen.sh create mode 100644 patches/localedef-eglibc-2.11.90-ptx1/series diff --git a/patches/localedef-eglibc-2.11.90-ptx1/0001-Darwin-Fix-problem-with-__block-parameter-name.patch b/patches/localedef-eglibc-2.11.90-ptx1/0001-Darwin-Fix-problem-with-__block-parameter-name.patch new file mode 100644 index 000..a80321e --- /dev/null +++ b/patches/localedef-eglibc-2.11.90-ptx1/0001-Darwin-Fix-problem-with-__block-parameter-name.patch @@ -0,0 +1,33 @@ +From: Bernhard Walle +Date: Sat, 21 Jan 2012 22:00:14 +0100 +Subject: [PATCH] Darwin: Fix problem with __block parameter name + +This fixes the following compile error: + + 8< --- +./glibc/malloc/obstack.h:190: error: __block attribute can be specified +on variables only +In file included from glibc/locale/programs/charmap.c:32: + >8 --- + +Compiler war gcc-4.2 [i686-apple-darwin11-gcc-4.2.1 (GCC) 4.2.1 (Apple +Inc. build 5666) (dot 3)]. + +Signed-off-by: Bernhard Walle +--- + eglibc/malloc/obstack.h |2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/eglibc/malloc/obstack.h b/eglibc/malloc/obstack.h +index 449070e..0c4f2e4 100644 +--- a/eglibc/malloc/obstack.h b/eglibc/malloc/obstack.h +@@ -187,7 +187,7 @@ extern int _obstack_begin_1 (struct obstack *, int, int, +void (*) (void *, void *), void *); + extern int _obstack_memory_used (struct obstack *); + +-void obstack_free (struct obstack *__obstack, void *__block); ++void obstack_free (struct obstack *__obstack, void *); + + + /* Error handler called when `obstack_chunk_alloc' failed to allocate diff --git a/patches/localedef-eglibc-2.11.90-ptx1/0002-Darwin-Provide-dummy-implementation-of-gettext-funct.patch b/patches/localedef-eglibc-2.11.90-ptx1/0002-Darwin-Provide-dummy-implementation-of-gettext-funct.patch new file mode 100644 index 000..9c3f005 --- /dev/null +++ b/patches/localedef-eglibc-2.11.90-ptx1/0002-Darwin-Provide-dummy-implementation-of-gettext-funct.patch @@ -0,0 +1,45 @@ +From: Bernhard Walle +Date: Sat, 21 Jan 2012 23:00:43 +0100 +Subject: [PATCH] Darwin: Provide dummy implementation of gettext functions + +It's just not worth the effort requiring gettext for building locales in +a cross build system. English error messages are sufficient. + +Signed-off-by: Bernhard Walle +--- + include/libintl.h | 23 ++- + 1 files changed, 22 insertions(+), 1 deletions(-) + +diff --git a/include/libintl.h b/include/libintl.h +index 096aa8c..edf34eb 100644 +--- a/include/libintl.h b/include/libintl.h +@@ -1,6 +1,27 @@ + #ifdef HAVE_LIBINTL_H + #include_next +-#endif ++#else ++ ++#ifndef LIBINTL_H_ ++#define LIBINTL_H_ 1 ++ ++// dummy implementations of gettext() and textdomain() ++// ++static inline char *gettext(const char *msgid) ++{ ++return (char *)msgid; ++} ++ ++static inline char *textdomain (const char * domainname) ++{ ++static char current_domain[1024]; ++strncpy(current_domain, domainname, sizeof(current_domain)); ++current_domain[sizeof(current_domain)-1] = '\0'; ++return current_domain; ++} ++ ++#endif /* LIBINTL_H_ */ ++#endif /* !HAVE_LIBINTL_H */ + + #ifndef _ + #define _(X) (X) diff --git a/patches/localedef-eglibc-2.11.90-ptx1/0003-Darwin-Copy-some-locale-related-definitions-from-Lin.patch b/patches/localedef-eglibc-2.11.90-ptx1/0003-Darwin-Copy-some-locale-related-definitions-from-Lin.patch new file mode 100644 index 000..fad815a --- /dev/null +++ b/patches/localedef-eglibc-2.11.90-ptx1/00
[ptxdist] [PATCH] gnuplot: Fix build on Darwin
This patch adds 0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch for gnuplot. This patch fixes building the documentation generator which is executed on the host. Signed-off-by: Bernhard Walle --- ...ld-documentation-generator-tools-with-CC_.patch |2 - ...DFLAGS-when-building-the-documentation-ge.patch | 30 patches/gnuplot-4.4.3/series |3 +- 3 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 patches/gnuplot-4.4.3/0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch diff --git a/patches/gnuplot-4.4.3/0001-gnuplot-build-documentation-generator-tools-with-CC_.patch b/patches/gnuplot-4.4.3/0001-gnuplot-build-documentation-generator-tools-with-CC_.patch index cbc130b..702ab8b 100644 --- a/patches/gnuplot-4.4.3/0001-gnuplot-build-documentation-generator-tools-with-CC_.patch +++ b/patches/gnuplot-4.4.3/0001-gnuplot-build-documentation-generator-tools-with-CC_.patch @@ -9,8 +9,6 @@ CC_FOR_BUILD. Signed-off-by: Robert Schwebel --- -# 20091222 rsc: https://sourceforge.net/tracker/?func=detail&aid=2918992&group_id=2055&atid=302055 - configure.in | 42 ++ docs/Makefile.in |4 ++-- 2 files changed, 44 insertions(+), 2 deletions(-) diff --git a/patches/gnuplot-4.4.3/0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch b/patches/gnuplot-4.4.3/0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch new file mode 100644 index 000..968eaf8 --- /dev/null +++ b/patches/gnuplot-4.4.3/0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch @@ -0,0 +1,30 @@ +From: Bernhard Walle +Date: Sun, 22 Jan 2012 00:03:59 +0100 +Subject: [PATCH] Don't use LDFLAGS when building the documentation generator + +The documentation generator is a tool running on the build machine. +Therefore the LDFLAGS computed for the cross compiler may not work, such +as the "-Wl,-rpath-link" flag which is not understood by the Darwin +linker. + +The doc2gih is simple and doesn't require an external library. So we +don't also need special LDFLAGS. Omit them. + +Signed-off-by: Bernhard Walle +--- + docs/Makefile.in |2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/docs/Makefile.in b/docs/Makefile.in +index 591d818..0e2ef8f 100644 +--- a/docs/Makefile.in b/docs/Makefile.in +@@ -83,7 +83,7 @@ LIBS = + + COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) + CCLD = $(CC) +-LINK = $(CCLD) $(CFLAGS) $(LDFLAGS) -o $@ ++LINK = $(CCLD) $(CFLAGS) -o $@ + + .c.o: + $(COMPILE) -c $< diff --git a/patches/gnuplot-4.4.3/series b/patches/gnuplot-4.4.3/series index 2abd8f8..585745c 100644 --- a/patches/gnuplot-4.4.3/series +++ b/patches/gnuplot-4.4.3/series @@ -1,4 +1,5 @@ # generated by git-ptx-patches #tag:base --start-number 1 0001-gnuplot-build-documentation-generator-tools-with-CC_.patch -# 3e114650ad53e5a48943395ff97a63b0 - git-ptx-patches magic +0002-Don-t-use-LDFLAGS-when-building-the-documentation-ge.patch +# ffd95c4575ca3e3194e093f925705906 - git-ptx-patches magic -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] cross-compiling and uname
Hi Michael, Am 19.01.12 22:47, schrieb Michael Olbrich: > > we had some patches lately about configure scripts etc. using uname to > detect stuff. Why don't we create a fake ../sysroot-cross/bin/uname that > produces the output we would expect on the target? > This way we don't have to fix all those packages and we have on less source > of host system information leaking into the build. I agree with the others: Fixing the packages is the better solution in my opinion. For the neon fix I'm trying to bring the patch upstream, so that would be one patch less in the long term. Especially as the absolute number of packages affected is quite low. With the current git ptxdist (and one fix for the kernel and module-init-tools I didn't post yet) and Andreas' OSELAS.Toolchain patches I'm able to build a complete image for my weather station receiver on Mac OS. :) Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH / RFC] replace umkimage by u-boot sources
Am 21.01.12 19:22, schrieb Michael Olbrich: > I don't know fw_printenv. Please elaborate. This is a tool to print the u-boot environment in Linux. fw_setenv can be used to change the u-boot environment from Linux. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] host-e2fsprogs: Fix build on Darwin
The O_DIRECT flag in e2fsprogs is relatively new. MacPorts is still using the old version of e2fsprogs. However, this patch from the upstream bug tracker fixes the build of e2fsprogs. Strictly direct I/O is not required for ptxdist because we're working on images only. So removing O_DIRECT here would also work, but this solution is cleaner. Signed-off-by: Bernhard Walle --- .../0003-Fix-compilation-on-Darwin.patch | 44 patches/e2fsprogs-1.41.14/series |3 +- 2 files changed, 46 insertions(+), 1 deletions(-) create mode 100644 patches/e2fsprogs-1.41.14/0003-Fix-compilation-on-Darwin.patch diff --git a/patches/e2fsprogs-1.41.14/0003-Fix-compilation-on-Darwin.patch b/patches/e2fsprogs-1.41.14/0003-Fix-compilation-on-Darwin.patch new file mode 100644 index 000..cb58afd --- /dev/null +++ b/patches/e2fsprogs-1.41.14/0003-Fix-compilation-on-Darwin.patch @@ -0,0 +1,44 @@ +From: Bernhard Walle +Date: Thu, 19 Jan 2012 22:31:46 +0100 +Subject: [PATCH] Fix compilation on Darwin + +The patch is inspired by the patch at +http://sourceforge.net/tracker/?func=detail&aid=3140289&group_id=2406&atid=102406 +(bug tracker of the upstream project). + +Signed-off-by: Bernhard Walle +--- + lib/ext2fs/unix_io.c | 11 +++ + 1 files changed, 11 insertions(+), 0 deletions(-) + +diff --git a/lib/ext2fs/unix_io.c b/lib/ext2fs/unix_io.c +index 1df1fdd..cbd3d70 100644 +--- a/lib/ext2fs/unix_io.c b/lib/ext2fs/unix_io.c +@@ -463,8 +463,10 @@ static errcode_t unix_open(const char *name, int flags, io_channel *channel) + open_flags = (flags & IO_FLAG_RW) ? O_RDWR : O_RDONLY; + if (flags & IO_FLAG_EXCLUSIVE) + open_flags |= O_EXCL; ++#ifdef O_DIRECT + if (flags & IO_FLAG_DIRECT_IO) + open_flags |= O_DIRECT; ++#endif + data->flags = flags; + + #ifdef HAVE_OPEN64 +@@ -477,6 +479,15 @@ static errcode_t unix_open(const char *name, int flags, io_channel *channel) + goto cleanup; + } + ++#if !defined(O_DIRECT) && defined(F_NOCACHE) ++ if (flags & IO_FLAG_DIRECT_IO) { ++ if (fcntl(data->dev, F_NOCACHE, 1) < 0) { ++ retval = errno; ++ goto cleanup; ++ } ++ } ++#endif ++ + #ifdef BLKSSZGET + if (flags & IO_FLAG_DIRECT_IO) { + if (ioctl(data->dev, BLKSSZGET, &data->align) != 0) diff --git a/patches/e2fsprogs-1.41.14/series b/patches/e2fsprogs-1.41.14/series index fac473a..44a543e 100644 --- a/patches/e2fsprogs-1.41.14/series +++ b/patches/e2fsprogs-1.41.14/series @@ -2,4 +2,5 @@ #tag:base --start-number 1 0001-Fixed-bitops.h-for-Coldfire-V4E.patch 0002-fix-linking-problem.patch -# ec0cc8b8677eb72a286f38e0e9ba63e9 - git-ptx-patches magic +0003-Fix-compilation-on-Darwin.patch +# b3f719def2b2e0004e2d9a830ebc59d0 - git-ptx-patches magic -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Fix usage of fakeroot on Darwin
The extension of shared libraries on Darwin is .dylib, not .so. Because fakeroot doesn't need specification of the pre-load library but finds the library automatically, remove calling fakeroot with -l. Signed-off-by: Bernhard Walle --- rules/pre/Rules.make |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/rules/pre/Rules.make b/rules/pre/Rules.make index c531a50..1d6da52 100644 --- a/rules/pre/Rules.make +++ b/rules/pre/Rules.make @@ -13,7 +13,8 @@ GNU_BUILD := $(shell $(SCRIPTSDIR)/autoconf/config.guess) GNU_HOST := $(shell echo $(GNU_BUILD) | sed s/-[a-zA-Z0-9_]*-/-host-/) INSTALL:= install -FAKEROOT := $(PTXDIST_SYSROOT_HOST)/bin/fakeroot -l $(PTXDIST_SYSROOT_HOST)/lib/libfakeroot.so + +FAKEROOT := $(PTXDIST_SYSROOT_HOST)/bin/fakeroot CHECK_PIPE_STATUS := \ for i in "$${PIPESTATUS[@]}"; do [ $$i -gt 0 ] && { \ -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] Fix usage of fakeroot on Darwin
Am 19.01.12 20:55, schrieb Michael Olbrich: > On Mon, Jan 16, 2012 at 09:30:25PM +0100, Bernhard Walle wrote: >> The extension of shared libraries on Darwin is .dylib, not .so. While >> the fakeroot script itself (which is part of the fakeroot distribution) >> can handle Darwin, ptxdist calls 'fakeroot' with the '-l' parameter and >> directly provides the full path to the shared library which is >> pre-loaded. > > Can you try removing '-l ' instead. From looking at the fakeroot > source, it should work. We use it like that in other places already. That works indeed. I also wondered why you're calling fakeroot with -l, but I thought it must have a reason. :) New version is coming. Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] host-e2fsprogs: Fix build on Darwin
The O_DIRECT flag in e2fsprogs is relatively new. MacPorts is still using the old version of e2fsprogs. However, this patch from the upstream bug tracker fixes the build of e2fsprogs. Strictly direct I/O is not required for ptxdist because we're working on images only. So removing O_DIRECT here would also work, but this solution is cleaner. Signed-off-by: Bernhard Walle --- .../0003-darwin_directio_fix.patch | 46 patches/e2fsprogs-1.41.14/series |1 + 2 files changed, 47 insertions(+), 0 deletions(-) create mode 100644 patches/e2fsprogs-1.41.14/0003-darwin_directio_fix.patch diff --git a/patches/e2fsprogs-1.41.14/0003-darwin_directio_fix.patch b/patches/e2fsprogs-1.41.14/0003-darwin_directio_fix.patch new file mode 100644 index 000..1e00c04 --- /dev/null +++ b/patches/e2fsprogs-1.41.14/0003-darwin_directio_fix.patch @@ -0,0 +1,46 @@ +Fix compilation on Darwin + +The patch is from upstream bug tracker [1]. However, it's not (yet) in the +upstream repository. + +[1] http://sourceforge.net/tracker/?func=detail&aid=3140289&group_id=2406&atid=102406 +--- + lib/ext2fs/unix_io.c | 12 + 1 file changed, 12 insertions(+) + +--- a/lib/ext2fs/unix_io.c b/lib/ext2fs/unix_io.c +@@ -428,6 +428,7 @@ static errcode_t unix_open(const char *n + struct unix_private_data *data = NULL; + errcode_t retval; + int open_flags; ++ int f_nocache = 0; + struct stat st; + #ifdef __linux__ + struct utsname ut; +@@ -464,7 +465,11 @@ static errcode_t unix_open(const char *n + if (flags & IO_FLAG_EXCLUSIVE) + open_flags |= O_EXCL; + if (flags & IO_FLAG_DIRECT_IO) ++#if !defined(O_DIRECT) && defined(F_NOCACHE) ++ f_nocache = F_NOCACHE; ++#else + open_flags |= O_DIRECT; ++#endif + data->flags = flags; + + #ifdef HAVE_OPEN64 +@@ -477,6 +482,13 @@ static errcode_t unix_open(const char *n + goto cleanup; + } + ++ if (f_nocache) { ++ if (fcntl(data->dev, f_nocache, 1) < 0) { ++ retval = errno; ++ goto cleanup; ++ } ++ } ++ + #ifdef BLKSSZGET + if (flags & IO_FLAG_DIRECT_IO) { + if (ioctl(data->dev, BLKSSZGET, &data->align) != 0) diff --git a/patches/e2fsprogs-1.41.14/series b/patches/e2fsprogs-1.41.14/series index fac473a..26e2c33 100644 --- a/patches/e2fsprogs-1.41.14/series +++ b/patches/e2fsprogs-1.41.14/series @@ -3,3 +3,4 @@ 0001-Fixed-bitops.h-for-Coldfire-V4E.patch 0002-fix-linking-problem.patch # ec0cc8b8677eb72a286f38e0e9ba63e9 - git-ptx-patches magic +0003-darwin_directio_fix.patch -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH v2] zlib: Fix build on non-Linux hosts
The build system of zlib uses 'uname' to determine the operating system for which it compiles zlib. However, on non-Linux hosts, this leads to wrong results. Fixes Darwin (tested on Mac OS 10.7 Lion), doesn't break Linux (verified with current Arch Linux on x86_64). Signed-off-by: Bernhard Walle --- v2: After reworking the sitecopy fix, I checked if it makes sense to use the same fix for zlib. However, zlib isn't using autoconf, it just uses a hand-written configure script. But now I think the "--uname" option which is explicitly provided is more clean than just setting some environment variable which indeed is an implementation detail of the script. rules/zlib.make |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/rules/zlib.make b/rules/zlib.make index 0d437e3..e51fe8a 100644 --- a/rules/zlib.make +++ b/rules/zlib.make @@ -47,7 +47,8 @@ ZLIB_CONF_ENV := \ # autoconf # ZLIB_AUTOCONF := \ - --prefix=/usr + --prefix=/usr \ + --uname=Linux ifdef PTXCONF_ZLIB_STATIC ZLIB_AUTOCONF += --static -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] sitecopy: Fix build on non-Linux hosts
The build system of sitecopy uses 'uname' to determine the operating system for which it compiles sitecopy. However, on non-Linux hosts, this leads to wrong results. Fixes Darwin (tested on Mac OS 10.7 Lion). Signed-off-by: Bernhard Walle --- patches/sitecopy-0.16.6/autoconf-neon-darwin.diff | 44 + patches/sitecopy-0.16.6/autogen.sh|1 + patches/sitecopy-0.16.6/series|1 + 3 files changed, 46 insertions(+), 0 deletions(-) create mode 100644 patches/sitecopy-0.16.6/autoconf-neon-darwin.diff create mode 12 patches/sitecopy-0.16.6/autogen.sh diff --git a/patches/sitecopy-0.16.6/autoconf-neon-darwin.diff b/patches/sitecopy-0.16.6/autoconf-neon-darwin.diff new file mode 100644 index 000..245f684 --- /dev/null +++ b/patches/sitecopy-0.16.6/autoconf-neon-darwin.diff @@ -0,0 +1,44 @@ +--- + m4/neon/neon.m4 | 23 +++ + 1 file changed, 11 insertions(+), 12 deletions(-) + +--- a/m4/neon/neon.m4 b/m4/neon/neon.m4 +@@ -410,19 +410,17 @@ fi + ]) + + AC_DEFUN([NE_CHECK_OS], [ +-# Check for Darwin, which needs extra cpp and linker flags. +-AC_CACHE_CHECK([for uname], ne_cv_os_uname, [ +- ne_cv_os_uname=`uname -s 2>/dev/null` +-]) + +-if test "$ne_cv_os_uname" = "Darwin"; then +- CPPFLAGS="$CPPFLAGS -no-cpp-precomp" +- LDFLAGS="$LDFLAGS -flat_namespace" +- # poll has various issues in various Darwin releases +- if test x${ac_cv_func_poll+set} != xset; then +-ac_cv_func_poll=no +- fi +-fi ++case "$host_os" in ++ darwin*) ++CPPFLAGS="$CPPFLAGS -no-cpp-precomp" ++LDFLAGS="$LDFLAGS -flat_namespace" ++# poll has various issues in various Darwin releases ++if test x${ac_cv_func_poll+set} != xset; then ++ ac_cv_func_poll=no ++fi ++;; ++esac + ]) + + AC_DEFUN([NEON_COMMON_CHECKS], [ +@@ -431,6 +429,7 @@ AC_DEFUN([NEON_COMMON_CHECKS], [ + # is used. + + AC_REQUIRE([AC_PROG_CC]) ++AC_REQUIRE([AC_CANONICAL_SYSTEM]) + AC_REQUIRE([AC_ISC_POSIX]) + AC_REQUIRE([AC_C_INLINE]) + AC_REQUIRE([AC_C_CONST]) diff --git a/patches/sitecopy-0.16.6/autogen.sh b/patches/sitecopy-0.16.6/autogen.sh new file mode 12 index 000..9f8a4cb --- /dev/null +++ b/patches/sitecopy-0.16.6/autogen.sh @@ -0,0 +1 @@ +../autogen.sh \ No newline at end of file diff --git a/patches/sitecopy-0.16.6/series b/patches/sitecopy-0.16.6/series index c295b75..f84ad01 100644 --- a/patches/sitecopy-0.16.6/series +++ b/patches/sitecopy-0.16.6/series @@ -1 +1,2 @@ sitecopy-neon-openssl.diff +autoconf-neon-darwin.diff -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] opkg-utils: use toolchain provided ar
Am 19.01.12 16:02, schrieb Andreas Bießmann: > On OS X (and other maybe other systems) the default provided ar is not a > GNU version and does not understand all the required switches. That should also fix the problem that ar on Darwin (regardless whether it's the GNU variant built by Mac Ports or if it's the ar from Apple) create ar archives without leading '/' in the index, which needs a small patch for arfile.py [1]. Right? Regards, Bernhard [1] https://bitbucket.org/bwalle/ptxdist-arm-boards/raw/5aace267/patches/opkg-utils-r4747/0005-opkg-darwin.diff -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] sitecopy: Fix build on non-Linux hosts
Am 18.01.12 11:23, schrieb Juergen Beisert: > Hi Bernhard, > > Bernhard Walle wrote: >> Am 18.01.2012 11:05, schrieb Juergen Beisert: >>> Can you send me the "config.log" file of the sitecopy package, after >>> *preparing* (prepare stage) it? Please run it one times without your >>> patch shown above. >>> I have no other system than Linux here, to check what the autotools >>> really detecting on different systems. >> >> Will do in the evening, > > Thanks. A bite late for the evening, but anyway attached. ;-) The check comes from m4/neon/neon.m4 which is included in sitecopy sources. Maybe I should patch that to check for the target system and link ptxdist autogen.sh? Regards, Bernhard This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by sitecopy configure 0.16.6, which was generated by GNU Autoconf 2.61. Invocation command line was $ ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --host=arm-v5te-linux-gnueabi --build=i386-host-darwin11.2.0 --disable-gnomefe --enable-threadsafe-ssl=posix --disable-nls --enable-threads=posix --disable-rpath --without-pakchois --without-socks --without-gssapi --enable-sftp --enable-rsh --enable-ftp --enable-webdav --with-expat ## - ## ## Platform. ## ## - ## hostname = galilei.fritz.box uname -m = x86_64 uname -r = 11.2.0 uname -s = Darwin uname -v = Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 /usr/bin/uname -p = i386 /bin/uname -X = unknown /bin/arch = unknown /usr/bin/arch -k = unknown /usr/convex/getsysinfo = unknown /usr/bin/hostinfo = Mach kernel version: Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 Kernel configured for up to 2 processors. 2 processors are physically available. 2 processors are logically available. Processor type: i486 (Intel 80486) Processors active: 0 1 Primary memory available: 4.00 gigabytes Default processor set: 118 tasks, 534 threads, 2 processors Load average: 4.61, Mach factor: 0.35 /bin/machine = unknown /usr/bin/oslevel = unknown /bin/universe = unknown PATH: /Volumes/mdevel/ptxdist-vetero/platform-dockstar/sysroot-cross/bin PATH: /Volumes/mdevel/ptxdist-vetero/platform-dockstar/sysroot-cross/sbin PATH: /Volumes/mdevel/ptxdist-vetero/platform-dockstar/sysroot-host/bin PATH: /Volumes/mdevel/ptxdist-vetero/platform-dockstar/sysroot-host/sbin PATH: /opt/OSELAS.Toolchain-2011.11.0/arm-v5te-linux-gnueabi/gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/bin PATH: /opt/ptxdist/lib/ptxdist-2012.01.0/bin PATH: /opt/ptxdist/bin PATH: /opt/texlive/2011-new/bin/universal-darwin PATH: /Users/bwalle/bin PATH: /opt/local/bin PATH: /opt/local/sbin PATH: /usr/bin PATH: /bin PATH: /usr/sbin PATH: /sbin PATH: /usr/local/bin PATH: /usr/X11/bin ## --- ## ## Core tests. ## ## --- ## configure:1905: checking for arm-v5te-linux-gnueabi-gcc configure:1932: result: arm-v5te-linux-gnueabi-gcc configure:2210: checking for C compiler version configure:2217: arm-v5te-linux-gnueabi-gcc --version >&5 arm-v5te-linux-gnueabi-gcc (OSELAS.Toolchain-2011.11.0) 4.6.2 Copyright (C) 2011 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. configure:2220: $? = 0 configure:2227: arm-v5te-linux-gnueabi-gcc -v >&5 Using built-in specs. COLLECT_GCC=arm-v5te-linux-gnueabi-gcc COLLECT_LTO_WRAPPER=/opt/OSELAS.Toolchain-2011.11.0/arm-v5te-linux-gnueabi/gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/libexec/gcc/arm-v5te-linux-gnueabi/4.6.2/lto-wrapper Target: arm-v5te-linux-gnueabi Configured with: /Volumes/Devel/OSELAS.Toolchain-2011.11.0/platform-arm-v5te-linux-gnueabi-gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/build-cross/gcc-4.6.2/configure --target=arm-v5te-linux-gnueabi --with-sysroot=/opt/OSELAS.Toolchain-2011.11.0/arm-v5te-linux-gnueabi/gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/sysroot-arm-v5te-linux-gnueabi --disable-multilib --with-float=soft --with-fpu=vfp --with-cpu=arm926ej-s --enable-__cxa_atexit --disable-sjlj-exceptions --disable-nls --disable-decimal-float --disable-fixed-point --disable-win32-registry --enable-symvers=gnu --with-pkgversion=OSELAS.Toolchain-2011.11.0 --with-system-zlib --with-gmp=/Volumes/Devel/OSELAS.Toolchain-2011.11.0/platform-arm-v5te-linux-gnueabi-gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/sysroot-host --with-mpfr=/Volumes/Devel/OSELAS.Toolchain-2011.11.0/platform-arm-v5te-linux-gnueabi-gcc-4.6.2-glibc-2.14.1-binutils-2.21.1a-kernel-2.6.39-sanitized/sysroot-host --prefix=/opt/OSELAS.Tool
Re: [ptxdist] [PATCH] sitecopy: Fix build on non-Linux hosts
Hi Jürgen, Am 18.01.2012 11:05, schrieb Juergen Beisert: > > Can you send me the "config.log" file of the sitecopy package, after > *preparing* (prepare stage) it? Please run it one times without your patch > shown above. > I have no other system than Linux here, to check what the autotools really > detecting on different systems. Will do in the evening, but as I remember, it was the '-no-cpp-precomp' compiler flag that caused the compilation failure: (from configure:) if test "$ne_cv_os_uname" = "Darwin"; then CPPFLAGS="$CPPFLAGS -no-cpp-precomp" LDFLAGS="$LDFLAGS -flat_namespace" # poll has various issues in various Darwin releases if test x${ac_cv_func_poll+set} != xset; then ac_cv_func_poll=no fi fi Regards, Bernhard -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] sqlite: Update to 3.7.10
Signed-off-by: Bernhard Walle --- rules/sqlite.make |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rules/sqlite.make b/rules/sqlite.make index 9491c4e..451c3b3 100644 --- a/rules/sqlite.make +++ b/rules/sqlite.make @@ -20,8 +20,8 @@ PACKAGES-$(PTXCONF_SQLITE) += sqlite # # Paths and names # -SQLITE_VERSION := 3070900 -SQLITE_MD5 := dce303524736fe89a76b8ed29d566352 +SQLITE_VERSION := 3071000 +SQLITE_MD5 := 9ed2ca93577b58cfa0d01f64b9312ab9 SQLITE_TYPE:= autoconf ifeq ($(SQLITE_TYPE),) SQLITE := sqlite-$(SQLITE_VERSION) -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] rootfs: Allow installation of /etc/modprobe.conf
I added this option in rootfs and not in module-init-tools because there are various implementations of modprobe that are using that file (module-init-tools, busybox and possibly kmod in future). Signed-off-by: Bernhard Walle --- rules/rootfs.in | 10 ++ rules/rootfs.make |3 +++ 2 files changed, 13 insertions(+), 0 deletions(-) diff --git a/rules/rootfs.in b/rules/rootfs.in index ecc3bf8..d8777c2 100644 --- a/rules/rootfs.in +++ b/rules/rootfs.in @@ -395,5 +395,15 @@ config ROOTFS_SERVICES If enabled, it installs the "./projectroot/etc/services" file if present, else a generic one from the ptxdist directory. +config ROOTFS_MODPROBE_CONF + bool + default n + prompt "install /etc/modprobe.conf" + help + If enabled, it installs the "./projectroot/etc/modprobe.conf" file if + present. Default options for kernel modules can be configured in that + file. It's read either in busybox modprobe or in the module-init-tools + modprobe implementation. + endmenu diff --git a/rules/rootfs.make b/rules/rootfs.make index ca7d3f4..e6187fc 100644 --- a/rules/rootfs.make +++ b/rules/rootfs.make @@ -226,6 +226,9 @@ endif ifdef PTXCONF_ROOTFS_SERVICES @$(call install_alternative, rootfs, 0, 0, 0644, /etc/services) endif +ifdef PTXCONF_ROOTFS_MODPROBE_CONF + @$(call install_alternative, rootfs, 0, 0, 0644, /etc/modprobe.conf) +endif @$(call install_finish, rootfs) -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] host-tz-database: Fix build on Darwin
This patch fixes following build error: localtime.c:1174: error: static declaration of 'tzsetwall' follows non-static declaration /usr/include/time.h:150: error: previous declaration of 'tzsetwall' was here On Linux: % grep -r tzsetwall /usr/include/ [nothing] On Mac OS 10.7: % grep -r tzsetwall /usr/include/ /usr/include/time.h:void tzsetwall(void); So this patch doesn't break Linux. Signed-off-by: Bernhard Walle --- rules/host-tz-database.make |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/rules/host-tz-database.make b/rules/host-tz-database.make index 018ec97..54a1003 100644 --- a/rules/host-tz-database.make +++ b/rules/host-tz-database.make @@ -75,7 +75,7 @@ $(STATEDIR)/host-tz-database.extract: HOST_TZ_DATABASE_PATH := PATH=$(HOST_PATH) HOST_TZ_DATABASE_CONF_TOOL := NO HOST_TZ_DATABASE_MAKE_OPT := \ - zic TZDIR=/usr/share/zoneinfo + zic TZDIR=/usr/share/zoneinfo CFLAGS=-DSTD_INSPIRED HOST_TZ_DATABASE_INSTALL_OPT := \ posix_only TZDIR=$(HOST_TZ_DATABASE_PKGDIR)/usr/share/zoneinfo -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] Fix usage of fakeroot on Darwin
The extension of shared libraries on Darwin is .dylib, not .so. While the fakeroot script itself (which is part of the fakeroot distribution) can handle Darwin, ptxdist calls 'fakeroot' with the '-l' parameter and directly provides the full path to the shared library which is pre-loaded. This patch adds a simple check, explicitly checking for Darwin in the 'uname -s' output. Verified to fix the build on Mac OS 10.7 (Lion). Signed-off-by: Bernhard Walle --- rules/pre/Rules.make |9 - 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/rules/pre/Rules.make b/rules/pre/Rules.make index c531a50..32c198b 100644 --- a/rules/pre/Rules.make +++ b/rules/pre/Rules.make @@ -13,7 +13,14 @@ GNU_BUILD:= $(shell $(SCRIPTSDIR)/autoconf/config.guess) GNU_HOST := $(shell echo $(GNU_BUILD) | sed s/-[a-zA-Z0-9_]*-/-host-/) INSTALL:= install -FAKEROOT := $(PTXDIST_SYSROOT_HOST)/bin/fakeroot -l $(PTXDIST_SYSROOT_HOST)/lib/libfakeroot.so + +ifeq ($(shell uname -s),Darwin) +SHLIB_SUFFIX := dylib +else +SHLIB_SUFFIX := so +endif + +FAKEROOT := $(PTXDIST_SYSROOT_HOST)/bin/fakeroot -l $(PTXDIST_SYSROOT_HOST)/lib/libfakeroot.$(SHLIB_SUFFIX) CHECK_PIPE_STATUS := \ for i in "$${PIPESTATUS[@]}"; do [ $$i -gt 0 ] && { \ -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] sitecopy: Fix build on non-Linux hosts
The build system of sitecopy uses 'uname' to determine the operating system for which it compiles sitecopy. However, on non-Linux hosts, this leads to wrong results. Fixes Darwin (tested on Mac OS 10.7 Lion), doesn't break Linux (verified with current Arch Linux on x86_64). Signed-off-by: Bernhard Walle --- rules/sitecopy.make |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/rules/sitecopy.make b/rules/sitecopy.make index 44a7b8a..c5af415 100644 --- a/rules/sitecopy.make +++ b/rules/sitecopy.make @@ -40,7 +40,8 @@ SITECOPY_AUTOCONF := $(CROSS_AUTOCONF_USR) \ --disable-rpath \ --without-pakchois \ --without-socks \ - --without-gssapi + --without-gssapi \ + ne_cv_os_uname=Linux ifdef PTXCONF_SITECOPY_SFTP SITECOPY_AUTOCONF += --enable-sftp -- 1.7.7.4 -- ptxdist mailing list ptxdist@pengutronix.de