From 6957c7806603edcce99b6aba2e3f402b186fb04a Mon Sep 17 00:00:00 2001 From: Robert Joseph Evans Date: Thu, 10 May 2012 21:09:08 +0000 Subject: [PATCH] HADOOP-8375. test-patch should stop immediately once it has found compilation errors (bobby) git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1336887 13f79535-47bb-0310-9956-ffa450edef68 --- dev-support/test-patch.sh | 14 ++++++++++---- hadoop-common-project/hadoop-common/CHANGES.txt | 3 +++ 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/dev-support/test-patch.sh b/dev-support/test-patch.sh index 90757a1d8b..2d6bcfebd4 100755 --- a/dev-support/test-patch.sh +++ b/dev-support/test-patch.sh @@ -423,8 +423,8 @@ checkJavacWarnings () { if [[ $? != 0 ]] ; then JIRA_COMMENT="$JIRA_COMMENT - -1 javac. The patch appears to cause tar ant target to fail." - return 1 + -1 javac. The patch appears to cause the build to fail." + return 2 fi ### Compare trunk and patch javac warning numbers if [[ -f $PATCH_DIR/patchJavacWarnings.txt ]] ; then @@ -900,9 +900,15 @@ if [[ $? != 0 ]] ; then submitJiraComment 1 cleanupAndExit 1 fi -checkJavadocWarnings -(( RESULT = RESULT + $? )) checkJavacWarnings +JAVAC_RET=$? +#2 is returned if the code could not compile +if [[ $JAVAC_RET == 2 ]] ; then + submitJiraComment 1 + cleanupAndExit 1 +fi +(( RESULT = RESULT + $JAVAC_RET )) +checkJavadocWarnings (( RESULT = RESULT + $? )) checkEclipseGeneration (( RESULT = RESULT + $? )) diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt index 23ff172272..d849db5d0d 100644 --- a/hadoop-common-project/hadoop-common/CHANGES.txt +++ b/hadoop-common-project/hadoop-common/CHANGES.txt @@ -132,6 +132,9 @@ Trunk (unreleased changes) HADOOP-8354. test-patch findbugs may fail if a dependent module is changed (Tom White and Robert Evans) + HADOOP-8375. test-patch should stop immediately once it has found + compilation errors (bobby) + OPTIMIZATIONS HADOOP-7761. Improve the performance of raw comparisons. (todd)