Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updpatch: opencv 4.7.0-13 #2779

Merged
merged 1 commit into from
Jul 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 11 additions & 8 deletions opencv/riscv64.patch
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-pkgname=(opencv opencv-samples python-opencv opencv-cuda)
+pkgname=(opencv opencv-samples python-opencv)
pkgver=4.7.0
pkgrel=10
pkgrel=13
pkgdesc='Open Source Computer Vision Library'
@@ -12,7 +12,7 @@ license=(BSD)
url='https://opencv.org/'
Expand All @@ -18,24 +18,24 @@
optdepends=('opencv-samples: samples'
'vtk: for the viz module'
'glew: for the viz module'
@@ -26,6 +26,8 @@ source=(https://github.com/opencv/opencv/archive/$pkgver/$pkgname-$pkgver.tar.gz
sha256sums=('8df0079cdbe179748a18d44731af62a245a45ebf5085223dc03133954c662973'
'42df840cf9055e59d0e22c249cfb19f04743e1bdad113d31b1573d3934d62584'
@@ -30,6 +30,8 @@ sha256sums=('8df0079cdbe179748a18d44731af62a245a45ebf5085223dc03133954c662973'
'a71e8ffad606d518a846296a06e59beac38887b30021a72b08321aeffd43a75d'
'572f7b774678e2fc46b524ce72d4b0ddf175b2a576c6dcfd013d16165ba39863'
'f35a2d4ea0d6212c7798659e59eda2cb0b5bc858360f7ce9c696c77d3029668e')
+# fix error 'relocation truncated to fit: R_RISCV_PCREL_HI20 against `.LC19''
+options=(!lto)

prepare() {
patch -d $pkgname-$pkgver -p1 < vtk9.patch # Don't require all vtk optdepends
@@ -49,7 +51,6 @@ build() {
@@ -56,7 +58,6 @@ build() {
-DINSTALL_PYTHON_EXAMPLES=ON \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCPU_BASELINE_DISABLE=SSE3 \
- -DCPU_BASELINE_REQUIRE=SSE2 \
-DOPENCV_EXTRA_MODULES_PATH=$srcdir/opencv_contrib-$pkgver/modules \
-DOPENCV_SKIP_PYTHON_LOADER=ON \
-DLAPACK_LIBRARIES=/usr/lib/liblapack.so;/usr/lib/libblas.so;/usr/lib/libcblas.so \
@@ -64,15 +65,6 @@ build() {
@@ -71,17 +72,6 @@ build() {
cmake -B build -S $pkgname-$pkgver $_opts \
-DBUILD_WITH_DEBUG_INFO=ON
cmake --build build
Expand All @@ -45,16 +45,19 @@
- -DBUILD_WITH_DEBUG_INFO=OFF \
- -DWITH_CUDA=ON \
- -DWITH_CUDNN=ON \
- -DCMAKE_C_COMPILER=gcc-12 \
- -DCMAKE_CXX_COMPILER=g++-12 \
- -DCUDA_ARCH_BIN='52-real;53-real;60-real;61-real;62-real;70-real;72-real;75-real;80-real;86-real;87-real;89-real;90-real;90-virtual' \
- -DCUDA_ARCH_PTX='90-virtual'
- cmake --build build-cuda
}

package_opencv() {
@@ -115,25 +107,3 @@ package_python-opencv() {
@@ -123,26 +113,3 @@ package_python-opencv() {
# install license file
install -Dm644 $pkgbase-$pkgver/LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
}
-
-package_opencv-cuda() {
- pkgdesc+=' (with CUDA support)'
- depends+=(cudnn)
Expand Down