DIST: Fix architecture dependencies. 86/193586/1 accepted/tizen/unified/20181212.062457 submit/tizen/20181211.022328
authorMyungJoo Ham <myungjoo.ham@samsung.com>
Thu, 22 Nov 2018 06:25:47 +0000 (15:25 +0900)
committerMyungJoo Ham <myungjoo.ham@samsung.com>
Thu, 22 Nov 2018 06:35:59 +0000 (15:35 +0900)
1. Do not enable NEON for x86.
2. Do not define ARCH=arm for x86

Change-Id: Idc30def83543ae10f6c665d58ad672962de7a8e4
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
packaging/opencv.spec

index 45a10b5..0f71e8e 100644 (file)
@@ -1,7 +1,7 @@
 Name: opencv
 Summary: OpenCV library
 Version: 3.4.1
-Release: 4
+Release: 5
 Group: Development/Libraries
 License: BSD-3-Clause and LGPL-2.1+
 Source0: %{name}-%{version}.tar.gz
@@ -40,11 +40,18 @@ The Open Computer Vision Library (Dev) includes various algorithms for computer
 %setup -q -T -D -a 100
 
 %build
-%ifarch aarch64 x86_64
+%ifarch aarch64
 ARCH=aarch64
-%else
+%endif
+%ifarch %arm
 ARCH=arm
 %endif
+%ifarch x86_64
+ARCH=x86_64
+%endif
+%ifarch %ix86
+ARCH=i386
+%endif
 mkdir -p build
 cd build
 cmake .. -DCMAKE_INSTALL_PREFIX=/usr \
@@ -193,9 +200,11 @@ cmake .. -DCMAKE_INSTALL_PREFIX=/usr \
        -DENABLE_SOLUTION_FOLDERS=OFF \
        -DENABLE_PROFILLING=OFF \
        -DENABLE_COVERAGE=OFF \
-       -DCV_TRACE=OFF \
+%ifarch %arm aarch64
        -DCPU_BASELINE="" \
-       -DCPU_DISPATCH=NEON
+       -DCPU_DISPATCH=NEON \
+%endif
+       -DCV_TRACE=OFF
 
 make %{?jobs:-j%jobs}