Remove unsued lines of spec file and move wfd-manage executable 66/145666/1 submit/tizen/20170823.080619
authorJiung <jiung.yu@samsung.com>
Wed, 23 Aug 2017 07:57:53 +0000 (16:57 +0900)
committerJiung <jiung.yu@samsung.com>
Wed, 23 Aug 2017 07:58:13 +0000 (16:58 +0900)
Change-Id: Id00aaed6c842f8ad92de4288e0bdb7a0b7ef795b
Signed-off-by: Yu jiung <jiung.yu@samsung.com>
files/p2p_supp.sh.in
files/wifi-direct-manager.conf.common [new file with mode: 0644]
files/wifi-direct-manager.conf.mobile
files/wifi-direct-manager.conf.wearable
packaging/wifi-direct-manager.spec

index b45d52b..eb663ca 100644 (file)
@@ -16,9 +16,9 @@ start()
        fi
        ## For Hawk-P Platform, Hardware model is Samsung
        if [ $HARDWARE_MODEL = "Samsung" ];then
-               @SBIN_DIR@/wpa_supplicant -t -B -ddd -Dnl80211 -ip2p0 -c@TZ_SYS_ETC@/p2p_supp.conf -g@TZ_SYS_RUN@/wpa_global  -f/var/log/wpa_supplicant.log
+               @SBIN_DIR@/wpa_supplicant -t -B -ddd -Dnl80211 -ip2p0 -c@TZ_SYS_ETC@/p2p_supp.conf -g@TZ_SYS_RUN@/wpa_global  -f/opt/usr/data/network/wpa_supplicant.log
         else
-               @SBIN_DIR@/wpa_supplicant -t -B -C@TZ_SYS_RUN@/wpa_supplicant -ddd -Dnl80211 -iwlan0 -c@TZ_SYS_ETC@/p2p_supp.conf -f/var/log/wpa_supplicant.log
+               @BIN_DIR@/wpa_supplicant -t -B -ddd -O @TZ_SYS_RUN@/wpa_supplicant-Dnl80211 -iwlan0 -c@TZ_SYS_ETC@/p2p_supp.conf -f/opt/usr/data/network/wpa_supplicant.log
        fi
  }
 
@@ -30,7 +30,7 @@ start_p2p0()
                echo "File not exist. Reinstall: @TZ_SYS_ETC@/p2p_supp.conf"
                 @BIN_DIR@/cp @TZ_SYS_RO_ETC@/wifi-direct/p2p_supp.conf @TZ_SYS_ETC@/
        fi
-       @SBIN_DIR@/wpa_supplicant -t -B -ddd -Dnl80211 -ip2p0 -c@TZ_SYS_ETC@/p2p_supp.conf -f/var/log/wpa_supplicant.log
+       @BIN_DIR@/wpa_supplicant -t -B -ddd -Dnl80211 -ip2p0 -c@TZ_SYS_ETC@/p2p_supp.conf -f/opt/usr/data/network/wpa_supplicant.log
 }
 
 start_dbus()
@@ -45,7 +45,7 @@ start_dbus()
                        echo "File not exist. Reinstall: @TZ_SYS_ETC@/p2p_supp.conf"
                         @BIN_DIR@/cp @TZ_SYS_RO_ETC@/wifi-direct/p2p_supp.conf @TZ_SYS_ETC@/
                fi
-               @SBIN_DIR@/wpa_supplicant -t -B -u -ddd -K -f/var/log/wpa_supplicant.log
+               @BIN_DIR@/wpa_supplicant -t -B -u -ddd -O @TZ_SYS_RUN@/wpa_supplicant -g/var/run/wpa_global -K -f/opt/usr/data/network/wpa_supplicant.log
        else
                echo "${program} is already running"
        fi
