Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(127730)

Unified Diff: configure.ac

Issue 23670: Modifications to support iOS as a development platform
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « configure ('k') | iOS/README » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/configure.ac Tue Mar 01 10:26:10 2016 +0200
+++ b/configure.ac Wed Mar 02 00:01:35 2016 +0000
@@ -368,16 +368,19 @@ then
# in the case statement below.
case "$host" in
*-*-linux*)
ac_sys_system=Linux
;;
*-*-cygwin*)
ac_sys_system=Cygwin
;;
+ *-apple-ios)
+ ac_sys_system=iOS
+ ;;
*)
# for now, limit cross builds to known configurations
MACHDEP="unknown"
AC_MSG_ERROR([cross build not supported for $host])
esac
ac_sys_release=
else
ac_sys_system=`uname -s`
@@ -410,16 +413,25 @@ if test "$cross_compiling" = yes; then
case "$host_cpu" in
arm*)
_host_cpu=arm
;;
*)
_host_cpu=$host_cpu
esac
;;
+ *-apple-ios)
+ case "$host_cpu" in
+ arm*)
+ _host_cpu=arm
+ ;;
+ *)
+ _host_cpu=$host_cpu
+ esac
+ ;;
*-*-cygwin*)
_host_cpu=
;;
*)
# for now, limit cross builds to known configurations
MACHDEP="unknown"
AC_MSG_ERROR([cross build not supported for $host])
esac
@@ -486,16 +498,19 @@ case $ac_sys_system/$ac_sys_release in
# On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
# disables platform specific features beyond repair.
# On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
# has no effect, don't bother defining them
Darwin/@<:@6789@:>@.*)
define_xopen_source=no;;
Darwin/1@<:@0-9@:>@.*)
define_xopen_source=no;;
+ # On iOS, defining _POSIX_C_SOURCE also disables platform specific features.
+ iOS/*)
+ define_xopen_source=no;;
# On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but
# used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined
# or has another value. By not (re)defining it, the defaults come in place.
AIX/4)
define_xopen_source=no;;
AIX/5)
if test `uname -r` -eq 1; then
define_xopen_source=no
@@ -1164,21 +1179,27 @@ AC_CHECK_TOOLS(AR, ar aal, ar)
AC_SUBST(ARFLAGS)
if test -z "$ARFLAGS"
then
ARFLAGS="rc"
fi
AC_CHECK_TOOLS([READELF], [readelf], [:])
if test "$cross_compiling" = yes; then
- case "$READELF" in
- readelf|:)
- AC_MSG_ERROR([readelf for the host is required for cross builds])
- ;;
- esac
+ case "$host" in
+ *-apple-ios)
+ # readelf not required for iOS cross builds.
+ ;;
+ *)
+ case "$READELF" in
+ readelf|:)
+ AC_MSG_ERROR([readelf for the host is required for cross builds])
+ ;;
+ esac
+ esac
fi
AC_SUBST(READELF)
AC_SUBST(ASDLGEN)
AC_CHECK_PROGS(PYTHON, python$PACKAGE_VERSION python3 python, not-found)
if test "$PYTHON" = not-found; then
ASDLGEN="@echo python: $PYTHON! cannot run \$(srcdir)/Parser/asdl_c.py #"
else
@@ -3187,16 +3208,18 @@ then
if test "$ac_cv_func_dlopen" = yes
then DYNLOADFILE="dynload_shlib.o"
else DYNLOADFILE="dynload_aix.o"
fi
;;
hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
# Use dynload_next.c only on 10.2 and below, which don't have native dlopen()
Darwin/@<:@0156@:>@\..*) DYNLOADFILE="dynload_next.o";;
+ # Disable dynamic loading on iOS
+ iOS/*) DYNLOADFILE="dynload_stub.o";;
*)
# use dynload_shlib.c and dlopen() if we have it; otherwise stub
# out any dynamic loading
if test "$ac_cv_func_dlopen" = yes
then DYNLOADFILE="dynload_shlib.o"
else DYNLOADFILE="dynload_stub.o"
fi
;;
@@ -5243,16 +5266,26 @@ echo "creating Modules/Setup" >&AS_MESSA
if test ! -f Modules/Setup
then
cp $srcdir/Modules/Setup.dist Modules/Setup
fi
echo "creating Modules/Setup.local" >&AS_MESSAGE_FD
if test ! -f Modules/Setup.local
then
- echo "# Edit this file for local setup changes" >Modules/Setup.local
+ if test ! -f Modules/Setup.$_PYTHON_HOST_PLATFORM
+ then
+ echo "# Edit this file for local setup changes" >Modules/Setup.local
+ else
+ if test -f Modules/Setup.$_PYTHON_HOST_PLATFORM.local
+ then
+ cp Modules/Setup.$_PYTHON_HOST_PLATFORM.local Modules/Setup.local
+ else
+ cat Modules/Setup.embedded Modules/Setup.$_PYTHON_HOST_PLATFORM > Modules/Setup.local
+ fi
+ fi
fi
echo "creating Makefile" >&AS_MESSAGE_FD
$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
-s Modules Modules/Setup.config \
Modules/Setup.local Modules/Setup
mv config.c Modules
« no previous file with comments | « configure ('k') | iOS/README » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+