summaryrefslogtreecommitdiff
path: root/numpy/distutils/command
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #22493 from mwtoews/maint-openSebastian Berg2023-04-283-5/+5
|\ | | | | MAINT: remove redundant open() modes and io.open() alias
| * MAINT: remove redundant open() modes and io.open() aliasMike Taves2022-10-293-5/+5
| |
* | BUG, BLD: Fix indentation bug in distutilsCharles Harris2023-04-171-1/+1
| | | | | | | | | | | | | | This fixes a bug in distutils that prevented the use of the C++ linker needed to link _multiarray_umath. Fixes #23595
* | ENH: Raise C++ standard to C++17Sayed Adel2023-04-042-0/+2
| |
* | BLD: update OpenBLAS to 0.3.21 and clean up openblas download test (#22525)Matti Picus2022-11-171-0/+7
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * BUILD: update OpenBLAS to 0.3.21 and clean up openblas download test * set LDFLAGS on windows64 like the openblaslib build does * use rtools compilers on windows when building wheels * fix typos * add rtools gfortran to PATH * use the openblas dll from the zip archive without rewrapping * typos * copy dll import library for 64-bit interfaces * revert many of the changes to azure-steps-windows.yaml, copy openblas better in wheels * fix wildcard copy * test OpenBLAS build worked with threadpoolctl * typos * install threadpoolctl where needed, use for loop to recursively copy * update macos OpenBLAS suffixes for newer gfortran hashes * use libgfortran5.dylib on macos * fix scripts * re-use gfortran install from MacPython/gfortran-install on macos * use pre-release version of delocate * fixes for wheel builds/tests * add debugging cruft for pypy+win, macos wheels * add DYLD_LIBRARY_PATH on macosx-x86_64 * use 32-bit openblas interfaces for ppc64le tests * skip large_archive test that sometimes segfaults on PyPy+windows
* DOC: remove reference to Python 2Dimitri Papadopoulos2022-10-181-3/+2
| | | | | | | Remove reference to Visual Studio version required by old versions of Python. Python >= 3.5 is built with Microsoft Visual C++ 14.0 / Visual Studio 2015: https://wiki.python.org/moin/WindowsCompilers
* Fix build_ext interaction with non numpy extensionsserge-sans-paille2022-01-281-2/+2
| | | | | | | | Numpy extensions define the extra_cxx_compile_args and extra_c_compile_args filed, but distutils extensions don't. Take that into account when populating build_extension. Should fix #20928
* BUG: distutils: fix building mixed C/Fortran extensionsRalf Gommers2022-01-241-7/+23
| | | | | | | | | | | | In SciPy we had a couple of cases where we build a Python extension with C source files but linked against static libraries built from Fortran code. Those should be using the Fortran linker, but this was broken in 1.22.0 by gh-19713 (the PR that introduced C++ in NumPy). This fixes a few issues in the `build_ext` command, and documents better what is going on there. Should close SciPy issues 8325 and 15414.
* TST: Add CPU dispatch/baseline tests for VSX4Rafael Cardoso Fernandes Sousa2022-01-171-2/+2
|
* Fix lint issuesPradipta Ghosh2021-12-141-1/+2
|
* Extending CPU feature detection framework to support IBM Z SIMDPradipta Ghosh2021-12-141-1/+1
| | | | | | | | | | We would like to extend CPU feature detection infrastructure for IBM Z CPU features. Eventually It will help to add and enable Z specific SIMD builtins and instructions. As part of the PR, we have extended ccompiler_opt.py, npy_cpu_features.c.src, npy_cpu_features.h, other files for Z CPU feature detection and added test files for VX/VXE/VXE2 in distutils/checks.
* Allow clib callable build flagsMatthew Brett2021-10-231-3/+31
| | | | | | | | | | | | | | | | | | | At the moment, we are guessing whether we have the MSVC compiler, by looking at what Python was originally compiled for. That works only if we are using the same compiler, but this is not the case when we compile with e.g. mingw-w64 using Python.org Python. Unfortunately, at the time we are specifying build flags, we don't know what compiler we are using. Allow build flags to clib to be callables that return lists of strings, instead of strings, where the callables can do work like inspecting the compiler, at build time. Use this to check for MSVC at build time, when specifying the `/GL-` flag. See gh-9977 for a related discussion about these flags.
* [demo] how-to replacing numpy custom generation engine by raw C++serge-sans-paille2021-10-222-44/+62
| | | | | This is just a technical prototype to measure and discuss the impact and implication of moving to C++ for kernel code generation.
* DOC: Typos found by codespellDimitri Papadopoulos2021-09-211-1/+1
|
* BLD, BUG: Fix bdist_wheel duplicate buildingSayed Adel2021-05-052-10/+29
| | | | | | | | | The bug can occur only if the build option `build` was passed before the option `bdist_wheel`. You may still realize a duplicate printing for the compiler optimization report in the build log, which is normal due to multiple calling of command `build` by setuptools.
* BLD, BUG: Fix compiler optimization log AttributeErrorSayed Adel2021-05-042-8/+9
| | | | | The error appears when option `build` is represented before `bdist_wheel`.
* ENH, SIMD: Add support for dispatching C++ sourcesSayed Adel2021-04-222-8/+48
| | | | | Same usage as the C dispatch-able sources except files extensions should be `.dispatcher.cpp` or `.dispatch.cxx` rather than `.dispatch.c`
* MAINT: Added Chain exceptions where appropriate (#18394)Abhay Raghuvanshi2021-03-181-3/+2
| | | | | | | | | | | | | | | | | | | | | * Added chain exception in _bits_of func * Added chain exception * Added chain exception in unixccompiler.py * Added chain exception in config.py * Added chain exception in fcompiler __init__.py * Added chain exception in compaq.py * Added chain exception in format.py * Updated raise chain exception * STY: Break long line. Co-authored-by: Charles Harris <charlesr.harris@gmail.com>
* MAINT: improve failure message when compiler is unavailablePearu Peterson2021-02-091-0/+2
|
* BUG: don't mutate list of fake libraries while iterating over it (#18295)Nicholas McKibben2021-02-041-2/+5
| | | | | | | | | | | | | | | | | * BUG: don't mutate list of fake libraries while iterating over it * BUG: iterate over copy of list * TST: add build test for build_ext fix (#1) * TST: add build test for build_ext fix * TST: clearer test name * STY: use triple quotes instead of lists of strings * FIX: check for f77 compiler before test is run * DOC: add comment explaining that a list copy is necessary
* BUG, BLD: Generate the main dispatcher config header into the build dirSayed Adel2021-01-032-11/+29
| | | | | | | | | | The new path becomes `build/src.*/numpy/distutils/include/npy_cpu_dispatch_config.h` instead of `numpy/core/src/common/_cpu_dispatch.h`. The new path allows other projects to re-use the CPU dispatcher once we decide to expose the following headers: - `numpy/core/src/common/npy_cpu_dispatch.h` - `numpy/core/src/common/npy_cpu_features.h`
* MAINT: regex char class improveTyler Reddy2020-12-281-4/+4
| | | | | | | | | | | | | * replace superfluous single-character regex character classes with their literal string equivalents; this avoids the overhead associated with a character class when there's only a single character enclosed (so there's no benefit to the class overhead) * for more information see: Chapter 6 of: Friedl, Jeffrey. Mastering Regular Expressions. 3rd ed., O’Reilly Media, 2009.
* MAINT, TST: Serveral imporvments to _SIMD moduleSayed Adel2020-10-271-1/+1
| | | | | | | | | | | | | | | | | | - use plain variables - clean up aligned allocate - use `PyArg_ParseTuple` for empty args - use `Py_ssize_t` instead of `unsigned` and `size_t` - improve coding style - no need for a custom raises assertions - use parametrize instead of inner loops - leave a comment about nature of mode testing unit - shift to get max/min of int72 - add more info to repr of vector object - get ride of exec() and use type() instead - use `.inc` as extension for sub-headers instead of `.h` - add `FMA4` and drop `SSE41` from _SIMD targets Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* ENH: Expose the NumPy C SIMD vectorization interface "NPYV" to PythonSayed Adel2020-10-272-2/+18
| | | | | | | | | | | | | | | | '_simd' is a new module to bring the NumPy C SIMD vectorization interface "NPYV" The module is designed to be extremely flexible so that it can accommodate any kind intrinsics, also to generate a python interface almost similar to the C interface. The main purpose of this module is to test NPYV intrinsics in python, but still can be used as an effective solution in designing SIMD kernels. Also add a new command-line argument `--simd-test` to control of targeted CPU features for the `_simd` module. Co-authored-by: Matti Picus <matti.picus@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* Merge pull request #17546 from seiko2plus/issue_17321Matti Picus2020-10-152-65/+61
|\ | | | | MAINT: explicit disabling `CCompilerOpt` in F2PY
| * MAINT: Explicit disabling `CCompilerOpt` in F2PYSayed Adel2020-10-132-65/+61
| | | | | | | | This patch also cleans up `CCompilerOpt` calls in build_ext and build_clib.
* | BLD: add new check_compiler_gcc and check_gcc_version_at_least configureE. Madison Bray2020-10-132-8/+39
|/ | | | | | | commands replaces obsolete (no longer used anywhere AFICT check_compiler_gcc4 with some more general utilities for checking GCC version
* MAINT: Delete obsolete conversion to list (gh-17052)jakobjakobson132020-08-111-1/+1
| | | see gh-17012 item 12
* ENH: [3/7] enable multi-platform SIMD compiler optimizationsSayed Adel2020-06-153-5/+131
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Put `CCompilerOpt` in action through add two command line arguments that passed directly to `CCompilerOpt`'s parameters which explained as follows: * `--cpu-baseline` minimal set of required optimizations, default is 'min' which provides the minimum CPU features that can safely run on a wide range of users platforms. * `--cpu-dispatch` dispatched set of additional optimizations, default is 'max-xop-fma4' which enables all CPU features, except for AMD legacy features. the new arguments can be reached from `build`, `build_clib`, `build_ext`, if `build_clib` or `build_ext` are not specified by the user the arguments of `build` will be used, which also hold the default values. - Activate the new compiler dispatcher that comes with `CCompilerOpt`, through adding a hock inside `build_clib` and `build_ext` that works as a filter taking any C source files ends with `.dispatch.c` and pass it directly to `CCompilerOpt` and then take returned objects and linked to the final C lib. - Add a third command-line argument `--disable-optimization` which explicitly disable the whole new infrastructure, also It adds a new compiler definition called `NPY_DISABLE_OPTIMIZATION`. when `--disable-optimization` is enabled the dispatch-able sources that end with `.dispatch.c` will be treated as a normal C sources, also due to this disabling any C headers that generated by `CCompilerOpt` must guard it with `NPY_DISABLE_OPTIMIZATION`, otherwise, it will definitely break the build. - New auto-generated C header located at `core/include/numpy/_cpu_dispatch.h`, the new header contains all definitions and headers of CPU features that enabled according to specified configuration in `--cpu-baseline` and `--cpu-dispatch`.
* BLD: Avoid "visibility attribute not supported" warning (gh-16288)E. M. Bray2020-05-201-1/+4
| | | | | | | | | | | | I found that when building the latest master branch on Cygwin, while testing #16246, that thousands of warnings were generated at build time like: numpy/core/src/npysort/binsearch.c.src: In function ‘binsearch_left_bool’: numpy/core/src/npysort/binsearch.c.src:82:1: warning: visibility attribute not supported in this configuration; ignored [-Wattributes] Granted this is just a warning, so I don't think it's a serious issue. It seems the test that was supposed to check for __attribute__ support was not working as expected. The #pragmas only take effect if I provide a function body--they are ignored for bare declarations. I don't know if that's by intent, or if it's a GCC issue. For reference: $ gcc --version gcc (GCC) 7.4.0
* BUG: relpath fails for different drives on windows (#16308)Matti Picus2020-05-201-1/+1
| | | | | * BUG: relpath fails for different drives on windows * ENH: always use abspath
* ENH: Fix exception causes in build_ext.pykeremh2020-04-221-2/+2
|
* ENH: Fix exception causes in build_clib.pykeremh2020-04-211-2/+2
|
* MAINT: cleanup unused imports; avoid redefinition of importsMike Taves2020-02-062-8/+9
| | | | | | | * Cleanup unused imports (F401) of mostly standard Python modules, or some internal but unlikely referenced modules * Where internal imports are potentially used, mark with noqa * Avoid redefinition of imports (F811)
* STY,MAINT: avoid 'multiple imports on one line' (flake8 E401)Mike Taves2020-01-281-3/+4
| | | | | | * PEP 8: "Imports should usually be on separate lines" * Where modified, sort imported modules alphabetically * Clean-up unused imports from these expanded lines
* Merge pull request #15248 from eric-wieser/avoid-exc_infoCharles Harris2020-01-051-5/+3
|\ | | | | MAINT: cleanup use of sys.exc_info
| * MAINT: cleanup use of sys.exc_infoEric Wieser2020-01-051-5/+3
| | | | | | | | | | | | This code originates from python 2.6, before there was an `as` clause in `except`. This removes all callers of `numpy.distutils.compat.get_exception`.
* | MAINT: Remove implicit inheritance from object class (#15236)Jon Dufresne2020-01-051-1/+1
| | | | | | | | | | | | | | Inheriting from object was necessary for Python 2 compatibility to use new-style classes. In Python 3, this is unnecessary as there are no old-style classes. Dropping the object is more idiomatic Python.
* | MAINT: Remove unnecessary 'from __future__ import ...' statementsJon Dufresne2020-01-0318-36/+0
|/ | | | | As numpy is Python 3 only, these import statements are now unnecessary and don't alter runtime behavior.
* BUILD: change to build_src --verbose-cfg, runtests.py --debug-infomattip2019-10-031-4/+4
|
* BUILD, DOC: fix 14518, add release notemattip2019-09-221-1/+1
|
* BUILD: add warn-error option to turn compiler warnings into errors (-Werror)mattip2019-09-203-3/+29
|
* MAINT: move the option to build_src, simplifies logicmattip2019-09-202-7/+6
|
* BUILD: add --debug-configure option to reduce output, use logger moremattip2019-09-202-9/+13
|
* Use *sys.version_info[:2]Hugo2019-08-262-2/+2
|
* BUG: Fix for Python 3.10Hugo2019-08-262-2/+2
|
* MAINT: Remove unnecessary backslashes when not needed.MSeifert042019-07-022-6/+6
| | | | See also: #13880
* MAINT: Use textwrap.dedent for multiline stringsEric Wieser2019-06-122-136/+143
| | | | | | This makes it easier to visually jump between functions. A couple places have changed to not emit leading whitespace where they previously did. Since this is C code and not fortran, that doesn't matter.
* BUG: setup.py install --skip-build failsmattip2019-05-261-0/+3
|
* BUG: Adding macro HAVE_ATTRIBUTE_TARGET_@ISA@_WITH_INTRINSICSRaghuveer Devulapalli2019-04-192-0/+26
| | | | | | | | | 1) use __builtin_cpu_supports("avx512f") only for gcc ver >= 5 2) Introduced two new macro's: HAVE_ATTRIBUTE_TARGET_@ISA@_WITH_INTRINSICS for ensuring compiler can compile functions that use intrinsics and are compiled with avx2/avx512f attributes