diff --git a/files/wifi-direct-manager.conf.common b/files/wifi-direct-manager.conf.common
new file mode 100644 (file)
index 0000000..2945ad1
--- /dev/null
@@ -0,0 +1,32 @@
+[wfd-manager]
+on_demand=yes
+connection_agent=yes
+ip_over_eapol=yes
+# default common interface
+interface=wlan0
+# default group interface
+group_interface=p2p-wlan0-0
+# default device name
+device_name=Tizen
+# default primary device type
+primary_device_type=10
+# default secondary device type
+secondary_device_type=5
+# default GO intent
+go_intent=7
+# default persistent reconnect
+persistent_reconnect=1
+# default listen reg class
+listen_reg_class=81
+# default listen channel
+listen_channel=1
+# default operating reg class
+operating_reg_class=81
+# default operating channel
+operating_channel=1
+# default config method
+config_methods=display push_button keypad p2ps
+# default no group interface
+no_group_iface=1
+# Group operating frequency
+group_operating_freq=2
index 1a4fcd6..f8109c7 100644 (file)
@@ -6,7 +6,7 @@ ip_over_eapol=yes
 # default common interface
 interface=wlan0
 # default group interface
-group_interface=p2p0
+group_interface=p2p-wlan0-0
 # default device name
 device_name=Tizen
 # default primary device type
index 3b2e646..9ff871d 100644 (file)
@@ -6,7 +6,7 @@ ip_over_eapol=yes
 # default common interface
 interface=wlan0
 # default group interface
-group_interface=p2p0
+group_interface=p2p-wlan0-0
 # default device name
 device_name=Tizen
 # default primary device type
index de03b56..9a832f1 100644 (file)
@@ -8,7 +8,7 @@
 
 Name:          wifi-direct-manager
 Summary:       Wi-Fi Direct manger
-Version:       1.2.239
+Version:       1.2.240
 Release:       1
 Group:      Network & Connectivity/Wireless
 License:    Apache-2.0
@@ -199,85 +199,7 @@ export ARCH=i586
 
 %endif
 
-# This is for backward-compatibility. This does not deteriorate 4.0 Configurability
-# if mobile || "undefined"
-%if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
-mkdir -p build_mobile
-pushd build_mobile
-cmake .. -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
-%if ! 0%{?model_build_feature_network_tethering_disable}
-       -DTIZEN_TETHERING_ENABLE=0 \
-%endif
-       -DTIZEN_DEBUG_DBUS_VALUE=1 \
-%if "%{?_lib}" == "lib64"
-       -DTIZEN_ARCH_64=1 \
-%endif
-       -DLIB_DIR=%{_libdir} \
-       -DBIN_DIR=%{_bindir} \
-       -DSBIN_DIR=%{_sbindir} \
-       -DTZ_SYS_RO_ETC=%{TZ_SYS_RO_ETC} \
-       -DTZ_SYS_VAR=%{TZ_SYS_VAR} \
-       -DTZ_SYS_ETC=%{TZ_SYS_ETC} \
-       -DTZ_SYS_RUN=%{TZ_SYS_RUN}
-
-make %{?_smp_mflags}
-popd
-
-%ifarch %{arm}
-mkdir -p build_tm1
-pushd build_tm1
-cmake .. -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
-%if ! 0%{?model_build_feature_network_tethering_disable}
-       -DTIZEN_TETHERING_ENABLE=0 \
-%endif
-       -DTIZEN_DEBUG_DBUS_VALUE=1 \
-%if "%{?_lib}" == "lib64"
-       -DTIZEN_ARCH_64=1 \
-%endif
-       -DLIB_DIR=%{_libdir} \
-       -DBIN_DIR=%{_bindir} \
-       -DSBIN_DIR=%{_sbindir} \
-       -DTZ_SYS_RO_ETC=%{TZ_SYS_RO_ETC} \
-       -DTZ_SYS_VAR=%{TZ_SYS_VAR} \
-       -DTZ_SYS_ETC=%{TZ_SYS_ETC} \
-       -DTZ_SYS_RUN=%{TZ_SYS_RUN}
-
-make %{?_smp_mflags}
-popd
-%endif
-%endif
-
-# This is for backward-compatibility. This does not deteriorate 4.0 Configurability
-# if wearable || "undefined"
-%if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
-mkdir -p build_wearable
-pushd build_wearable
-cmake .. -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
-%if ! 0%{?model_build_feature_network_tethering_disable}
-       -DTIZEN_TETHERING_ENABLE=0 \
-%endif
-       -DTIZEN_DEBUG_DBUS_VALUE=1 \
-%if "%{?_lib}" == "lib64"
-       -DTIZEN_ARCH_64=1 \
-%endif
-       -DLIB_DIR=%{_libdir} \
-       -DBIN_DIR=%{_bindir} \
-       -DSBIN_DIR=%{_sbindir} \
-       -DTZ_SYS_RO_ETC=%{TZ_SYS_RO_ETC} \
-       -DTZ_SYS_VAR=%{TZ_SYS_VAR} \
-       -DTZ_SYS_ETC=%{TZ_SYS_ETC} \
-       -DTZ_SYS_RUN=%{TZ_SYS_RUN}
-
-make %{?_smp_mflags}
-popd
-%endif
-
-# This is for backward-compatibility. This does not deteriorate 4.0 Configurability
-# if tv || "undefined"
-%if "%{?profile}" != "mobile" && "%{?profile}" != "wearable" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
-mkdir -p build_tv
-pushd build_tv
-cmake .. -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
+cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
 %if ! 0%{?model_build_feature_network_tethering_disable}
        -DTIZEN_TETHERING_ENABLE=0 \
 %endif
