Skip to content

Commit 4b7fdba

Browse files
feat: 更新构建
1 parent 6a108f9 commit 4b7fdba

2 files changed

Lines changed: 4 additions & 36 deletions

File tree

.github/workflows/build-manylinux-images.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
run: |
4242
mkdir -p docker/manylinux_2_38
4343
wget -qO docker/manylinux_2_38/Dockerfile_loongarch64 https://github.com/opencv/opencv-python/raw/refs/tags/${version}/docker/manylinux_2_28/Dockerfile_x86_64
44-
# patch -p1 < loong64.patch
44+
patch -p1 < loong64.patch
4545
cd docker/manylinux_2_38
4646
sed -i "s@FROM quay.io/pypa/manylinux_2_28_x86_64@FROM ghcr.io/loong64/manylinux_2_38_loongarch64@g" Dockerfile_loongarch64
4747
sed -i "s@epel-release@anolis-epao-release@g" Dockerfile_loongarch64

loong64.patch

Lines changed: 3 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,38 +2,15 @@ diff --git a/docker/manylinux_2_38/Dockerfile_loongarch64 b/docker/manylinux_2_3
22
index 3ed3aa4..783ee6a 100644
33
--- a/docker/manylinux_2_38/Dockerfile_loongarch64
44
+++ b/docker/manylinux_2_38/Dockerfile_loongarch64
5-
@@ -18,10 +18,11 @@ ARG AVIF_VERSION=v1.3.0
6-
ENV LD_LIBRARY_PATH /usr/local/lib:$LD_LIBRARY_PATH
7-
8-
# epel-release need for aarch64 to get openblas packages
9-
-RUN yum install zlib-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel epel-release -y && \
10-
+RUN yum install zlib-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel perl-lib -y && \
11-
yum install openblas-devel dejavu-sans-fonts -y && \
12-
cp /usr/include/openblas/*.h /usr/include/ && \
13-
- cp /usr/include/lapacke/lapacke*.h /usr/include/ && \
14-
+ # cp /usr/include/lapacke/lapacke*.h /usr/include/ && \
15-
+ cp -R /usr/share/fonts/dejavu-sans-fonts /usr/share/fonts/dejavu && \
16-
# libpng will be built from source
17-
yum remove libpng -y
18-
19-
@@ -50,6 +51,7 @@ RUN mkdir ~/freetype_sources && \
5+
@@ -44,6 +44,7 @@
206
RUN curl -O -L https://download.qt.io/archive/qt/5.15/${QT_VERSION}/single/qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
217
tar -xf qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
228
cd qt-everywhere-src-${QT_VERSION} && \
239
+ sed -i 's/defined(__mips__) || /defined(__mips__) || defined(__loongarch__) || /g' qtbase/src/3rdparty/double-conversion/include/double-conversion/utils.h && \
2410
export MAKEFLAGS=-j$(nproc) && \
2511
./configure -prefix /opt/Qt${QT_VERSION} -release -opensource -confirm-license -qtnamespace QtOpenCVPython -xcb -xcb-xlib -bundled-xcb-xinput -no-openssl -no-dbus -skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtconnectivity -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmultimedia -skip qtpurchasing -skip qtqa -skip qtremoteobjects -skip qtrepotools -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttranslations -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview -skip xmlpatterns -skip declarative -make libs && \
2612
make && \
27-
@@ -87,6 +89,8 @@ RUN mkdir ~/yasm_sources && \
28-
curl -O -L http://www.tortall.net/projects/yasm/releases/yasm-${YASM_VERSION}.tar.gz && \
29-
tar -xf yasm-${YASM_VERSION}.tar.gz && \
30-
cd yasm-${YASM_VERSION} && \
31-
+ curl -o config/config.sub -L https://github.com/cgitmirror/config/raw/refs/heads/master/config.sub && \
32-
+ curl -o config/config.guess -L https://github.com/cgitmirror/config/raw/refs/heads/master/config.guess && \
33-
./configure --prefix="/ffmpeg_build" --bindir="$HOME/bin" && \
34-
make -j$(getconf _NPROCESSORS_ONLN) && \
35-
make install && \
36-
@@ -97,6 +101,8 @@ RUN mkdir ~/libvpx_sources && \
13+
@@ -58,6 +59,8 @@
3714
cd ~/libvpx_sources && \
3815
git clone --depth 1 -b ${VPX_VERSION} https://chromium.googlesource.com/webm/libvpx.git && \
3916
cd libvpx && \
@@ -42,16 +19,7 @@ index 3ed3aa4..783ee6a 100644
4219
./configure --prefix="/ffmpeg_build" --disable-examples --disable-unit-tests --enable-vp9-highbitdepth --as=yasm --enable-pic --enable-shared && \
4320
make -j$(getconf _NPROCESSORS_ONLN) && \
4421
make install && \
45-
@@ -137,6 +143,8 @@ RUN mkdir ~/ffmpeg_sources && \
46-
RUN curl -O -L https://github.com/ccache/ccache/releases/download/v${CCACHE_VERSION}/ccache-${CCACHE_VERSION}.tar.gz && \
47-
tar -xf ccache-${CCACHE_VERSION}.tar.gz && \
48-
cd ccache-${CCACHE_VERSION} && \
49-
+ curl -O -L https://github.com/cgitmirror/config/raw/refs/heads/master/config.sub && \
50-
+ curl -O -L https://github.com/cgitmirror/config/raw/refs/heads/master/config.guess && \
51-
./configure && \
52-
make -j$(getconf _NPROCESSORS_ONLN) && \
53-
make install && \
54-
@@ -157,6 +165,7 @@ USER ci
22+
@@ -109,6 +112,7 @@
5523
# Git security vulnerability: https://github.blog/2022-04-12-git-security-vulnerability-announced
5624
RUN git config --global --add safe.directory /io
5725

0 commit comments

Comments
 (0)