[openrtm-commit:01662] r2683 - in branches/RELENG_1_1/OpenRTM-aist: . build

openrtm @ openrtm.org openrtm @ openrtm.org
2015年 12月 11日 (金) 10:00:24 JST


Author: kawauchi
Date: 2015-12-11 10:00:24 +0900 (Fri, 11 Dec 2015)
New Revision: 2683

Modified:
   branches/RELENG_1_1/OpenRTM-aist/
   branches/RELENG_1_1/OpenRTM-aist/build/pkg_install_ubuntu.sh
Log:
[merge] r2610,2626,2682 has been merged from trunk.


Property changes on: branches/RELENG_1_1/OpenRTM-aist
___________________________________________________________________
Modified: svn:mergeinfo
   - /tags/RELEASE_1_1_0/OpenRTM-aist:2364-2372
/tags/RELEASE_1_1_0_RC2/OpenRTM-aist:2173
/trunk/OpenRTM-aist:2154-2172,2174-2176,2180,2183-2208,2213,2328,2346,2381-2383,2389-2393,2397-2398,2400-2401,2409,2411-2412,2512-2513,2515-2516,2522-2525,2530-2531,2534-2539,2542-2543,2545-2546,2548-2566,2568,2573-2574,2592,2605,2648,2652-2653,2670,2677-2678
   + /tags/RELEASE_1_1_0/OpenRTM-aist:2364-2372
/tags/RELEASE_1_1_0_RC2/OpenRTM-aist:2173
/trunk/OpenRTM-aist:2154-2172,2174-2176,2180,2183-2208,2213,2328,2346,2381-2383,2389-2393,2397-2398,2400-2401,2409,2411-2412,2512-2513,2515-2516,2522-2525,2530-2531,2534-2539,2542-2543,2545-2546,2548-2566,2568,2573-2574,2592,2605,2610,2626,2648,2652-2653,2670,2677-2678,2682

Modified: branches/RELENG_1_1/OpenRTM-aist/build/pkg_install_ubuntu.sh
===================================================================
--- branches/RELENG_1_1/OpenRTM-aist/build/pkg_install_ubuntu.sh	2015-12-10 09:16:05 UTC (rev 2682)
+++ branches/RELENG_1_1/OpenRTM-aist/build/pkg_install_ubuntu.sh	2015-12-11 01:00:24 UTC (rev 2683)
@@ -6,8 +6,21 @@
 #         Shinji Kurihara
 #         Tetsuo Ando
 #         Harumi Miyamoto
+#         Seisho Irie
 #
 
+#
+# sudo sh pkg_install_ubuntu.sh [-s/-us/-d/-ud/-c/-uc/-r/-ur]
+# option -s            : install tool_packages for build Source packages 
+# option -us           : Uninstall tool_packages for build Source packages 
+# option -d            : install tool_packages for build Distribution
+# option -ud           : Uninstall tool_packages for build Distribution
+# option -c            : install robot Component developer tool_packages
+# option -uc           : Uninstall robot Component developer tool_packages
+# option -r            : install robot component Runtime tool_packages
+# option -ur           : Uninstall robot component Runtime tool_packages
+#
+
 #---------------------------------------
 # パッケージリスト
 #---------------------------------------
@@ -24,6 +37,30 @@
 reposerver=""
 
 #---------------------------------------
+autotools="autoconf libtool libtool-bin"
+build_tools="gcc g++ make"
+dep_pkg="uuid-dev doxygen"
+deb_tools="build-essential debhelper devscripts"
+omni_devel="libomniorb4-dev omniidl omniorb-nameserver"
+omni_runtime="omniorb-nameserver"
+openrtm_devel="openrtm-aist-doc openrtm-aist-dev python-yaml"
+openrtm_runtime="openrtm-aist openrtm-aist-example"
+
+source_tools="subversion texlive texlive-lang-cjk xdvik-ja python-yaml"
+
+source_pkgs="$autotools $build_tools $dep_pkg $source_tools $omni_devel"
+u_source_pkgs="$autotools $build_tools $dep_pkg $source_tools $omni_devel"
+
+distribution_pkgs="$build_tools $dep_pkg $deb_tools $omni_devel"
+u_distribution_pkgs="$build_tools $dep_pkg $deb_tools $omni_devel"
+
+component_pkgs="$build_tools $dep_pkg $omni_devel $openrtm_devel $openrtm_runtime"
+u_component_pkgs="$build_tools $dep_pkg $omni_devel $openrtm_devel $openrtm_runtime"
+
+runtime_pkgs="$omni_runtime $openrtm_runtime"
+u_runtime_pkgs="$omni_runtime $openrtm_runtime"
+
+#---------------------------------------
 # ロケールの言語確認
 #---------------------------------------
 check_lang()
