Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tag parameter to build.sh (otherwise top level dir in the tarball is wrong) #223

Merged
merged 2 commits into from
Feb 15, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions makejdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ getOpenJDKUpdateAndBuildVersion()
cd "${WORKING_DIR}/${OPENJDK_REPO_NAME}" || return
echo "${git}Pulling latest tags and getting the latest update version using git fetch -q --tags ${SHALLOW_CLONE_OPTION}"
git fetch -q --tags "${SHALLOW_CLONE_OPTION}"
OPENJDK_REPO_TAG=$(getFirstTagFromOpenJDKGitRepo)
OPENJDK_REPO_TAG=${TAG:-$(getFirstTagFromOpenJDKGitRepo)}
if [[ "${OPENJDK_REPO_TAG}" == "" ]] ; then
echo "${error}Unable to detect git tag"
exit 1
Expand Down Expand Up @@ -422,8 +422,8 @@ testOpenJDKInNativeEnvironmentIfExpected()

buildAndTestOpenJDKInNativeEnvironment()
{
echo "Calling sbin/build.sh $WORKING_DIR $TARGET_DIR $OPENJDK_REPO_NAME $JVM_VARIANT $OPENJDK_UPDATE_VERSION $OPENJDK_BUILD_NUMBER"
"${SCRIPT_DIR}"/sbin/build.sh "${WORKING_DIR}" "${TARGET_DIR}" "${OPENJDK_REPO_NAME}" "${JVM_VARIANT}" "${OPENJDK_UPDATE_VERSION}" "${OPENJDK_BUILD_NUMBER}"
echo "Calling sbin/build.sh $WORKING_DIR $TARGET_DIR $OPENJDK_REPO_NAME $JVM_VARIANT $OPENJDK_UPDATE_VERSION $OPENJDK_BUILD_NUMBER $TAG"
"${SCRIPT_DIR}"/sbin/build.sh "${WORKING_DIR}" "${TARGET_DIR}" "${OPENJDK_REPO_NAME}" "${JVM_VARIANT}" "${OPENJDK_UPDATE_VERSION}" "${OPENJDK_BUILD_NUMBER}" "${TAG}"

testOpenJDKInNativeEnvironmentIfExpected
}
Expand Down
9 changes: 7 additions & 2 deletions sbin/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ OPENJDK_REPO_NAME=$3
JVM_VARIANT=${JVM_VARIANT:-server}
OPENJDK_UPDATE_VERSION=$5
OPENJDK_BUILD_NUMBER=$6
OPENJDK_REPO_TAG=$7
OPENJDK_DIR=$WORKING_DIR/$OPENJDK_REPO_NAME


Expand Down Expand Up @@ -252,7 +253,9 @@ removingUnnecessaryFiles()
echo "Removing unnecessary files now..."

echo "Fetching the first tag from the OpenJDK git repo..."
OPENJDK_REPO_TAG=$(getFirstTagFromOpenJDKGitRepo)
if [ -z "$OPENJDK_REPO_TAG" ]; then
OPENJDK_REPO_TAG=$(getFirstTagFromOpenJDKGitRepo)
fi
if [ "$USE_DOCKER" != "true" ] ; then
rm -rf cacerts_area
fi
Expand Down Expand Up @@ -324,7 +327,9 @@ createOpenJDKTarArchive()
{
echo "Archiving the build OpenJDK image..."

OPENJDK_REPO_TAG=$(getFirstTagFromOpenJDKGitRepo)
if [ -z "$OPENJDK_REPO_TAG" ]; then
OPENJDK_REPO_TAG=$(getFirstTagFromOpenJDKGitRepo)
fi
echo "OpenJDK repo tag is ${OPENJDK_REPO_TAG}"

if [ "$USE_DOCKER" == "true" ] ; then
Expand Down