Skip to content

Commit bde3dbd

Browse files
Merge pull request #45 from oscarbenjamin/pr_bump_version_0.4.0
Bump version to 0.4.0
2 parents deb4448 + 17033b5 commit bde3dbd

File tree

10 files changed

+70
-17
lines changed

10 files changed

+70
-17
lines changed

MANIFEST.in

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
include LICENSE
22
include CHANGES
33
include README
4-
include src/*.pxd
5-
include src/*.pyx
6-
include src/*.py
4+
include src/flint/*.pxd
5+
include src/flint/*.pyx
6+
include src/flint/*.py
7+
include test/*.py
78
include doc/source/*.py
89
include doc/source/*.rst
910
include doc/Makefile

README.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,9 @@ as follows:
3434
pip install .
3535

3636
See the documentation for further notes on building and installing
37-
Python-FLINT.
37+
Python-FLINT:
38+
39+
https://fredrikj.net/python-flint/setup.html
3840

3941
Examples
4042
-------------------------------------

bin/activate

-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,3 @@ export C_INCLUDE_PATH=$(pwd)/.local/include
22
export LIBRARY_PATH=$(pwd)/.local/lib
33
export LD_LIBRARY_PATH=$(pwd)/.local/lib
44
export PYTHONPATH=$(pwd)/src
5-
source .local/venv/bin/activate

bin/build_dependencies_unix.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,8 @@ cd arb-$ARBVER
232232
#
233233
PATH=$PATH:$PREFIX/lib:$PREFIX/bin \
234234
ARB_TEST_MULTIPLIER=0.1 \
235-
make check
235+
# Skip Arb tests now because they are slow.
236+
# make check
236237
cd ..
237238

238239
# ------------------------------------------------------------------------- #

bin/build_mingw64_wheel.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ fi
4444
PYTHON=$PYTHONDIR/python
4545
VER="${PYTHONVER//./}"
4646

47-
WHEELNAME=python_flint-0.3.0-cp$VER-cp$VER-win_amd64.whl
47+
WHEELNAME=python_flint-0.4.0-cp$VER-cp$VER-win_amd64.whl
4848

4949
$PYTHON -c 'print("hello world")'
5050

@@ -90,7 +90,7 @@ wheel pack python_flint-*
9090
cd ..
9191

9292
# Make the wheel relocatable
93-
delvewheel repair dist/python_flint-0.3.0-cp$VER-cp$VER-win_amd64.whl \
93+
delvewheel repair dist/python_flint-0.4.0-cp$VER-cp$VER-win_amd64.whl \
9494
--add-path .local/bin:.local/lib/
9595

9696
# Make a virtual enironment to test the wheel

doc/source/conf.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@
5151
# built documents.
5252
#
5353
# The short X.Y version.
54-
version = '0.3.0'
54+
version = '0.4.0'
5555
# The full version, including alpha/beta/rc tags.
56-
release = '0.3.0'
56+
release = '0.4.0'
5757

5858
# The language for content autogenerated by Sphinx. Refer to documentation
5959
# for a list of supported languages.

doc/source/setup.rst

+51-6
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Setup
22
===============================================================================
33

4-
First install both FLINT (version 2.5 or later) and Arb (version 2.16 or later).
4+
First install both FLINT (version 2.9 or later) and Arb (version 2.23 or later).
55
See:
66

77
* http://flintlib.org/
@@ -13,7 +13,13 @@ The latest release can be installed using::
1313

1414
pip install python-flint
1515

16-
Python-FLINT is also available on conda-forge
16+
Binary wheels are provided for Windows amd64, Linux (manylinux 2_17) x86_64,
17+
macOS x86_64 and macOS arm64. For other platforms, pip will attempt to build
18+
Python-FLINT from source which requires a C compiler and the FLINT and Arb
19+
header files and library files (libflint.so and libarb.so) to be available as
20+
well as the Python development headers and Cython and numpy.
21+
22+
Python-FLINT is also available on conda-forge for Linux and macOS.
1723
(https://anaconda.org/conda-forge/python-flint).
1824
It can be installed using::
1925

@@ -24,19 +30,20 @@ as follows::
2430

2531
pip install .
2632

27-
To build Python-FLINT manually, you may first have to install
28-
some build dependencies::
33+
To build Python-FLINT manually, you first need to install some build
34+
dependencies::
2935

30-
sudo apt-get install cython python-dev
36+
pip install Cython numpy
3137

3238
Then run::
3339

3440
python setup.py build_ext
35-
sudo python setup.py install
41+
python setup.py install
3642

3743
Run the test suite::
3844

3945
python test/test.py
46+
python test/dtest.py
4047

4148
Build the documentation::
4249

@@ -59,3 +66,41 @@ where to find the library files using something like::
5966

6067
export LD_LIBRARY_PATH=/home/fredrik/src/flint2:/home/fredrik/src/arb:$LD_LIBRARY_PATH
6168

69+
Build all dependencies from source
70+
----------------------------------
71+
72+
From a VCS checkout, to build python-flint and all dependencies from source,
73+
using the exact versions that are tested in CI and used for the binary PyPI
74+
wheels, run the following in a unix shell::
75+
76+
source bin/activate
77+
bin/build_dependencies_unix.sh
78+
79+
The script will download and build GMP, MPFR, FLINT and Arb and build them all
80+
in a ``.local`` directory. The ``bin/activate`` script sets the appropriate
81+
path environment variables for C headers and libraries which is needed for
82+
the ``build_dependencies_unix.sh`` script to work. After running the script,
83+
you can then build Python-FLINT in place with::
84+
85+
python setup.py build_ext --in-place
86+
87+
and run the test suite with::
88+
89+
python test/test.py
90+
python test/dtest.py
91+
92+
This way of building Python-FLINT depends on the ``bin/activate`` script to
93+
locate the shared libraries at runtime. The script will also set ``PYTHONPATH``
94+
so that the in-place build of Python-FLINT can be imported.
95+
96+
These steps will also work under MinGW with the mingw64 toolchain, but you
97+
should first run::
98+
99+
echo '[build]' > setup.cfg
100+
echo 'compiler = mingw32' >> setup.cfg
101+
102+
# Install the mingw-w64 toolchain
103+
pacman -S --noconfirm mingw-w64-x86_64-gcc m4 make mingw-w64-x86_64-tools-git
104+
105+
To change the versions of the dependencies that are built, edit the
106+
``bin/build_variables.sh`` script.

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
packages=['flint'],
7979
package_dir={'': 'src'},
8080
description='Bindings for FLINT and Arb',
81-
version='0.3.0',
81+
version='0.4.0',
8282
url='https://github.com/python-flint/python-flint',
8383
author='Fredrik Johansson',
8484
author_email='[email protected]',

src/flint/__init__.py

+2
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
from ._flint import *
2+
3+
__version__ = '0.4.0'

test/test.py

+3
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ def raises(f, exception):
2929
"""
3030

3131
def test_pyflint():
32+
33+
assert flint.__version__ == "0.4.0"
34+
3235
ctx = flint.ctx
3336
assert str(ctx) == repr(ctx) == _default_ctx_string
3437
assert ctx.prec == 53

0 commit comments

Comments
 (0)