[OE-core] [PATCH 1/3] sanity.bbclass: Check for the known broken version of make
Martin Jansa
martin.jansa at gmail.com
Tue Jun 25 14:26:27 UTC 2013
On Tue, Jun 25, 2013 at 09:12:24AM -0500, Mark Hatle wrote:
> On 6/25/13 6:20 AM, Martin Jansa wrote:
> > On Mon, Jun 24, 2013 at 09:06:11PM -0500, Mark Hatle wrote:
> >> On 6/24/13 5:09 PM, Saul Wold wrote:
> >>> On 06/24/2013 07:45 AM, Mark Hatle wrote:
> >>>> See GNU Savannah bug 30612 -- make 3.82 is known to be broken.
> >>>>
> >>>> A number of vendors are providing a modified version, so checking
> >>>> for just the version string is not enough. We also need to check
> >>>> if the patch for the issue has been applied. We use a modified
> >>>> version of the reproduced to check for the issue.
> >>>>
> >>>> Signed-off-by: Mark Hatle <mark.hatle at windriver.com>
> >>>> ---
> >>>> meta/classes/sanity.bbclass | 39 +++++++++++++++++++++++++++++++++++++++
> >>>> 1 file changed, 39 insertions(+)
> >>>>
> >>>
> >>> Seems this needs a rebase since RP also changed sanity.bbclass recently.
> >>
> >> This is from Friday morning. I'll start a rebase and send new code when I have
> >> it ready.
> >
> > There is another issues with unpatched make-3.82, webkit and newer
> > nodejs are failing for some people.
> > https://savannah.gnu.org/bugs/?36451
> >
> > What about for cycle which generates some very long "ls" or something
> > like that?
> >
> > On other hand so long commands arn't so common, so many people
> > could be using "broken" make without seeing issues with their images.
>
> If you can point me to a reproducer, I'm happy to add it to the sanity check as
> part of the rebase work.
>
> The current reproducer covers two cases (see the patch for the savannah bug
> number). These were the two cases that I knew had caused problems for others in
> the past.
I don't have simple reproducer, because it works fine in both make-3.82
I'm using (from Gentoo and Ubuntu) and with my reasonable long TOPDIR.
The problem is triggered in some webkit builds and also in nodejs-0.10.4
http://patchwork.openembedded.org/patch/48253/
Tasslehoff reported today that nodejs was failing for him with
/home/tas/angstrom-setup-scripts and works fine with /home/tas/oe
adding him to Cc, maybe he has better reproducer now.
>
> --Mark
>
> >>
> >> --Mark
> >>
> >>> Sau!
> >>>
> >>>> diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
> >>>> index 7f95f31..dc251a1 100644
> >>>> --- a/meta/classes/sanity.bbclass
> >>>> +++ b/meta/classes/sanity.bbclass
> >>>> @@ -336,6 +336,41 @@ def check_gcc_march(sanity_data):
> >>>>
> >>>> return result
> >>>>
> >>>> +# Unpatched versions of make 3.82 are known to be broken. See GNU Savannah Bug 30612.
> >>>> +# Use a modified reproducer from http://savannah.gnu.org/bugs/?30612 to validate.
> >>>> +def check_make_version(sanity_data, loosever):
> >>>> + status, result = oe.utils.getstatusoutput("make --version")
> >>>> + if status != 0:
> >>>> + return "Unable to execute make --version, exit code %s\n" % status
> >>>> + version = result.split()[2]
> >>>> + if loosever(version) == loosever("3.82"):
> >>>> + # Construct a test file
> >>>> + f = open("makefile_test", "w")
> >>>> + f.write("makefile_test.a: makefile_test_a.c makefile_test_b.c makefile_test.a( makefile_test_a.c makefile_test_b.c)\n")
> >>>> + f.write("\n")
> >>>> + f.write("makefile_test_a.c:\n")
> >>>> + f.write(" touch $@\n")
> >>>> + f.write("\n")
> >>>> + f.write("makefile_test_b.c:\n")
> >>>> + f.write(" touch $@\n")
> >>>> + f.close()
> >>>> +
> >>>> + # Check if make 3.82 has been patched
> >>>> + status,result = oe.utils.getstatusoutput("make -f makefile_test")
> >>>> +
> >>>> + os.remove("makefile_test")
> >>>> + if os.path.exists("makefile_test_a.c"):
> >>>> + os.remove("makefile_test_a.c")
> >>>> + if os.path.exists("makefile_test_b.c"):
> >>>> + os.remove("makefile_test_b.c")
> >>>> + if os.path.exists("makefile_test.a"):
> >>>> + os.remove("makefile_test.a")
> >>>> +
> >>>> + if status != 0:
> >>>> + return "Your version of make 3.82 is broken. Please revert to 3.81 or install a patched version.\n"
> >>>> + return None
> >>>> +
> >>>> +
> >>>> # Tar version 1.24 and onwards handle overwriting symlinks correctly
> >>>> # but earlier versions do not; this needs to work properly for sstate
> >>>> def check_tar_version(sanity_data, loosever):
> >>>> @@ -407,6 +442,10 @@ def check_sanity(sanity_data):
> >>>> messages = messages + 'Please set a MACHINE in your local.conf or environment\n'
> >>>> machinevalid = False
> >>>>
> >>>> + makemsg = check_make_version(sanity_data, LooseVersion)
> >>>> + if makemsg:
> >>>> + messages = messages + makemsg
> >>>> +
> >>>> tarmsg = check_tar_version(sanity_data, LooseVersion)
> >>>> if tarmsg:
> >>>> messages = messages + tarmsg
> >>>>
> >>
> >> _______________________________________________
> >> Openembedded-core mailing list
> >> Openembedded-core at lists.openembedded.org
> >> http://lists.openembedded.org/mailman/listinfo/openembedded-core
> >
>
--
Martin 'JaMa' Jansa jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20130625/7eb89abb/attachment-0002.sig>
More information about the Openembedded-core
mailing list