# HG changeset patch # User Andrew John Hughes # Date 1437159549 -3600 # Node ID c931536f194af662f375fade140b9843e69aa238 # Parent de1a34f4a1a01d1b9f3a4b01a48daa0b8f379f23 PR2499: Update remove-intree-libraries.sh script 2015-07-13 Andrew John Hughes PR2499: Update remove-intree-libraries.sh script * NEWS: Updated. * acinclude.m4: (IT_ENABLE_SUNEC): Rename enable_sunec to ENABLE_SUNEC and substitute into autoconf generated files. * remove-intree-libraries.sh.in: Update enablement tests following PR1661. Check that system library code exists first before deleting and fail if not. diff -r de1a34f4a1a0 -r c931536f194a ChangeLog --- a/ChangeLog Fri Jul 17 19:49:37 2015 +0100 +++ b/ChangeLog Fri Jul 17 19:59:09 2015 +0100 @@ -1,3 +1,16 @@ +2015-07-13 Andrew John Hughes + + PR2499: Update remove-intree-libraries.sh script + * NEWS: Updated. + * acinclude.m4: + (IT_ENABLE_SUNEC): Rename enable_sunec to + ENABLE_SUNEC and substitute into autoconf + generated files. + * remove-intree-libraries.sh.in: + Update enablement tests following PR1661. Check + that system library code exists first before deleting + and fail if not. + 2015-07-13 Andrew John Hughes PR2390: Make elliptic curve removal diff -r de1a34f4a1a0 -r c931536f194a NEWS --- a/NEWS Fri Jul 17 19:49:37 2015 +0100 +++ b/NEWS Fri Jul 17 19:59:09 2015 +0100 @@ -31,6 +31,7 @@ - PR2367: 7 no longer builds with 6 - Util is not public in sun.management - PR2390: Make elliptic curve removal optional - PR2395: Path to jvm.cfg is wrong in add-systemtap-boot + - PR2499: Update remove-intree-libraries.sh script * CACAO - PR2380: Raise javadoc and JAVAC_FLAGS memory limits for CACAO * PPC & AIX port diff -r de1a34f4a1a0 -r c931536f194a acinclude.m4 --- a/acinclude.m4 Fri Jul 17 19:49:37 2015 +0100 +++ b/acinclude.m4 Fri Jul 17 19:59:09 2015 +0100 @@ -2688,19 +2688,18 @@ [ case "${enableval}" in yes) - enable_sunec=yes + ENABLE_SUNEC=yes ;; *) - enable_sunec=no + ENABLE_SUNEC=no ;; esac ], [ - enable_sunec=no + ENABLE_SUNEC=no ]) - AC_MSG_RESULT([$enable_sunec]) - AM_CONDITIONAL([ENABLE_SUNEC], test x"${enable_sunec}" = "xyes") - if test x"${enable_sunec}" = "xyes"; then + AC_MSG_RESULT([$ENABLE_SUNEC]) + if test x"${ENABLE_SUNEC}" = "xyes"; then PKG_CHECK_MODULES(NSS_SOFTOKN, nss-softokn >= 3.16.1, [NSS_SOFTOKN_FOUND=yes], [NSS_SOFTOKN_FOUND=no]) PKG_CHECK_MODULES(NSS_JAVA, nss-java, [NSS_JAVA_FOUND=yes], [NSS_JAVA_FOUND=no]) if test "x${NSS_SOFTOKN_FOUND}" = "xyes"; then @@ -2715,6 +2714,8 @@ AC_SUBST(SUNEC_CFLAGS) AC_SUBST(SUNEC_LIBS) fi + AM_CONDITIONAL([ENABLE_SUNEC], test x"${ENABLE_SUNEC}" = "xyes") + AC_SUBST(ENABLE_SUNEC) ]) AC_DEFUN_ONCE([IT_CHECK_TOOLS_JAR_EXISTS], diff -r de1a34f4a1a0 -r c931536f194a remove-intree-libraries.sh.in --- a/remove-intree-libraries.sh.in Fri Jul 17 19:49:37 2015 +0100 +++ b/remove-intree-libraries.sh.in Fri Jul 17 19:59:09 2015 +0100 @@ -8,27 +8,47 @@ LCMS_SRC=openjdk/jdk/src/share/native/sun/java2d/cmm/lcms PCSC_SRC=openjdk/jdk/src/solaris/native/sun/security/smartcardio/MUSCLE -if test "x@ENABLE_SYSTEM_ZLIB@" = "xyes"; then +if test "x@ENABLE_SYSTEM_ZLIB@" = "xtrue"; then + if [ ! -d ${ZIP_SRC} ]; then + echo "${ZIP_SRC} does not exist. Refusing to proceed." + exit -1; + fi echo "Removing zlib" rm -rvf ${ZIP_SRC} fi -if test "x@ENABLE_SYSTEM_JPEG@" = "xyes"; then +if test "x@ENABLE_SYSTEM_JPEG@" = "xtrue"; then + if [ ! -d ${JPEG_SRC} ]; then + echo "${JPEG_SRC} does not exist. Refusing to proceed." + exit -2; + fi echo "Removing libjpeg" rm -rvf ${JPEG_SRC} fi -if test "x@ENABLE_SYSTEM_GIF@" = "xyes"; then +if test "x@ENABLE_SYSTEM_GIF@" = "xtrue"; then + if [ ! -d ${GIF_SRC} ]; then + echo "${GIF_SRC} does not exist. Refusing to proceed." + exit -3; + fi echo "Removing giflib" rm -rvf ${GIF_SRC} fi -if test "x@ENABLE_SYSTEM_PNG@" = "xyes"; then +if test "x@ENABLE_SYSTEM_PNG@" = "xtrue"; then + if [ ! -d ${PNG_SRC} ]; then + echo "${PNG_SRC} does not exist. Refusing to proceed." + exit -4; + fi echo "Removing libpng" rm -rvf ${PNG_SRC} fi -if test "x@ENABLE_SYSTEM_LCMS@" = "xyes"; then +if test "x@ENABLE_SYSTEM_LCMS@" = "xtrue"; then + if [ ! -f ${LCMS_SRC}/cmscam02.c ]; then + echo "${LCMS_SRC}/cmscam02.c does not exist. Refusing to proceed." + exit -5; + fi echo "Removing lcms" rm -vf ${LCMS_SRC}/cmscam02.c rm -vf ${LCMS_SRC}/cmscgats.c @@ -59,7 +79,11 @@ rm -vf ${LCMS_SRC}/lcms2_plugin.h fi -if test "x@ENABLE_SYSTEM_PCSC@" = "xyes"; then +if test "x@ENABLE_SYSTEM_PCSC@" = "xtrue"; then + if [ ! -d ${PCSC_SRC} ]; then + echo "${PCSC_SRC} does not exist. Refusing to proceed." + exit -6; + fi echo "Removing libpcsc headers" rm -rvf ${PCSC_SRC} fi