Closed Bug 1405389 Opened 3 years ago Closed 3 years ago

mach bootstrap uses wrong macports port name

Categories

(Firefox Build System :: General, enhancement)

x86_64
macOS
enhancement
Not set
normal

Tracking

(firefox58 fixed)

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: areinald.bug, Assigned: areinald.bug)

References

Details

Attachments

(1 file, 1 obsolete file)

mach bootstrap wants macports to install py27-readline.
That port has been renamed to py27-gnureadline.
Attached patch bug-1405389-1.patch (obsolete) — Splinter Review
Assignee: nobody → areinald.bug
Status: NEW → ASSIGNED
Thanks for the patch!  I'm going to assume that as the author of the patch, you have verified this fix works on a macports system, since I don't have such a system close at hand. :)

How recently did the port get renamed?  Do we have to try and handle both names, for people using macports who haven't updated to the latest-and-greatest?

Did you mean to ask for review on the patch, or were you putting it here for reference?
Flags: needinfo?(areinald.bug)
Comment on attachment 8914826 [details] [diff] [review]
bug-1405389-1.patch

Yes, the fix works on a current installation of MacPorts.

Thanks for pointing that out: after some digging it looks the package name change occurred about 3-4 years ago. MacPorts requires a full update of ports at every major system upgrade, and a few of those happened in this period. Plus compiling mozcentral requires ports which are much more recent than 3-4 years (clang/llvm 4.0). So I think it's safe to assume targeted developers have a sufficiently current MacPorts.

I'd be glad to have a review and land the patch, I just didn't know who to ask.
Flags: needinfo?(areinald.bug)
Attachment #8914826 - Flags: review?(nfroyd)
If the change occurred several years ago and nobody reported that before, it is probably safe to say that the Macports bootstrap support is not used by Firefox contributors or dev. Maybe we should remove that.
Blocks: 1288249
Or maybe potential contributors gave up?
It looks like this script is the only place where we "support" macports anyway, and I only hit this issue when running it.
As a macports user, I'd be happy with human readable instructions about build dependencies: maybe one day I'll create a portfile to build Firefox from macports :-)
Comment on attachment 8914826 [details] [diff] [review]
bug-1405389-1.patch

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

Thank you!
Attachment #8914826 - Flags: review?(nfroyd) → review+
Duplicate of this bug: 1406646
Changed previous patch comment to respect guidelines.
Carrying over r+
Keywords: checkin-needed
Comment on attachment 8914826 [details] [diff] [review]
bug-1405389-1.patch

>diff --git a/python/mozboot/mozboot/osx.py b/python/mozboot/mozboot/osx.py
>--- a/python/mozboot/mozboot/osx.py
>+++ b/python/mozboot/mozboot/osx.py
>@@ -370,17 +370,17 @@ class OSXBootstrapper(BaseBootstrapper):
>         missing = [package for package in packages if package not in installed]
>         if missing:
>             print(PACKAGE_MANAGER_PACKAGES % ('MacPorts',))
>             self.run_as_root([self.port, '-v', 'install'] + missing)
> 
>     def ensure_macports_system_packages(self):
>         packages = [
>             'python27',
>-            'py27-readline',
>+            'py27-gnureadline',
>             'mercurial',
>             'autoconf213',
>             'gnutar',
>             'watchman',
>         ]
> 
>         self._ensure_macports_packages(packages)
>         self.run_as_root([self.port, 'select', '--set', 'python', 'python27'])
Attachment #8914826 - Attachment is obsolete: true
https://hg.mozilla.org/integration/mozilla-inbound/rev/85d26f1a75cf677beeacb9967a9bf490306e0af6
Bug 1405389 - Change port name from py27-readline to py27-gnureadline to enable mach bootstrap on current macports. r=nfroyd
https://hg.mozilla.org/mozilla-central/rev/85d26f1a75cf
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
(In reply to Sylvestre Ledru [:sylvestre] from comment #4)
> If the change occurred several years ago and nobody reported that before, it
> is probably safe to say that the Macports bootstrap support is not used by
> Firefox contributors or dev. Maybe we should remove that.

We've definitely had people use the MacPorts bootstrapper in the past year. I suspect MacPorts maintained some backwards compatibility for the old name and only recently dropped it? Who knows.
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.