< prev index next >

common/autoconf/flags.m4

Print this page




  82     AR_OUT_OPTION='rcs$(SPACE)'
  83   fi
  84   AC_SUBST(CC_OUT_OPTION)
  85   AC_SUBST(EXE_OUT_OPTION)
  86   AC_SUBST(LD_OUT_OPTION)
  87   AC_SUBST(AR_OUT_OPTION)
  88 
  89   # On Windows, we need to set RC flags.
  90   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
  91     RC_FLAGS="-nologo -l0x409"
  92     if test "x$VARIANT" = xOPT; then
  93       RC_FLAGS="$RC_FLAGS -DNDEBUG"
  94     fi
  95 
  96     # The version variables used to create RC_FLAGS may be overridden
  97     # in a custom configure script, or possibly the command line.
  98     # Let those variables be expanded at make time in spec.gmk.
  99     # The \$ are escaped to the shell, and the $(...) variables
 100     # are evaluated by make.
 101     RC_FLAGS="$RC_FLAGS \
 102         -D\"JDK_BUILD_ID=\$(FULL_VERSION)\" \
 103         -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \
 104         -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
 105         -D\"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
 106         -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
 107         -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
 108         -D\"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
 109   fi
 110   AC_SUBST(RC_FLAGS)
 111 
 112   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
 113     # silence copyright notice and other headers.
 114     COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo"
 115   fi
 116 
 117   if test "x$SYSROOT" != "x"; then
 118     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
 119       if test "x$OPENJDK_TARGET_OS" = xsolaris; then
 120         # Solaris Studio does not have a concept of sysroot. Instead we must
 121         # make sure the default include and lib dirs are appended to each
 122         # compile and link command line.
 123         SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
 124         SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
 125             -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
 126             -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
 127       fi
 128     elif test "x$OPENJDK_TARGET_OS" = xmacosx; then


 618       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN"
 619     fi
 620   fi
 621 
 622   # Setup target OS define. Use OS target name but in upper case.
 623   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
 624   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
 625 
 626   # Setup target CPU
 627   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
 628 
 629   # Setup debug/release defines
 630   if test "x$DEBUG_LEVEL" = xrelease; then
 631     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG"
 632     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
 633       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED"
 634     fi
 635   else
 636     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG"
 637   fi
 638 
 639   # Setup release name
 640   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
 641 
 642 
 643   # Set some additional per-OS defines.
 644   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
 645     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
 646   elif test "x$OPENJDK_TARGET_OS" = xaix; then
 647     # FIXME: PPC64 should not be here.
 648     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DPPC64"
 649   elif test "x$OPENJDK_TARGET_OS" = xbsd; then
 650     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
 651   fi
 652 
 653   # Additional macosx handling
 654   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
 655     # Setting these parameters makes it an error to link to macosx APIs that are
 656     # newer than the given OS version and makes the linked binaries compatible
 657     # even if built on a newer version of the OS.
 658     # The expected format is X.Y.Z
 659     MACOSX_VERSION_MIN=10.7.0
 660     AC_SUBST(MACOSX_VERSION_MIN)
 661 




  82     AR_OUT_OPTION='rcs$(SPACE)'
  83   fi
  84   AC_SUBST(CC_OUT_OPTION)
  85   AC_SUBST(EXE_OUT_OPTION)
  86   AC_SUBST(LD_OUT_OPTION)
  87   AC_SUBST(AR_OUT_OPTION)
  88 
  89   # On Windows, we need to set RC flags.
  90   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
  91     RC_FLAGS="-nologo -l0x409"
  92     if test "x$VARIANT" = xOPT; then
  93       RC_FLAGS="$RC_FLAGS -DNDEBUG"
  94     fi
  95 
  96     # The version variables used to create RC_FLAGS may be overridden
  97     # in a custom configure script, or possibly the command line.
  98     # Let those variables be expanded at make time in spec.gmk.
  99     # The \$ are escaped to the shell, and the $(...) variables
 100     # are evaluated by make.
 101     RC_FLAGS="$RC_FLAGS \
 102         -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \
 103         -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \
 104         -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
 105         -D\"JDK_VER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \
 106         -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
 107         -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \
 108         -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\""
 109   fi
 110   AC_SUBST(RC_FLAGS)
 111 
 112   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
 113     # silence copyright notice and other headers.
 114     COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo"
 115   fi
 116 
 117   if test "x$SYSROOT" != "x"; then
 118     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
 119       if test "x$OPENJDK_TARGET_OS" = xsolaris; then
 120         # Solaris Studio does not have a concept of sysroot. Instead we must
 121         # make sure the default include and lib dirs are appended to each
 122         # compile and link command line.
 123         SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
 124         SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
 125             -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
 126             -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
 127       fi
 128     elif test "x$OPENJDK_TARGET_OS" = xmacosx; then


 618       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN"
 619     fi
 620   fi
 621 
 622   # Setup target OS define. Use OS target name but in upper case.
 623   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
 624   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
 625 
 626   # Setup target CPU
 627   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
 628 
 629   # Setup debug/release defines
 630   if test "x$DEBUG_LEVEL" = xrelease; then
 631     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG"
 632     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
 633       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED"
 634     fi
 635   else
 636     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG"
 637   fi




 638 
 639   # Set some additional per-OS defines.
 640   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
 641     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
 642   elif test "x$OPENJDK_TARGET_OS" = xaix; then
 643     # FIXME: PPC64 should not be here.
 644     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DPPC64"
 645   elif test "x$OPENJDK_TARGET_OS" = xbsd; then
 646     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
 647   fi
 648 
 649   # Additional macosx handling
 650   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
 651     # Setting these parameters makes it an error to link to macosx APIs that are
 652     # newer than the given OS version and makes the linked binaries compatible
 653     # even if built on a newer version of the OS.
 654     # The expected format is X.Y.Z
 655     MACOSX_VERSION_MIN=10.7.0
 656     AC_SUBST(MACOSX_VERSION_MIN)
 657 


< prev index next >