1
- FROM python:3.7
2
- MAINTAINER Josip Janzic <josip@jjanzic.com>
1
+ FROM python:3.9
2
+ LABEL mantainer= " Josip Janzic <josip@jjanzic.com>"
3
3
4
4
RUN apt-get update \
5
5
&& apt-get install -y \
@@ -23,7 +23,7 @@ RUN apt-get update \
23
23
RUN pip install numpy
24
24
25
25
WORKDIR /
26
- ENV OPENCV_VERSION="4.1.1 "
26
+ ENV OPENCV_VERSION="4.5.0 "
27
27
RUN wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip \
28
28
&& unzip ${OPENCV_VERSION}.zip \
29
29
&& mkdir /opencv-${OPENCV_VERSION}/cmake_binary \
@@ -40,14 +40,14 @@ RUN wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip \
40
40
-DBUILD_TESTS=OFF \
41
41
-DBUILD_PERF_TESTS=OFF \
42
42
-DCMAKE_BUILD_TYPE=RELEASE \
43
- -DCMAKE_INSTALL_PREFIX=$(python3.7 -c "import sys; print(sys.prefix)" ) \
44
- -DPYTHON_EXECUTABLE=$(which python3.7 ) \
45
- -DPYTHON_INCLUDE_DIR=$(python3.7 -c "from distutils.sysconfig import get_python_inc; print(get_python_inc())" ) \
46
- -DPYTHON_PACKAGES_PATH=$(python3.7 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())" ) \
43
+ -DCMAKE_INSTALL_PREFIX=$(python3.9 -c "import sys; print(sys.prefix)" ) \
44
+ -DPYTHON_EXECUTABLE=$(which python3.9 ) \
45
+ -DPYTHON_INCLUDE_DIR=$(python3.9 -c "from distutils.sysconfig import get_python_inc; print(get_python_inc())" ) \
46
+ -DPYTHON_PACKAGES_PATH=$(python3.9 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())" ) \
47
47
.. \
48
48
&& make install \
49
49
&& rm /${OPENCV_VERSION}.zip \
50
50
&& rm -r /opencv-${OPENCV_VERSION}
51
51
RUN ln -s \
52
- /usr/local/python/cv2/python-3.7 /cv2.cpython-37m-x86_64-linux-gnu.so \
53
- /usr/local/lib/python3.7 /site-packages/cv2.so
52
+ /usr/local/python/cv2/python-3.9 /cv2.cpython-37m-x86_64-linux-gnu.so \
53
+ /usr/local/lib/python3.9 /site-packages/cv2.so
0 commit comments