Skip to content

Commit

Permalink
* configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag.
Browse files Browse the repository at this point in the history
  Bug #4977


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information
nobu committed Jul 16, 2011
1 parent c2dfaa7 commit 2915c15
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
5 changes: 5 additions & 0 deletions ChangeLog
@@ -1,3 +1,8 @@
Sat Jul 16 17:29:20 2011 Nobuyoshi Nakada <nobu@ruby-lang.org>

* configure.in (RUBY_UNIVERSAL_ARCH): restore arch flag.
Bug #4977

Sat Jul 16 06:27:51 2011 Marc-Andre Lafortune <ruby-core@marc-andre.ca>

* lib/uri/common.rb (module): Remove optional parser argument to
Expand Down
9 changes: 6 additions & 3 deletions configure.in
Expand Up @@ -155,9 +155,10 @@ AC_MSG_RESULT([$ARCH_FLAG])

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 , ' '`
Expand Down Expand Up @@ -202,8 +203,6 @@ if test ${target_archs+set}; then
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"],
Expand Down Expand Up @@ -236,6 +235,10 @@ if test "${target_archs}" != "${rb_cv_target_archs-${target_archs}}"; then
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
])

Expand Down

0 comments on commit 2915c15

Please sign in to comment.