@@ -228,6 +228,13 @@ On Debian ("buster" or newer) or Ubuntu ("bionic" or newer):
228228
229229.. literalinclude :: debian.txt
230230
231+ .. WARNING ::
232+
233+ Note: in this documentation, commands like these are
234+ autogenerated. They may as such include duplications. The
235+ duplications are certainly not necessary for the commands to
236+ function properly, but they don't cause any harm, either.
237+
231238On Fedora / Redhat / CentOS:
232239
233240.. literalinclude :: fedora.txt
@@ -297,6 +304,43 @@ a registration.
297304 to Command Line Tools.
298305
299306
307+
308+ macOS recommended installation
309+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
310+
311+ Although Sage can in theory build its own version of gfortran, this
312+ can take a while, and the process fails on some recent versions of
313+ OS X. So instead you can install your own copy. One advantage of this
314+ is that you can install it once, and it will get used every time you
315+ build Sage, rather than building gfortran every time.
316+
317+ One way to do that is with the `Homebrew package manager
318+ <https://brew.sh> `_. Install Homebrew as their web page describes, and
319+ then the command ::
320+
321+ $ brew install gcc
322+
323+ will install Homebrew's gcc package, which includes gfortran. Sage
324+ will also use other Homebrew packages, if they are present. You can
325+ install the following:
326+
327+ .. literalinclude :: homebrew.txt
328+
329+ Some Homebrew packages are installed "keg-only," meaning that they are
330+ not available in standard paths. To make them accessible when building
331+ Sage, run ::
332+
333+ $ source SAGE_ROOT/.homebrew-build-env
334+
335+ (replacing ``SAGE_ROOT `` by Sage's home directory). You can add a
336+ command like this to your shell profile if you want the settings to
337+ persist between shell sessions.
338+
339+ Some additional optional packages are taken care of by:
340+
341+ .. literalinclude :: homebrew-optional.txt
342+
343+
300344.. _section_cygwinprereqs :
301345
302346Cygwin prerequisite installation
0 commit comments