diff options
author | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2008-08-14 17:41:19 +0000 |
---|---|---|
committer | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2008-08-14 17:41:19 +0000 |
commit | 8e4cc7c19066c82a091dc66bd8ce79bce16e830d (patch) | |
tree | fa125c2ca08ed43f3cd10408039e6e65f57cd803 /scripts | |
parent | 5466d3284b7a2685c1e0d120b47b3fe2ecd550b5 (diff) |
merged in changes from the v0-40 pd-extended release branch
svn path=/trunk/; revision=10244
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/auto-build/tcltk_core-8-4-branch_auto-builder.sh | 4 | ||||
-rwxr-xr-x | scripts/generate-pd-settings-files.sh | 115 | ||||
-rwxr-xr-x | scripts/insert_declare.py | 31 | ||||
-rwxr-xr-x | scripts/update-developer-layout.sh | 2 |
4 files changed, 113 insertions, 39 deletions
diff --git a/scripts/auto-build/tcltk_core-8-4-branch_auto-builder.sh b/scripts/auto-build/tcltk_core-8-4-branch_auto-builder.sh index c0f0d572..64b3c158 100755 --- a/scripts/auto-build/tcltk_core-8-4-branch_auto-builder.sh +++ b/scripts/auto-build/tcltk_core-8-4-branch_auto-builder.sh @@ -28,8 +28,8 @@ case $SYSTEM in BUILD_DIR=macosx echo "Configuring to use $BUILD_DIR on Darwin/Mac OS X" export PATH=/bin:/sbin:/usr/bin:/usr/sbin - export CFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 \ - -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4" +# export CFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 \ +# -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4" make -C tcl/${BUILD_DIR} deploy make -C tk/${BUILD_DIR} deploy ;; diff --git a/scripts/generate-pd-settings-files.sh b/scripts/generate-pd-settings-files.sh index 6078716e..e7a744ca 100755 --- a/scripts/generate-pd-settings-files.sh +++ b/scripts/generate-pd-settings-files.sh @@ -1,11 +1,18 @@ #!/bin/sh -LIBS="libdir Gem cyclone zexy creb cxc iemlib list-abs mapping markex maxlib memento mjlib motex oscx pddp pdogg pixeltango pmpd rradical sigpack smlib toxy unauthorized vbap pan freeverb hcs jmmmp ext13 hardware ggee iem_anything flib ekext flatspace deprecated pdp pidip" +LIBS="libdir Gem cyclone zexy creb cxc iemlib list-abs mapping markex maxlib memento mjlib motex oscx pddp pdogg pixeltango pmpd rradical sigpack smlib toxy unauthorized vbap pan freeverb hcs jmmmp ext13 ggee iem_anything flib ekext flatspace pdp pidip" -GNULINUX_FONTPATH="~/pd /usr/share/pd /var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType" +GNULINUX_FONTPATH="~/pd-externals /usr/local/lib/pd-externals /var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType" MACOSX_FONTPATH="~/Library/Pd /Library/Pd /System/Library/Fonts /Library/Fonts ~/Library/Fonts /usr/X11R6/lib/X11/fonts/TTF /System/Library/Frameworks/JavaVM.framework/Versions/1.3.1/Home/lib/fonts /sw/lib/X11/fonts/msttf /sw/lib/X11/fonts/intl/TrueType /sw/lib/X11/fonts/applettf" -# TODO this needs to be changed to add to a user dir like %USERPROFILE% (like /Library/Pd) -WINDOWS_FONTPATH="hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,00,2f,00,46,00,6f,00,6e,00,74,00,73,00,00,00" +# these are set as hex(2) since the .reg format doesn't support REG_EXPAND_SZ. +# Inno Setup doesn't convert REG_SZ hex values to REG_EXPAND_SZ, so Pd can't +# read the values then. Therefore there is a separate set for InnoSetup to +# use to create REG_EXPAND_SZ VALUES +# path1 = %USERPROFILE%/Application Data/Pd +# path2 = %ProgramFiles%/Common Files/Pd +# path3 = %SystemRoot%/Fonts +WINDOWS_INNO_PATH="%USERPROFILE%/Application Data/Pd;%ProgramFiles%/Common Files/Pd;%SystemRoot%/Fonts" +WINDOWS_REG_PATH="hex(2):25,00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,00,69,00,6c,00,65,00,73,00,25,00,2f,00,43,00,6f,00,6d,00,6d,00,6f,00,6e,00,20,00,46,00,69,00,6c,00,65,00,73,00,2f,00,50,00,64,00,00,00 hex(2):25,00,55,00,53,00,45,00,52,00,50,00,52,00,4f,00,46,00,49,00,4c,00,45,00,25,00,2f,00,41,00,70,00,70,00,6c,00,69,00,63,00,61,00,74,00,69,00,6f,00,6e,00,20,00,44,00,61,00,74,00,61,00,2f,00,50,00,64,00,00,00 hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,00,2f,00,46,00,6f,00,6e,00,74,00,73,00,00,00" SCRIPT_DIR=`echo $0 | sed 's|\(.*\)/.*$|\1|'` ROOT_DIR=${SCRIPT_DIR}/../packages @@ -13,12 +20,13 @@ ROOT_DIR=${SCRIPT_DIR}/../packages GNULINUX_FILE=${ROOT_DIR}/linux_make/default.pdsettings MACOSX_FILE=${ROOT_DIR}/darwin_app/org.puredata.pd.default.plist WINDOWS_FILE=${ROOT_DIR}/win32_inno/pd-settings.reg -WINDOWS_INNO_FILE=${ROOT_DIR}/win32_inno/pd-inno.registry.reg +WINDOWS_INNO_FILE=${ROOT_DIR}/win32_inno/pd-inno.iss.in +WINDOWS_INNO_REG_FILE=${ROOT_DIR}/win32_inno/pd-inno.registry.reg -GNULINUX_HEADER='standardpath: 1\nverbose: 0\ndefeatrt: 0\nflags: -helppath /usr/share/pd' +GNULINUX_HEADER='standardpath: 1\nverbose: 0\ndefeatrt: 0\nflags: -helppath ~/pd -helppath /usr/share/pd' -MACOSX_HEADER='<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">\n<plist version="1.0">\n<dict>\n\t<key>defeatrt</key>\n\t<string>0</string>\n\t<key>flags</key>\n\t<string>-helppath /Library/Pd</string>' +MACOSX_HEADER='<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">\n<plist version="1.0">\n<dict>\n\t<key>defeatrt</key>\n\t<string>0</string>\n\t<key>flags</key>\n\t<string>-helppath ~/Library/Pd -helppath /Library/Pd</string>' MACOSX_FOOTER='</dict>\n </plist>\n' @@ -30,12 +38,6 @@ WINDOWS_HEADER='Windows Registry Editor Version 5.00\n\n[HKEY_LOCAL_MACHINE\SOFT WINDOWS_INNO_HEADER='' -echo -e $GNULINUX_HEADER > $GNULINUX_FILE -echo -e $MACOSX_HEADER > $MACOSX_FILE -echo -e $WINDOWS_HEADER > $WINDOWS_FILE -echo -e $WINDOWS_INNO_HEADER > $WINDOWS_INNO_FILE - - # GNU/Linux -------------------------------------------------------------------# print_gnulinux () { @@ -45,6 +47,7 @@ print_gnulinux () print_gnulinux_fontpath () { i=0 + IFS=' ' for fontpath in $GNULINUX_FONTPATH; do ((++i)) echo "path${i}: ${fontpath}" >> $GNULINUX_FILE @@ -67,6 +70,7 @@ print_macosx () print_macosx_fontpath () { i=0 + IFS=' ' for fontpath in $MACOSX_FONTPATH; do ((++i)) echo -e "\t<key>path${i}</key>" >> $MACOSX_FILE @@ -86,36 +90,67 @@ print_macosx_nloadlib () print_windows () { echo "\"loadlib$1\"=\"$2\"" >> $WINDOWS_FILE - echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: loadlib$1; ValueData: $2; Tasks: libs" >> $WINDOWS_INNO_FILE + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: loadlib$1; ValueData: $2; Tasks: libs" >> $WINDOWS_INNO_REG_FILE } -print_windows_fontpath () +print_windows_delete () { - j=0 - for fontpath in $WINDOWS_FONTPATH; do - ((++j)) - echo "\"path${j}\"=${fontpath}" >> $WINDOWS_FILE - echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: path${j}; ValueData: ${fontpath}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_FILE - done - echo "\"npath\"=${j}" >> $WINDOWS_FILE - echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: npath; ValueData: ${j}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_FILE + echo "\"${1}${2}\"=-" >> $WINDOWS_FILE + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: none; ValueName: ${1}${2}; Flags: deletevalue; Tasks: libs" >> $WINDOWS_INNO_REG_FILE } -print_windows_delete () +print_windows_helppath () { - echo "\"${1}${2}\"=-" >> $WINDOWS_FILE - echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: none; ValueName: ${1}${2}; Flags: deletevalue; Tasks: libs" >> $WINDOWS_INNO_FILE + echo "\"flags\"=\"-helppath %UserProfile%/applic~1/Pd -helppath %ProgramFiles%/common~1/pd\"" >> $WINDOWS_FILE + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: flags; ValueData: -helppath %UserProfile%/applic~1/Pd -helppath %ProgramFiles%/common~1/pd; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_REG_FILE +} + +print_windows_inno_path () +{ + j=0 + IFS=';' + for fontpath in $WINDOWS_INNO_PATH; do + ((++j)) + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: expandsz; ValueName: path${j}; ValueData: ${fontpath}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_REG_FILE + done + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: npath; ValueData: ${j}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_REG_FILE +# print lines to delete existing path flags + echo "; delete all existing path flags" >> $WINDOWS_FILE + while [ $j -lt 100 ]; do + ((++j)) + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: none; ValueName: path${j}; Flags: deletevalue; Tasks: libs" >> $WINDOWS_INNO_REG_FILE + done +} + +print_windows_reg_path () +{ + j=0 + IFS=' ' + for fontpath in $WINDOWS_REG_PATH; do + ((++j)) + echo "\"path${j}\"=${fontpath}" >> $WINDOWS_FILE + done + echo "\"npath\"=${j}" >> $WINDOWS_FILE +# print lines to delete existing path flags + echo "; delete all existing path flags" >> $WINDOWS_FILE + while [ $j -lt 100 ]; do + ((++j)) + echo "\"path${j}\"=-" >> $WINDOWS_FILE + done } print_windows_nloadlib () { echo "\"nloadlib\"=${1}" >> $WINDOWS_FILE - echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: nloadlib; ValueData: ${1}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_FILE + echo "Root: HKLM; SubKey: SOFTWARE\Pd; ValueType: string; ValueName: nloadlib; ValueData: ${1}; Tasks: libs; Flags: uninsdeletekey" >> $WINDOWS_INNO_REG_FILE } #==============================================================================# echo "Running for GNU/Linux and Darwin:" +echo -e $GNULINUX_HEADER > $GNULINUX_FILE +echo -e $MACOSX_HEADER > $MACOSX_FILE i=0 +IFS=' ' for lib in $LIBS; do ((++i)) echo -n "$lib " @@ -129,7 +164,14 @@ print_macosx_nloadlib $i # run separately so some libs can be excluded on Windows echo "Running for Windows:" + +echo -e $WINDOWS_HEADER > $WINDOWS_FILE +echo -e $WINDOWS_INNO_HEADER > $WINDOWS_INNO_REG_FILE + +print_windows_helppath + i=0 +IFS=' ' for lib in $LIBS; do case "$lib" in pdp) echo -n "(ignoring $lib on Windows) " ;; @@ -151,15 +193,16 @@ while [ $i -lt 100 ]; do print_windows_delete loadlib $i done -print_windows_fontpath - -# print lines to delete existing path flags -i=1 -echo "; delete all existing path flags" >> $WINDOWS_FILE -while [ $i -lt 100 ]; do - ((++i)) - print_windows_delete path $i -done +print_windows_reg_path +print_windows_inno_path +# +TMPFILE=$WINDOWS_INNO_FILE.`date +%s` +head -`grep -n "STARTHERE" $WINDOWS_INNO_FILE | cut -d ':' -f 1` $WINDOWS_INNO_FILE > $TMPFILE +cat $WINDOWS_INNO_REG_FILE >> $TMPFILE +FILE_LENGTH=`wc -l $WINDOWS_INNO_FILE | cut -d ' ' -f 1` +END_LENGTH=`grep -n "ENDHERE" $WINDOWS_INNO_FILE | cut -d ':' -f 1` +tail -`expr $FILE_LENGTH - $END_LENGTH` $WINDOWS_INNO_FILE >> $TMPFILE +mv -f -- $TMPFILE $WINDOWS_INNO_FILE # the .pd-settings file needs an end tag for the path statements print_gnulinux_fontpath diff --git a/scripts/insert_declare.py b/scripts/insert_declare.py new file mode 100755 index 00000000..025d0a23 --- /dev/null +++ b/scripts/insert_declare.py @@ -0,0 +1,31 @@ +#!/usr/bin/python + +import string +import os,sys +import re +import StringIO + +library = os.getcwd().split('/')[-1] + +print "current library: " + library + "\n" + +for root, dirs, files in os.walk('.'): + dirs.remove('.svn') +# print "root: " + root + for name in files: + m = re.search(".*-help\.pd$", name) + if m: + helppatch = os.path.join(root, m.string) + fd = open(helppatch, 'r') + contents = fd.readlines() + fd.close() + firstline = contents[0] + contents.remove(firstline) +# fd = open(helppatch + ".new", 'w') + print helppatch + fd = open(helppatch, 'w') + fd.write(firstline) + fd.write("#X declare -lib " + library.lower() + ";\n") + fd.writelines(contents) + fd.close() + diff --git a/scripts/update-developer-layout.sh b/scripts/update-developer-layout.sh index 6364ad10..e9e3d7e5 100755 --- a/scripts/update-developer-layout.sh +++ b/scripts/update-developer-layout.sh @@ -16,7 +16,7 @@ cd $cvs_root_dir echo "Running svn update:" svn update echo "Running cvs update:" -for section in Gem GemLibs; do +for section in Gem; do echo "$section" cd $section cvs up -Pd |