598 [enable_zip_debug_info="${enableval}"], [enable_zip_debug_info="yes"]) |
604 [enable_zip_debug_info="${enableval}"], [enable_zip_debug_info="yes"]) |
599 AC_MSG_RESULT([${enable_zip_debug_info}]) |
605 AC_MSG_RESULT([${enable_zip_debug_info}]) |
600 |
606 |
601 if test "x${enable_zip_debug_info}" = "xno"; then |
607 if test "x${enable_zip_debug_info}" = "xno"; then |
602 ZIP_DEBUGINFO_FILES=false |
608 ZIP_DEBUGINFO_FILES=false |
603 else |
609 elif test "x${enable_zip_debug_info}" = "xyes"; then |
604 ZIP_DEBUGINFO_FILES=true |
610 ZIP_DEBUGINFO_FILES=true |
605 fi |
611 fi |
606 |
612 |
|
613 # |
|
614 # NATIVE_DEBUG_SYMBOLS |
|
615 # This must be done after the toolchain is setup, since we're looking at objcopy. |
|
616 # In addition, this must be done after ENABLE_DEBUG_SYMBOLS and ZIP_DEBUGINFO_FILES |
|
617 # checking in order to preserve backwards compatibility post JDK-8207234. |
|
618 # |
|
619 AC_MSG_CHECKING([what type of native debug symbols to use (this will override previous settings)]) |
|
620 AC_ARG_WITH([native-debug-symbols], |
|
621 [AS_HELP_STRING([--with-native-debug-symbols], |
|
622 [set the native debug symbol configuration (none, internal, external, zipped) @<:@varying@:>@])], |
|
623 [ |
|
624 if test "x$OPENJDK_TARGET_OS" = xaix; then |
|
625 if test "x$with_native_debug_symbols" = xexternal || test "x$with_native_debug_symbols" = xzipped; then |
|
626 AC_MSG_ERROR([AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols]) |
|
627 fi |
|
628 fi |
|
629 ], |
|
630 [ |
|
631 # Default to unset for backwards compatibility |
|
632 with_native_debug_symbols="" |
|
633 ]) |
|
634 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols |
|
635 if test "x$NATIVE_DEBUG_SYMBOLS" = x; then |
|
636 AC_MSG_RESULT([not specified]) |
|
637 else |
|
638 AC_MSG_RESULT([$NATIVE_DEBUG_SYMBOLS]) |
|
639 fi |
|
640 # Default is empty |
|
641 DEBUG_BINARIES= |
|
642 # Default is min_strip. Possible values are min_strip, all_strip, no_strip |
|
643 STRIP_POLICY=min_strip |
|
644 |
|
645 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then |
|
646 |
|
647 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then |
|
648 if test "x$OBJCOPY" = x; then |
|
649 # enabling of enable-debug-symbols and can't find objcopy |
|
650 # this is an error |
|
651 AC_MSG_ERROR([Unable to find objcopy, cannot enable native debug symbols]) |
|
652 fi |
|
653 fi |
|
654 |
|
655 ENABLE_DEBUG_SYMBOLS=true |
|
656 STRIP_POLICY=min_strip |
|
657 ZIP_DEBUGINFO_FILES=true |
|
658 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then |
|
659 ENABLE_DEBUG_SYMBOLS=false |
|
660 STRIP_POLICY=min_strip |
|
661 ZIP_DEBUGINFO_FILES=false |
|
662 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then |
|
663 ENABLE_DEBUG_SYMBOLS=true |
|
664 STRIP_POLICY=no_strip |
|
665 ZIP_DEBUGINFO_FILES=false |
|
666 POST_STRIP_CMD= |
|
667 DEBUG_BINARIES=true |
|
668 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then |
|
669 |
|
670 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then |
|
671 if test "x$OBJCOPY" = x; then |
|
672 # enabling of enable-debug-symbols and can't find objcopy |
|
673 # this is an error |
|
674 AC_MSG_ERROR([Unable to find objcopy, cannot enable native debug symbols]) |
|
675 fi |
|
676 fi |
|
677 |
|
678 ENABLE_DEBUG_SYMBOLS=true |
|
679 STRIP_POLICY=min_strip |
|
680 ZIP_DEBUGINFO_FILES=false |
|
681 elif test "x$NATIVE_DEBUG_SYMBOLS" != x; then |
|
682 AC_MSG_ERROR([Allowed native debug symbols are: none, internal, external, zipped]) |
|
683 else |
|
684 AC_MSG_NOTICE([--with-native-debug-symbols not specified. Using values from --disable-debug-symbols and --disable-zip-debug-info]) |
|
685 fi |
|
686 |
607 AC_SUBST(ENABLE_DEBUG_SYMBOLS) |
687 AC_SUBST(ENABLE_DEBUG_SYMBOLS) |
|
688 AC_SUBST(STRIP_POLICY) |
|
689 AC_SUBST(POST_STRIP_CMD) |
|
690 AC_SUBST(DEBUG_BINARIES) |
608 AC_SUBST(ZIP_DEBUGINFO_FILES) |
691 AC_SUBST(ZIP_DEBUGINFO_FILES) |
609 ]) |
692 ]) |
610 |
693 |
611 # Support for customization of the build process. Some build files |
694 # Support for customization of the build process. Some build files |
612 # will include counterparts from this location, if they exist. This allows |
695 # will include counterparts from this location, if they exist. This allows |