You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
717 B

  1. #! /bin/sh
  2. export XCODEDIR=$(xcode-select -p)
  3. export BASEDIR="${XCODEDIR}/Platforms/iPhoneOS.platform/Developer"
  4. export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH"
  5. export SDK="${BASEDIR}/SDKs/iPhoneOS.sdk"
  6. export IPHONEOS_VERSION_MIN="5.1.1"
  7. export CFLAGS="-Oz -mthumb -arch armv7 -isysroot ${SDK} -miphoneos-version-min=${IPHONEOS_VERSION_MIN}"
  8. export LDFLAGS="-mthumb -arch armv7 -isysroot ${SDK} -miphoneos-version-min=${IPHONEOS_VERSION_MIN}"
  9. export PREFIX="$(pwd)/libsodium-ios"
  10. ./configure --host=arm-apple-darwin10 \
  11. --disable-shared \
  12. --enable-minimal \
  13. --prefix="$PREFIX" && \
  14. make clean && \
  15. make -j3 install && \
  16. echo "libsodium has been installed into $PREFIX"