Changeset 24354
- Timestamp:
- 07/15/2008 08:34:17 AM (5 months ago)
- Files:
-
- trunk/Utilities/dep-build-scripts/copy_frameworks.sh (modified) (1 diff)
- trunk/Utilities/dep-build-scripts/make_po_files.sh (modified) (1 diff)
- trunk/Utilities/dep-build-scripts/purple_make.sh (modified) (8 diffs)
- trunk/Utilities/dep-build-scripts/README (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/Utilities/dep-build-scripts/copy_frameworks.sh
r24050 r24354 4 4 cp -r "`dirname $0`"/build/Frameworks/*.framework "$ADIUM/Frameworks/" 5 5 6 pushd "$ADIUM/build" 6 pushd "$ADIUM/build" > /dev/null 2>&1 7 7 rm -rf */AdiumLibpurple.framework 8 8 rm -rf */*/Adium.app/Contents/Frameworks/lib* 9 popd 9 popd > /dev/null 2>&1 10 11 echo "Done - now build Adium" trunk/Utilities/dep-build-scripts/make_po_files.sh
r23823 r24354 28 28 popd 29 29 30 echo "Done - now run ./copy_frameworks.sh" trunk/Utilities/dep-build-scripts/purple_make.sh
r24243 r24354 5 5 cd "$BUILDDIR" 6 6 7 # Note that msn-pecan needs the --enable-msnp14 flag 8 MSN=msn_pecan 9 10 DEBUG_SYMBOLS=TRUE 11 PROTOCOLS="bonjour gg irc jabber $MSN myspace novell oscar qq sametime simple yahoo zephyr" 12 13 if [ "x$PIDGIN_SOURCE" == "x" ] ; then 7 if [ "x$PIDGIN_SOURCE" = "x" ] ; then 14 8 echo 'Error: you need to set PIDGIN_SOURCE to be the location of' \ 15 9 'your pidgin source tree.' … … 19 13 echo "Using Pidgin source from: $PIDGIN_SOURCE" 20 14 21 # Apply our openssl patch - enables using OpenSSL and allows libgadu with SSL 22 # support. This is OK because OpenSSL is part of the base system on OS X. 15 # Read in our parameters 16 MSN=msn_pecan 17 USER_REGENERATE=FALSE 18 ARCHES=(ppc i386) 19 while [ $# -gt 0 ] ; do 20 case $1 in 21 --regenerate) 22 USER_REGENERATE=TRUE 23 shift 1 24 ;; 25 --msn-pecan) 26 # Note that msn-pecan needs the --enable-msnp14 flag 27 MSN=msn_pecan 28 shift 1 29 ;; 30 --msn) 31 MSN=msn 32 shift 1 33 ;; 34 --ppc) 35 ARCHES=(ppc) 36 shift 1 37 ;; 38 --i386) 39 ARCHES=(i386) 40 shift 1 41 ;; 42 *) 43 echo "Invalid argument: $1" 44 shift 1 45 ;; 46 esac 47 done 48 49 DEBUG_SYMBOLS=TRUE 50 PROTOCOLS="bonjour gg irc jabber $MSN myspace novell oscar qq sametime simple yahoo zephyr" 23 51 24 52 pushd $PIDGIN_SOURCE > /dev/null 2>&1 … … 55 83 "$PATCHDIR/libpurple_xmlnode_parser_error_handler.diff" \ 56 84 "$PATCHDIR/libpurple_zephyr_fix_krb4_flags.diff" \ 57 "$PATCHDIR/libpurple_static_for_msn_pecan.diff" \58 85 "$PATCHDIR/libpurple_jabber_use_builtin_digestmd5.diff" \ 59 86 "$PATCHDIR/libpurple_jabber_fallback_to_auth_old_after_gssapi_only_fails.diff" \ 60 87 "$PATCHDIR/libpurple_jabber_roster_debug.diff") 88 89 ## 90 # msn-pecan specific patches 91 ## 92 if [ x"$MSN" = x"msn_pecan" ] ; then 93 LIBPURPLE_PATCHES=( \ 94 ${LIBPURPLE_PATCHES[@]} \ 95 "$PATCHDIR/libpurple_static_for_msn_pecan.diff" \ 96 ) 97 fi 61 98 62 99 for patch in ${LIBPURPLE_PATCHES[@]} ; do … … 66 103 popd > /dev/null 2>&1 67 104 68 for ARCH in ppc i386 ; do 105 ### 106 # These files are overwritten during each build, which prevents us from 107 # performing incremental builds. 108 # 109 # This list was generated by a DTrace script that watched files being written 110 # to during a build of each architecture. I then narrowed the list to only the 111 # files that were written during BOTH builds. 112 # 113 # It should be confirmed that these files all need to be copied. 114 # 115 # -- Ryan Govostes, July 15 '08 116 ## 117 AUTOGEN_GREMLINS=("autom4te.cache" \ 118 "config.guess" \ 119 "config.sub" \ 120 "configure" \ 121 "intltool-extract.in" \ 122 "intltool-merge.in" \ 123 "intltool-update.in" \ 124 "ltmain.sh" \ 125 "mkinstalldirs" \ 126 "po/Makefile.in.in" \ 127 ) 128 129 for ARCH in $ARCHES ; do 69 130 case $ARCH in 70 131 ppc) export HOST=powerpc-apple-darwin9 … … 85 146 86 147 #Note that whether we use openssl or cdsa the same underlying workarounds (as seen in jabber.c, only usage at present 12/07) are needed 87 export CFLAGS="$BASE_CFLAGS -arch $ARCH -I$TARGET_DIR/include -I$SDK_ROOT/usr/include/kerberosIV -DHAVE_SSL -DHAVE_OPENSSL -fno-common -DLIBPURPLE_NEW_API " 148 export CFLAGS="$BASE_CFLAGS -arch $ARCH -I$TARGET_DIR/include -I$SDK_ROOT/usr/include/kerberosIV -DHAVE_SSL -DHAVE_OPENSSL -fno-common " 149 if [ x"$MSN" = x"msn_pecan" ] ; then 150 export CFLAGS="$CFLAGS -DLIBPURPLE_NEW_API " 151 fi 88 152 89 153 if [ "$DEBUG_SYMBOLS" = "TRUE" ] ; then … … 101 165 echo LDFLAGS is $LDFLAGS 102 166 echo PKG_CONFIG is $PKG_CONFIG 103 104 # this part is really ew. We actually re-run autogen.sh per-arch. 105 # we pass configure --help so that it bails out and doesn't fubar the source 106 # tree, because otherwise we'd have to un-configure it. Stupid autotools. 107 pushd $PIDGIN_SOURCE > /dev/null 2>&1 108 ./autogen.sh --help 109 popd > /dev/null 2>&1 167 110 168 # we don't need pkg-config for this 111 169 export LIBXML_CFLAGS='-I/usr/include/libxml2' … … 115 173 export MEANWHILE_CFLAGS="-I$TARGET_DIR/include/meanwhile -I$TARGET_DIR/include/glib-2.0 -I$TARGET_DIR/lib/glib-2.0/include" 116 174 export MEANWHILE_LIBS="-lmeanwhile -lglib-2.0 -liconv" 117 118 $PIDGIN_SOURCE/configure \ 119 --disable-gtkui --disable-consoleui \ 120 --disable-perl \ 121 --enable-debug \ 122 --disable-static --enable-shared \ 123 --with-krb4 \ 124 --enable-cyrus-sasl \ 125 --prefix=$TARGET_DIR \ 126 --enable-msnp14 \ 127 --with-static-prpls="$PROTOCOLS" --disable-plugins \ 128 --host=$HOST \ 129 --disable-gstreamer \ 130 --disable-avahi \ 131 --disable-dbus \ 132 --enable-gnutls=no --enable-nss=no --enable-openssl=no $@ 175 176 # If we're trying to use files we generated previously, make sure they're there 177 FORCE_REGENERATE="$USER_REGENERATE" 178 if [ x"$FORCE_REGENERATE" = x"FALSE" ] ; then 179 if [ ! -e ./Makefile ] ; then 180 echo "Makefile not found; forcing regenerate" 181 FORCE_REGENERATE=TRUE 182 fi 183 if [ ! -e ./config.status ] ; then 184 echo "config.status not found; forcing regenerate" 185 FORCE_REGENERATE=TRUE 186 fi 187 if [ ! -d ./autogen_cache ] ; then 188 echo "autogen_cache not found; forcing regenerate" 189 FORCE_REGENERATE=TRUE 190 else 191 pushd autogen_cache > /dev/null 2>&1 192 for file in ${AUTOGEN_GREMLINS[@]} ; do 193 if [ ! -e $file ] ; then 194 echo "autogen_cache/$file not found; forcing regenerate" 195 FORCE_REGENERATE=TRUE 196 break 197 fi 198 done 199 popd > /dev/null 2>&1 200 fi 201 fi 202 203 # We only need to autogen if building from scratch or it's requested 204 if [ x"$FORCE_REGENERATE" = x"TRUE" ] ; then 205 pushd $PIDGIN_SOURCE > /dev/null 2>&1 206 ./autogen.sh --help 207 popd > /dev/null 2>&1 208 209 $PIDGIN_SOURCE/configure \ 210 --disable-gtkui --disable-consoleui \ 211 --disable-perl \ 212 --enable-debug \ 213 --disable-static --enable-shared \ 214 --with-krb4 \ 215 --enable-cyrus-sasl \ 216 --prefix=$TARGET_DIR \ 217 --enable-msnp14 \ 218 --with-static-prpls="$PROTOCOLS" --disable-plugins \ 219 --host=$HOST \ 220 --disable-gstreamer \ 221 --disable-avahi \ 222 --disable-dbus \ 223 --enable-gnutls=no --enable-nss=no --enable-openssl=no $@ 224 else 225 echo "Restoring files from previous build" 226 for file in ${AUTOGEN_GREMLINS[@]} ; do 227 cp -pRv autogen_cache/$file $PIDGIN_SOURCE/`dirname $file` 228 done 229 fi 230 133 231 pushd libpurple > /dev/null 2>&1 134 232 make -j $NUMBER_OF_CORES && make install 135 233 popd > /dev/null 2>&1 136 popd 234 235 # Now save the files for later 236 echo "Rescuing files for subsequent builds" 237 rm -Rf ./autogen_cache || true 238 mkdir autogen_cache 239 pushd autogen_cache > /dev/null 2>&1 240 for file in ${AUTOGEN_GREMLINS[@]} ; do 241 if [ x`dirname $file` != x"." ] ; then 242 mkdir `dirname $file` || true 243 fi 244 cp -pRv $PIDGIN_SOURCE/$file `dirname $file` || true 245 done 246 popd > /dev/null 2>&1 247 248 popd > /dev/null 2>&1 249 137 250 # HACK ALERT! We use the following internal-only headers: 138 251 cp $PIDGIN_SOURCE/libpurple/protocols/oscar/oscar.h \ … … 157 270 pushd $PIDGIN_SOURCE > /dev/null 2>&1 158 271 for patch in ${LIBPURPLE_PATCHES[@]} ; do 272 echo "Reverting $patch" 159 273 patch -R -p0 < $patch || true 160 274 done trunk/Utilities/dep-build-scripts/README
r24279 r24354 12 12 Alternatively, you can substitute curl and xargs: 13 13 14 $ (mkdir source || true) && cd source && (cat ../urls.txt | xargs -I %url%\15 curl -LO %url%) && (ls -1 *.tar.gz | xargs -I %file% tar xzf %file%) &&\16 (ls -1 *.tar.bz2 | xargs -I %file% tar xjf %file%) && rm -f *.tar.* &&cd ..14 $ mkdir source; cd source; (cat ../urls.txt | xargs -I %url% curl -LO %url%) \ 15 && (ls -1 *.tar.gz | xargs -I %file% tar xzf %file%) && (ls -1 *.tar.bz2 | \ 16 xargs -I %file% tar xjf %file%); rm -f *.tar.*; cd .. 17 17 18 18 … … 20 20 21 21 The Pidgin source is not installed by the download script. Adium currently uses 22 libpurple 2.4. 2mtn from branch im.pidgin.pidgin. Patches applied during the22 libpurple 2.4.3mtn from branch im.pidgin.pidgin. Patches applied during the 23 23 build process expect this version. 24 24 … … 34 34 process. Please note that this file is nearly 200 MB. 35 35 36 $ cd source; (mkdir im.pidgin.pidgin || true); cd im.pidgin.pidgin; curl -LO \37 http://developer.pidgin.im/static/pidgin.mtn.bz2 ; bzip2 -d pidgin.mtn.bz2;\38 mtn db -d pidgin.mtn migrate; mtn -d pidgin.mtn pull --set-default pidgin.im\39 "im.pidgin.*";mtn -d pidgin.mtn co -b im.pidgin.pidgin .; cd ../..36 $ cd source; mkdir im.pidgin.pidgin; cd im.pidgin.pidgin; curl -LO \ 37 http://developer.pidgin.im/static/pidgin.mtn.bz2 && bzip2 -d pidgin.mtn.bz2 \ 38 && mtn db -d pidgin.mtn migrate && mtn -d pidgin.mtn pull --set-default \ 39 pidgin.im "im.pidgin.*" && mtn -d pidgin.mtn co -b im.pidgin.pidgin .; cd ../.. 40 40 41 41 … … 47 47 48 48 49 ==== MOVING ==== 50 51 If you move the Pidgin source tree, you must update the absolute path of the 52 pidgin.mtn database file in source/im.pidgin.pidgin/_MTN/options. Otherwise, 53 you will be unable to pull changesets from the monotone repository. 54 55 49 56 === DOWNLOADING MSN-PECAN SOURCE TREE === 50 57 51 * Skip this stepif you are building without msn-pecan.58 * Skip these steps if you are building without msn-pecan. 52 59 53 60 The msn-pecan source is not installed by the download script. Adium currently … … 61 68 ==== INITIAL CHECKOUT ==== 62 69 63 * Skip this step if you are building without msn-pecan. 64 65 To check out the adium-test branch of msn-pecan, run 70 To check out the msn-pecan master source tree, run 66 71 67 72 $ cd source/im.pidgin.pidgin/libpurple/protocols; git clone \ 68 git://github.com/felipec/msn-pecan.git msn_pecan ; cd msn_pecan; git checkout\69 -b adium_test origin/adium_test; cd ../../../../..73 git://github.com/felipec/msn-pecan.git msn_pecan && ln \ 74 msn_pecan/adium/Makefile.am msn_pecan && cd ../../../.. 70 75 71 76 72 77 ==== UPDATING ==== 73 74 * Skip this step if you are building without msn-pecan.75 78 76 79 To update the msn-pecan source, run … … 147 150 === LIBPURPLE === 148 151 149 * If you are building with msn-pecan. Official Adium releases are using 150 msn-pecan at the moment. 151 $ ./purple_make.sh 152 153 * If you are building with libpurple's msnp14/15 implementation. 154 $ ./purple_make_without_msn-pecan.sh 152 $ ./purple_make.sh [--ppc | --i386 ] [--regenerate] [--msn-pecan | --msn] 153 154 This phase builds libpurple. The output of the build process is written to 155 STDOUT. 156 157 The script to build libpurple accepts some options: 158 159 * You may limit the build to one architecture by using either --ppc or --i386, 160 but note that you cannot build a Universal Binary when using either option. 161 This is mainly useful for checking that code compiles. 162 163 * If you would like to force the script to rerun autoconf and automake, use 164 the --regenerate option. Otherwise, it will detect whether or not to run 165 them based on the presence or absence of needed files. 166 167 * If you are building with msn-pecan, use the --msn-pecan option. This is the 168 default. Note that current releases of Adium use msn-pecan. 169 170 * If you are building with libpurple's msnp14/15 implementation, use the --msn 171 option. 155 172 156 173 You must have set the PIDGIN_SOURCE variable for this script to run; see 157 174 SETTING PIDGIN PATH above. 158 175 159 This phase builds libpurple. The output of the build process is written to160 STDOUT.161 162 176 You must run this part of the build process each time you update libpurple. 163 177 … … 183 197 written to STDOUT. 184 198 185 You must run this part of the build process after a clean build, or after you186 update libpurple.199 You must run this part of the build process after a clean build, or whenever 200 libpurple has received localization updates. 187 201 188 202