File tree Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -30,14 +30,16 @@ RUN \
3030        python${PYTHON_VERSION} \
3131        python${PYTHON_VERSION}-dev \
3232        $( if [ "${PYTHON_VERSION%%.*}"  -eq 3 ] && [ "${PYTHON_VERSION#*.}"  -lt 10 ]; then echo "python${PYTHON_VERSION}-distutils" ; fi ) \
33+         $( if [ "${PYTHON_VERSION}"  -eq "3.12"  ]; then echo "python3-pip" ; fi ) \
3334        curl \
3435        wget && \
3536    rm -rf /var/lib/apt/lists/* && \
3637    #  Set the default python and install PIP packages
3738    update-alternatives --install /usr/bin/python${PYTHON_VERSION%%.*} python${PYTHON_VERSION%%.*} /usr/bin/python${PYTHON_VERSION} 1 && \
3839    update-alternatives --install /usr/bin/python python /usr/bin/python${PYTHON_VERSION} 1 && \
39-     #  install python ecosystem
40-     python -m ensurepip --upgrade
40+     #  install python dependencies
41+     PIP_URL="https://bootstrap.pypa.io/get-pip.py"  && \
42+     curl $PIP_URL | python
4143
4244ENV  PYTHONPATH="/usr/lib/python${PYTHON_VERSION}/site-packages:/usr/local/lib/python${PYTHON_VERSION}/site-packages" 
4345
Original file line number Diff line number Diff line change 3939        curl \
4040        wget && \
4141    rm -rf /var/lib/apt/lists/* && \
42- 
4342    #  Set the default python and install PIP packages
4443    update-alternatives --install /usr/bin/python${PYTHON_VERSION%%.*} python${PYTHON_VERSION%%.*} /usr/bin/python${PYTHON_VERSION} 1 && \
4544    update-alternatives --install /usr/bin/python python /usr/bin/python${PYTHON_VERSION} 1 && \
46- 
4745    #  install python dependencies
4846    PIP_URL="https://bootstrap.pypa.io/get-pip.py"  && \
4947    curl $PIP_URL | python
5654    CUDA=`basename $CUDA_PATH` && \
5755    echo "$CUDA_PATH/compat"  >> /etc/ld.so.conf.d/${CUDA/./-}.conf && \
5856    ldconfig && \
59- 
6057    #  Install all dependencies for OpenCV
6158    apt-get -y update -qq --fix-missing && \
6259    apt-get -y install --no-install-recommends \
9491        libxrender1 \
9592    && \
9693    pip install numpy && \
97- 
9894    #  Install OpenCV
9995    wget https://github.com/opencv/opencv/archive/$OPENCV_VERSION.zip -O opencv.zip --progress=bar:force:noscroll && \
10096    unzip -q opencv.zip && \
@@ -104,7 +100,6 @@ RUN \
104100    unzip -q opencv_contrib.zip && \
105101    mv /opencv_contrib-$OPENCV_VERSION /opencv_contrib && \
106102    rm opencv_contrib.zip && \
107- 
108103    #  Prepare build
109104    mkdir /opencv/build && \
110105    cd /opencv/build && \
@@ -145,13 +140,11 @@ RUN \
145140      -D ENABLE_PRECOMPILED_HEADERS=OFF \
146141      .. \
147142    && \
148- 
149143   #  Build, Test and Install
150144    cd /opencv/build && \
151145    make -j$(nproc) && \
152146    make install && \
153147    ldconfig && \
154- 
155148   #  cleaning
156149   apt-get -y remove \
157150        unzip \
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments