Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Use exisiting CFLAGS and CMAKE_OPTIONS variables.

  • Loading branch information...
commit 39d3f6d1480e1d21a14a74ccbf0e0734184e5968 1 parent 2c0e00e
@niw authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 opencv_cmake.sh
View
10 opencv_cmake.sh
@@ -12,6 +12,8 @@ if [ "$1" = "-h" -o "$1" = "--help" -o -z "$1" ]; then
echo " INSTALL_PREFIX Path to OpenCV binary directory"
echo " SDK_VERSION iOS SDK version"
echo " IPHONEOS_VERSION_MIN iOS deployment target"
+ echo " CMAKE_OPTIONS Additional CMake options"
+ echo " CFLAGS Additional compiler flags"
exit
fi
@@ -81,13 +83,13 @@ echo "OpenCV Install Prefix = $INSTALL_PREFIX"
echo ""
if [ "$TARGET_SDK" = "device" ]; then
- CFLAGS="-arch armv6 -arch armv7 -mthumb -miphoneos-version-min=${IPHONEOS_VERSION_MIN}"
+ CFLAGS="-arch armv6 -arch armv7 -mthumb -miphoneos-version-min=${IPHONEOS_VERSION_MIN} ${CFLAGS}"
ARCH="armv6;armv7"
- CMAKE_OPTIONS="-D ENABLE_SSE=OFF -D ENABLE_SSE2=OFF"
+ CMAKE_OPTIONS="-D ENABLE_SSE=OFF -D ENABLE_SSE2=OFF ${CMAKE_OPTIONS}"
else
- CFLAGS="-m32"
+ CFLAGS="-m32 ${CFLAGS}"
ARCH="i386"
- CMAKE_OPTIONS='-D CMAKE_OSX_DEPLOYMENT_TARGET="10.6"'
+ CMAKE_OPTIONS="-D CMAKE_OSX_DEPLOYMENT_TARGET=\"10.6\" ${CMAKE_OPTIONS}"
fi
env \
Please sign in to comment.
Something went wrong with that request. Please try again.