* [PATCH 1/8] m4: do_configure: fix "Argument list too long"
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 8:45 ` [PATCH 2/8] guile: " Robert Yang
` (6 subsequent siblings)
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
Fixed when len(TMPDIR) = 410:
Can't exec "/bin/sh": Argument list too long at /usr/lib/perl/5.18/IO/File.pm line 65.
This is becuase it has a lot of m4 files, use relative path for them
can fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-devtools/m4/m4-1.4.18.inc | 3 +++
1 file changed, 3 insertions(+)
diff --git a/meta/recipes-devtools/m4/m4-1.4.18.inc b/meta/recipes-devtools/m4/m4-1.4.18.inc
index 5652b74308..d7c8648577 100644
--- a/meta/recipes-devtools/m4/m4-1.4.18.inc
+++ b/meta/recipes-devtools/m4/m4-1.4.18.inc
@@ -15,5 +15,8 @@ SRC_URI_append_class-target = "\
file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
"
+# Fix "Argument list too long" error when len(TMPDIR) = 410
+acpaths = "-I ./m4"
+
SRC_URI[md5sum] = "a077779db287adf4e12a035029002d28"
SRC_URI[sha256sum] = "ab2633921a5cd38e48797bf5521ad259bdc4b979078034a3b790d7fec5493fab"
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* [PATCH 2/8] guile: do_configure: fix "Argument list too long"
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
2017-03-14 8:45 ` [PATCH 1/8] m4: do_configure: fix "Argument list too long" Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 12:06 ` Burton, Ross
2017-03-14 8:45 ` [PATCH 3/8] kmod: set ac_cv_path_DOLT_BASH to /bin/bash Robert Yang
` (5 subsequent siblings)
7 siblings, 1 reply; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
Fixed when len(TMPDIR) = 410:
Can't exec "/bin/sh": Argument list too long at /usr/lib/perl/5.18/IO/File.pm line 65.
This is becuase it has a lot of m4 files, use relative path for them
can fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-devtools/guile/guile_2.0.14.bb | 3 +++
1 file changed, 3 insertions(+)
diff --git a/meta/recipes-devtools/guile/guile_2.0.14.bb b/meta/recipes-devtools/guile/guile_2.0.14.bb
index d2306e6a75..7a36ba0c3b 100644
--- a/meta/recipes-devtools/guile/guile_2.0.14.bb
+++ b/meta/recipes-devtools/guile/guile_2.0.14.bb
@@ -30,6 +30,9 @@ SRC_URI[sha256sum] = "e8442566256e1be14e51fc18839cd799b966bc5b16c6a1d7a7c35155a8
inherit autotools gettext pkgconfig texinfo
BBCLASSEXTEND = "native"
+# Fix "Argument list too long" error when len(TMPDIR) = 410
+acpaths = "-I ./m4"
+
DEPENDS = "libunistring bdwgc gmp libtool libffi ncurses readline"
# add guile-native only to the target recipe's DEPENDS
DEPENDS_append_class-target = " guile-native libatomic-ops"
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* Re: [PATCH 2/8] guile: do_configure: fix "Argument list too long"
2017-03-14 8:45 ` [PATCH 2/8] guile: " Robert Yang
@ 2017-03-14 12:06 ` Burton, Ross
2017-03-15 2:17 ` Robert Yang
0 siblings, 1 reply; 15+ messages in thread
From: Burton, Ross @ 2017-03-14 12:06 UTC (permalink / raw)
To: Robert Yang; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 264 bytes --]
On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com> wrote:
> +# Fix "Argument list too long" error when len(TMPDIR) = 410
> +acpaths = "-I ./m4"
>
If we're fixing this in various recipes, why not fix in autotools.bbclass
directly?
Ross
[-- Attachment #2: Type: text/html, Size: 700 bytes --]
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH 2/8] guile: do_configure: fix "Argument list too long"
2017-03-14 12:06 ` Burton, Ross
@ 2017-03-15 2:17 ` Robert Yang
0 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-15 2:17 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
On 03/14/2017 08:06 PM, Burton, Ross wrote:
>
> On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com
> <mailto:liezhi.yang@windriver.com>> wrote:
>
> +# Fix "Argument list too long" error when len(TMPDIR) = 410
> +acpaths = "-I ./m4"
>
>
> If we're fixing this in various recipes, why not fix in autotools.bbclass directly?
We had tried this about 3 years, but failed since the m4 files may not in
./m4, and the worse is that it may in sub directory, RP didn't think that
set it in autotools.bbclass is a good idea, so we fix the recipe one by one.
// Robert
>
> Ross
^ permalink raw reply [flat|nested] 15+ messages in thread
* [PATCH 3/8] kmod: set ac_cv_path_DOLT_BASH to /bin/bash
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
2017-03-14 8:45 ` [PATCH 1/8] m4: do_configure: fix "Argument list too long" Robert Yang
2017-03-14 8:45 ` [PATCH 2/8] guile: " Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 8:45 ` [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl Robert Yang
` (4 subsequent siblings)
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
#define BINPRM_BUF_SIZE 128
So there would be errors when /path/to/hosttools/bash is longer than 128:
/bin/sh: ./doltcompile: [snip]: bad interpreter: No such file or directory
Set ac_cv_path_DOLT_BASH to /bin/bash to fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-kernel/kmod/kmod.inc | 2 ++
1 file changed, 2 insertions(+)
diff --git a/meta/recipes-kernel/kmod/kmod.inc b/meta/recipes-kernel/kmod/kmod.inc
index cfa409dbb3..77bf689db3 100644
--- a/meta/recipes-kernel/kmod/kmod.inc
+++ b/meta/recipes-kernel/kmod/kmod.inc
@@ -30,6 +30,8 @@ S = "${WORKDIR}/git"
EXTRA_AUTORECONF += "--install --symlink"
EXTRA_OECONF +=" --enable-tools --with-zlib"
+CACHED_CONFIGUREVARS += "ac_cv_path_DOLT_BASH=/bin/bash"
+
PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
PACKAGECONFIG[logging] = " --enable-logging,--disable-logging"
PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
` (2 preceding siblings ...)
2017-03-14 8:45 ` [PATCH 3/8] kmod: set ac_cv_path_DOLT_BASH to /bin/bash Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 12:06 ` Burton, Ross
2017-03-14 8:45 ` [PATCH 5/8] valgrind: " Robert Yang
` (3 subsequent siblings)
7 siblings, 1 reply; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
#define BINPRM_BUF_SIZE 128
So there would be errors when /path/to/hosttools/perl is longer than 128.
Set ac_cv_path_PERL to /usr/bin/perl to fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-extended/mc/mc_4.8.18.bb | 2 ++
1 file changed, 2 insertions(+)
diff --git a/meta/recipes-extended/mc/mc_4.8.18.bb b/meta/recipes-extended/mc/mc_4.8.18.bb
index 78abb275ba..87cc4d0677 100644
--- a/meta/recipes-extended/mc/mc_4.8.18.bb
+++ b/meta/recipes-extended/mc/mc_4.8.18.bb
@@ -22,6 +22,8 @@ PACKAGECONFIG[sftp] = "--enable-vfs-sftp,--disable-vfs-sftp,libssh2,"
EXTRA_OECONF = "--with-screen=ncurses --without-gpm-mouse --without-x"
+CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
+
do_install_append () {
sed -i -e '1s,#!.*perl,#!${bindir}/env perl,' ${D}${libexecdir}/mc/extfs.d/*
sed -i -e '1s,#!.*python,#!${bindir}/env python,' ${D}${libexecdir}/mc/extfs.d/*
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* Re: [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl
2017-03-14 8:45 ` [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl Robert Yang
@ 2017-03-14 12:06 ` Burton, Ross
2017-03-14 12:10 ` Burton, Ross
0 siblings, 1 reply; 15+ messages in thread
From: Burton, Ross @ 2017-03-14 12:06 UTC (permalink / raw)
To: Robert Yang; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 211 bytes --]
On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com> wrote:
> +CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
>
Would it be sensible to put this in autotools.bbclass?
Ross
[-- Attachment #2: Type: text/html, Size: 637 bytes --]
^ permalink raw reply [flat|nested] 15+ messages in thread* Re: [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl
2017-03-14 12:06 ` Burton, Ross
@ 2017-03-14 12:10 ` Burton, Ross
2017-03-15 2:14 ` Robert Yang
0 siblings, 1 reply; 15+ messages in thread
From: Burton, Ross @ 2017-03-14 12:10 UTC (permalink / raw)
To: Robert Yang; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 607 bytes --]
On 14 March 2017 at 12:06, Burton, Ross <ross.burton@intel.com> wrote:
> On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com> wrote:
>
>> +CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
>>
>
> Would it be sensible to put this in autotools.bbclass?
>
Hang on. ac_cv_path_PERL is the result of AC_PATH_PROG(perl) which is the
path to the perl on the host. Is mc using this path only for writing the
hashbang into scripts? If it tries to execute the path on the build host
then there's several ways this can fail (perl in /usr/local or with
buildtools).
Ross
[-- Attachment #2: Type: text/html, Size: 1389 bytes --]
^ permalink raw reply [flat|nested] 15+ messages in thread* Re: [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl
2017-03-14 12:10 ` Burton, Ross
@ 2017-03-15 2:14 ` Robert Yang
2017-03-16 6:35 ` Robert Yang
0 siblings, 1 reply; 15+ messages in thread
From: Robert Yang @ 2017-03-15 2:14 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
On 03/14/2017 08:10 PM, Burton, Ross wrote:
>
> On 14 March 2017 at 12:06, Burton, Ross <ross.burton@intel.com
> <mailto:ross.burton@intel.com>> wrote:
>
> On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com
> <mailto:liezhi.yang@windriver.com>> wrote:
>
> +CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
>
>
> Would it be sensible to put this in autotools.bbclass?
>
>
> Hang on. ac_cv_path_PERL is the result of AC_PATH_PROG(perl) which is the path
> to the perl on the host. Is mc using this path only for writing the hashbang
> into scripts? If it tries to execute the path on the build host then there's
> several ways this can fail (perl in /usr/local or with buildtools).
Hi Ross,
The automake and autoconf had already set this:
CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
So I set it for mc referred to them, should we use "#!/usr/bin/env perl" here ?
// Robert
>
> Ross
>
^ permalink raw reply [flat|nested] 15+ messages in thread* Re: [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl
2017-03-15 2:14 ` Robert Yang
@ 2017-03-16 6:35 ` Robert Yang
0 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-16 6:35 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
On 03/15/2017 10:14 AM, Robert Yang wrote:
>
>
> On 03/14/2017 08:10 PM, Burton, Ross wrote:
>>
>> On 14 March 2017 at 12:06, Burton, Ross <ross.burton@intel.com
>> <mailto:ross.burton@intel.com>> wrote:
>>
>> On 14 March 2017 at 08:45, Robert Yang <liezhi.yang@windriver.com
>> <mailto:liezhi.yang@windriver.com>> wrote:
>>
>> +CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
>>
>>
>> Would it be sensible to put this in autotools.bbclass?
>>
>>
>> Hang on. ac_cv_path_PERL is the result of AC_PATH_PROG(perl) which is the path
>> to the perl on the host. Is mc using this path only for writing the hashbang
>> into scripts? If it tries to execute the path on the build host then there's
>> several ways this can fail (perl in /usr/local or with buildtools).
>
> Hi Ross,
>
> The automake and autoconf had already set this:
>
> CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
>
> So I set it for mc referred to them, should we use "#!/usr/bin/env perl" here ?
Hi Ross,
Any comments, please ?
// Robert
>
> // Robert
>
>>
>> Ross
>>
^ permalink raw reply [flat|nested] 15+ messages in thread
* [PATCH 5/8] valgrind: set ac_cv_path_PERL to /usr/bin/perl
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
` (3 preceding siblings ...)
2017-03-14 8:45 ` [PATCH 4/8] mc: set ac_cv_path_PERL to /usr/bin/perl Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 8:45 ` [PATCH 6/8] autogen-native: config/libopts.m4 Robert Yang
` (2 subsequent siblings)
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
#define BINPRM_BUF_SIZE 128
So there would be errors when /path/to/hosttools/perl is longer than 128.
Set ac_cv_path_PERL to /usr/bin/perl to fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-devtools/valgrind/valgrind_3.12.0.bb | 2 ++
1 file changed, 2 insertions(+)
diff --git a/meta/recipes-devtools/valgrind/valgrind_3.12.0.bb b/meta/recipes-devtools/valgrind/valgrind_3.12.0.bb
index a4a3e72ecd..48091420c3 100644
--- a/meta/recipes-devtools/valgrind/valgrind_3.12.0.bb
+++ b/meta/recipes-devtools/valgrind/valgrind_3.12.0.bb
@@ -56,6 +56,8 @@ EXTRA_OECONF_append_arm = " --host=armv7${HOST_VENDOR}-${HOST_OS}"
EXTRA_OEMAKE = "-w"
+CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl"
+
# valgrind likes to control its own optimisation flags. It generally defaults
# to -O2 but uses -O0 for some specific test apps etc. Passing our own flags
# (via CFLAGS) means we interfere with that. Only pass DEBUG_FLAGS to it
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* [PATCH 6/8] autogen-native: config/libopts.m4
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
` (4 preceding siblings ...)
2017-03-14 8:45 ` [PATCH 5/8] valgrind: " Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 8:45 ` [PATCH 7/8] autogen-native: fix POSIX_SHELL and perl Robert Yang
2017-03-14 8:45 ` [PATCH 8/8] oe/path.py: fix for "Argument list too long" Robert Yang
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
It was out of date compared to config/libopts.def, so regenerate it via
"autogen config/libopts.def" command.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
.../autogen/autogen-native_5.18.12.bb | 1 +
...pts.m4-regenerate-it-from-config-libopts..patch | 39 ++++++++++++++++++++++
2 files changed, 40 insertions(+)
create mode 100644 meta/recipes-devtools/autogen/autogen/0001-config-libopts.m4-regenerate-it-from-config-libopts..patch
diff --git a/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb b/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
index cf1744c8c0..0004389b11 100644
--- a/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
+++ b/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
@@ -12,6 +12,7 @@ SRC_URI = "${GNU_MIRROR}/autogen/rel${PV}/autogen-${PV}.tar.gz \
file://increase-timeout-limit.patch \
file://mk-tpl-config.sh-force-exit-value-to-be-0-in-subproc.patch \
file://fix-script-err-when-processing-libguile.patch \
+ file://0001-config-libopts.m4-regenerate-it-from-config-libopts..patch \
"
SRC_URI[md5sum] = "551d15ccbf5b5fc5658da375d5003389"
diff --git a/meta/recipes-devtools/autogen/autogen/0001-config-libopts.m4-regenerate-it-from-config-libopts..patch b/meta/recipes-devtools/autogen/autogen/0001-config-libopts.m4-regenerate-it-from-config-libopts..patch
new file mode 100644
index 0000000000..a14018e339
--- /dev/null
+++ b/meta/recipes-devtools/autogen/autogen/0001-config-libopts.m4-regenerate-it-from-config-libopts..patch
@@ -0,0 +1,39 @@
+From 45040e7d268329ebc40e6cb237c64a6637cfab5c Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Mon, 13 Mar 2017 20:22:10 -0700
+Subject: [PATCH] config/libopts.m4: regenerate it from config/libopts.def
+
+It was out of date compared to config/libopts.def, so regenerate it via
+"autogen config/libopts.def" command.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ config/libopts.m4 | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/config/libopts.m4 b/config/libopts.m4
+index c7ba4f3..51e6a39 100644
+--- a/config/libopts.m4
++++ b/config/libopts.m4
+@@ -2,7 +2,7 @@ dnl -*- buffer-read-only: t -*- vi: set ro:
+ dnl
+ dnl DO NOT EDIT THIS FILE (libopts.m4)
+ dnl
+-dnl It has been AutoGen-ed
++dnl It has been AutoGen-ed March 13, 2017 at 08:21:21 PM by AutoGen 5.18
+ dnl From the definitions libopts.def
+ dnl and the template file conftest.tpl
+ dnl
+@@ -114,6 +114,7 @@ AC_DEFUN([INVOKE_LIBOPTS_MACROS_FIRST],[
+ AC_PROG_SED
+ [while :
+ do
++ test -x "$POSIX_SHELL" && break
+ POSIX_SHELL=`which bash`
+ test -x "$POSIX_SHELL" && break
+ POSIX_SHELL=`which dash`
+--
+2.10.2
+
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* [PATCH 7/8] autogen-native: fix POSIX_SHELL and perl
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
` (5 preceding siblings ...)
2017-03-14 8:45 ` [PATCH 6/8] autogen-native: config/libopts.m4 Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
2017-03-14 8:45 ` [PATCH 8/8] oe/path.py: fix for "Argument list too long" Robert Yang
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
#define BINPRM_BUF_SIZE 128
So there would be errors when /path/to/hosttools/perl is longer than 128.
This patch fixes the problem when POSIX_SHELL and perl are used as the interpreters.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
.../autogen/autogen-native_5.18.12.bb | 3 ++
...2-autoopts-mk-tpl-config.sh-fix-perl-path.patch | 32 ++++++++++++++++++++++
2 files changed, 35 insertions(+)
create mode 100644 meta/recipes-devtools/autogen/autogen/0002-autoopts-mk-tpl-config.sh-fix-perl-path.patch
diff --git a/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb b/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
index 0004389b11..c3c8287210 100644
--- a/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
+++ b/meta/recipes-devtools/autogen/autogen-native_5.18.12.bb
@@ -13,6 +13,7 @@ SRC_URI = "${GNU_MIRROR}/autogen/rel${PV}/autogen-${PV}.tar.gz \
file://mk-tpl-config.sh-force-exit-value-to-be-0-in-subproc.patch \
file://fix-script-err-when-processing-libguile.patch \
file://0001-config-libopts.m4-regenerate-it-from-config-libopts..patch \
+ file://0002-autoopts-mk-tpl-config.sh-fix-perl-path.patch \
"
SRC_URI[md5sum] = "551d15ccbf5b5fc5658da375d5003389"
@@ -30,6 +31,8 @@ inherit autotools texinfo native pkgconfig
export GUILE_LOAD_PATH = "${STAGING_DATADIR_NATIVE}/guile/2.0"
export GUILE_LOAD_COMPILED_PATH = "${STAGING_LIBDIR_NATIVE}/guile/2.0/ccache"
+export POSIX_SHELL = "/bin/bash"
+
do_install_append () {
create_wrapper ${D}/${bindir}/autogen \
GUILE_LOAD_PATH=${STAGING_DATADIR_NATIVE}/guile/2.0 \
diff --git a/meta/recipes-devtools/autogen/autogen/0002-autoopts-mk-tpl-config.sh-fix-perl-path.patch b/meta/recipes-devtools/autogen/autogen/0002-autoopts-mk-tpl-config.sh-fix-perl-path.patch
new file mode 100644
index 0000000000..d5fe143ce4
--- /dev/null
+++ b/meta/recipes-devtools/autogen/autogen/0002-autoopts-mk-tpl-config.sh-fix-perl-path.patch
@@ -0,0 +1,32 @@
+From 9f69f3f5ef22bf1bcffb0e651efc260889cfaa46 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Mon, 13 Mar 2017 20:33:30 -0700
+Subject: [PATCH] autoopts/mk-tpl-config.sh: fix perl path
+
+Use "which perl" as shebang doesn't work when it is longer than
+BINPRM_BUF_SIZE which is 128 usually. So use "/usr/bin/env perl" to
+instead of.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ autoopts/mk-tpl-config.sh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/autoopts/mk-tpl-config.sh b/autoopts/mk-tpl-config.sh
+index 093e808..8dfc6dd 100755
+--- a/autoopts/mk-tpl-config.sh
++++ b/autoopts/mk-tpl-config.sh
+@@ -98,7 +98,7 @@ fix_scripts() {
+ st=`sed 1q $f`
+
+ case "$st" in
+- *perl ) echo '#!' `which perl`
++ *perl ) echo '#!/usr/bin/env perl'
+ sed 1d $f
+ ;;
+
+--
+2.10.2
+
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread* [PATCH 8/8] oe/path.py: fix for "Argument list too long"
2017-03-14 8:45 [PATCH 0/8] fixes for building in long path Robert Yang
` (6 preceding siblings ...)
2017-03-14 8:45 ` [PATCH 7/8] autogen-native: fix POSIX_SHELL and perl Robert Yang
@ 2017-03-14 8:45 ` Robert Yang
7 siblings, 0 replies; 15+ messages in thread
From: Robert Yang @ 2017-03-14 8:45 UTC (permalink / raw)
To: openembedded-core
Issue: LIN9-1648
Fixed when len(TMPDIR) = 410:
$ bitbake core-image-sato-sdk
[snip]
Subprocess output:
/bin/sh: /bin/cp: Argument list too long
ERROR: core-image-sato-sdk-1.0-r0 do_rootfs: Function failed: do_rootfs
[snip]
This is because "copyhardlinktree(src, dst)" does "cp -afl src/* dst",
while src/* is expanded to "src/file1 src/file2, src/file3..." which
causes the "Argument list too long", use ./* as src and change cwd in
subprocess.check_output() to fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/lib/oe/path.py | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/meta/lib/oe/path.py b/meta/lib/oe/path.py
index a2a50c5b39..448a2b944e 100644
--- a/meta/lib/oe/path.py
+++ b/meta/lib/oe/path.py
@@ -103,12 +103,14 @@ def copyhardlinktree(src, dst):
source = ''
if os.path.isdir(src):
if len(glob.glob('%s/.??*' % src)) > 0:
- source = '%s/.??* ' % src
- source = source + '%s/*' % src
+ source = './.??* '
+ source += './*'
+ s_dir = src
else:
source = src
- cmd = 'cp -afl --preserve=xattr %s %s' % (source, dst)
- subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
+ s_dir = os.getcwd()
+ cmd = 'cp -afl --preserve=xattr %s %s' % (source, os.path.realpath(dst))
+ subprocess.check_output(cmd, shell=True, cwd=s_dir, stderr=subprocess.STDOUT)
else:
copytree(src, dst)
--
2.11.0.rc2.dirty
^ permalink raw reply related [flat|nested] 15+ messages in thread