ruby-changes:20514
From: nobu <ko1@a...>
Date: Sat, 16 Jul 2011 17:29:34 +0900 (JST)
Subject: [ruby-changes:20514] nobu:r32562 (trunk, ruby_1_9_3): * configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag.
nobu 2011-07-16 17:29:21 +0900 (Sat, 16 Jul 2011) New Revision: 32562 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=32562 Log: * configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag. Bug #4977 Modified files: branches/ruby_1_9_3/ChangeLog branches/ruby_1_9_3/configure.in trunk/ChangeLog trunk/configure.in Index: configure.in =================================================================== --- configure.in (revision 32561) +++ configure.in (revision 32562) @@ -155,9 +155,10 @@ AC_DEFUN([RUBY_UNIVERSAL_ARCH], [ # RUBY_UNIVERSAL_ARCH begin +ARCH_FLAG=`expr " $CFLAGS " : ['.* \(-m[0-9][0-9]*\) ']` test ${CFLAGS+set} && CFLAGS=`echo "$CFLAGS" | sed -e 's/ *-arch *[^ ]*//g' -e 's/ *-m32//g' -e 's/ *-m64//g'` test ${LDFLAGS+set} && LDFLAGS=`echo "$LDFLAGS" | sed -e 's/ *-arch *[^ ]*//g' -e 's/ *-m32//g' -e 's/ *-m64//g'` -unset ARCH_FLAG universal_binary universal_archnames +unset universal_binary universal_archnames if test ${target_archs+set}; then AC_MSG_CHECKING([target architectures]) target_archs=`echo $target_archs | tr , ' '` @@ -202,8 +203,6 @@ fi AS_CASE(["$target"], [-*], [ target="$target_cpu${target}"]) AS_CASE(["$target_alias"], [-*], [ target_alias="$target_cpu${target_alias}"]) - CFLAGS="$CFLAGS ${ARCH_FLAG}" - LDFLAGS="${LDFLAGS+$LDFLAGS }${ARCH_FLAG}" else if test x"$target_alias" = x; then AS_CASE(["$target_os"], @@ -236,6 +235,10 @@ else rb_cv_target_archs=${target_archs} fi +if test "x${ARCH_FLAG}" != x; then + CFLAGS="$CFLAGS ${ARCH_FLAG}" + LDFLAGS="${LDFLAGS+$LDFLAGS }${ARCH_FLAG}" +fi # RUBY_UNIVERSAL_ARCH end ]) Index: ChangeLog =================================================================== --- ChangeLog (revision 32561) +++ ChangeLog (revision 32562) @@ -1,3 +1,8 @@ +Sat Jul 16 17:29:20 2011 Nobuyoshi Nakada <nobu@r...> + + * configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag. + Bug #4977 + Sat Jul 16 06:27:51 2011 Marc-Andre Lafortune <ruby-core@m...> * lib/uri/common.rb (module): Remove optional parser argument to Index: ruby_1_9_3/configure.in =================================================================== --- ruby_1_9_3/configure.in (revision 32561) +++ ruby_1_9_3/configure.in (revision 32562) @@ -155,9 +155,10 @@ AC_DEFUN([RUBY_UNIVERSAL_ARCH], [ # RUBY_UNIVERSAL_ARCH begin +ARCH_FLAG=`expr " $CFLAGS " : ['.* \(-m[0-9][0-9]*\) ']` test ${CFLAGS+set} && CFLAGS=`echo "$CFLAGS" | sed -e 's/ *-arch *[^ ]*//g' -e 's/ *-m32//g' -e 's/ *-m64//g'` test ${LDFLAGS+set} && LDFLAGS=`echo "$LDFLAGS" | sed -e 's/ *-arch *[^ ]*//g' -e 's/ *-m32//g' -e 's/ *-m64//g'` -unset ARCH_FLAG universal_binary universal_archnames +unset universal_binary universal_archnames if test ${target_archs+set}; then AC_MSG_CHECKING([target architectures]) target_archs=`echo $target_archs | tr , ' '` @@ -202,8 +203,6 @@ fi AS_CASE(["$target"], [-*], [ target="$target_cpu${target}"]) AS_CASE(["$target_alias"], [-*], [ target_alias="$target_cpu${target_alias}"]) - CFLAGS="$CFLAGS ${ARCH_FLAG}" - LDFLAGS="${LDFLAGS+$LDFLAGS }${ARCH_FLAG}" else if test x"$target_alias" = x; then AS_CASE(["$target_os"], @@ -236,6 +235,10 @@ else rb_cv_target_archs=${target_archs} fi +if test "x${ARCH_FLAG}" != x; then + CFLAGS="$CFLAGS ${ARCH_FLAG}" + LDFLAGS="${LDFLAGS+$LDFLAGS }${ARCH_FLAG}" +fi # RUBY_UNIVERSAL_ARCH end ]) Index: ruby_1_9_3/ChangeLog =================================================================== --- ruby_1_9_3/ChangeLog (revision 32561) +++ ruby_1_9_3/ChangeLog (revision 32562) @@ -1,3 +1,8 @@ +Sat Jul 16 17:29:20 2011 Nobuyoshi Nakada <nobu@r...> + + * configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag. + Bug #4977 + Sat Jul 16 11:18:26 2011 NAKAMURA Usaku <usa@r...> * win32/setup.mak: support to build x64-mswin64 on Windows7 (and Vista, -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/