@@ -294,31 +216,6 @@ cmake .. -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
        -DTZ_SYS_RUN=%{TZ_SYS_RUN}
 
 make %{?_smp_mflags}
-popd
-%endif
-
-# This is for backward-compatibility. This does not deteriorate 4.0 Configurability
-# if common || ivi || "undefined"
-%if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "mobile"
-# common
-cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DARCHITECTURE=$ARCH \
-%if ! 0%{?model_build_feature_network_tethering_disable}
-       -DTIZEN_TETHERING_ENABLE=0 \
-%endif
-       -DTIZEN_DEBUG_DBUS_VALUE=1 \
-%if "%{?_lib}" == "lib64"
-       -DTIZEN_ARCH_64=1 \
-%endif
--DLIB_DIR=%{_libdir} \
--DBIN_DIR=%{_bindir} \
--DSBIN_DIR=%{_sbindir} \
--DTZ_SYS_RO_ETC=%{TZ_SYS_RO_ETC} \
--DTZ_SYS_VAR=%{TZ_SYS_VAR} \
--DTZ_SYS_ETC=%{TZ_SYS_ETC} \
--DTZ_SYS_RUN=%{TZ_SYS_RUN}
-
-make %{?_smp_mflags}
-%endif
 
 %install
 rm -rf %{buildroot}
@@ -328,15 +225,8 @@ mkdir -p %{buildroot}/etc/wifi-direct
 # if mobile || "undefined"
 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 cp files/wifi-direct-manager.conf.mobile %{buildroot}/etc/wifi-direct/wifi-direct-manager.conf.mobile
-pushd build_mobile
-%make_install
-popd
-
 %ifarch %{arm}
 cp files/wifi-direct-manager.conf.tm1 %{buildroot}/etc/wifi-direct/wifi-direct-manager.conf.tm1
-pushd build_tm1
-%make_install
-popd
 %endif
 %endif
 
@@ -344,26 +234,22 @@ popd
 # if wearable || "undefined"
 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 cp files/wifi-direct-manager.conf.wearable %{buildroot}/etc/wifi-direct/wifi-direct-manager.conf.wearable
-pushd build_wearable
-%make_install
-popd
 %endif
 
 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
 # if tv || "undefined"
 %if "%{?profile}" != "mobile" && "%{?profile}" != "wearable" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 cp files/wifi-direct-manager.conf.tv %{buildroot}/etc/wifi-direct/wifi-direct-manager.conf.tv
-pushd build_tv
-%make_install
-popd
 %endif
 
 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
 # if common || ivi || "undefined"
 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "mobile"
-%make_install
+cp files/wifi-direct-manager.conf.common %{buildroot}/etc/wifi-direct/wifi-direct-manager.conf.common
 %endif
 
+%make_install
+
 mkdir -p %{buildroot}%{_sysconfdir}/dbus-1/system.d
 cp wfd-manager.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/wfd-manager.conf
 mkdir -p %{buildroot}%{_datadir}/dbus-1/system-services/
@@ -393,119 +279,31 @@ fi
 touch %{TZ_SYS_VAR}/lib/misc/dhcpd.leases
 chmod 666 %{TZ_SYS_VAR}/lib/misc/dhcpd.leases
 
+
+# This is for backward-compatibility. This does not deteriorate 4.0 Configurability
+# if common || "undefined"
+%if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
+%post profile_common
+mv -f %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.common %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf
+%endif
+
 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
 # if mobile || "undefined"
 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 %post profile_mobile
 mv -f %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.mobile %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf
