packaging: fix wrong condition checking 32/90332/2
authorMinkyu Kang <mk7.kang@samsung.com>
Thu, 29 Sep 2016 11:08:50 +0000 (20:08 +0900)
committerHermet Park <chuneon.park@samsung.com>
Wed, 5 Oct 2016 08:43:06 +0000 (01:43 -0700)
Since there's no rule for "else if" on RPM spec, "else if" will be interpreted to "else".
So, if the profile is not a mobile then all other profiles are recognized as wearable.
It has made errors on TV profile.

Change-Id: Iac40137954f6f2d196dca20f72fc6f004a0d5701
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
packaging/elementary.spec

index 8be5295..ae5a36a 100644 (file)
@@ -99,11 +99,13 @@ cp %{SOURCE1001} .
 # Patch profile dependency widgets
 %if "%{profile}" == "mobile"
     cp %{_builddir}/%{buildsubdir}/src/mobile_lib/* %{_builddir}/%{buildsubdir}/src/lib
-%else if "%{profile}" == "wearable"
-    cp %{_builddir}/%{buildsubdir}/src/mobile_lib/* %{_builddir}/%{buildsubdir}/src/lib
-    export CFLAGS+=" -DELM_FEATURE_WEARABLE"
-    %if "%{?model_build_feature_formfactor}" == "circle"
-       export CFLAGS+=" -DELM_FEATURE_WEARABLE_C1"
+%else
+    %if "%{profile}" == "wearable"
+        cp %{_builddir}/%{buildsubdir}/src/mobile_lib/* %{_builddir}/%{buildsubdir}/src/lib
+        export CFLAGS+=" -DELM_FEATURE_WEARABLE"
+        %if "%{?model_build_feature_formfactor}" == "circle"
+           export CFLAGS+=" -DELM_FEATURE_WEARABLE_C1"
+        %endif
     %endif
 %endif