pushd $BUILDDIRARMV6
make install DESTDIR=$TMPDIR/dist.armv6
popd
+ if [ ! -h $TMPDIR/dist.armv6/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv6/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib
+ elif [ ! -h $TMPDIR/dist.armv6/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv6/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib
+ fi
lipo -create \
$PKGROOT/$LIBDIR/libjpeg.a \
-arch arm $TMPDIR/dist.armv6/$LIBDIR/libjpeg.a \
-output $PKGROOT/$LIBDIR/libjpeg.a
+ lipo -create \
+ $PKGROOT/$LIBDIR/libturbojpeg.0.dylib \
+ -arch arm $TMPDIR/dist.armv6/$LIBDIR/libturbojpeg.0.dylib \
+ -output $PKGROOT/$LIBDIR/libturbojpeg.0.dylib
lipo -create \
$PKGROOT/$LIBDIR/libturbojpeg.a \
-arch arm $TMPDIR/dist.armv6/$LIBDIR/libturbojpeg.a \
-output $PKGROOT/$LIBDIR/libturbojpeg.a
+ lipo -create \
+ $PKGROOT/$BINDIR/cjpeg \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/cjpeg \
+ -output $PKGROOT/$BINDIR/cjpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/djpeg \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/djpeg \
+ -output $PKGROOT/$BINDIR/djpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/jpegtran \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/jpegtran \
+ -output $PKGROOT/$BINDIR/jpegtran
+ lipo -create \
+ $PKGROOT/$BINDIR/tjbench \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/tjbench \
+ -output $PKGROOT/$BINDIR/tjbench
+ lipo -create \
+ $PKGROOT/$BINDIR/rdjpgcom \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/rdjpgcom \
+ -output $PKGROOT/$BINDIR/rdjpgcom
+ lipo -create \
+ $PKGROOT/$BINDIR/wrjpgcom \
+ -arch arm $TMPDIR/dist.armv6/$BINDIR/wrjpgcom \
+ -output $PKGROOT/$BINDIR/wrjpgcom
fi
if [ $BUILDARMV7 = 1 ]; then
pushd $BUILDDIRARMV7
make install DESTDIR=$TMPDIR/dist.armv7
popd
+ if [ ! -h $TMPDIR/dist.armv7/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv7/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib
+ elif [ ! -h $TMPDIR/dist.armv7/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv7/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib
+ fi
lipo -create \
$PKGROOT/$LIBDIR/libjpeg.a \
-arch arm $TMPDIR/dist.armv7/$LIBDIR/libjpeg.a \
-output $PKGROOT/$LIBDIR/libjpeg.a
+ lipo -create \
+ $PKGROOT/$LIBDIR/libturbojpeg.0.dylib \
+ -arch arm $TMPDIR/dist.armv7/$LIBDIR/libturbojpeg.0.dylib \
+ -output $PKGROOT/$LIBDIR/libturbojpeg.0.dylib
lipo -create \
$PKGROOT/$LIBDIR/libturbojpeg.a \
-arch arm $TMPDIR/dist.armv7/$LIBDIR/libturbojpeg.a \
-output $PKGROOT/$LIBDIR/libturbojpeg.a
+ lipo -create \
+ $PKGROOT/$BINDIR/cjpeg \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/cjpeg \
+ -output $PKGROOT/$BINDIR/cjpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/djpeg \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/djpeg \
+ -output $PKGROOT/$BINDIR/djpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/jpegtran \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/jpegtran \
+ -output $PKGROOT/$BINDIR/jpegtran
+ lipo -create \
+ $PKGROOT/$BINDIR/tjbench \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/tjbench \
+ -output $PKGROOT/$BINDIR/tjbench
+ lipo -create \
+ $PKGROOT/$BINDIR/rdjpgcom \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/rdjpgcom \
+ -output $PKGROOT/$BINDIR/rdjpgcom
+ lipo -create \
+ $PKGROOT/$BINDIR/wrjpgcom \
+ -arch arm $TMPDIR/dist.armv7/$BINDIR/wrjpgcom \
+ -output $PKGROOT/$BINDIR/wrjpgcom
fi
if [ $BUILDARMV7S = 1 ]; then
pushd $BUILDDIRARMV7S
make install DESTDIR=$TMPDIR/dist.armv7s
popd
+ if [ ! -h $TMPDIR/dist.armv7s/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv7s/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib
+ elif [ ! -h $TMPDIR/dist.armv7s/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib -a \
+ ! -h $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib ]; then
+ lipo -create \
+ $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -arch arm $TMPDIR/dist.armv7s/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
+ -output $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib
+ fi
lipo -create \
$PKGROOT/$LIBDIR/libjpeg.a \
-arch arm $TMPDIR/dist.armv7s/$LIBDIR/libjpeg.a \
-output $PKGROOT/$LIBDIR/libjpeg.a
+ lipo -create \
+ $PKGROOT/$LIBDIR/libturbojpeg.0.dylib \
+ -arch arm $TMPDIR/dist.armv7s/$LIBDIR/libturbojpeg.0.dylib \
+ -output $PKGROOT/$LIBDIR/libturbojpeg.0.dylib
lipo -create \
$PKGROOT/$LIBDIR/libturbojpeg.a \
-arch arm $TMPDIR/dist.armv7s/$LIBDIR/libturbojpeg.a \
-output $PKGROOT/$LIBDIR/libturbojpeg.a
+ lipo -create \
+ $PKGROOT/$BINDIR/cjpeg \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/cjpeg \
+ -output $PKGROOT/$BINDIR/cjpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/djpeg \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/djpeg \
+ -output $PKGROOT/$BINDIR/djpeg
+ lipo -create \
+ $PKGROOT/$BINDIR/jpegtran \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/jpegtran \
+ -output $PKGROOT/$BINDIR/jpegtran
+ lipo -create \
+ $PKGROOT/$BINDIR/tjbench \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/tjbench \
+ -output $PKGROOT/$BINDIR/tjbench
+ lipo -create \
+ $PKGROOT/$BINDIR/rdjpgcom \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/rdjpgcom \
+ -output $PKGROOT/$BINDIR/rdjpgcom
+ lipo -create \
+ $PKGROOT/$BINDIR/wrjpgcom \
+ -arch arm $TMPDIR/dist.armv7s/$BINDIR/wrjpgcom \
+ -output $PKGROOT/$BINDIR/wrjpgcom
fi
install_name_tool -id $LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib $PKGROOT/$LIBDIR/libjpeg.@SO_MAJOR_VERSION@.dylib
--package-path $TMPDIR/pkg/ --resources $TMPDIR/pkg/ \
$TMPDIR/dmg/$PACKAGE_NAME.pkg
hdiutil create -fs HFS+ -volname $PACKAGE_NAME-$VERSION \
- -srcfolder "$TMPDIR/dmg" $TMPDIR/$PACKAGE_NAME-$VERSION.dmg
-cp $TMPDIR/$PACKAGE_NAME-$VERSION.dmg .
+ -srcfolder "$TMPDIR/dmg" $TMPDIR/$PACKAGE_NAME-$VERSION.dmg
+cp $TMPDIR/$PACKAGE_NAME-$VERSION.dmg .
exit