Changeset 24

Show
Ignore:
Timestamp:
07/11/06 21:23:51 (3 years ago)
Author:
gbooker
Message:

Create separate builds for Deployment and Development.
Use -Os in Deployment.
Use no optimizations in Development (had to turn off mmx and altivec because it won't build with them if optimizations are off).

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/createStaticLibs.sh

    r19 r24  
    33buildid_ffmpeg="r`svn info ffmpeg | grep -F Revision | awk '{print $2}'`" 
    44 
    5 OUTPUT_FILE="$SYMROOT/Universal/buildid" 
     5if [ "$BUILD_STYLE" = "Development" ] ; then 
     6        extraConfigureOptions="--disable-strip --disable-opts --disable-mmx --disable-altivec" 
     7else 
     8        extraConfigureOptions="--enable-small" 
     9fi 
     10 
     11OUTPUT_FILE="$BUILT_PRODUCTS_DIR/Universal/buildid" 
    612 
    713if [[ -e "$OUTPUT_FILE" ]] ; then 
     
    2026else 
    2127        echo "Static ffmpeg libs are out-of-date ; rebuilding" 
     28        mkdir "$BUILT_PRODUCTS_DIR" 
    2229        ####################### 
    2330        # Intel shlibs 
    2431        ####################### 
    25         BUILDDIR="$SYMROOT/intel" 
     32        BUILDDIR="$BUILT_PRODUCTS_DIR/intel" 
    2633        mkdir "$BUILDDIR" 
    2734         
    2835        cd "$SRCROOT/ffmpeg" 
    29         #patch -p0 < ../ffmpeg-configure-crosscomp.patch 
    3036        patch -p0 < ../ffmpeg-svn-mactel.patch 
    3137         
    3238        cd "$BUILDDIR" 
    3339        if [ `arch` != i386 ] ; then 
    34                 "$SRCROOT/ffmpeg/configure" --cross-compile --cpu=x86 --enable-pp --enable-gpl --cc='gcc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk' 
     40                "$SRCROOT/ffmpeg/configure" --cross-compile --cpu=x86 --enable-pp --enable-gpl --extra-ldflags='-arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk' --extra-cflags='-arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk' $extraConfigureOptions 
    3541        else 
    36                 "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl --enable-memalign-hack 
     42                "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl --enable-memalign-hack $extraConfigureOptions 
    3743        fi 
    3844        make -j3 
    3945         
    4046        cd "$SRCROOT/ffmpeg" 
    41         #patch -R -p0 < ../ffmpeg-configure-crosscomp.patch 
    4247        patch -R -p0 < ../ffmpeg-svn-mactel.patch 
    4348         
     
    4651        # PPC shlibs 
    4752        ####################### 
    48         BUILDDIR="$SYMROOT/ppc" 
     53        BUILDDIR="$BUILT_PRODUCTS_DIR/ppc" 
    4954        mkdir "$BUILDDIR" 
    5055         
    5156        cd "$SRCROOT/ffmpeg" 
    52         #patch -p0 < ../ffmpeg-configure-crosscomp.patch 
    5357         
    5458        cd "$BUILDDIR" 
    5559        if [ `arch` = ppc ] ; then 
    56                 "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl 
     60                "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl $extraConfigureOptions 
    5761        else 
    58                 "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl --cpu=ppc  --cc='gcc -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk' 
     62                "$SRCROOT/ffmpeg/configure" --enable-pp --enable-gpl --cpu=ppc  --extra-ldflags='-arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk' --extra-cflags='-arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk' $extraConfigureOptions 
    5963        fi 
    6064        make -j3 
    6165         
    6266        cd "$SRCROOT/ffmpeg" 
    63         #patch -R -p0 < ../ffmpeg-configure-crosscomp.patch 
    64          
    65          
     67 
    6668        ####################### 
    6769        # lipo shlibs 
    6870        ####################### 
    69         BUILDDIR="$SYMROOT/Universal" 
    70         INTEL="$SYMROOT/intel" 
    71         PPC="$SYMROOT/ppc" 
     71        BUILDDIR="$BUILT_PRODUCTS_DIR/Universal" 
     72        INTEL="$BUILT_PRODUCTS_DIR/intel" 
     73        PPC="$BUILT_PRODUCTS_DIR/ppc" 
    7274        rm -rf "$BUILDDIR" 
    7375        mkdir "$BUILDDIR" 
     
    7981fi 
    8082 
     83cp "$BUILT_PRODUCTS_DIR/Universal"/* "$SYMROOT/Universal" 
     84ranlib "$SYMROOT/Universal"/*.a