-pushd %{_bindir}
-popd
-%preun profile_mobile
-case "$1" in
-  0)
-    # This is an un-installation.
-       rm %{_bindir}/wfd-manager
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
-
-%post -n wifi-direct-plugin-wpasupplicant-profile_mobile
-pushd %{_libdir}
-popd
-/sbin/ldconfig
-
-%preun -n wifi-direct-plugin-wpasupplicant-profile_mobile
-case "$1" in
-  0)
-    # This is an un-installation.
-       /sbin/ldconfig
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
+%endif
 
 %ifarch %{arm}
 %post extension-TM1
 mv -f %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.tm1 %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf
-pushd %{_bindir}
-popd
-%preun extension-TM1
-case "$1" in
-  0)
-    # This is an un-installation.
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
-
-%post -n wifi-direct-plugin-wpasupplicant-extension-TM1
-pushd %{_libdir}
-popd
-/sbin/ldconfig
-
-%preun -n wifi-direct-plugin-wpasupplicant-extension-TM1
-case "$1" in
-  0)
-    # This is an un-installation.
-       pushd %{_libdir}
-       popd
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
-
-%endif
-%endif //mobile
+%endif
 
 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
 # if wearable || "undefined"
 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 %post profile_wearable
 mv -f %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.wearable %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf
-pushd %{_bindir}
-popd
-%preun profile_wearable
-case "$1" in
-  0)
-    # This is an un-installation.
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
-
-%post -n wifi-direct-plugin-wpasupplicant-profile_wearable
-pushd %{_libdir}
-popd
-/sbin/ldconfig
-
-%preun -n wifi-direct-plugin-wpasupplicant-profile_wearable
-case "$1" in
-  0)
-    # This is an un-installation.
-       /sbin/ldconfig
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
 %endif
 
 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
@@ -513,38 +311,6 @@ esac
 %if "%{?profile}" != "mobile" && "%{?profile}" != "wearable" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 %post profile_tv
 mv -f %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.tv %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf
-pushd %{_bindir}
-popd
-%preun profile_tv
-case "$1" in
-  0)
-    # This is an un-installation.
-       rm %{_bindir}/wfd-manager
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
-
-%post -n wifi-direct-plugin-wpasupplicant-profile_tv
-pushd %{_libdir}
-popd
-/sbin/ldconfig
-
-%preun -n wifi-direct-plugin-wpasupplicant-profile_tv
-case "$1" in
-  0)
-    # This is an un-installation.
-       /sbin/ldconfig
-  ;;
-  1)
-    # This is an upgrade.
-    # Do nothing.
-    :
-  ;;
-esac
 %endif
 
 %files
@@ -567,6 +333,7 @@ esac
 %{_unitdir}/wifi-direct-manager.service
 %endif
 %attr(755,-,-) %{_sbindir}/p2p_supp.sh
+%attr(755,-,-) %{_bindir}/wfd-manager
 %{upgrade_script_path}/500.wifi-direct-manager_upgrade.sh
 
 %files -n wifi-direct-plugin-wpasupplicant
@@ -583,8 +350,7 @@ esac
 # if common || ivi || "undefined"
 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "mobile"
 %files profile_common
-%defattr(-,network_fw,network_fw,-)
-%{_bindir}/wfd-manager
+%attr(644,network_fw,network_fw) %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.common
 
 %files -n wifi-direct-plugin-wpasupplicant-profile_common
 # default .so files are housed in the main pkg.
@@ -594,7 +360,7 @@ esac
 # if mobile || "undefined"
 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 %files profile_mobile
-%attr(644,root,root) %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.mobile
+%attr(644,network_fw,network_fw) %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.mobile
 
 %files -n wifi-direct-plugin-wpasupplicant-profile_mobile
 %manifest wifi-direct-plugin-wpasupplicant.manifest
@@ -625,7 +391,7 @@ esac
 # if tv || "undefined"
 %if "%{?profile}" != "mobile" && "%{?profile}" != "wearable" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
 %files profile_tv
-%attr(644,root,root) %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.tv
+%attr(644,network_fw,network_fw) %{_sysconfdir}/wifi-direct/wifi-direct-manager.conf.tv
 
 %files -n wifi-direct-plugin-wpasupplicant-profile_tv
 %manifest wifi-direct-plugin-wpasupplicant.manifest