Closed Bug 1031593 Opened 6 years ago Closed 5 years ago

B2G cannot be built with GNU make 4.0

Categories

(Firefox OS Graveyard :: GonkIntegration, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(b2g-master fixed)

RESOLVED FIXED
FxOS-S4 (07Aug)
Tracking Status
b2g-master --- fixed

People

(Reporter: jld, Assigned: kanru)

References

Details

Attachments

(1 file, 1 obsolete file)

Because Android requires GNU make 3.81 or 3.82, and no other versions, by extension so does B2G.  As more Linux distributions upgrade, and as we continue to support B2G configurations based on old Android versions like ICS, this is likely to become a larger issue.

Do we want to do something about this?  If so, what?
I just hit this after upgrading to Ubuntu 14.10.
Note: The current work-around is the build/install an older version of make and use that when building b2g (one technique is to put /path/to/old-make/bin at the beginning of your search path).
I just disabled the check on my local copy, and building with make 4.0 works fine for the flame.
(In reply to Augustin Trancart [:autra] from comment #3)
> I just disabled the check on my local copy, and building with make 4.0 works
> fine for the flame.

I tried doing that with a Buri/Hamachi build and I got a failure very early during |./build.sh gecko|:

> build/core/prebuilt.mk:141: *** recipe commences before first target.  Stop.

With make 3.82 it's currently progressing normally.
Duplicate of this bug: 1083730
New Debian stable is released and it comes with make 4.0 as well.
I just ran into this problem on Debian Jessie.

Can this be solved by adding a prebuilt make to our repositories and setting the MAKE variable in 'build.sh'?
Another problem on Debian 8 is that there are no older compilers available for building Android code from ICS repositories. Is it possible to use one of the prebuilt compilers for this?
(In reply to Nicholas Nethercote [:njn] from comment #4)
> (In reply to Augustin Trancart [:autra] from comment #3)
> > I just disabled the check on my local copy, and building with make 4.0 works
> > fine for the flame.
> 
> I tried doing that with a Buri/Hamachi build and I got a failure very early
> during |./build.sh gecko|:
> 
> > build/core/prebuilt.mk:141: *** recipe commences before first target.  Stop.
> 
> With make 3.82 it's currently progressing normally.

I tried to build emulator with make 4.0 today but also encountered this error.
commenting out build/core/prebuilt.mk line 139 to line 145 let the build continues
looks like a bug introduced in build/core/prebuilt.mk rev 1b6d0a65fc62901f2c18d00c556bd5da50f35584 because it made line 139 to 145 dangling recipe commences
Attached patch patch (obsolete) — Splinter Review
apply this patch under build/
Attachment #8606093 - Attachment is patch: true
Comment on attachment 8606093 [details] [diff] [review]
patch

Ping on this. Who can review this change? Looks like the prebuilt fix might no longer be necessary, so I think just the make version check is needed.
Attachment #8606093 - Flags: review?(21)
Comment on attachment 8606093 [details] [diff] [review]
patch

Maybe mwu but clearly not me :)
Attachment #8606093 - Flags: review?(21) → review?(mwu)
Comment on attachment 8606093 [details] [diff] [review]
patch

Review of attachment 8606093 [details] [diff] [review]:
-----------------------------------------------------------------

The main.mk part looks fine. I don't think we need the prebuilt.mk part. Please resubmit as a PR.
Attachment #8606093 - Flags: review?(mwu)
Assignee: nobody → kchen
Attachment #8606093 - Attachment is obsolete: true
Attachment #8639667 - Flags: review?(mwu)
Comment on attachment 8639667 [details] [review]
https://github.com/mozilla-b2g/platform_build/pull/122

r=me for this on master branch and any other branch this might apply to. (I think everything up to and including kitkat probably needs this..)
Attachment #8639667 - Flags: review?(mwu) → review+
See comment 17.
Keywords: checkin-needed
https://github.com/mozilla-b2g/platform_build/commit/1b0db93fb6b870b03467aff50d6419771ba0d88c
Status: NEW → RESOLVED
Closed: 5 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → FxOS-S4 (07Aug)
You need to log in before you can comment on or make changes to this bug.