Changeset 9774:95e6cdc3fe1e in orange


Ignore:
Timestamp:
02/06/12 17:13:27 (2 years ago)
Author:
ales_erjavec
Branch:
default
Children:
9775:68401a9db09c, 10260:5d6203d6bf91
rebase_source:
a370fb8a5cfd254b95fbc3de8331f10a9f4fba32
Message:

Using hg repos for daily addons.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • install-scripts/mac/bundle-daily-build.sh

    r9731 r9774  
    88# Lists of add-ons to include 
    99STABLE_ADDONS="" 
    10 DAILY_ADDONS="Bioinformatics Text" 
     10DAILY_ADDONS="bioinformatics text" 
    1111 
    1212# Sets error handler 
     
    2020fi 
    2121 
    22 # Clone hg repo if not yet local. 
     22# Clone hg repos if not yet local. 
    2323if [ ! -e orange ]; then 
    2424    hg clone https://bitbucket.org/biolab/orange 
     
    3333 
    3434hg archive ../orange_archive 
     35 
     36DAILY_REVISION_1=`hg log -l1 daily | grep 'changeset:' | cut -d ' ' -f 4 | cut -d ':' -f 1` 
     37 
    3538cd .. 
    3639 
    37 ORANGE_REPO=`pwd`/orange 
     40 
     41for addon in $DAILY_ADDONS ; do 
     42    if [ ! -e $addon ]; then 
     43        hg clone https://bitbucket.org/biolab/orange-addon-$addon $addon 
     44    fi 
     45 
     46    cd $addon 
     47    hg pull --update 
     48     
     49    # This is where the addons will be build, so they don't  
     50    # pollute the hg repos 
     51    if [ -e ../${addon}_archive ]; then 
     52        rm -rf ../${addon}_archive 
     53    fi 
     54 
     55    hg archive ../${addon}_archive 
     56     
     57    cd .. 
     58done 
     59 
     60 
    3861ORANGE_ARCHIVE=`pwd`/orange_archive 
    3962 
     
    5174fi 
    5275 
    53 DAILY_REVISION_1 = `hg log -l1 daily | grep 'changeset:' | cut -d ' ' -f 4 | cut -d ':' -f 1` 
    54  
    55 #TODO: versions of hg and svn repos are no longer in sync 
     76 
     77# versions of hg and svn repos are no longer in sync 
    5678 
    5779#DAILY_REVISION_2=${2:-`svn info --non-interactive http://orange.biolab.si/svn/orange/externals/trunk/ | grep 'Last Changed Rev:' | cut -d ' ' -f 4`} 
     
    211233    /private/tmp/bundle/Orange.app/Contents/MacOS/python setup.py install 
    212234         
    213 #   echo "Correcting install names for modules." 
    214 #   for module in *.so ; do 
    215 #       [ -L $module ] && continue 
    216 #        
    217 #       install_name_tool -id @executable_path/../Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/$module $module 
    218 #        
    219 #       perl -MFile::Spec::Functions=abs2rel -e ' 
    220 #       for (`/usr/bin/otool -L -X $ARGV[0]`) { 
    221 #           next unless m|^\s+(/private/tmp/bundle/Orange.app/.*) \(.*\)$|; 
    222 #           system("/usr/bin/install_name_tool", "-change", $1, "\@loader_path/" . abs2rel($1), $ARGV[0]);  
    223 #       } 
    224 #       ' $module 
    225 #   done 
    226      
    227 #   echo "Cleaning up." 
    228 #   rm -rf source/ c45.dll liborange_include.a updateOrange.py 
    229      
    230     # Installation registration 
    231 #   echo "orange" > /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange.pth 
    232      
    233     # TODO: hg repos for addons 
    234235    for addon in $DAILY_ADDONS ; do 
    235         echo "Downloading Orange add-on $addon daily source code revision $DAILY_REVISION." 
    236         svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/add-ons/$addon/ /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/ 
    237          
    238         [ -e /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/doc/COPYING ] || svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/COPYING /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/doc/COPYING 
    239         [ -e /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/doc/LICENSES ] || svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/LICENSES /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/doc/LICENSES 
    240          
    241         if [ -e /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/source/ ]; then 
    242             echo "Compiling add-on." 
    243             cd /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/source/ 
    244             make 
    245             cd /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/ 
    246              
    247             echo "Correcting install names for modules." 
    248             for module in *.so ; do 
    249                 [ -L $module ] && continue 
    250              
    251                 install_name_tool -id @executable_path/../Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/add-ons/$addon/$module $module 
    252                  
    253                 perl -MFile::Spec::Functions=abs2rel -e ' 
    254                 for (`/usr/bin/otool -L -X $ARGV[0]`) { 
    255                     next unless m|^\s+(/private/tmp/bundle/Orange.app/.*) \(.*\)$|; 
    256                     system("/usr/bin/install_name_tool", "-change", $1, "\@loader_path/" . abs2rel($1), $ARGV[0]);  
    257                 } 
    258                 ' $module 
    259             done 
    260         fi 
    261          
    262 #       echo "Cleaning up." 
    263 #       rm -rf source/ setup.py 
    264          
    265         # Installation registration 
    266         echo "orange/add-ons/$addon" > /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange-`echo $addon | tr "[:upper:]" "[:lower:]"`.pth 
     236        cd $REPO_DIR/${addon}_archive 
     237        echo "Building $addon addon." 
     238        /private/tmp/bundle/Orange.app/Contents/MacOS/python setup.py install 
     239         
    267240    done 
    268241     
Note: See TracChangeset for help on using the changeset viewer.