From abb199b4559819707b18b592ea5de841becb43e0 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Fri, 5 Nov 2021 20:02:15 +0000 Subject: [PATCH 01/12] DOC: Windows and F2PY --- doc/source/f2py/windows/index.rst | 95 +++++++++++++++++++++++++++++++ doc/source/f2py/windows/intel.rst | 34 +++++++++++ 2 files changed, 129 insertions(+) create mode 100644 doc/source/f2py/windows/index.rst create mode 100644 doc/source/f2py/windows/intel.rst diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst new file mode 100644 index 000000000000..ab9406c79e8b --- /dev/null +++ b/doc/source/f2py/windows/index.rst @@ -0,0 +1,95 @@ +.. _f2py-windows: + +================= +F2PY and Windows +================= + +.. note:: + + F2PY support for Windows is not at par with Linux support, and + OS specific flags can be seen via ``python -m numpy.f2py`` + +Broadly speaking there are two issues working with F2PY on Windows, the lack of actively +developed FOSS Fortran compilers, and the linking issues related to the C +runtime library for building Python-C extensions. + +The focus of this chapter is to establish a guideline for developing and +extending Fortran modules for Python natively, via F2PY on Windows. +For this document we will asume the following basic tools: + +- The IDE being considered is the community supported `Microsoft Visual Studio Code`_ +- The shell environment is assumed to be `Powershell 7.x`_ +- Python 3.9 from `the Microsoft Store`_ and this can be tested with +``Get-Command python.exe`` resolving to +``C:\Users\$USERNAME\AppData\Local\Microsoft\WindowsApps\python.exe`` +- The Microsoft Visual C++ (MSVC) toolset + +With this baseline configuration, we will further consider a configuration +matrix as follows: + +.. _table-f2py-winsup-mat: + +.. table:: Support matrix, exe implies a Windows installer + ++----------------------+--------------------+------------+ +| **Fortran Compiler** | **C/C++ Compiler** | **Source** | ++======================+====================+============+ +| GFortran | MSVC | MSYS2/exe | ++----------------------+--------------------+------------+ +| GFortran | GCC | MSYS2 | ++----------------------+--------------------+------------+ +| GFortran | GCC | WSL | ++----------------------+--------------------+------------+ +| GFortran | GCC | Cygwin | ++----------------------+--------------------+------------+ +| Classic Flang | MSVC | Source | ++----------------------+--------------------+------------+ +| Intel Fortran | MSVC | exe | ++----------------------+--------------------+------------+ +| Anaconda GFortran | Anaconda GCC | exe | ++----------------------+--------------------+------------+ + +`This MSYS2 document`_ covers details of differences between MSYS2 and Cygwin, +but broadly speaking, MSYS2 is geared towards building native Windows but Cygwin +is closer to providing a `more complete POSIX environment`_. Since MSVC is a +core component of the Windows setup, its installation and the setup for the +Powershell environment are described below. + +Powershell and MSVC +==================== + +MSVC is installed either via the Visual Studio Bundle or the lighter (preferred) +`Build Tools for Visual Studio`_ with the ``Desktop development with C++`` +setting. + +.. note:: + + This can take a significant amount of time as it includes a download of around + 2GB and requires a restart + +Though it is possible use the resulting environment from a `standard command +prompt`_, it is more pleasant to use a `Powershell module like VCVars`_ which +exposes a much simpler ``set (vcvars)``. So this would essentially mean testing +the compiler toolchain could look like: + +.. code:: + :language: bash + + # New Powershell instance + set (vcvars) + echo "#include" > blah.cpp; echo 'int main(){printf("Hi");return 1;}' >> blah.cpp + cl blah.cpp + # Hello + rm blah.cpp + +It is also possible to check that the environment has been updated correctly +with ``$ENV:PATH``. + +.. _the Microsoft Store: https://www.microsoft.com/en-us/p/python-39/9p7qfqmjrfp7?activetab=pivot:overviewtab +.. _Microsoft Visual Studio Code: https://code.visualstudio.com/Download +.. _more complete POSIX environment: https://www.cygwin.com/ +.. _This MSYS2 document: https://www.msys2.org/wiki/How-does-MSYS2-differ-from-Cygwin/ +.. _Build Tools for Visual Studio: https://visualstudio.microsoft.com/downloads/#build-tools-for-visual-studio-2019 +.. _Powershell 7.x: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1 +.. _standard command prompt: https://docs.microsoft.com/en-us/cpp/build/building-on-the-command-line?view=msvc-160#developer_command_file_locations +.. _Powershell module like VCVars: https://github.com/bruxisma/VCVars diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst new file mode 100644 index 000000000000..6cfd3abbb382 --- /dev/null +++ b/doc/source/f2py/windows/intel.rst @@ -0,0 +1,34 @@ +.. _f2py-win-intel: + +================================= +F2PY and Windows Intel Fortran +================================= + +At this time, only the classic Intel compilers (``ifort``) are supported. + +.. note:: + + The licensing restrictions for beta software `have been relaxed`_ during + the transition to the LLVM backed ``ifx/icc`` family of compilers. + However this document does not endorse the usage of Intel in downstream + projects due to the issues pertaining to `disassembly of components and + liability`_. + + Neither the Python Intel installation nor the `Classic Intel C/C++ + Compiler` are required. + +- The `Intel Fortran Compilers`_ come in a combined installer providing both +Classic and Beta versions; these also take around a gigabyte and a half or so + +This configuration now works with MSVC as: + +.. code:: + :language: bash + + python -m numpy.f2py -c fib1.f -m fib1 --f77exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' --f90exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' -L'C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\compiler\lib\ia32' + + +.. _have been relaxed: https://www.intel.com/content/www/us/en/developer/articles/release-notes/oneapi-fortran-compiler-release-notes.html +.. _disassembly of components and liability: https://software.intel.com/content/www/us/en/develop/articles/end-user-license-agreement.html +.. _Intel Fortran Compilers: https://www.intel.com/content/www/us/en/developer/articles/tool/oneapi-standalone-components.html#inpage-nav-6-1 +.. _Classic Intel C/C++ Compiler: https://www.intel.com/content/www/us/en/developer/articles/tool/oneapi-standalone-components.html#inpage-nav-6-undefined \ No newline at end of file From 03aafd82bf3fb8a5233c22a3f5f625964f25fcb8 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Sun, 7 Nov 2021 21:04:50 +0000 Subject: [PATCH 02/12] DOC: Intel F2PY --- doc/source/f2py/windows/intel.rst | 36 +++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst index 6cfd3abbb382..0040bede8266 100644 --- a/doc/source/f2py/windows/intel.rst +++ b/doc/source/f2py/windows/intel.rst @@ -20,15 +20,47 @@ At this time, only the classic Intel compilers (``ifort``) are supported. - The `Intel Fortran Compilers`_ come in a combined installer providing both Classic and Beta versions; these also take around a gigabyte and a half or so +We will consider the classic example of the generation of Fibonnaci numbers, +``fib1.f``, given by: + +.. literalinclude:: ./code/fib1.f + :language: fortran + +For ``cmd.exe`` fans, using the Intel oneAPI command prompt is the easiest approach, as +it loads the required environment for both ``ifort`` and ``msvc``. Helper batch +scripts are also provided. + +.. code:: + :language: bash + + # cmd.exe + "C:\Program Files (x86)\Intel\oneAPI\setvars.bat" + python -m numpy.f2py -c fib1.f -m fib1 + python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" + +Powershell usage is a little less pleasant. + +.. code:: + :language: bash + + This configuration now works with MSVC as: .. code:: :language: bash + # Powershell python -m numpy.f2py -c fib1.f -m fib1 --f77exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' --f90exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' -L'C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\compiler\lib\ia32' - + python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" + # Alternatively, set environment and reload Powershell + cmd.exe /k "C:\Program Files (x86)\Intel\oneAPI\setvars.bat" + powershell + python -m numpy.f2py -c fib1.f -m fib1 + python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" + + .. _have been relaxed: https://www.intel.com/content/www/us/en/developer/articles/release-notes/oneapi-fortran-compiler-release-notes.html -.. _disassembly of components and liability: https://software.intel.com/content/www/us/en/develop/articles/end-user-license-agreement.html +.. _disassembly of components and liability: https://software.sintel.com/content/www/us/en/develop/articles/end-user-license-agreement.html .. _Intel Fortran Compilers: https://www.intel.com/content/www/us/en/developer/articles/tool/oneapi-standalone-components.html#inpage-nav-6-1 .. _Classic Intel C/C++ Compiler: https://www.intel.com/content/www/us/en/developer/articles/tool/oneapi-standalone-components.html#inpage-nav-6-undefined \ No newline at end of file From a4c51cdf4f4696b20a095a5ee004d863d568ed1b Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Tue, 9 Nov 2021 17:35:33 +0000 Subject: [PATCH 03/12] DOC: F2PY Windows Reviewer Comments I MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Melissa Weber Mendonça --- doc/source/f2py/windows/index.rst | 58 +++++++++++++++++-------------- doc/source/f2py/windows/intel.rst | 15 ++++---- 2 files changed, 37 insertions(+), 36 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index ab9406c79e8b..0a7ede9e943c 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -9,19 +9,19 @@ F2PY and Windows F2PY support for Windows is not at par with Linux support, and OS specific flags can be seen via ``python -m numpy.f2py`` -Broadly speaking there are two issues working with F2PY on Windows, the lack of actively +Broadly speaking, there are two issues working with F2PY on Windows: the lack of actively developed FOSS Fortran compilers, and the linking issues related to the C runtime library for building Python-C extensions. -The focus of this chapter is to establish a guideline for developing and +The focus of this section is to establish a guideline for developing and extending Fortran modules for Python natively, via F2PY on Windows. For this document we will asume the following basic tools: - The IDE being considered is the community supported `Microsoft Visual Studio Code`_ - The shell environment is assumed to be `Powershell 7.x`_ - Python 3.9 from `the Microsoft Store`_ and this can be tested with -``Get-Command python.exe`` resolving to -``C:\Users\$USERNAME\AppData\Local\Microsoft\WindowsApps\python.exe`` + ``Get-Command python.exe`` resolving to + ``C:\Users\$USERNAME\AppData\Local\Microsoft\WindowsApps\python.exe`` - The Microsoft Visual C++ (MSVC) toolset With this baseline configuration, we will further consider a configuration @@ -31,26 +31,26 @@ matrix as follows: .. table:: Support matrix, exe implies a Windows installer -+----------------------+--------------------+------------+ -| **Fortran Compiler** | **C/C++ Compiler** | **Source** | -+======================+====================+============+ -| GFortran | MSVC | MSYS2/exe | -+----------------------+--------------------+------------+ -| GFortran | GCC | MSYS2 | -+----------------------+--------------------+------------+ -| GFortran | GCC | WSL | -+----------------------+--------------------+------------+ -| GFortran | GCC | Cygwin | -+----------------------+--------------------+------------+ -| Classic Flang | MSVC | Source | -+----------------------+--------------------+------------+ -| Intel Fortran | MSVC | exe | -+----------------------+--------------------+------------+ -| Anaconda GFortran | Anaconda GCC | exe | -+----------------------+--------------------+------------+ - -`This MSYS2 document`_ covers details of differences between MSYS2 and Cygwin, -but broadly speaking, MSYS2 is geared towards building native Windows but Cygwin + +----------------------+--------------------+------------+ + | **Fortran Compiler** | **C/C++ Compiler** | **Source** | + +======================+====================+============+ + | GFortran | MSVC | MSYS2/exe | + +----------------------+--------------------+------------+ + | GFortran | GCC | MSYS2 | + +----------------------+--------------------+------------+ + | GFortran | GCC | WSL | + +----------------------+--------------------+------------+ + | GFortran | GCC | Cygwin | + +----------------------+--------------------+------------+ + | Classic Flang | MSVC | Source | + +----------------------+--------------------+------------+ + | Intel Fortran | MSVC | exe | + +----------------------+--------------------+------------+ + | Anaconda GFortran | Anaconda GCC | exe | + +----------------------+--------------------+------------+ + +`This MSYS2 document`_ covers details of differences between MSYS2 and Cygwin. +Broadly speaking, MSYS2 is geared towards building native Windows, while Cygwin is closer to providing a `more complete POSIX environment`_. Since MSVC is a core component of the Windows setup, its installation and the setup for the Powershell environment are described below. @@ -65,15 +65,14 @@ setting. .. note:: This can take a significant amount of time as it includes a download of around - 2GB and requires a restart + 2GB and requires a restart. Though it is possible use the resulting environment from a `standard command prompt`_, it is more pleasant to use a `Powershell module like VCVars`_ which exposes a much simpler ``set (vcvars)``. So this would essentially mean testing the compiler toolchain could look like: -.. code:: - :language: bash +.. code:: bash # New Powershell instance set (vcvars) @@ -93,3 +92,8 @@ with ``$ENV:PATH``. .. _Powershell 7.x: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1 .. _standard command prompt: https://docs.microsoft.com/en-us/cpp/build/building-on-the-command-line?view=msvc-160#developer_command_file_locations .. _Powershell module like VCVars: https://github.com/bruxisma/VCVars + +.. toctree:: + :maxdepth: 2 + + intel diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst index 0040bede8266..c93a7dbe496e 100644 --- a/doc/source/f2py/windows/intel.rst +++ b/doc/source/f2py/windows/intel.rst @@ -18,20 +18,19 @@ At this time, only the classic Intel compilers (``ifort``) are supported. Compiler` are required. - The `Intel Fortran Compilers`_ come in a combined installer providing both -Classic and Beta versions; these also take around a gigabyte and a half or so + Classic and Beta versions; these also take around a gigabyte and a half or so. We will consider the classic example of the generation of Fibonnaci numbers, ``fib1.f``, given by: -.. literalinclude:: ./code/fib1.f +.. literalinclude:: ../code/fib1.f :language: fortran For ``cmd.exe`` fans, using the Intel oneAPI command prompt is the easiest approach, as it loads the required environment for both ``ifort`` and ``msvc``. Helper batch scripts are also provided. -.. code:: - :language: bash +.. code:: bash # cmd.exe "C:\Program Files (x86)\Intel\oneAPI\setvars.bat" @@ -40,14 +39,12 @@ scripts are also provided. Powershell usage is a little less pleasant. -.. code:: - :language: bash +.. code:: bash This configuration now works with MSVC as: -.. code:: - :language: bash +.. code:: bash # Powershell python -m numpy.f2py -c fib1.f -m fib1 --f77exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' --f90exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' -L'C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\compiler\lib\ia32' @@ -58,7 +55,7 @@ This configuration now works with MSVC as: python -m numpy.f2py -c fib1.f -m fib1 python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" - +Note that the actual path to your local installation of `ifort` may vary, and the command above will need to be updated accordingly. .. _have been relaxed: https://www.intel.com/content/www/us/en/developer/articles/release-notes/oneapi-fortran-compiler-release-notes.html .. _disassembly of components and liability: https://software.sintel.com/content/www/us/en/develop/articles/end-user-license-agreement.html From c52faf58487e0f27a81680ce3e46730f870aa531 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Tue, 9 Nov 2021 20:20:19 +0000 Subject: [PATCH 04/12] DOC: Clean F2PY Win and add to index --- doc/source/f2py/index.rst | 8 +++++++- doc/source/f2py/windows/index.rst | 21 ++++++++++++++++----- doc/source/f2py/windows/intel.rst | 11 +++-------- 3 files changed, 26 insertions(+), 14 deletions(-) diff --git a/doc/source/f2py/index.rst b/doc/source/f2py/index.rst index 913eacbb131b..dedfe3f644dd 100644 --- a/doc/source/f2py/index.rst +++ b/doc/source/f2py/index.rst @@ -34,9 +34,15 @@ replace all calls to ``f2py`` mentioned in this guide with the longer version. .. toctree:: :maxdepth: 3 + f2py.getting-started f2py-user f2py-reference - + usage + python-usage + signature-file + buildtools/index + advanced + windows/index .. _Python: https://www.python.org/ .. _NumPy: https://www.numpy.org/ diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index 0a7ede9e943c..1d04f86acab1 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -15,6 +15,7 @@ runtime library for building Python-C extensions. The focus of this section is to establish a guideline for developing and extending Fortran modules for Python natively, via F2PY on Windows. + For this document we will asume the following basic tools: - The IDE being considered is the community supported `Microsoft Visual Studio Code`_ @@ -49,12 +50,20 @@ matrix as follows: | Anaconda GFortran | Anaconda GCC | exe | +----------------------+--------------------+------------+ +From the point of view of a standard end-user, the most favored approach is the +Intel Fortran and MSVC toolchain; however licensing restrictions still apply, as +described further in the `f2py-win-intel`_. + `This MSYS2 document`_ covers details of differences between MSYS2 and Cygwin. Broadly speaking, MSYS2 is geared towards building native Windows, while Cygwin is closer to providing a `more complete POSIX environment`_. Since MSVC is a core component of the Windows setup, its installation and the setup for the Powershell environment are described below. +For an understanding of the key issues motivating the need for such a matrix +`Pauli Virtanen's in-depth post on wheels with Fortran for Windows`_ is an +excellent resource. + Powershell and MSVC ==================== @@ -84,6 +93,12 @@ the compiler toolchain could look like: It is also possible to check that the environment has been updated correctly with ``$ENV:PATH``. +.. toctree:: + :maxdepth: 2 + + intel + + .. _the Microsoft Store: https://www.microsoft.com/en-us/p/python-39/9p7qfqmjrfp7?activetab=pivot:overviewtab .. _Microsoft Visual Studio Code: https://code.visualstudio.com/Download .. _more complete POSIX environment: https://www.cygwin.com/ @@ -92,8 +107,4 @@ with ``$ENV:PATH``. .. _Powershell 7.x: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1 .. _standard command prompt: https://docs.microsoft.com/en-us/cpp/build/building-on-the-command-line?view=msvc-160#developer_command_file_locations .. _Powershell module like VCVars: https://github.com/bruxisma/VCVars - -.. toctree:: - :maxdepth: 2 - - intel +.. _Pauli Virtanen's in-depth post on wheels with Fortran for Windows: https://pav.iki.fi/blog/2017-10-08/pywingfortran.html#building-python-wheels-with-fortran-for-windows diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst index c93a7dbe496e..1771cdaadb33 100644 --- a/doc/source/f2py/windows/intel.rst +++ b/doc/source/f2py/windows/intel.rst @@ -30,21 +30,16 @@ For ``cmd.exe`` fans, using the Intel oneAPI command prompt is the easiest appro it loads the required environment for both ``ifort`` and ``msvc``. Helper batch scripts are also provided. -.. code:: bash +.. code-block:: bat # cmd.exe "C:\Program Files (x86)\Intel\oneAPI\setvars.bat" python -m numpy.f2py -c fib1.f -m fib1 python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" -Powershell usage is a little less pleasant. +Powershell usage is a little less pleasant, and this configuration now works with MSVC as: -.. code:: bash - - -This configuration now works with MSVC as: - -.. code:: bash +.. code-block:: powershell # Powershell python -m numpy.f2py -c fib1.f -m fib1 --f77exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' --f90exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' -L'C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\compiler\lib\ia32' From 50cafae593ba41cb1e540c189387055b33113245 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Sun, 30 Jan 2022 00:03:17 +0000 Subject: [PATCH 05/12] DOC: F2PY windows narrative rewrite --- doc/source/f2py/windows/index.rst | 128 ++++++++++++++++++++++-------- 1 file changed, 94 insertions(+), 34 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index 1d04f86acab1..c9f46f80d203 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -4,18 +4,84 @@ F2PY and Windows ================= -.. note:: +.. warning:: F2PY support for Windows is not at par with Linux support, and OS specific flags can be seen via ``python -m numpy.f2py`` -Broadly speaking, there are two issues working with F2PY on Windows: the lack of actively -developed FOSS Fortran compilers, and the linking issues related to the C -runtime library for building Python-C extensions. +Broadly speaking, there are two issues working with F2PY on Windows: +- the lack of actively developed FOSS Fortran compilers, and, +- the linking issues related to the C runtime library for building Python-C extensions. The focus of this section is to establish a guideline for developing and extending Fortran modules for Python natively, via F2PY on Windows. +Overview +======== +From a user perspective, the most UNIX compatible Windows +development environment is through emulation, either via the Windows Subsystem +on Linux, or facilitated by Docker. In a similar vein, traditional +virtualization methods like VirtualBox are also reasonable methods to develop +UNIX tools on Windows. + +Native Windows support is typically stunted beyond the usage of commerical compilers. +However, most commerical compilers now have free plans which are sufficient for +general use. Additionally, the Fortran language features supported by ``f2py`` +(partial coverage of Fortran 2003), means that newer toolchains are often not +required. Briefly, then, for an end user, in order of use: + +Classic Intel Compilers (commercial) + These are maintained actively, though licensing restrictions may apply as + further detailed in :ref:`f2py-win-intel`. + + Suitable for general use for those building native Windows programs by + building off of MSVC. + +MSYS2 (FOSS) + In conjunction with the ``mingw-w64`` project, ``gfortran`` and ``gcc`` + toolchains can be used to natively build Windows programs. + +Windows Subsystem for Linux + Assuming the usage of ``gfortran``, this can be used for cross-compiling + Windows applications, but is significantly more complicated. + +Conda + Windows support for compilers in ``conda`` is facilitated by pulling MSYS2 + binaries, however these `are outdated`_, and therefore not recommended (as of 30-01-2022). + +PGI Compilers (commerical) + Unmaintained but sufficient if an existing license is present. Works + natively, but has been superceeded by the Nvidia HPC SDK, with no `native + Windows support`_. + +Cygwin (FOSS) + Can also be used for ``gfortran``. Howeve, the POSIX API compatibility layer provided by + Cygwin is meant to compile UNIX software on Windows, instead of building + native Windows programs. This means cross compilation is required. + +The compilation suites described so far are compatible with the `now +deprecated`_ ``np.distutils`` build backend which is exposed by the F2PY CLI. +Additional build system usage (``meson``, ``cmake``) as described in +:ref:`f2py-bldsys` allows for a more flexible set of compiler +backends including: + +Intel oneAPI + The newer Intel compilers (``ifx``, ``icx``) are based on LLVM and can be + used for native compilation. Licensing requirements can be onerous. + +Classic Flang (FOSS) + The backbone of the PGI compilers were cannibalized to form the "classic" or + `legacy version of Flang`_. This may be compiled from source and used + natively. `LLVM Flang`_ does not support Windows yet (30-01-2022). + +LFortran (FOSS) + One of two LLVM based compilers. Not all of F2PY supported Fortran can be + compiled yet (30-01-2022) but uses MSVC for native linking. + + +Baseline +======== + For this document we will asume the following basic tools: - The IDE being considered is the community supported `Microsoft Visual Studio Code`_ @@ -23,7 +89,7 @@ For this document we will asume the following basic tools: - Python 3.9 from `the Microsoft Store`_ and this can be tested with ``Get-Command python.exe`` resolving to ``C:\Users\$USERNAME\AppData\Local\Microsoft\WindowsApps\python.exe`` -- The Microsoft Visual C++ (MSVC) toolset +- The Microsoft Visual C++ (MSVC) toolset With this baseline configuration, we will further consider a configuration matrix as follows: @@ -32,37 +98,24 @@ matrix as follows: .. table:: Support matrix, exe implies a Windows installer - +----------------------+--------------------+------------+ - | **Fortran Compiler** | **C/C++ Compiler** | **Source** | - +======================+====================+============+ - | GFortran | MSVC | MSYS2/exe | - +----------------------+--------------------+------------+ - | GFortran | GCC | MSYS2 | - +----------------------+--------------------+------------+ - | GFortran | GCC | WSL | - +----------------------+--------------------+------------+ - | GFortran | GCC | Cygwin | - +----------------------+--------------------+------------+ - | Classic Flang | MSVC | Source | - +----------------------+--------------------+------------+ - | Intel Fortran | MSVC | exe | - +----------------------+--------------------+------------+ - | Anaconda GFortran | Anaconda GCC | exe | - +----------------------+--------------------+------------+ - -From the point of view of a standard end-user, the most favored approach is the -Intel Fortran and MSVC toolchain; however licensing restrictions still apply, as -described further in the `f2py-win-intel`_. - -`This MSYS2 document`_ covers details of differences between MSYS2 and Cygwin. -Broadly speaking, MSYS2 is geared towards building native Windows, while Cygwin -is closer to providing a `more complete POSIX environment`_. Since MSVC is a -core component of the Windows setup, its installation and the setup for the -Powershell environment are described below. + +----------------------+--------------------+-------------------+ + | **Fortran Compiler** | **C/C++ Compiler** | **Source** | + +======================+====================+===================+ + | Intel Fortran | MSVC / ICC | exe | + +----------------------+--------------------+-------------------+ + | GFortran | MSVC | MSYS2/exe | + +----------------------+--------------------+-------------------+ + | GFortran | GCC | WSL | + +----------------------+--------------------+-------------------+ + | Classic Flang | MSVC | Source / Conda | + +----------------------+--------------------+-------------------+ + | Anaconda GFortran | Anaconda GCC | exe | + +----------------------+--------------------+-------------------+ For an understanding of the key issues motivating the need for such a matrix `Pauli Virtanen's in-depth post on wheels with Fortran for Windows`_ is an -excellent resource. +excellent resource. An entertaining explanation of an application binary +interface (ABI) can be found in this post by `JeanHeyd Meneide`_. Powershell and MSVC ==================== @@ -81,7 +134,7 @@ prompt`_, it is more pleasant to use a `Powershell module like VCVars`_ which exposes a much simpler ``set (vcvars)``. So this would essentially mean testing the compiler toolchain could look like: -.. code:: bash +.. code-block:: powershell # New Powershell instance set (vcvars) @@ -108,3 +161,10 @@ with ``$ENV:PATH``. .. _standard command prompt: https://docs.microsoft.com/en-us/cpp/build/building-on-the-command-line?view=msvc-160#developer_command_file_locations .. _Powershell module like VCVars: https://github.com/bruxisma/VCVars .. _Pauli Virtanen's in-depth post on wheels with Fortran for Windows: https://pav.iki.fi/blog/2017-10-08/pywingfortran.html#building-python-wheels-with-fortran-for-windows +.. _Nvidia HPC SDK: https://www.pgroup.com/index.html +.. _JeanHeyd Meneide: https://thephd.dev/binary-banshees-digital-demons-abi-c-c++-help-me-god-please +.. _legacy version of Flang: https://github.com/flang-compiler/flang +.. _native Windows support: https://developer.nvidia.com/nvidia-hpc-sdk-downloads#collapseFour +.. _are outdated: https://github.com/conda-forge/conda-forge.github.io/issues/1044 +.. _now deprecated: https://github.com/numpy/numpy/pull/20875 +.. _LLVM Flang: https://releases.llvm.org/11.0.0/tools/flang/docs/ReleaseNotes.html \ No newline at end of file From 7c88bd25ae80cd9ae597b6b6baa31d07a3330867 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Sun, 30 Jan 2022 14:48:09 +0000 Subject: [PATCH 06/12] DOC: Clean up Windows environment suggestions --- doc/source/f2py/windows/index.rst | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index c9f46f80d203..fb61b61ef8e0 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -85,6 +85,7 @@ Baseline For this document we will asume the following basic tools: - The IDE being considered is the community supported `Microsoft Visual Studio Code`_ +- The terminal being used is the `Windows Terminal`_ - The shell environment is assumed to be `Powershell 7.x`_ - Python 3.9 from `the Microsoft Store`_ and this can be tested with ``Get-Command python.exe`` resolving to @@ -129,18 +130,18 @@ setting. This can take a significant amount of time as it includes a download of around 2GB and requires a restart. -Though it is possible use the resulting environment from a `standard command -prompt`_, it is more pleasant to use a `Powershell module like VCVars`_ which -exposes a much simpler ``set (vcvars)``. So this would essentially mean testing -the compiler toolchain could look like: +It is possible use the resulting environment from a `standard command +prompt`_. However, it is more pleasant to use a `developer powershell`_, +with a `profile in Windows Terminal`_. So +this would essentially mean testing the compiler toolchain could look like: .. code-block:: powershell - # New Powershell instance - set (vcvars) + # New Windows Developer Powershell instance / tab echo "#include" > blah.cpp; echo 'int main(){printf("Hi");return 1;}' >> blah.cpp cl blah.cpp - # Hello + .\blah.exe + # Hi rm blah.cpp It is also possible to check that the environment has been updated correctly @@ -157,9 +158,11 @@ with ``$ENV:PATH``. .. _more complete POSIX environment: https://www.cygwin.com/ .. _This MSYS2 document: https://www.msys2.org/wiki/How-does-MSYS2-differ-from-Cygwin/ .. _Build Tools for Visual Studio: https://visualstudio.microsoft.com/downloads/#build-tools-for-visual-studio-2019 +.. _Windows Terminal: https://www.microsoft.com/en-us/p/windows-terminal/9n0dx20hk701?activetab=pivot:overviewtab .. _Powershell 7.x: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1 .. _standard command prompt: https://docs.microsoft.com/en-us/cpp/build/building-on-the-command-line?view=msvc-160#developer_command_file_locations -.. _Powershell module like VCVars: https://github.com/bruxisma/VCVars +.. _developer powershell: https://docs.microsoft.com/en-us/visualstudio/ide/reference/command-prompt-powershell?view=vs-2019 +.. _profile in Windows Terminal: https://techcommunity.microsoft.com/t5/microsoft-365-pnp-blog/add-developer-powershell-and-developer-command-prompt-for-visual/ba-p/2243078 .. _Pauli Virtanen's in-depth post on wheels with Fortran for Windows: https://pav.iki.fi/blog/2017-10-08/pywingfortran.html#building-python-wheels-with-fortran-for-windows .. _Nvidia HPC SDK: https://www.pgroup.com/index.html .. _JeanHeyd Meneide: https://thephd.dev/binary-banshees-digital-demons-abi-c-c++-help-me-god-please From 366c64b4f62df433abfbfec1bd4b2c78e19ee777 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Sun, 30 Jan 2022 17:55:04 +0000 Subject: [PATCH 07/12] DOC: Add Windows Terminal Details --- doc/source/f2py/windows/index.rst | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index fb61b61ef8e0..b13859fb161e 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -132,12 +132,28 @@ setting. It is possible use the resulting environment from a `standard command prompt`_. However, it is more pleasant to use a `developer powershell`_, -with a `profile in Windows Terminal`_. So -this would essentially mean testing the compiler toolchain could look like: +with a `profile in Windows Terminal`_. This can be achieved by adding the +following block to the ``profiles->list`` section of the JSON file used to +configure Windows Terminal (see ``Settings->Open JSON file``): + +.. code-block:: json + + { + "name": "Developer PowerShell for VS 2019", + "commandline": "powershell.exe -noe -c \"$vsPath = (Join-Path ${env:ProgramFiles(x86)} -ChildPath 'Microsoft Visual Studio\\2019\\BuildTools'); Import-Module (Join-Path $vsPath 'Common7\\Tools\\Microsoft.VisualStudio.DevShell.dll'); Enter-VsDevShell -VsInstallPath $vsPath -SkipAutomaticLocation\"", + "icon": "ms-appx:///ProfileIcons/{61c54bbd-c2c6-5271-96e7-009a87ff44bf}.png" + } + +Now, testing the compiler toolchain could look like: .. code-block:: powershell # New Windows Developer Powershell instance / tab + ********************************************************************** + ** Visual Studio 2019 Developer PowerShell v16.11.9 + ** Copyright (c) 2021 Microsoft Corporation + ********************************************************************** + cd $HOME echo "#include" > blah.cpp; echo 'int main(){printf("Hi");return 1;}' >> blah.cpp cl blah.cpp .\blah.exe From d40ff6f8d332072d42e1cffd6647f81422896a61 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 7 Mar 2022 00:23:41 +0000 Subject: [PATCH 08/12] DOC: Update windows index --- doc/source/f2py/windows/index.rst | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index b13859fb161e..5f78546ade39 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -87,7 +87,7 @@ For this document we will asume the following basic tools: - The IDE being considered is the community supported `Microsoft Visual Studio Code`_ - The terminal being used is the `Windows Terminal`_ - The shell environment is assumed to be `Powershell 7.x`_ -- Python 3.9 from `the Microsoft Store`_ and this can be tested with +- Python 3.10 from `the Microsoft Store`_ and this can be tested with ``Get-Command python.exe`` resolving to ``C:\Users\$USERNAME\AppData\Local\Microsoft\WindowsApps\python.exe`` - The Microsoft Visual C++ (MSVC) toolset @@ -149,6 +149,10 @@ Now, testing the compiler toolchain could look like: .. code-block:: powershell # New Windows Developer Powershell instance / tab + # or + $vsPath = (Join-Path ${env:ProgramFiles(x86)} -ChildPath 'Microsoft Visual Studio\\2019\\BuildTools'); + Import-Module (Join-Path $vsPath 'Common7\\Tools\\Microsoft.VisualStudio.DevShell.dll'); + Enter-VsDevShell -VsInstallPath $vsPath -SkipAutomaticLocation ********************************************************************** ** Visual Studio 2019 Developer PowerShell v16.11.9 ** Copyright (c) 2021 Microsoft Corporation @@ -163,13 +167,24 @@ Now, testing the compiler toolchain could look like: It is also possible to check that the environment has been updated correctly with ``$ENV:PATH``. + +Windows Store Python Paths +========================== + +The MS Windows version of Python discussed here installs to a non-deterministic +path using a hash. This needs to be added to the ``PATH`` variable. + +.. code-block:: powershell + + $Env:Path += ";$env:LOCALAPPDATA\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\scripts" + .. toctree:: :maxdepth: 2 intel -.. _the Microsoft Store: https://www.microsoft.com/en-us/p/python-39/9p7qfqmjrfp7?activetab=pivot:overviewtab +.. _the Microsoft Store: https://www.microsoft.com/en-us/p/python-310/9pjpw5ldxlz5 .. _Microsoft Visual Studio Code: https://code.visualstudio.com/Download .. _more complete POSIX environment: https://www.cygwin.com/ .. _This MSYS2 document: https://www.msys2.org/wiki/How-does-MSYS2-differ-from-Cygwin/ From f79276430dffbeb90609fd5fd9e68a0f2efc02fa Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 7 Mar 2022 00:24:24 +0000 Subject: [PATCH 09/12] MAINT: Clean doc --- doc/source/f2py/windows/intel.rst | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst index 1771cdaadb33..c0bc7e07b6b7 100644 --- a/doc/source/f2py/windows/intel.rst +++ b/doc/source/f2py/windows/intel.rst @@ -1,8 +1,8 @@ .. _f2py-win-intel: -================================= +============================== F2PY and Windows Intel Fortran -================================= +============================== At this time, only the classic Intel compilers (``ifort``) are supported. @@ -44,9 +44,8 @@ Powershell usage is a little less pleasant, and this configuration now works wit # Powershell python -m numpy.f2py -c fib1.f -m fib1 --f77exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' --f90exec='C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\bin\intel64\ifort.exe' -L'C:\Program Files (x86)\Intel\oneAPI\compiler\latest\windows\compiler\lib\ia32' python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" - # Alternatively, set environment and reload Powershell - cmd.exe /k "C:\Program Files (x86)\Intel\oneAPI\setvars.bat" - powershell + # Alternatively, set environment and reload Powershell in one line + cmd.exe /k '"C:\Program Files (x86)\Intel\oneAPI\setvars.bat" && powershell' python -m numpy.f2py -c fib1.f -m fib1 python -c "import fib1; import numpy as np; a=np.zeros(8); fib1.fib(a); print(a)" From 17c19a72f59c300c0d639b7a9354efeed4d14437 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 7 Mar 2022 00:35:53 +0000 Subject: [PATCH 10/12] DOC: Add partials for Windows --- doc/source/f2py/windows/conda.rst | 31 +++++++++++++++++++++++++++++++ doc/source/f2py/windows/msys2.rst | 19 +++++++++++++++++++ doc/source/f2py/windows/pgi.rst | 28 ++++++++++++++++++++++++++++ 3 files changed, 78 insertions(+) create mode 100644 doc/source/f2py/windows/conda.rst create mode 100644 doc/source/f2py/windows/msys2.rst create mode 100644 doc/source/f2py/windows/pgi.rst diff --git a/doc/source/f2py/windows/conda.rst b/doc/source/f2py/windows/conda.rst new file mode 100644 index 000000000000..5eabe334ee8e --- /dev/null +++ b/doc/source/f2py/windows/conda.rst @@ -0,0 +1,31 @@ +.. _f2py-win-conda: + + +As a convienience measure, we will additionally assume the +existence of ``scoop``, which can be used to install tools without +administrative access. + +.. code-block:: powershell + + Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh') + +Now we will setup a ``conda`` environment. + +.. code-block:: powershell + + scoop install miniconda3 + # For conda activate / deactivate in powershell + conda install -n root -c pscondaenvs pscondaenvs + Powershell -c Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser + conda init powershell + # Open a new shell for the rest + +``conda`` pulls packages from ``msys2``, however, the UX is sufficiently different enough to warrant a separate discussion. + +.. warning:: + + As of 30-01-2022, the `MSYS2 binaries`_ shipped with ``conda`` are **outdated** and this approach is **not preferred**. + + + +.. _MSYS2 binaries: https://github.com/conda-forge/conda-forge.github.io/issues/1044 \ No newline at end of file diff --git a/doc/source/f2py/windows/msys2.rst b/doc/source/f2py/windows/msys2.rst new file mode 100644 index 000000000000..68c4353111c9 --- /dev/null +++ b/doc/source/f2py/windows/msys2.rst @@ -0,0 +1,19 @@ +.. _f2py-win-msys2: + +=========================== +F2PY and Windows with MSYS2 +=========================== + +Follow the standard `installation instructions`_. Then, to grab the requisite Fortran compiler with ``MVSC``: + +.. code-block:: bash + + # Assuming a fresh install + pacman -Syu # Restart the terminal + pacman -Su # Update packages + # Get the toolchains + pacman -S --needed base-devel gcc-fortran + pacman -S mingw-w64-x86_64-toolchain + + +.. _`installation instructions`: https://www.msys2.org/ diff --git a/doc/source/f2py/windows/pgi.rst b/doc/source/f2py/windows/pgi.rst new file mode 100644 index 000000000000..3139d9c5b574 --- /dev/null +++ b/doc/source/f2py/windows/pgi.rst @@ -0,0 +1,28 @@ +.. _f2py-win-pgi: + +=============================== +F2PY and PGI Fortran on Windows +=============================== + +A variant of these are part of the so called "classic" Flang, however, +as classic Flang requires a custom LLVM and compilation from sources. + +.. warning:: + + Since the proprietary compilers are no longer available for + usage they are not recommended and will not be ported to the + new ``f2py`` CLI. + + + +.. note:: + + **As of November 2021** + + As of 29-01-2022, `PGI compiler toolchains`_ have been superceeded by the Nvidia + HPC SDK, with no `native Windows support`_. + +However, + +.. _PGI compiler toolchains: https://www.pgroup.com/index.html +.. _native Windows support: https://developer.nvidia.com/nvidia-hpc-sdk-downloads#collapseFour \ No newline at end of file From ee113d4b194806056e3f141b4836ec357ee38448 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 7 Mar 2022 00:37:08 +0000 Subject: [PATCH 11/12] DOC: Update as per review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Melissa Weber Mendonça --- doc/source/f2py/windows/index.rst | 11 ++++++----- doc/source/f2py/windows/intel.rst | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index 5f78546ade39..7f27247dc708 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -10,6 +10,7 @@ F2PY and Windows OS specific flags can be seen via ``python -m numpy.f2py`` Broadly speaking, there are two issues working with F2PY on Windows: + - the lack of actively developed FOSS Fortran compilers, and, - the linking issues related to the C runtime library for building Python-C extensions. @@ -24,8 +25,8 @@ on Linux, or facilitated by Docker. In a similar vein, traditional virtualization methods like VirtualBox are also reasonable methods to develop UNIX tools on Windows. -Native Windows support is typically stunted beyond the usage of commerical compilers. -However, most commerical compilers now have free plans which are sufficient for +Native Windows support is typically stunted beyond the usage of commercial compilers. +However, as of 2022, most commercial compilers have free plans which are sufficient for general use. Additionally, the Fortran language features supported by ``f2py`` (partial coverage of Fortran 2003), means that newer toolchains are often not required. Briefly, then, for an end user, in order of use: @@ -49,9 +50,9 @@ Conda Windows support for compilers in ``conda`` is facilitated by pulling MSYS2 binaries, however these `are outdated`_, and therefore not recommended (as of 30-01-2022). -PGI Compilers (commerical) +PGI Compilers (commercial) Unmaintained but sufficient if an existing license is present. Works - natively, but has been superceeded by the Nvidia HPC SDK, with no `native + natively, but has been superseded by the Nvidia HPC SDK, with no `native Windows support`_. Cygwin (FOSS) @@ -130,7 +131,7 @@ setting. This can take a significant amount of time as it includes a download of around 2GB and requires a restart. -It is possible use the resulting environment from a `standard command +It is possible to use the resulting environment from a `standard command prompt`_. However, it is more pleasant to use a `developer powershell`_, with a `profile in Windows Terminal`_. This can be achieved by adding the following block to the ``profiles->list`` section of the JSON file used to diff --git a/doc/source/f2py/windows/intel.rst b/doc/source/f2py/windows/intel.rst index c0bc7e07b6b7..ab0cea219e70 100644 --- a/doc/source/f2py/windows/intel.rst +++ b/doc/source/f2py/windows/intel.rst @@ -4,7 +4,7 @@ F2PY and Windows Intel Fortran ============================== -At this time, only the classic Intel compilers (``ifort``) are supported. +As of NumPy 1.23, only the classic Intel compilers (``ifort``) are supported. .. note:: From dfc4ea4e975b37e249982d49b98f32fb6ae645de Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 21 Mar 2022 03:21:54 +0000 Subject: [PATCH 12/12] DOC,BLD: Add to toctree to appease build --- doc/source/f2py/windows/conda.rst | 5 ++++- doc/source/f2py/windows/index.rst | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/doc/source/f2py/windows/conda.rst b/doc/source/f2py/windows/conda.rst index 5eabe334ee8e..b16402bbcf2f 100644 --- a/doc/source/f2py/windows/conda.rst +++ b/doc/source/f2py/windows/conda.rst @@ -1,5 +1,8 @@ .. _f2py-win-conda: +========================= +F2PY and Conda on Windows +========================= As a convienience measure, we will additionally assume the existence of ``scoop``, which can be used to install tools without @@ -28,4 +31,4 @@ Now we will setup a ``conda`` environment. -.. _MSYS2 binaries: https://github.com/conda-forge/conda-forge.github.io/issues/1044 \ No newline at end of file +.. _MSYS2 binaries: https://github.com/conda-forge/conda-forge.github.io/issues/1044 diff --git a/doc/source/f2py/windows/index.rst b/doc/source/f2py/windows/index.rst index 7f27247dc708..aee96cb13c6d 100644 --- a/doc/source/f2py/windows/index.rst +++ b/doc/source/f2py/windows/index.rst @@ -183,6 +183,9 @@ path using a hash. This needs to be added to the ``PATH`` variable. :maxdepth: 2 intel + msys2 + conda + pgi .. _the Microsoft Store: https://www.microsoft.com/en-us/p/python-310/9pjpw5ldxlz5 @@ -202,4 +205,4 @@ path using a hash. This needs to be added to the ``PATH`` variable. .. _native Windows support: https://developer.nvidia.com/nvidia-hpc-sdk-downloads#collapseFour .. _are outdated: https://github.com/conda-forge/conda-forge.github.io/issues/1044 .. _now deprecated: https://github.com/numpy/numpy/pull/20875 -.. _LLVM Flang: https://releases.llvm.org/11.0.0/tools/flang/docs/ReleaseNotes.html \ No newline at end of file +.. _LLVM Flang: https://releases.llvm.org/11.0.0/tools/flang/docs/ReleaseNotes.html