@@ -117,7 +154,7 @@
 # ソースリスト更新関数の定義
 #---------------------------------------
 update_source_list () {
-    rtmsite=`grep '^$openrtm_repo' /etc/apt/sources.list`
+    rtmsite=`grep "$openrtm_repo" /etc/apt/sources.list`
     if test "x$rtmsite" = "x" ; then
 	echo $msg4
 	echo $msg5
@@ -152,7 +189,7 @@
 install_packages () {
     for p in $*; do
 	echo $msg9 $p
-	apt-get install $p
+	apt-get install --force-yes -y $p
 	echo $msg10
 	echo ""
     done
@@ -174,34 +211,127 @@
     for p in $*; do
 	echo $msg11 $p
 	aptitude remove $p
-    if test "$?" != 0; then
-        apt-get purge $p
-    fi
-    echo $msg10
+	if test "$?" != 0; then
+            apt-get purge $p
+	fi
+	echo $msg10
 	echo ""
     done
 }
 
 #---------------------------------------
+# install tool_packages for build Source packages 
+#---------------------------------------
+install_source_packages(){
+    echo "--------install $source_pkgs"
+    install_packages $source_pkgs
+}
+#---------------------------------------
+# Uninstall tool_packages for build Source packages 
+#---------------------------------------
+uninstall_source_packages(){
+    echo "--------uninstall $u_source_pkgs"
+    uninstall_packages `reverse $u_source_pkgs`
+}
+#---------------------------------------
+# install tool_packages for build Distribution
+#---------------------------------------
+install_distribution(){
+    echo "--------install $distribution_pkgs"
+    install_packages $distribution_pkgs
+}
+#---------------------------------------
+# Uninstall tool_packages for build Distribution
+#---------------------------------------
+uninstall_distribution(){
+    echo "--------uninstall $u_distribution_pkgs"
+    uninstall_packages `reverse $u_distribution_pkgs`
+}
+#---------------------------------------
+# install robot Component developer tool_packages
+#---------------------------------------
+install_componet_developer(){
+    echo "--------install $component_pkgs()"
+    install_packages $component_pkgs
+}
+#---------------------------------------
+# Uninstall robot Component developer tool_packages
+#---------------------------------------
+uninstall_componet_developer(){
+    echo "--------uninstall $u_component_pkgs"
+    uninstall_packages `reverse $u_component_pkgs`
+}
+#---------------------------------------
+# install robot component Runtime tool_packages
+#---------------------------------------
+install_runtime(){
+    echo "--------install $runtime_pkgs"
+    install_packages $runtime_pkgs
+}
+#---------------------------------------
+# Uninstall robot component Runtime tool_packages
+#---------------------------------------
+uninstall_runtime(){
+    echo "--------uninstall $u_runtime_pkgs"
+    uninstall_packages `reverse $u_runtime_pkgs`
+}
+#---------------------------------------
+#
+#---------------------------------------
+howto_usage(){
+    echo "Usage: sudo sh pkg_install_ubuntu.sh [-s/-us/-d/-ud/-c/-uc/-r/-ur]"
+    echo "       option -s            : install tool_packages for build Source packages"
+    echo "       option -us           : Uninstall tool_packages for build Source packages"
+    echo "       option -d            : install tool_packages for build Distribution"
+    echo "       option -ud           : Uninstall tool_packages for build Distribution"
+    echo "       option -c            : install robot Component developer tool_packages"
+    echo "       option -uc           : Uninstall robot Component developer tool_packages"
+    echo "       option -r            : install robot component Runtime tool_packages"
+    echo "       option -ur           : Uninstall robot component Runtime tool_packages"
+}
+
+#---------------------------------------
 # メイン
 #---------------------------------------
 check_lang
 check_root
+check_reposerver
+create_srclist
+update_source_list
+apt-get autoclean
+apt-get update
 
-if test "x$1" = "x0.4.2" || test "x$1" = "x0.4" ; then
-    openrtm=$openrtm04
-    packages="$devel $omni $ace $openrtm"
+if test "x$1" = "x-s" ; then
+    install_source_packages
+    exit 0
 fi
-
-if test "x$1" = "x-u" ; then
-    uninstall_packages `reverse $u_packages`
-else
-    check_reposerver
-    create_srclist
-    update_source_list
-    apt-get autoclean
-    apt-get update
-    uninstall_packages `reverse $openrtm`
-    install_packages $packages
+if test "x$1" = "x-us" ; then
+    uninstall_source_packages
+    exit 0
 fi
+if test "x$1" = "x-d" ; then
+    install_distribution
+    exit 0
+fi
+if test "x$1" = "x-ud" ; then
+    uninstall_distribution
+    exit 0
+fi
+if test "x$1" = "x-c" ; then
+    install_componet_developer
+    exit 0
+fi
+if test "x$1" = "x-uc" ; then
+    uninstall_componet_developer
+    exit 0
+fi
+if test "x$1" = "x-r" ; then
+    install_runtime
+    exit 0
+fi
+if test "x$1" = "x-ur" ; then
+    uninstall_runtime
+    exit 0
+fi
 
+howto_usage


Property changes on: branches/RELENG_1_1/OpenRTM-aist/build/pkg_install_ubuntu.sh
___________________________________________________________________
Added: svn:executable
   + *



More information about the openrtm-commit mailing list