[rkward-cvs] SF.net SVN: rkward:[4148] trunk/rkward

m-eik at users.sourceforge.net m-eik at users.sourceforge.net
Mon Jan 9 17:12:39 UTC 2012


Revision: 4148
          http://rkward.svn.sourceforge.net/rkward/?rev=4148&view=rev
Author:   m-eik
Date:     2012-01-09 17:12:39 +0000 (Mon, 09 Jan 2012)
Log Message:
-----------
added README.MacPorts with info on bundle installations, and improved the MacPorts bundle build script

Modified Paths:
--------------
    trunk/rkward/ChangeLog
    trunk/rkward/macports/update_bundle.sh

Added Paths:
-----------
    trunk/rkward/macports/README.MacPorts

Modified: trunk/rkward/ChangeLog
===================================================================
--- trunk/rkward/ChangeLog	2012-01-08 22:42:14 UTC (rev 4147)
+++ trunk/rkward/ChangeLog	2012-01-09 17:12:39 UTC (rev 4148)
@@ -1,3 +1,4 @@
+- Added MacPorts support, see README.MacPorts and bundle build script in the macports folder
 - Added dynamically generated table-of-contents menu to output document
 - Fixed: Would not show output of system() commands to stderr on the console (on Unix-like systems)
 - Allow some markup inside <text> elements in plugins, and auto-add breaks only for duplicate newlines.

Added: trunk/rkward/macports/README.MacPorts
===================================================================
--- trunk/rkward/macports/README.MacPorts	                        (rev 0)
+++ trunk/rkward/macports/README.MacPorts	2012-01-09 17:12:39 UTC (rev 4148)
@@ -0,0 +1,42 @@
+AFTER THE INSTALLATION
+======================
+
+KDE needs dbus to run. Therefore, after you installed the bundle image, run these command *once* in a terminal session:
+
+  sudo launchctl load -w /opt/rkward/Library/LaunchDaemons/org.freedesktop.dbus-system.plist
+  launchctl load -w /opt/rkward/Library/LaunchAgents/org.freedesktop.dbus-session.plist
+
+The bundle installs mostly to /opt/rkward. To launch all newly installed applications directly (e.g., R), you probably want to add this to the PATH environment variable, by adding this to ~/.profile (create it, if not present):
+
+  export PATH=/opt/rkward/bin:/opt/rkward/sbin:$PATH
+
+
+LOCALIZATION
+============
+
+Support for other localizations than english are available for all KDE applications, if the environment variable LANG is set accordingly. To acheive that temporarily for your running session, call the following (example for german):
+
+  launchctl setenv LANG de_DE.UTF-8
+
+To set the variable permanently, you can create or edit the file ~/.MacOSX/environment.plist (you need to login again for the changes to take effect):
+
+  <?xml version="1.0" encoding="UTF-8"?>
+  <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+  <plist version="1.0">
+      <dict>
+          <key>LANG</key>
+          <string>de_DE.UTF-8</string>
+      </dict>
+  </plist>
+
+
+UPDATES/UNINSTALL
+=================
+
+There is no real update for binary bundles yet. That is, you need to uninstall and install the new version. Your personal settings should survive that, as they are sored in your personal directory (including manually installed R packages, if you didn't install them to /opt/rkward):
+
+1. pull the "RKWard" folder from Applications to Trash
+2. remove the directory /opt/rkward:
+  sudo rm -rf /opt/rkward
+
+Afterwards, you can install the new bundle.

Modified: trunk/rkward/macports/update_bundle.sh
===================================================================
--- trunk/rkward/macports/update_bundle.sh	2012-01-08 22:42:14 UTC (rev 4147)
+++ trunk/rkward/macports/update_bundle.sh	2012-01-09 17:12:39 UTC (rev 4148)
@@ -4,8 +4,12 @@
 SRCFILE=${SRCPATH}/sources_bundle_${SRCDATE}.tar
 # specify macports installation path
 MPTINST=/opt/rkward
+# specify work directory
+WORKDIR=/opt/ports/kde/rkward/work
 # specify the target port
 PTARGET=rkward-devel
+# specify local public directory
+LPUBDIR=~/Public/rkward
 
 if [[ $1 == "" ]] ; then
  echo "Usage: update_bundle.sh OPTION
@@ -14,22 +18,25 @@
            -p (update macports, remove inactive)
            -r (update port ${PTARGET})
            -m (create .mdmg of ${PTARGET})
-           -s (create sources .tar)"
+           -s (create sources .tar)
+           -c (copy .mdmg and src.tar to ${LPUBDIR}, if created)"
 fi
 
 # get the options
-while getopts ":fprms" OPT; do
+while getopts ":fprmsc" OPT; do
   case $OPT in
     f)
        UPMPORTS=TRUE >&2
        UPRKWARD=TRUE >&2
        MAKEMDMD=TRUE >&2
        MKSRCTAR=TRUE >&2
+       COPYMDMD=TRUE >&2
        ;;
     p) UPMPORTS=TRUE >&2 ;;
     r) UPRKWARD=TRUE >&2 ;;
     m) MAKEMDMD=TRUE >&2 ;;
     s) MKSRCTAR=TRUE >&2 ;;
+    c) COPYMDMD=TRUE >&2 ;;
     \?)
       echo "Invalid option: -$OPTARG" >&2
       exit 1
@@ -47,8 +54,8 @@
   sudo port selfupdate
   sudo port -v upgrade outdated
   # get rid of inactive stuff
-  sudo port uninstall inactive
   sudo port clean inactive
+  sudo port -f uninstall inactive
 fi
 
 # remove previous installation and its build left-overs
@@ -62,6 +69,16 @@
 # make meta-package including dependencies
 if [[ $MAKEMDMD ]] ; then
   sudo port -v mdmg $PTARGET
+  # copy the image file to a public directory
+  if [[ $COPYMDMD ]] ; then
+    # get version information of installed port
+    PORTVERS=$(port list $PTARGET | sed -e "s/.*@//;s/[[:space:]].*//")
+    MDMGFILE=${WORKDIR}/${PTARGET}-${PORTVERS}.dmg
+    TRGTFILE=${LPUBDIR}/${PTARGET}-${PORTVERS}_${SRCDATE}.dmg
+    echo "copying: $MDMGFILE to $TRGTFILE ..."
+    cp -av $MDMGFILE $TRGTFILE
+    echo "done."
+  fi
 fi
 
 # archive sources
@@ -69,7 +86,15 @@
   if [ -f $SRCFILE ] ; then
     rm $SRCFILE || exit 1
   fi
-  tar cvf $SRCFILE ${MPTINST}/var/macports/software || exit 1
+  tar cvf $SRCFILE ${MPTINST}/var/macports/distfiles || exit 1
+  # copy the source archive to a public directory
+  if [[ $COPYMDMD ]] ; then
+    PORTVERS=$(port list $PTARGET | sed -e "s/.*@//;s/[[:space:]].*//")
+    TRGSFILE=${LPUBDIR}/${PTARGET}-${PORTVERS}_${SRCDATE}_src.tar
+    echo "copying: $SRCFILE to $TRGSFILE ..."
+    cp -av $SRCFILE $TRGSFILE
+    echo "done."
+  fi
 fi
 
 exit 0

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.





More information about the rkward-tracker mailing list