8024265: Enable new build on AIX

Thu, 12 Sep 2013 12:29:17 -0700

author
simonis
date
Thu, 12 Sep 2013 12:29:17 -0700
changeset 971
584dc2e95e04
parent 970
e885c762cedd
child 972
f3697e0783e2

8024265: Enable new build on AIX
Reviewed-by: ihse

common/autoconf/build-aux/config.guess file | annotate | diff | comparison | revisions
common/autoconf/build-performance.m4 file | annotate | diff | comparison | revisions
common/autoconf/generated-configure.sh file | annotate | diff | comparison | revisions
common/autoconf/help.m4 file | annotate | diff | comparison | revisions
common/autoconf/libraries.m4 file | annotate | diff | comparison | revisions
common/autoconf/platform.m4 file | annotate | diff | comparison | revisions
common/autoconf/spec.gmk.in file | annotate | diff | comparison | revisions
common/autoconf/toolchain.m4 file | annotate | diff | comparison | revisions
common/makefiles/JavaCompilation.gmk file | annotate | diff | comparison | revisions
common/makefiles/NativeCompilation.gmk file | annotate | diff | comparison | revisions
     1.1 --- a/common/autoconf/build-aux/config.guess	Thu Sep 05 10:58:25 2013 -0700
     1.2 +++ b/common/autoconf/build-aux/config.guess	Thu Sep 12 12:29:17 2013 -0700
     1.3 @@ -60,4 +60,20 @@
     1.4    esac
     1.5  fi  
     1.6  
     1.7 +# Test and fix architecture string on AIX
     1.8 +# On AIX 'config.guess' returns 'powerpc' as architecture but 'powerpc' is
     1.9 +# implicitely handled as 32-bit architecture in 'platform.m4' so we check
    1.10 +# for the kernel mode rewrite it to 'powerpc64' if we'Re running in 64-bit mode.
    1.11 +# The check could also be done with `/usr/sbin/prtconf | grep "Kernel Type" | grep "64-bit"`
    1.12 +echo $OUT | grep powerpc-ibm-aix > /dev/null 2> /dev/null
    1.13 +if test $? = 0; then
    1.14 +  if [ -x /bin/getconf ] ; then
    1.15 +    KERNEL_BITMODE=`getconf KERNEL_BITMODE`
    1.16 +    if  [ "$KERNEL_BITMODE" = "32" ]; then
    1.17 +      KERNEL_BITMODE=""
    1.18 +    fi
    1.19 +  fi
    1.20 +  OUT=powerpc$KERNEL_BITMODE`echo $OUT | sed -e 's/[^-]*//'`
    1.21 +fi
    1.22 +
    1.23  echo $OUT
     2.1 --- a/common/autoconf/build-performance.m4	Thu Sep 05 10:58:25 2013 -0700
     2.2 +++ b/common/autoconf/build-performance.m4	Thu Sep 12 12:29:17 2013 -0700
     2.3 @@ -41,6 +41,9 @@
     2.4          # Looks like a MacOSX system
     2.5          NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print [$]5}'`
     2.6          FOUND_CORES=yes
     2.7 +    elif test "x$OPENJDK_BUILD_OS" = xaix ; then
     2.8 +        NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print [$]4 }'`
     2.9 +        FOUND_CORES=yes
    2.10      elif test -n "$NUMBER_OF_PROCESSORS"; then
    2.11          # On windows, look in the env
    2.12          NUM_CORES=$NUMBER_OF_PROCESSORS
    2.13 @@ -69,8 +72,8 @@
    2.14          MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
    2.15          FOUND_MEM=yes
    2.16      elif test -x /usr/sbin/prtconf; then
    2.17 -        # Looks like a Solaris system
    2.18 -        MEMORY_SIZE=`/usr/sbin/prtconf | grep "Memory size" | awk '{ print [$]3 }'`
    2.19 +        # Looks like a Solaris or AIX system
    2.20 +        MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [[Ss]]ize" | awk '{ print [$]3 }'`
    2.21          FOUND_MEM=yes
    2.22      elif test -x /usr/sbin/system_profiler; then
    2.23          # Looks like a MacOSX system
     3.1 --- a/common/autoconf/generated-configure.sh	Thu Sep 05 10:58:25 2013 -0700
     3.2 +++ b/common/autoconf/generated-configure.sh	Thu Sep 12 12:29:17 2013 -0700
     3.3 @@ -710,7 +710,6 @@
     3.4  SHARED_LIBRARY
     3.5  OBJ_SUFFIX
     3.6  COMPILER_NAME
     3.7 -TARGET_BITS_FLAG
     3.8  JT_HOME
     3.9  JTREGEXE
    3.10  LIPO
    3.11 @@ -752,6 +751,7 @@
    3.12  PROPER_COMPILER_CXX
    3.13  POTENTIAL_CXX
    3.14  TOOLS_DIR_CXX
    3.15 +COMPILER_TARGET_BITS_FLAG
    3.16  OBJEXT
    3.17  EXEEXT
    3.18  ac_ct_CC
    3.19 @@ -3450,8 +3450,6 @@
    3.20          PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P zip" ;;
    3.21      make)
    3.22          PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P make" ;;
    3.23 -    * )
    3.24 -       break ;;
    3.25      esac
    3.26  }
    3.27  
    3.28 @@ -3473,8 +3471,6 @@
    3.29          PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
    3.30      ccache)
    3.31          PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
    3.32 -    * )
    3.33 -       break ;;
    3.34      esac
    3.35  }
    3.36  
    3.37 @@ -3496,8 +3492,6 @@
    3.38          PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
    3.39      ccache)
    3.40          PKGHANDLER_COMMAND="sudo yum install ccache" ;;
    3.41 -    * )
    3.42 -       break ;;
    3.43      esac
    3.44  }
    3.45  
    3.46 @@ -3826,7 +3820,7 @@
    3.47  #CUSTOM_AUTOCONF_INCLUDE
    3.48  
    3.49  # Do not change or remove the following line, it is needed for consistency checks:
    3.50 -DATE_WHEN_GENERATED=1378403883
    3.51 +DATE_WHEN_GENERATED=1379014108
    3.52  
    3.53  ###############################################################################
    3.54  #
    3.55 @@ -6745,6 +6739,11 @@
    3.56        VAR_OS_API=winapi
    3.57        VAR_OS_ENV=windows.msys
    3.58        ;;
    3.59 +    *aix*)
    3.60 +      VAR_OS=aix
    3.61 +      VAR_OS_API=posix
    3.62 +      VAR_OS_ENV=aix
    3.63 +      ;;
    3.64      *)
    3.65        as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
    3.66        ;;
    3.67 @@ -6853,6 +6852,11 @@
    3.68        VAR_OS_API=winapi
    3.69        VAR_OS_ENV=windows.msys
    3.70        ;;
    3.71 +    *aix*)
    3.72 +      VAR_OS=aix
    3.73 +      VAR_OS_API=posix
    3.74 +      VAR_OS_ENV=aix
    3.75 +      ;;
    3.76      *)
    3.77        as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
    3.78        ;;
    3.79 @@ -15749,7 +15753,7 @@
    3.80      case $PKGHANDLER in
    3.81  	apt-get)
    3.82                  apt_help     $MISSING_DEPENDENCY ;;
    3.83 -    yum)
    3.84 +	yum)
    3.85                  yum_help     $MISSING_DEPENDENCY ;;
    3.86  	port)
    3.87                  port_help    $MISSING_DEPENDENCY ;;
    3.88 @@ -15757,8 +15761,6 @@
    3.89                  pkgutil_help $MISSING_DEPENDENCY ;;
    3.90  	pkgadd)
    3.91                  pkgadd_help  $MISSING_DEPENDENCY ;;
    3.92 -    * )
    3.93 -      break ;;
    3.94      esac
    3.95  
    3.96      if test "x$PKGHANDLER_COMMAND" != x; then
    3.97 @@ -19177,6 +19179,9 @@
    3.98    COMPILER_CHECK_LIST="cl"
    3.99  elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
   3.100    COMPILER_CHECK_LIST="cc gcc"
   3.101 +elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
   3.102 +  # Do not probe for cc on AIX.
   3.103 +  COMPILER_CHECK_LIST="xlc_r"
   3.104  else
   3.105    COMPILER_CHECK_LIST="gcc cc"
   3.106  fi
   3.107 @@ -19300,7 +19305,7 @@
   3.108      case $PKGHANDLER in
   3.109  	apt-get)
   3.110                  apt_help     $MISSING_DEPENDENCY ;;
   3.111 -    yum)
   3.112 +	yum)
   3.113                  yum_help     $MISSING_DEPENDENCY ;;
   3.114  	port)
   3.115                  port_help    $MISSING_DEPENDENCY ;;
   3.116 @@ -19308,8 +19313,6 @@
   3.117                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.118  	pkgadd)
   3.119                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.120 -    * )
   3.121 -      break ;;
   3.122      esac
   3.123  
   3.124      if test "x$PKGHANDLER_COMMAND" != x; then
   3.125 @@ -19584,9 +19587,12 @@
   3.126  $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
   3.127      fi
   3.128  
   3.129 -  { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
   3.130 +  TEST_COMPILER="$CC"
   3.131 +  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
   3.132 +  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
   3.133 +  if test "x$OPENJDK_BUILD_OS" != xaix; then
   3.134 +    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
   3.135  $as_echo_n "checking resolved symbolic links for CC... " >&6; }
   3.136 -  TEST_COMPILER="$CC"
   3.137  
   3.138      if test "x$OPENJDK_BUILD_OS" != xwindows; then
   3.139          # Follow a chain of symbolic links. Use readlink
   3.140 @@ -19635,8 +19641,9 @@
   3.141          fi
   3.142      fi
   3.143  
   3.144 -  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
   3.145 +    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
   3.146  $as_echo "$TEST_COMPILER" >&6; }
   3.147 +  fi
   3.148    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
   3.149  $as_echo_n "checking if CC is disguised ccache... " >&6; }
   3.150  
   3.151 @@ -20100,6 +20107,15 @@
   3.152        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"`
   3.153        COMPILER_VENDOR="Sun Studio"
   3.154      fi
   3.155 +  elif test  "x$OPENJDK_TARGET_OS" = xaix; then
   3.156 +      COMPILER_VERSION_TEST=`$COMPILER -qversion  2>&1 | $TAIL -n 1`
   3.157 +      $ECHO $COMPILER_VERSION_TEST | $GREP "^Version: " > /dev/null
   3.158 +      if test $? -ne 0; then
   3.159 +        as_fn_error $? "Failed to detect the compiler version of $COMPILER ...." "$LINENO" 5
   3.160 +      else
   3.161 +        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n 's/Version: \(0-90-9\.0-90-9*\).*/\1/p'`
   3.162 +        COMPILER_VENDOR='IBM'
   3.163 +      fi
   3.164    elif test  "x$OPENJDK_TARGET_OS" = xwindows; then
   3.165      # First line typically looks something like:
   3.166      # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86
   3.167 @@ -20741,6 +20757,14 @@
   3.168  ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
   3.169  
   3.170  
   3.171 +# Option used to tell the compiler whether to create 32- or 64-bit executables
   3.172 +# Notice that CC contains the full compiler path at this point.
   3.173 +case $CC in
   3.174 +  *xlc_r) COMPILER_TARGET_BITS_FLAG="-q";;
   3.175 +  *)      COMPILER_TARGET_BITS_FLAG="-m";;
   3.176 +esac
   3.177 +
   3.178 +
   3.179  ### Locate C++ compiler (CXX)
   3.180  
   3.181  if test "x$CXX" != x; then
   3.182 @@ -20749,6 +20773,9 @@
   3.183    COMPILER_CHECK_LIST="cl"
   3.184  elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
   3.185    COMPILER_CHECK_LIST="CC g++"
   3.186 +elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
   3.187 +  # Do not probe for CC on AIX .
   3.188 +  COMPILER_CHECK_LIST="xlC_r"
   3.189  else
   3.190    COMPILER_CHECK_LIST="g++ CC"
   3.191  fi
   3.192 @@ -20872,7 +20899,7 @@
   3.193      case $PKGHANDLER in
   3.194  	apt-get)
   3.195                  apt_help     $MISSING_DEPENDENCY ;;
   3.196 -    yum)
   3.197 +	yum)
   3.198                  yum_help     $MISSING_DEPENDENCY ;;
   3.199  	port)
   3.200                  port_help    $MISSING_DEPENDENCY ;;
   3.201 @@ -20880,8 +20907,6 @@
   3.202                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.203  	pkgadd)
   3.204                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.205 -    * )
   3.206 -      break ;;
   3.207      esac
   3.208  
   3.209      if test "x$PKGHANDLER_COMMAND" != x; then
   3.210 @@ -21156,9 +21181,12 @@
   3.211  $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
   3.212      fi
   3.213  
   3.214 -  { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
   3.215 +  TEST_COMPILER="$CXX"
   3.216 +  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
   3.217 +  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
   3.218 +  if test "x$OPENJDK_BUILD_OS" != xaix; then
   3.219 +    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
   3.220  $as_echo_n "checking resolved symbolic links for CXX... " >&6; }
   3.221 -  TEST_COMPILER="$CXX"
   3.222  
   3.223      if test "x$OPENJDK_BUILD_OS" != xwindows; then
   3.224          # Follow a chain of symbolic links. Use readlink
   3.225 @@ -21207,8 +21235,9 @@
   3.226          fi
   3.227      fi
   3.228  
   3.229 -  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
   3.230 +    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
   3.231  $as_echo "$TEST_COMPILER" >&6; }
   3.232 +  fi
   3.233    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
   3.234  $as_echo_n "checking if CXX is disguised ccache... " >&6; }
   3.235  
   3.236 @@ -21672,6 +21701,15 @@
   3.237        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"`
   3.238        COMPILER_VENDOR="Sun Studio"
   3.239      fi
   3.240 +  elif test  "x$OPENJDK_TARGET_OS" = xaix; then
   3.241 +      COMPILER_VERSION_TEST=`$COMPILER -qversion  2>&1 | $TAIL -n 1`
   3.242 +      $ECHO $COMPILER_VERSION_TEST | $GREP "^Version: " > /dev/null
   3.243 +      if test $? -ne 0; then
   3.244 +        as_fn_error $? "Failed to detect the compiler version of $COMPILER ...." "$LINENO" 5
   3.245 +      else
   3.246 +        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n 's/Version: \(0-90-9\.0-90-9*\).*/\1/p'`
   3.247 +        COMPILER_VENDOR='IBM'
   3.248 +      fi
   3.249    elif test  "x$OPENJDK_TARGET_OS" = xwindows; then
   3.250      # First line typically looks something like:
   3.251      # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86
   3.252 @@ -22877,6 +22915,8 @@
   3.253  fi
   3.254  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
   3.255      ARFLAGS="-r"
   3.256 +elif test "x$OPENJDK_TARGET_OS" = xaix; then
   3.257 +    ARFLAGS="-X64"
   3.258  else
   3.259      ARFLAGS=""
   3.260  fi
   3.261 @@ -28852,21 +28892,23 @@
   3.262  # is made at runtime.)
   3.263  #
   3.264  
   3.265 -if test "x$OPENJDK_TARGET_OS" = xsolaris; then
   3.266 -  # Always specify -m flags on Solaris
   3.267 +if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
   3.268 +  # Always specify -m flag on Solaris
   3.269 +  # And -q on AIX because otherwise the compiler produces 32-bit objects by default
   3.270  
   3.271    # keep track of c/cxx flags that we added outselves...
   3.272    #   to prevent emitting warning...
   3.273 -  TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
   3.274 -
   3.275 -
   3.276 -  CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
   3.277 -  CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
   3.278 -  LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
   3.279 -
   3.280 -  CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.281 -  CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.282 -  LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.283 +  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.284 +  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.285 +  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.286 +
   3.287 +  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
   3.288 +  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
   3.289 +  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
   3.290 +
   3.291 +  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
   3.292 +  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
   3.293 +  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
   3.294  
   3.295  elif test "x$COMPILE_TYPE" = xreduced; then
   3.296    if test "x$OPENJDK_TARGET_OS" != xwindows; then
   3.297 @@ -28874,16 +28916,17 @@
   3.298  
   3.299    # keep track of c/cxx flags that we added outselves...
   3.300    #   to prevent emitting warning...
   3.301 -  TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
   3.302 -
   3.303 -
   3.304 -  CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
   3.305 -  CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
   3.306 -  LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
   3.307 -
   3.308 -  CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.309 -  CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.310 -  LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
   3.311 +  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.312 +  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.313 +  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.314 +
   3.315 +  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
   3.316 +  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
   3.317 +  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
   3.318 +
   3.319 +  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
   3.320 +  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
   3.321 +  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
   3.322  
   3.323    fi
   3.324  fi
   3.325 @@ -28949,20 +28992,83 @@
   3.326  
   3.327  
   3.328  
   3.329 -if test "x$SIZEOF_INT_P" != "x$ac_cv_sizeof_int_p"; then
   3.330 -  # Workaround autoconf bug, see http://lists.gnu.org/archive/html/autoconf/2010-07/msg00004.html
   3.331 -  SIZEOF_INT_P="$ac_cv_sizeof_int_p"
   3.332 -fi
   3.333 -
   3.334 -if test "x$SIZEOF_INT_P" = x; then
   3.335 +# AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
   3.336 +if test "x$ac_cv_sizeof_int_p" = x; then
   3.337      # The test failed, lets stick to the assumed value.
   3.338      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&5
   3.339  $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
   3.340  else
   3.341 -    TESTED_TARGET_CPU_BITS=`expr 8 \* $SIZEOF_INT_P`
   3.342 +    TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
   3.343  
   3.344      if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
   3.345 -        as_fn_error $? "The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)" "$LINENO" 5
   3.346 +        # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
   3.347 +        # Let's try to implicitely set the compilers target architecture and retry the test
   3.348 +        { $as_echo "$as_me:${as_lineno-$LINENO}: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&5
   3.349 +$as_echo "$as_me: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&6;}
   3.350 +        { $as_echo "$as_me:${as_lineno-$LINENO}: I'll retry after setting the platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5
   3.351 +$as_echo "$as_me: I'll retry after setting the platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;}
   3.352 +
   3.353 +  # keep track of c/cxx flags that we added outselves...
   3.354 +  #   to prevent emitting warning...
   3.355 +  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.356 +  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.357 +  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.358 +
   3.359 +  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
   3.360 +  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
   3.361 +  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
   3.362 +
   3.363 +  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
   3.364 +  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
   3.365 +  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
   3.366 +
   3.367 +
   3.368 +        # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
   3.369 +        unset ac_cv_sizeof_int_p
   3.370 +	# And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
   3.371 +	cat >>confdefs.h <<_ACEOF
   3.372 +#undef SIZEOF_INT_P
   3.373 +_ACEOF
   3.374 +
   3.375 +        # The cast to long int works around a bug in the HP C Compiler
   3.376 +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
   3.377 +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
   3.378 +# This bug is HP SR number 8606223364.
   3.379 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
   3.380 +$as_echo_n "checking size of int *... " >&6; }
   3.381 +if ${ac_cv_sizeof_int_p+:} false; then :
   3.382 +  $as_echo_n "(cached) " >&6
   3.383 +else
   3.384 +  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
   3.385 +
   3.386 +else
   3.387 +  if test "$ac_cv_type_int_p" = yes; then
   3.388 +     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
   3.389 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
   3.390 +as_fn_error 77 "cannot compute sizeof (int *)
   3.391 +See \`config.log' for more details" "$LINENO" 5; }
   3.392 +   else
   3.393 +     ac_cv_sizeof_int_p=0
   3.394 +   fi
   3.395 +fi
   3.396 +
   3.397 +fi
   3.398 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
   3.399 +$as_echo "$ac_cv_sizeof_int_p" >&6; }
   3.400 +
   3.401 +
   3.402 +
   3.403 +cat >>confdefs.h <<_ACEOF
   3.404 +#define SIZEOF_INT_P $ac_cv_sizeof_int_p
   3.405 +_ACEOF
   3.406 +
   3.407 +
   3.408 +
   3.409 +        TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
   3.410 +
   3.411 +        if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
   3.412 +            as_fn_error $? "The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)" "$LINENO" 5
   3.413 +        fi
   3.414      fi
   3.415  fi
   3.416  
   3.417 @@ -29275,6 +29381,29 @@
   3.418          POST_STRIP_CMD="$STRIP -x"
   3.419          POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
   3.420      fi
   3.421 +    if test "x$OPENJDK_TARGET_OS" = xaix; then
   3.422 +        COMPILER_NAME=xlc
   3.423 +        PICFLAG="-qpic=large"
   3.424 +        LIBRARY_PREFIX=lib
   3.425 +        SHARED_LIBRARY='lib$1.so'
   3.426 +        STATIC_LIBRARY='lib$1.a'
   3.427 +        SHARED_LIBRARY_FLAGS="-qmkshrobj"
   3.428 +        SHARED_LIBRARY_SUFFIX='.so'
   3.429 +        STATIC_LIBRARY_SUFFIX='.a'
   3.430 +        OBJ_SUFFIX='.o'
   3.431 +        EXE_SUFFIX=''
   3.432 +        SET_SHARED_LIBRARY_NAME=''
   3.433 +        SET_SHARED_LIBRARY_MAPFILE=''
   3.434 +        C_FLAG_REORDER=''
   3.435 +        CXX_FLAG_REORDER=''
   3.436 +        SET_SHARED_LIBRARY_ORIGIN=''
   3.437 +        SET_EXECUTABLE_ORIGIN=""
   3.438 +        CFLAGS_JDK=""
   3.439 +        CXXFLAGS_JDK=""
   3.440 +        CFLAGS_JDKLIB_EXTRA=''
   3.441 +        POST_STRIP_CMD="$STRIP -X32_64"
   3.442 +        POST_MCS_CMD=""
   3.443 +    fi
   3.444      if test "x$OPENJDK_TARGET_OS" = xwindows; then
   3.445          # If it is not gcc, then assume it is the MS Visual Studio compiler
   3.446          COMPILER_NAME=cl
   3.447 @@ -29457,8 +29586,26 @@
   3.448              ;;
   3.449          esac
   3.450  
   3.451 -    CFLAGS_DEBUG_SYMBOLS="-g -xs"
   3.452 -    CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
   3.453 +        CFLAGS_DEBUG_SYMBOLS="-g -xs"
   3.454 +        CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
   3.455 +        ;;
   3.456 +      xlc )
   3.457 +        C_FLAG_DEPS="-qmakedep=gcc -MF"
   3.458 +        CXX_FLAG_DEPS="-qmakedep=gcc -MF"
   3.459 +        C_O_FLAG_HIGHEST="-O3"
   3.460 +        C_O_FLAG_HI="-O3 -qstrict"
   3.461 +        C_O_FLAG_NORM="-O2"
   3.462 +        C_O_FLAG_NONE=""
   3.463 +        CXX_O_FLAG_HIGHEST="-O3"
   3.464 +        CXX_O_FLAG_HI="-O3 -qstrict"
   3.465 +        CXX_O_FLAG_NORM="-O2"
   3.466 +        CXX_O_FLAG_NONE=""
   3.467 +        CFLAGS_DEBUG_SYMBOLS="-g"
   3.468 +        CXXFLAGS_DEBUG_SYMBOLS="-g"
   3.469 +        LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
   3.470 +        CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
   3.471 +        CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
   3.472 +        ;;
   3.473      esac
   3.474      ;;
   3.475    CL )
   3.476 @@ -29582,6 +29729,13 @@
   3.477            LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
   3.478            LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
   3.479            ;;
   3.480 +      xlc )
   3.481 +          CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
   3.482 +          CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
   3.483 +
   3.484 +          LDFLAGS_JDK="$LDFLAGS_JDK"
   3.485 +          LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK"
   3.486 +          ;;
   3.487        cl )
   3.488            CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
   3.489                 -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
   3.490 @@ -29651,6 +29805,9 @@
   3.491  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
   3.492      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DSOLARIS"
   3.493  fi
   3.494 +if test "x$OPENJDK_TARGET_OS" = xaix; then
   3.495 +    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DAIX -DPPC64"
   3.496 +fi
   3.497  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
   3.498      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMACOSX -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
   3.499      # Setting these parameters makes it an error to link to macosx APIs that are
   3.500 @@ -29783,10 +29940,10 @@
   3.501    # ZERO_ARCHFLAG tells the compiler which mode to build for
   3.502    case "${OPENJDK_TARGET_CPU}" in
   3.503      s390)
   3.504 -      ZERO_ARCHFLAG="-m31"
   3.505 +      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
   3.506        ;;
   3.507      *)
   3.508 -      ZERO_ARCHFLAG="-m${OPENJDK_TARGET_CPU_BITS}"
   3.509 +      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.510    esac
   3.511  
   3.512    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
   3.513 @@ -29859,15 +30016,15 @@
   3.514  
   3.515  
   3.516  
   3.517 -  # Check that the compiler supports -mX flags
   3.518 +  # Check that the compiler supports -mX (or -qX on AIX) flags
   3.519    # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
   3.520  
   3.521 -  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"-m${OPENJDK_TARGET_CPU_BITS}\"" >&5
   3.522 -$as_echo_n "checking if compiler supports \"-m${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
   3.523 +  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
   3.524 +$as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
   3.525    supports=yes
   3.526  
   3.527    saved_cflags="$CFLAGS"
   3.528 -  CFLAGS="$CFLAGS -m${OPENJDK_TARGET_CPU_BITS}"
   3.529 +  CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.530    ac_ext=c
   3.531  ac_cpp='$CPP $CPPFLAGS'
   3.532  ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
   3.533 @@ -29895,7 +30052,7 @@
   3.534    CFLAGS="$saved_cflags"
   3.535  
   3.536    saved_cxxflags="$CXXFLAGS"
   3.537 -  CXXFLAGS="$CXXFLAG -m${OPENJDK_TARGET_CPU_BITS}"
   3.538 +  CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   3.539    ac_ext=cpp
   3.540  ac_cpp='$CXXCPP $CPPFLAGS'
   3.541  ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
   3.542 @@ -30050,6 +30207,16 @@
   3.543  $as_echo "alsa pulse" >&6; }
   3.544  fi
   3.545  
   3.546 +if test "x$OPENJDK_TARGET_OS" = xaix; then
   3.547 +    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
   3.548 +$as_echo_n "checking what is not needed on AIX?... " >&6; }
   3.549 +    ALSA_NOT_NEEDED=yes
   3.550 +    PULSE_NOT_NEEDED=yes
   3.551 +    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
   3.552 +$as_echo "alsa pulse" >&6; }
   3.553 +fi
   3.554 +
   3.555 +
   3.556  if test "x$OPENJDK_TARGET_OS" = xwindows; then
   3.557      { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
   3.558  $as_echo_n "checking what is not needed on Windows?... " >&6; }
   3.559 @@ -30860,7 +31027,7 @@
   3.560      case $PKGHANDLER in
   3.561  	apt-get)
   3.562                  apt_help     $MISSING_DEPENDENCY ;;
   3.563 -    yum)
   3.564 +	yum)
   3.565                  yum_help     $MISSING_DEPENDENCY ;;
   3.566  	port)
   3.567                  port_help    $MISSING_DEPENDENCY ;;
   3.568 @@ -30868,8 +31035,6 @@
   3.569                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.570  	pkgadd)
   3.571                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.572 -    * )
   3.573 -      break ;;
   3.574      esac
   3.575  
   3.576      if test "x$PKGHANDLER_COMMAND" != x; then
   3.577 @@ -30953,7 +31118,7 @@
   3.578      case $PKGHANDLER in
   3.579  	apt-get)
   3.580                  apt_help     $MISSING_DEPENDENCY ;;
   3.581 -    yum)
   3.582 +	yum)
   3.583                  yum_help     $MISSING_DEPENDENCY ;;
   3.584  	port)
   3.585                  port_help    $MISSING_DEPENDENCY ;;
   3.586 @@ -30961,8 +31126,6 @@
   3.587                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.588  	pkgadd)
   3.589                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.590 -    * )
   3.591 -      break ;;
   3.592      esac
   3.593  
   3.594      if test "x$PKGHANDLER_COMMAND" != x; then
   3.595 @@ -31205,7 +31368,7 @@
   3.596      case $PKGHANDLER in
   3.597  	apt-get)
   3.598                  apt_help     $MISSING_DEPENDENCY ;;
   3.599 -    yum)
   3.600 +	yum)
   3.601                  yum_help     $MISSING_DEPENDENCY ;;
   3.602  	port)
   3.603                  port_help    $MISSING_DEPENDENCY ;;
   3.604 @@ -31213,8 +31376,6 @@
   3.605                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.606  	pkgadd)
   3.607                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.608 -    * )
   3.609 -      break ;;
   3.610      esac
   3.611  
   3.612      if test "x$PKGHANDLER_COMMAND" != x; then
   3.613 @@ -31828,7 +31989,7 @@
   3.614      case $PKGHANDLER in
   3.615  	apt-get)
   3.616                  apt_help     $MISSING_DEPENDENCY ;;
   3.617 -    yum)
   3.618 +	yum)
   3.619                  yum_help     $MISSING_DEPENDENCY ;;
   3.620  	port)
   3.621                  port_help    $MISSING_DEPENDENCY ;;
   3.622 @@ -31836,8 +31997,6 @@
   3.623                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.624  	pkgadd)
   3.625                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.626 -    * )
   3.627 -      break ;;
   3.628      esac
   3.629  
   3.630      if test "x$PKGHANDLER_COMMAND" != x; then
   3.631 @@ -32200,7 +32359,7 @@
   3.632      case $PKGHANDLER in
   3.633  	apt-get)
   3.634                  apt_help     $MISSING_DEPENDENCY ;;
   3.635 -    yum)
   3.636 +	yum)
   3.637                  yum_help     $MISSING_DEPENDENCY ;;
   3.638  	port)
   3.639                  port_help    $MISSING_DEPENDENCY ;;
   3.640 @@ -32208,8 +32367,6 @@
   3.641                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.642  	pkgadd)
   3.643                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.644 -    * )
   3.645 -      break ;;
   3.646      esac
   3.647  
   3.648      if test "x$PKGHANDLER_COMMAND" != x; then
   3.649 @@ -33073,6 +33230,9 @@
   3.650          # Looks like a MacOSX system
   3.651          NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
   3.652          FOUND_CORES=yes
   3.653 +    elif test "x$OPENJDK_BUILD_OS" = xaix ; then
   3.654 +        NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
   3.655 +        FOUND_CORES=yes
   3.656      elif test -n "$NUMBER_OF_PROCESSORS"; then
   3.657          # On windows, look in the env
   3.658          NUM_CORES=$NUMBER_OF_PROCESSORS
   3.659 @@ -33118,8 +33278,8 @@
   3.660          MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
   3.661          FOUND_MEM=yes
   3.662      elif test -x /usr/sbin/prtconf; then
   3.663 -        # Looks like a Solaris system
   3.664 -        MEMORY_SIZE=`/usr/sbin/prtconf | grep "Memory size" | awk '{ print $3 }'`
   3.665 +        # Looks like a Solaris or AIX system
   3.666 +        MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
   3.667          FOUND_MEM=yes
   3.668      elif test -x /usr/sbin/system_profiler; then
   3.669          # Looks like a MacOSX system
   3.670 @@ -35013,7 +35173,7 @@
   3.671      case $PKGHANDLER in
   3.672  	apt-get)
   3.673                  apt_help     $MISSING_DEPENDENCY ;;
   3.674 -    yum)
   3.675 +	yum)
   3.676                  yum_help     $MISSING_DEPENDENCY ;;
   3.677  	port)
   3.678                  port_help    $MISSING_DEPENDENCY ;;
   3.679 @@ -35021,8 +35181,6 @@
   3.680                  pkgutil_help $MISSING_DEPENDENCY ;;
   3.681  	pkgadd)
   3.682                  pkgadd_help  $MISSING_DEPENDENCY ;;
   3.683 -    * )
   3.684 -      break ;;
   3.685      esac
   3.686  
   3.687      if test "x$PKGHANDLER_COMMAND" != x; then
     4.1 --- a/common/autoconf/help.m4	Thu Sep 05 10:58:25 2013 -0700
     4.2 +++ b/common/autoconf/help.m4	Thu Sep 12 12:29:17 2013 -0700
     4.3 @@ -38,7 +38,7 @@
     4.4      case $PKGHANDLER in
     4.5  	apt-get)
     4.6                  apt_help     $MISSING_DEPENDENCY ;;
     4.7 -    yum)
     4.8 +	yum)
     4.9                  yum_help     $MISSING_DEPENDENCY ;;
    4.10  	port)
    4.11                  port_help    $MISSING_DEPENDENCY ;;
    4.12 @@ -46,8 +46,6 @@
    4.13                  pkgutil_help $MISSING_DEPENDENCY ;;
    4.14  	pkgadd)
    4.15                  pkgadd_help  $MISSING_DEPENDENCY ;;
    4.16 -    * )
    4.17 -      break ;;
    4.18      esac
    4.19  
    4.20      if test "x$PKGHANDLER_COMMAND" != x; then
    4.21 @@ -63,8 +61,6 @@
    4.22          PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P zip" ;;
    4.23      make)
    4.24          PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P make" ;;
    4.25 -    * )
    4.26 -       break ;;
    4.27      esac
    4.28  }
    4.29  
    4.30 @@ -86,8 +82,6 @@
    4.31          PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
    4.32      ccache)
    4.33          PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
    4.34 -    * )
    4.35 -       break ;;
    4.36      esac
    4.37  }
    4.38  
    4.39 @@ -109,8 +103,6 @@
    4.40          PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
    4.41      ccache)
    4.42          PKGHANDLER_COMMAND="sudo yum install ccache" ;;
    4.43 -    * )
    4.44 -       break ;;
    4.45      esac
    4.46  }
    4.47  
     5.1 --- a/common/autoconf/libraries.m4	Thu Sep 05 10:58:25 2013 -0700
     5.2 +++ b/common/autoconf/libraries.m4	Thu Sep 12 12:29:17 2013 -0700
     5.3 @@ -43,6 +43,14 @@
     5.4      AC_MSG_RESULT([alsa pulse])
     5.5  fi
     5.6  
     5.7 +if test "x$OPENJDK_TARGET_OS" = xaix; then
     5.8 +    AC_MSG_CHECKING([what is not needed on AIX?])
     5.9 +    ALSA_NOT_NEEDED=yes
    5.10 +    PULSE_NOT_NEEDED=yes
    5.11 +    AC_MSG_RESULT([alsa pulse])
    5.12 +fi
    5.13 +
    5.14 +
    5.15  if test "x$OPENJDK_TARGET_OS" = xwindows; then
    5.16      AC_MSG_CHECKING([what is not needed on Windows?])
    5.17      CUPS_NOT_NEEDED=yes    
     6.1 --- a/common/autoconf/platform.m4	Thu Sep 05 10:58:25 2013 -0700
     6.2 +++ b/common/autoconf/platform.m4	Thu Sep 12 12:29:17 2013 -0700
     6.3 @@ -114,6 +114,11 @@
     6.4        VAR_OS_API=winapi
     6.5        VAR_OS_ENV=windows.msys
     6.6        ;;
     6.7 +    *aix*)
     6.8 +      VAR_OS=aix
     6.9 +      VAR_OS_API=posix
    6.10 +      VAR_OS_ENV=aix
    6.11 +      ;;
    6.12      *)
    6.13        AC_MSG_ERROR([unsupported operating system $1])
    6.14        ;;
    6.15 @@ -412,16 +417,17 @@
    6.16  [
    6.17    # keep track of c/cxx flags that we added outselves...
    6.18    #   to prevent emitting warning...
    6.19 -  TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
    6.20 -  AC_SUBST(TARGET_BITS_FLAG)
    6.21 +  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
    6.22 +  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
    6.23 +  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
    6.24  
    6.25 -  CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
    6.26 -  CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
    6.27 -  LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
    6.28 +  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
    6.29 +  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
    6.30 +  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
    6.31  
    6.32 -  CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
    6.33 -  CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
    6.34 -  LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
    6.35 +  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
    6.36 +  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
    6.37 +  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
    6.38  ])
    6.39  
    6.40  AC_DEFUN_ONCE([PLATFORM_SETUP_OPENJDK_TARGET_BITS],
    6.41 @@ -433,8 +439,9 @@
    6.42  # is made at runtime.)
    6.43  #
    6.44  
    6.45 -if test "x$OPENJDK_TARGET_OS" = xsolaris; then
    6.46 -  # Always specify -m flags on Solaris
    6.47 +if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
    6.48 +  # Always specify -m flag on Solaris
    6.49 +  # And -q on AIX because otherwise the compiler produces 32-bit objects by default
    6.50    PLATFORM_SET_COMPILER_TARGET_BITS_FLAGS
    6.51  elif test "x$COMPILE_TYPE" = xreduced; then
    6.52    if test "x$OPENJDK_TARGET_OS" != xwindows; then
    6.53 @@ -456,19 +463,34 @@
    6.54  
    6.55  AC_CHECK_SIZEOF([int *], [1111])
    6.56  
    6.57 -if test "x$SIZEOF_INT_P" != "x$ac_cv_sizeof_int_p"; then
    6.58 -  # Workaround autoconf bug, see http://lists.gnu.org/archive/html/autoconf/2010-07/msg00004.html
    6.59 -  SIZEOF_INT_P="$ac_cv_sizeof_int_p"
    6.60 -fi
    6.61 -
    6.62 -if test "x$SIZEOF_INT_P" = x; then 
    6.63 +# AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
    6.64 +if test "x$ac_cv_sizeof_int_p" = x; then
    6.65      # The test failed, lets stick to the assumed value.
    6.66      AC_MSG_WARN([The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS.])
    6.67  else
    6.68 -    TESTED_TARGET_CPU_BITS=`expr 8 \* $SIZEOF_INT_P`
    6.69 +    TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
    6.70  
    6.71      if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
    6.72 -        AC_MSG_ERROR([The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)])
    6.73 +        # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
    6.74 +        # Let's try to implicitely set the compilers target architecture and retry the test
    6.75 +        AC_MSG_NOTICE([The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS).])
    6.76 +        AC_MSG_NOTICE([I'll retry after setting the platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}])
    6.77 +        PLATFORM_SET_COMPILER_TARGET_BITS_FLAGS
    6.78 +
    6.79 +        # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
    6.80 +        unset ac_cv_sizeof_int_p
    6.81 +	# And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
    6.82 +	cat >>confdefs.h <<_ACEOF
    6.83 +#undef SIZEOF_INT_P
    6.84 +_ACEOF
    6.85 +
    6.86 +        AC_CHECK_SIZEOF([int *], [1111])
    6.87 +
    6.88 +        TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
    6.89 +
    6.90 +        if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
    6.91 +            AC_MSG_ERROR([The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)])
    6.92 +        fi
    6.93      fi
    6.94  fi
    6.95  
     7.1 --- a/common/autoconf/spec.gmk.in	Thu Sep 05 10:58:25 2013 -0700
     7.2 +++ b/common/autoconf/spec.gmk.in	Thu Sep 12 12:29:17 2013 -0700
     7.3 @@ -305,7 +305,8 @@
     7.4  COMPILER_TYPE:=@COMPILER_TYPE@
     7.5  COMPILER_NAME:=@COMPILER_NAME@
     7.6  
     7.7 -TARGET_BITS_FLAG=@TARGET_BITS_FLAG@
     7.8 +# Option used to tell the compiler whether to create 32- or 64-bit executables
     7.9 +COMPILER_TARGET_BITS_FLAG:=@COMPILER_TARGET_BITS_FLAG@
    7.10  COMPILER_SUPPORTS_TARGET_BITS_FLAG=@COMPILER_SUPPORTS_TARGET_BITS_FLAG@
    7.11  
    7.12  CC_OUT_OPTION:=@CC_OUT_OPTION@
     8.1 --- a/common/autoconf/toolchain.m4	Thu Sep 05 10:58:25 2013 -0700
     8.2 +++ b/common/autoconf/toolchain.m4	Thu Sep 12 12:29:17 2013 -0700
     8.3 @@ -44,6 +44,15 @@
     8.4        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*@<:@ ,\t@:>@$COMPILER_NAME@<:@ ,\t@:>@\(@<:@1-9@:>@\.@<:@0-9@:>@@<:@0-9@:>@*\).*/\1/p"`
     8.5        COMPILER_VENDOR="Sun Studio"
     8.6      fi
     8.7 +  elif test  "x$OPENJDK_TARGET_OS" = xaix; then
     8.8 +      COMPILER_VERSION_TEST=`$COMPILER -qversion  2>&1 | $TAIL -n 1`
     8.9 +      $ECHO $COMPILER_VERSION_TEST | $GREP "^Version: " > /dev/null
    8.10 +      if test $? -ne 0; then
    8.11 +        AC_MSG_ERROR([Failed to detect the compiler version of $COMPILER ....])
    8.12 +      else
    8.13 +        COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n 's/Version: \([0-9][0-9]\.[0-9][0-9]*\).*/\1/p'`
    8.14 +        COMPILER_VENDOR='IBM'
    8.15 +      fi
    8.16    elif test  "x$OPENJDK_TARGET_OS" = xwindows; then
    8.17      # First line typically looks something like:
    8.18      # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86
    8.19 @@ -137,10 +146,14 @@
    8.20        AC_MSG_ERROR([Could not find a $COMPILER_NAME compiler. $HELP_MSG])
    8.21    fi
    8.22    BASIC_FIXUP_EXECUTABLE($1)
    8.23 -  AC_MSG_CHECKING([resolved symbolic links for $1])
    8.24    TEST_COMPILER="[$]$1"
    8.25 -  BASIC_REMOVE_SYMBOLIC_LINKS(TEST_COMPILER)
    8.26 -  AC_MSG_RESULT([$TEST_COMPILER])
    8.27 +  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
    8.28 +  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
    8.29 +  if test "x$OPENJDK_BUILD_OS" != xaix; then
    8.30 +    AC_MSG_CHECKING([resolved symbolic links for $1])
    8.31 +    BASIC_REMOVE_SYMBOLIC_LINKS(TEST_COMPILER)
    8.32 +    AC_MSG_RESULT([$TEST_COMPILER])
    8.33 +  fi
    8.34    AC_MSG_CHECKING([if $1 is disguised ccache])
    8.35  
    8.36    COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
    8.37 @@ -250,6 +263,9 @@
    8.38    COMPILER_CHECK_LIST="cl"
    8.39  elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
    8.40    COMPILER_CHECK_LIST="cc gcc"
    8.41 +elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
    8.42 +  # Do not probe for cc on AIX.
    8.43 +  COMPILER_CHECK_LIST="xlc_r"
    8.44  else
    8.45    COMPILER_CHECK_LIST="gcc cc"
    8.46  fi
    8.47 @@ -258,6 +274,14 @@
    8.48  # Now that we have resolved CC ourself, let autoconf have its go at it
    8.49  AC_PROG_CC([$CC])
    8.50  
    8.51 +# Option used to tell the compiler whether to create 32- or 64-bit executables
    8.52 +# Notice that CC contains the full compiler path at this point.
    8.53 +case $CC in
    8.54 +  *xlc_r) COMPILER_TARGET_BITS_FLAG="-q";;
    8.55 +  *)      COMPILER_TARGET_BITS_FLAG="-m";;
    8.56 +esac
    8.57 +AC_SUBST(COMPILER_TARGET_BITS_FLAG)
    8.58 +
    8.59  ### Locate C++ compiler (CXX)
    8.60  
    8.61  if test "x$CXX" != x; then
    8.62 @@ -266,6 +290,9 @@
    8.63    COMPILER_CHECK_LIST="cl"
    8.64  elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
    8.65    COMPILER_CHECK_LIST="CC g++"
    8.66 +elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
    8.67 +  # Do not probe for CC on AIX .
    8.68 +  COMPILER_CHECK_LIST="xlC_r"
    8.69  else
    8.70    COMPILER_CHECK_LIST="g++ CC"
    8.71  fi
    8.72 @@ -307,6 +334,8 @@
    8.73  fi
    8.74  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
    8.75      ARFLAGS="-r"
    8.76 +elif test "x$OPENJDK_TARGET_OS" = xaix; then
    8.77 +    ARFLAGS="-X64"
    8.78  else
    8.79      ARFLAGS=""
    8.80  fi
    8.81 @@ -371,7 +400,7 @@
    8.82      ])
    8.83  
    8.84      # The version variables used to create RC_FLAGS may be overridden
    8.85 -    # in a custom configure script, or possibly the command line.  
    8.86 +    # in a custom configure script, or possibly the command line.
    8.87      # Let those variables be expanded at make time in spec.gmk.
    8.88      # The \$ are escaped to the shell, and the $(...) variables
    8.89      # are evaluated by make.
    8.90 @@ -550,6 +579,29 @@
    8.91          POST_STRIP_CMD="$STRIP -x"
    8.92          POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
    8.93      fi
    8.94 +    if test "x$OPENJDK_TARGET_OS" = xaix; then
    8.95 +        COMPILER_NAME=xlc
    8.96 +        PICFLAG="-qpic=large"
    8.97 +        LIBRARY_PREFIX=lib
    8.98 +        SHARED_LIBRARY='lib[$]1.so'
    8.99 +        STATIC_LIBRARY='lib[$]1.a'
   8.100 +        SHARED_LIBRARY_FLAGS="-qmkshrobj"
   8.101 +        SHARED_LIBRARY_SUFFIX='.so'
   8.102 +        STATIC_LIBRARY_SUFFIX='.a'
   8.103 +        OBJ_SUFFIX='.o'
   8.104 +        EXE_SUFFIX=''
   8.105 +        SET_SHARED_LIBRARY_NAME=''
   8.106 +        SET_SHARED_LIBRARY_MAPFILE=''
   8.107 +        C_FLAG_REORDER=''
   8.108 +        CXX_FLAG_REORDER=''
   8.109 +        SET_SHARED_LIBRARY_ORIGIN=''
   8.110 +        SET_EXECUTABLE_ORIGIN=""
   8.111 +        CFLAGS_JDK=""
   8.112 +        CXXFLAGS_JDK=""
   8.113 +        CFLAGS_JDKLIB_EXTRA=''
   8.114 +        POST_STRIP_CMD="$STRIP -X32_64"
   8.115 +        POST_MCS_CMD=""
   8.116 +    fi
   8.117      if test "x$OPENJDK_TARGET_OS" = xwindows; then
   8.118          # If it is not gcc, then assume it is the MS Visual Studio compiler
   8.119          COMPILER_NAME=cl
   8.120 @@ -723,8 +775,26 @@
   8.121              ;;
   8.122          esac
   8.123  
   8.124 -    CFLAGS_DEBUG_SYMBOLS="-g -xs"
   8.125 -    CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
   8.126 +        CFLAGS_DEBUG_SYMBOLS="-g -xs"
   8.127 +        CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
   8.128 +        ;;
   8.129 +      xlc )
   8.130 +        C_FLAG_DEPS="-qmakedep=gcc -MF"
   8.131 +        CXX_FLAG_DEPS="-qmakedep=gcc -MF"
   8.132 +        C_O_FLAG_HIGHEST="-O3"
   8.133 +        C_O_FLAG_HI="-O3 -qstrict"
   8.134 +        C_O_FLAG_NORM="-O2"
   8.135 +        C_O_FLAG_NONE=""
   8.136 +        CXX_O_FLAG_HIGHEST="-O3"
   8.137 +        CXX_O_FLAG_HI="-O3 -qstrict"
   8.138 +        CXX_O_FLAG_NORM="-O2"
   8.139 +        CXX_O_FLAG_NONE=""
   8.140 +        CFLAGS_DEBUG_SYMBOLS="-g"
   8.141 +        CXXFLAGS_DEBUG_SYMBOLS="-g"
   8.142 +        LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
   8.143 +        CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
   8.144 +        CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
   8.145 +        ;;
   8.146      esac
   8.147      ;;
   8.148    CL )
   8.149 @@ -835,6 +905,13 @@
   8.150            LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
   8.151            LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
   8.152            ;;
   8.153 +      xlc )
   8.154 +          CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
   8.155 +          CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
   8.156 +
   8.157 +          LDFLAGS_JDK="$LDFLAGS_JDK"
   8.158 +          LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK"
   8.159 +          ;;
   8.160        cl )
   8.161            CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
   8.162                 -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
   8.163 @@ -904,6 +981,9 @@
   8.164  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
   8.165      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DSOLARIS"
   8.166  fi
   8.167 +if test "x$OPENJDK_TARGET_OS" = xaix; then
   8.168 +    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DAIX -DPPC64"
   8.169 +fi
   8.170  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
   8.171      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMACOSX -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
   8.172      # Setting these parameters makes it an error to link to macosx APIs that are
   8.173 @@ -1073,17 +1153,17 @@
   8.174    # ZERO_ARCHFLAG tells the compiler which mode to build for
   8.175    case "${OPENJDK_TARGET_CPU}" in
   8.176      s390)
   8.177 -      ZERO_ARCHFLAG="-m31"
   8.178 +      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
   8.179        ;;
   8.180      *)
   8.181 -      ZERO_ARCHFLAG="-m${OPENJDK_TARGET_CPU_BITS}"
   8.182 +      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
   8.183    esac
   8.184    TOOLCHAIN_COMPILER_CHECK_ARGUMENTS([$ZERO_ARCHFLAG], [], [ZERO_ARCHFLAG=""])
   8.185    AC_SUBST(ZERO_ARCHFLAG)
   8.186  
   8.187 -  # Check that the compiler supports -mX flags
   8.188 +  # Check that the compiler supports -mX (or -qX on AIX) flags
   8.189    # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
   8.190 -  TOOLCHAIN_COMPILER_CHECK_ARGUMENTS([-m${OPENJDK_TARGET_CPU_BITS}],
   8.191 +  TOOLCHAIN_COMPILER_CHECK_ARGUMENTS([${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}],
   8.192      [COMPILER_SUPPORTS_TARGET_BITS_FLAG=true],
   8.193      [COMPILER_SUPPORTS_TARGET_BITS_FLAG=false])
   8.194    AC_SUBST(COMPILER_SUPPORTS_TARGET_BITS_FLAG)
     9.1 --- a/common/makefiles/JavaCompilation.gmk	Thu Sep 05 10:58:25 2013 -0700
     9.2 +++ b/common/makefiles/JavaCompilation.gmk	Thu Sep 12 12:29:17 2013 -0700
     9.3 @@ -163,11 +163,12 @@
     9.4  
     9.5      # The capture contents macro finds all files (matching the patterns, typically
     9.6      # .class and .prp) that are newer than the jar-file, ie the new content to be put into the jar.
     9.7 +    # NOTICE: please leave the parentheses space separated otherwise the AIX build will break!
     9.8      $1_CAPTURE_CONTENTS=$$(foreach src,$$($1_SRCS),\
     9.9 -                   (($(FIND) $$(src) -type f -a \( $$($1_FIND_PATTERNS) \) -a -newer $$@ $$($1_GREP_INCLUDES) \
    9.10 +                   ( ( $(FIND) $$(src) -type f -a \( $$($1_FIND_PATTERNS) \) -a -newer $$@ $$($1_GREP_INCLUDES) \
    9.11                         $$($1_GREP_EXCLUDES) | $(SED) 's|$$(src)/||g' &&\
    9.12 -                       $(ECHO) $$(subst $$(src)/,,$$($1_EXTRA_FILES))) > \
    9.13 -                       $$(src)/_the.$$($1_JARNAME)_contents) $$(NEWLINE))
    9.14 +                       $(ECHO) $$(subst $$(src)/,,$$($1_EXTRA_FILES) ) ) > \
    9.15 +                       $$(src)/_the.$$($1_JARNAME)_contents) $$(NEWLINE) )
    9.16      # The capture metainf macro finds all files below the META-INF directory that are newer than the jar-file.
    9.17      ifeq (,$$($1_SKIP_METAINF))
    9.18          $1_CAPTURE_METAINF =$$(foreach src,$$($1_SRCS),($(FIND) $$(src)/META-INF -type f -a -newer $$@ 2> /dev/null | $(SED) 's|$$(src)/||g' >> $$(src)/_the.$$($1_JARNAME)_contents ) $$(NEWLINE))
    9.19 @@ -176,19 +177,20 @@
    9.20      # tells us what to remove from the jar-file.
    9.21      $1_CAPTURE_DELETES=$$(foreach src,$$($1_SRCS),($(FIND) $$(src) -name _the.package.deleted -newer $$@ -exec $(SED) 's|$$(src)||g' \{\} >> $$($1_DELETES_FILE) \;) $$(NEWLINE))
    9.22      # The update contents macro updates the jar file with the previously capture contents.
    9.23 -    # xargs is used to trim the whitespace from the contents file, to see if it is empty.
    9.24 +    # Use 'wc -w' to see if the contents file is empty.
    9.25      $1_UPDATE_CONTENTS=$$(foreach src,$$($1_SRCS),\
    9.26                      (cd $$(src) && \
    9.27 -                     if [ -n "`$(CAT) _the.$$($1_JARNAME)_contents | $(XARGS)`" ]; then \
    9.28 +                     if [ "`$(WC) -w _the.$$($1_JARNAME)_contents | $(AWK) '{ print $$$$1 }'`" -gt "0" ]; then \
    9.29                           $(ECHO) "  updating" `$(WC) -l _the.$$($1_JARNAME)_contents | $(AWK) '{ print $$$$1 }'` files && \
    9.30                           $(JAR) $$($1_JAR_UPDATE_OPTIONS) $$@ @_the.$$($1_JARNAME)_contents; \
    9.31                       fi) $$(NEWLINE))
    9.32      # The s-variants of the above macros are used when the jar is created from scratch.
    9.33 +    # NOTICE: please leave the parentheses space separated otherwise the AIX build will break!
    9.34      $1_SCAPTURE_CONTENTS=$$(foreach src,$$($1_SRCS),\
    9.35 -                    (($(FIND) $$(src) -type f -a \( $$($1_FIND_PATTERNS) \) $$($1_GREP_INCLUDES) \
    9.36 +                    ( ( $(FIND) $$(src) -type f -a \( $$($1_FIND_PATTERNS) \) $$($1_GREP_INCLUDES) \
    9.37  			$$($1_GREP_EXCLUDES) | $(SED) 's|$$(src)/||g' &&\
    9.38 -			$$(subst $$(src)/,,$(ECHO) $$($1_EXTRA_FILES))) > \
    9.39 -			$$(src)/_the.$$($1_JARNAME)_contents) $$(NEWLINE))
    9.40 +			$$(subst $$(src)/,,$(ECHO) $$($1_EXTRA_FILES) ) ) > \
    9.41 +			$$(src)/_the.$$($1_JARNAME)_contents) $$(NEWLINE) )
    9.42  
    9.43      ifeq (,$$($1_SKIP_METAINF))
    9.44          $1_SCAPTURE_METAINF=$$(foreach src,$$($1_SRCS),\
    10.1 --- a/common/makefiles/NativeCompilation.gmk	Thu Sep 05 10:58:25 2013 -0700
    10.2 +++ b/common/makefiles/NativeCompilation.gmk	Thu Sep 12 12:29:17 2013 -0700
    10.3 @@ -495,7 +495,7 @@
    10.4          # Generating a static library, ie object file archive.
    10.5          $$($1_TARGET) : $$($1_EXPECTED_OBJS) $$($1_RES)
    10.6  	        $$(call ARCHIVING_MSG,$$($1_LIBRARY))
    10.7 -	        $(AR) $$($1_AR_FLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_EXPECTED_OBJS) \
    10.8 +	        $(AR) $$($1_ARFLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_EXPECTED_OBJS) \
    10.9  			$$($1_RES) $$($1_LDFLAGS_SUFFIX) $$($1_EXTRA_LDFLAGS_SUFFIX)
   10.10      endif
   10.11  

mercurial