Skip to content

Commit 55fc534

Browse files
committed
multiple fixes
1 parent 75bbcf6 commit 55fc534

File tree

6 files changed

+20
-12
lines changed

6 files changed

+20
-12
lines changed

.travis.yml

+8-6
Original file line numberDiff line numberDiff line change
@@ -643,7 +643,7 @@ jobs:
643643
before_install: |
644644
set -e
645645
646-
if [ -z "$SDIST" ]; then
646+
if [ -n "$SDIST" ]; then
647647
echo "sdist build"
648648
else
649649
# Check out and prepare the source
@@ -687,7 +687,9 @@ install: |
687687
# Build and package
688688
set -x
689689
690-
if [ -z "$SDIST" ]; then
690+
if [ -n "$SDIST" ]; then
691+
python -m pip install --upgrade pip
692+
python -m pip install scikit-build
691693
python setup.py sdist
692694
else
693695
build_wheel $REPO_DIR $PLAT
@@ -699,7 +701,7 @@ script: |
699701
# Install and run tests
700702
set -x
701703
702-
if [ -z "$SDIST" ]; then
704+
if [ -n "$SDIST" ]; then
703705
echo "sdist"
704706
else
705707
install_run $PLAT && rc=$? || rc=$?
@@ -753,7 +755,7 @@ after_success: |
753755
pip install --user twine
754756
pip install --user --upgrade six
755757
756-
if [ -z "$SDIST" ]; then
758+
if [ -n "$SDIST" ]; then
757759
twine upload -u ${USER} -p ${PASS} --skip-existing ${TRAVIS_BUILD_DIR}/dist
758760
else
759761
twine upload -u ${USER} -p ${PASS} --skip-existing ${TRAVIS_BUILD_DIR}/wheelhouse/opencv*
@@ -768,7 +770,7 @@ after_success: |
768770
/usr/bin/python -m pip install --user -U pip
769771
/usr/bin/python -m pip install --user -U -I twine
770772
771-
if [ -z "$SDIST" ]; then
773+
if [ -n "$SDIST" ]; then
772774
/usr/bin/python -m upload -u ${USER} -p ${PASS} --skip-existing ${TRAVIS_BUILD_DIR}/dist
773775
else
774776
/usr/bin/python -m upload -u ${USER} -p ${PASS} --skip-existing ${TRAVIS_BUILD_DIR}/wheelhouse/opencv*
@@ -788,7 +790,7 @@ after_success: |
788790
789791
az storage container create -n ${TRAVIS_COMMIT} --public-access blob
790792
791-
if [ -z "$SDIST" ]; then
793+
if [ -n "$SDIST" ]; then
792794
az storage blob upload-batch -d ${TRAVIS_COMMIT} -s ${TRAVIS_BUILD_DIR}/dist --pattern *.gz
793795
else
794796
az storage blob upload-batch -d ${TRAVIS_COMMIT} -s ${TRAVIS_BUILD_DIR}/wheelhouse --pattern *.whl

MANIFEST.in

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ include LICENSE.txt
33
include README.md
44
include find_version.py
55
include setup.py
6+
include pyproject.toml
67
recursive-include cv2 *
78
recursive-include docker *
89
recursive-include opencv *

appveyor.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ build_script:
141141
- cmd: |
142142
"%PYTHON%/python.exe" -m pip install --upgrade pip
143143
"%PYTHON%/python.exe" -m pip install --upgrade setuptools
144-
"%PYTHON%/python.exe" setup.py bdist_wheel
144+
"%PYTHON%/python.exe" -m pip wheel . --no-build-isolation --verbose
145145
146146
before_test:
147147
- ps: |

pyproject.toml

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,8 @@
11
[build-system]
2-
requires = ["setuptools", "wheel", "scikit-build", "cmake"]
2+
requires = [
3+
"setuptools", "wheel", "scikit-build", "cmake", "pip",
4+
"numpy==1.11.3; python_version=='3.5'",
5+
"numpy==1.13.3; python_version=='3.6'",
6+
"numpy==1.14.5; python_version=='3.7'",
7+
"numpy==1.17.3; python_version>='3.8'"
8+
]

setup.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ def main():
1515

1616
# These are needed for source fetching
1717
cmake_source_dir = "opencv"
18-
minimum_supported_numpy = "1.11.1"
18+
minimum_supported_numpy = "1.13.1"
1919
build_contrib = get_build_env_var_by_name("contrib")
2020
# headless flag to skip GUI deps if needed
2121
build_headless = get_build_env_var_by_name("headless")
2222

2323
if sys.version_info[:2] >= (3, 6):
24-
minimum_supported_numpy = "1.11.3"
24+
minimum_supported_numpy = "1.13.3"
2525
if sys.version_info[:2] >= (3, 7):
2626
minimum_supported_numpy = "1.14.5"
2727
if sys.version_info[:2] >= (3, 8):
@@ -176,7 +176,6 @@ def main():
176176
packages=packages,
177177
package_data=package_data,
178178
maintainer="Olli-Pekka Heinisuo",
179-
include_package_data=True,
180179
ext_modules=EmptyListWithLength(),
181180
install_requires=numpy_version,
182181
classifiers=[

travis_config.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ function bdist_wheel_cmd {
1414
# copied from multibuild's common_utils.sh
1515
# add osx deployment target so it doesnt default to 10.6
1616
local abs_wheelhouse=$1
17-
python setup.py bdist_wheel $BDIST_PARAMS
17+
pip wheel . --no-build-isolation --verbose $BDIST_PARAMS
1818
cp dist/*.whl $abs_wheelhouse
1919
if [ -n "$USE_CCACHE" -a -z "$BREW_BOOTSTRAP_MODE" ]; then ccache -s; fi
2020
}

0 commit comments

Comments
 (0)