Changeset 10262:2cdd88c3ea67 in orange


Ignore:
Timestamp:
02/16/12 15:47:24 (2 years ago)
Author:
ales_erjavec
Branch:
default
Message:

Backout of r9731(Using hg repo in mac osx bundle building scripts.)

Location:
install-scripts/mac
Files:
2 edited

Legend:

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

    r9731 r10262  
    1919    exit 2 
    2020fi 
    21  
    22 # Clone hg repo if not yet local. 
    23 if [ ! -e orange ]; then 
    24     hg clone https://bitbucket.org/biolab/orange 
    25 fi 
    26  
    27 cd orange 
    28 hg pull --update 
    29  
    30 if [ -e ../orange_archive ]; then 
    31     rm -rf ../orange_archive 
    32 fi 
    33  
    34 hg archive ../orange_archive 
    35 cd .. 
    36  
    37 ORANGE_REPO=`pwd`/orange 
    38 ORANGE_ARCHIVE=`pwd`/orange_archive 
    3921 
    4022# Defaults are current latest revisions in stable branch and trunk 
     
    5032    STABLE_REVISION=$STABLE_REVISION_2 
    5133fi 
    52  
    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 
    56  
    57 #DAILY_REVISION_2=${2:-`svn info --non-interactive http://orange.biolab.si/svn/orange/externals/trunk/ | grep 'Last Changed Rev:' | cut -d ' ' -f 4`} 
    58 ## svn info does not return proper exit status on an error so we check it this way 
    59 #[ "$DAILY_REVISION_2" ] || exit 4 
    60 #if [[ $DAILY_REVISION_1 -gt $DAILY_REVISION_2 ]]; then 
    61 #    DAILY_REVISION=$DAILY_REVISION_1 
    62 #else 
    63 #    DAILY_REVISION=$DAILY_REVISION_2 
    64 #fi 
     34DAILY_REVISION_1=${2:-`svn info --non-interactive http://orange.biolab.si/svn/orange/trunk/ | grep 'Last Changed Rev:' | cut -d ' ' -f 4`} 
     35# svn info does not return proper exit status on an error so we check it this way 
     36[ "$DAILY_REVISION_1" ] || exit 4 
     37DAILY_REVISION_2=${2:-`svn info --non-interactive http://orange.biolab.si/svn/orange/externals/trunk/ | grep 'Last Changed Rev:' | cut -d ' ' -f 4`} 
     38# svn info does not return proper exit status on an error so we check it this way 
     39[ "$DAILY_REVISION_2" ] || exit 4 
     40if [[ $DAILY_REVISION_1 -gt $DAILY_REVISION_2 ]]; then 
     41    DAILY_REVISION=$DAILY_REVISION_1 
     42else 
     43    DAILY_REVISION=$DAILY_REVISION_2 
     44fi 
    6545 
    6646echo "Preparing temporary directory." 
     
    7454export CXXFLAGS="-arch ppc -arch i386" 
    7555export LDFLAGS="-arch ppc -arch i386" 
    76  
    77  
    78 ########################### 
    79 # Stable orange-1.0  bundle 
    80 ########################### 
    8156 
    8257if [ ! -e /Volumes/download/orange-bundle-1.0b.$STABLE_REVISION.dmg ]; then 
     
    199174/Users/ailabc/mount-dirs.sh 
    200175 
    201 ######################### 
    202 # Daily orange 2.* bundle 
    203 ######################### 
    204  
    205 if [ ! -e /Volumes/download/orange-bundle-hg-0.0.$DAILY_REVISION.dmg ]; then 
     176if [ ! -e /Volumes/download/orange-bundle-svn-0.0.$DAILY_REVISION.dmg ]; then 
    206177    echo "Downloading bundle template." 
    207178    svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/externals/trunk/install-scripts/mac/bundle/ /private/tmp/bundle/ 
    208179     
    209     echo "Building and installing orange into the bundle." 
    210     cd $ORANGE_ARCHIVE 
    211     /private/tmp/bundle/Orange.app/Contents/MacOS/python setup.py install 
    212          
    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 
     180    echo "Downloading Orange daily source code revision $DAILY_REVISION." 
     181    svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/orange/ /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/ 
     182    svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/source/ /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/source/ 
     183    svn export --non-interactive --revision $DAILY_REVISION http://orange.biolab.si/svn/orange/trunk/add-ons/orngCRS/src/ /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/source/crs/ 
     184     
     185    [ -e /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/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/doc/COPYING 
     186    [ -e /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/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/doc/LICENSES 
     187     
     188    ln -s ../Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/ /private/tmp/bundle/Orange.app/Contents/Resources/orange 
     189    ln -s ../Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/doc/ /private/tmp/bundle/Orange.app/Contents/Resources/doc 
     190     
     191    echo "Compiling." 
     192    cd /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/source/ 
     193    make EXCLUDE_ORANGEQT=1 
     194    cd /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/source/crs/ 
     195    make 
     196    mv _orngCRS.so ../../ 
     197    cd /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/ 
     198     
     199    echo "Correcting install names for modules." 
     200    for module in *.so ; do 
     201        [ -L $module ] && continue 
     202         
     203        install_name_tool -id @executable_path/../Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange/$module $module 
     204         
     205        perl -MFile::Spec::Functions=abs2rel -e ' 
     206        for (`/usr/bin/otool -L -X $ARGV[0]`) { 
     207            next unless m|^\s+(/private/tmp/bundle/Orange.app/.*) \(.*\)$|; 
     208            system("/usr/bin/install_name_tool", "-change", $1, "\@loader_path/" . abs2rel($1), $ARGV[0]);  
     209        } 
     210        ' $module 
     211    done 
     212     
     213    echo "Cleaning up." 
     214    rm -rf source/ c45.dll liborange_include.a updateOrange.py 
    229215     
    230216    # 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 
     217    echo "orange" > /private/tmp/bundle/Orange.app/Contents/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/orange.pth 
     218     
    234219    for addon in $DAILY_ADDONS ; do 
    235220        echo "Downloading Orange add-on $addon daily source code revision $DAILY_REVISION." 
     
    260245        fi 
    261246         
    262 #       echo "Cleaning up." 
    263 #       rm -rf source/ setup.py 
     247        echo "Cleaning up." 
     248        rm -rf source/ setup.py 
    264249         
    265250        # Installation registration 
     
    297282     
    298283    echo "Converting temporary image to a compressed image." 
    299     rm -f /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg 
    300     hdiutil convert /private/tmp/bundle.dmg -format UDZO -imagekey zlib-level=9 -o /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg 
     284    rm -f /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg 
     285    hdiutil convert /private/tmp/bundle.dmg -format UDZO -imagekey zlib-level=9 -o /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg 
    301286     
    302287    echo "Cleaning up." 
     
    310295echo "Removing old versions of bundles." 
    311296# (Keeps last 5 versions.) 
    312 perl -e 'unlink ((reverse sort </Volumes/download/orange-bundle-hg-0*.dmg>)[5..10000])' 
     297perl -e 'unlink ((reverse sort </Volumes/download/orange-bundle-svn-0*.dmg>)[5..10000])' 
    313298perl -e 'unlink ((reverse sort </Volumes/download/orange-bundle-1*.dmg>)[5..10000])' 
    314299 
    315 if [ -e /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg ] || [ -e /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg ]; then 
     300if [ -e /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg ] || [ -e /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg ]; then 
    316301    echo "Moving bundles to the download directory." 
    317302    [ -e /private/tmp/orange-bundle-1.0b.$STABLE_REVISION.dmg ] && mv /private/tmp/orange-bundle-1.0b.$STABLE_REVISION.dmg /Volumes/download/ 
    318     [ -e /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg ] && mv /private/tmp/orange-bundle-hg-0.0.$DAILY_REVISION.dmg /Volumes/download/ 
     303    [ -e /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg ] && mv /private/tmp/orange-bundle-svn-0.0.$DAILY_REVISION.dmg /Volumes/download/ 
    319304     
    320305    echo "Setting permissions." 
    321306    chmod +r /Volumes/download/orange-bundle-1.0b.$STABLE_REVISION.dmg 
    322     chmod +r /Volumes/download/orange-bundle-hg-0.0.$DAILY_REVISION.dmg 
    323  
    324 # Don't register the bundles until hg version stabilizes 
    325      
    326 #   echo "Registering new bundles." 
    327 #   egrep -v '^(MAC_STABLE|MAC_DAILY)=' /Volumes/download/filenames_mac.set > /Volumes/download/filenames_mac.set.new 
    328 #   echo "MAC_STABLE=orange-bundle-1.0b.$STABLE_REVISION.dmg" >> /Volumes/download/filenames_mac.set.new 
    329 #   echo "MAC_DAILY=orange-bundle-svn-0.0.$DAILY_REVISION.dmg" >> /Volumes/download/filenames_mac.set.new 
    330 #   mv /Volumes/download/filenames_mac.set.new /Volumes/download/filenames_mac.set 
    331 fi 
     307    chmod +r /Volumes/download/orange-bundle-svn-0.0.$DAILY_REVISION.dmg 
     308     
     309    echo "Registering new bundles." 
     310    egrep -v '^(MAC_STABLE|MAC_DAILY)=' /Volumes/download/filenames_mac.set > /Volumes/download/filenames_mac.set.new 
     311    echo "MAC_STABLE=orange-bundle-1.0b.$STABLE_REVISION.dmg" >> /Volumes/download/filenames_mac.set.new 
     312    echo "MAC_DAILY=orange-bundle-svn-0.0.$DAILY_REVISION.dmg" >> /Volumes/download/filenames_mac.set.new 
     313    mv /Volumes/download/filenames_mac.set.new /Volumes/download/filenames_mac.set 
     314fi 
  • install-scripts/mac/update-all-scripts.sh

    r9731 r10262  
    44# 
    55 
    6 # Clone the orange repo if not already present 
    7 if [ ! -e orange ]; then 
    8     hg clone https://bitbucket.org/biolab/orange 
    9 fi 
    10  
    11 # Pull all changesets and update to latest 
    12 cd orange 
    13 hg pull --update 
    14 cd .. 
    15  
    16 cp orange/install-scripts/mac/update-all-scripts.sh ./ 
    17 cp orange/install-scripts/mac/bundle-64bit-daily-build.sh ./ 
    18 cp orange/install-scripts/mac/bundle-daily-build.sh ./ 
    19 cp orange/install-scripts/mac/dailyrun.sh ./ 
    20 cp orange/install-scripts/mac/dailyrun-finkonly-withsource.sh ./ 
    21 cp orange/install-scripts/mac/dailyrun-finkonly.sh ./ 
    22 cp orange/install-scripts/mac/dailyrun-bundleonly.sh ./ 
    23 cp orange/install-scripts/mac/fink-daily-build.sh ./ 
    24 cp orange/install-scripts/mac/fink-restore-selections.sh ./ 
    25 cp orange/install-scripts/mac/fink-selfupdate-orange.sh ./ 
    26 cp orange/install-scripts/mac/force-fink-daily-build.sh ./ 
    27 cp orange/install-scripts/mac/mount-dirs.sh ./ 
     6curl --silent --output update-all-scripts.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/update-all-scripts.sh 
     7curl --silent --output bundle-64bit-daily-build.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/bundle-64bit-daily-build.sh 
     8curl --silent --output bundle-daily-build.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/bundle-daily-build.sh 
     9curl --silent --output dailyrun.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/dailyrun.sh 
     10curl --silent --output dailyrun-finkonly-withsource.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/dailyrun-finkonly-withsource.sh 
     11curl --silent --output dailyrun-finkonly.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/dailyrun-finkonly.sh 
     12curl --silent --output dailyrun-bundleonly.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/dailyrun-bundleonly.sh 
     13curl --silent --output fink-daily-build.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/fink-daily-build.sh 
     14curl --silent --output fink-restore-selections.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/fink-restore-selections.sh 
     15curl --silent --output fink-selfupdate-orange.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/fink-selfupdate-orange.sh 
     16curl --silent --output force-fink-daily-build.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/force-fink-daily-build.sh 
     17curl --silent --output mount-dirs.sh http://orange.biolab.si/svn/orange/trunk/install-scripts/mac/mount-dirs.sh 
    2818 
    2919chmod +x *.sh 
Note: See TracChangeset for help on using the changeset viewer.