From 76dc892491948adae5e5e62cf94448967e8d865b Mon Sep 17 00:00:00 2001 From: Ashlee Young Date: Sun, 6 Dec 2015 07:15:03 -0800 Subject: Fixes bad POM file with ONOS commit 8c68536972f63069c263635c9d9f4f31d7f3e9a2 Change-Id: I7adb5a2d3738d53dbc41db7577768b0e7ced5450 Signed-off-by: Ashlee Young --- framework/src/onos/tools/build/conf/pom.xml | 2 +- .../conf/src/main/resources/onos/checkstyle.xml | 4 --- framework/src/onos/tools/build/onos-change-version | 5 +--- framework/src/onos/tools/build/onos-package | 34 +++++++++++++++------- framework/src/onos/tools/build/pom.xml | 1 - 5 files changed, 26 insertions(+), 20 deletions(-) (limited to 'framework/src/onos/tools/build') diff --git a/framework/src/onos/tools/build/conf/pom.xml b/framework/src/onos/tools/build/conf/pom.xml index d56168f2..c76939ce 100644 --- a/framework/src/onos/tools/build/conf/pom.xml +++ b/framework/src/onos/tools/build/conf/pom.xml @@ -27,7 +27,7 @@ org.onosproject onos-build-conf - 1.1-SNAPSHOT + 1.2-SNAPSHOT Various ONOS build settings diff --git a/framework/src/onos/tools/build/conf/src/main/resources/onos/checkstyle.xml b/framework/src/onos/tools/build/conf/src/main/resources/onos/checkstyle.xml index fc6757a5..9260bae8 100644 --- a/framework/src/onos/tools/build/conf/src/main/resources/onos/checkstyle.xml +++ b/framework/src/onos/tools/build/conf/src/main/resources/onos/checkstyle.xml @@ -257,10 +257,6 @@ - - - - diff --git a/framework/src/onos/tools/build/onos-change-version b/framework/src/onos/tools/build/onos-change-version index a7117429..b41255b1 100755 --- a/framework/src/onos/tools/build/onos-change-version +++ b/framework/src/onos/tools/build/onos-change-version @@ -41,7 +41,7 @@ sed -i "" -E "s/Version\.version\(\"[^\"]*\"\)/Version.version(\"$NEW_VERSION\") # Augment the version in archetypes tree. mvn -f tools/package/archetypes/pom.xml versions:set -DnewVersion=$NEW_VERSION versions:commit -for atype in api bundle cli ui; do +for atype in api bundle cli ui uitab uitopo; do pom="tools/package/archetypes/$atype/src/main/resources/archetype-resources/pom.xml" sed -i "" -E "1,//s/[^<]*$NEW_VERSIONcord-gui<.*\n.*version>#cord-gui\n $NEW_VERSION#" $ONOS_ROOT/apps/demo/cord-gui/pom.xml sed -i "" -E "s#demo/cord-gui/target/cord-gui-.*\.war#demo/cord-gui/target/cord-gui-$NEW_VERSION.war#" $ONOS_ROOT/apps/demo/cord-gui/src/scripts/pullwar.sh sed -i "" -E "s#CORD=./cord-gui-.*\.war#CORD=./cord-gui-$NEW_VERSION.war#" $ONOS_ROOT/apps/demo/cord-gui/src/scripts/run.me - -# Augment the acl app -sed -i "" -E "s/[^<]*$NEW_VERSION bin/onos chmod a+x bin/onos-service bin/onos - # Stage the ONOS bundles, but only those that match the version - mkdir -p $ONOS_STAGE/$KARAF_DIST/system/org/onosproject - find $M2_REPO/org/onosproject -type f -path "*/$ONOS_POM_VERSION/*" \ - \( -name '*.jar' -o -name '*.pom' -o -name '*-features.xml' \) \ - | grep -v -Ee '-tests.jar|-[0-9]{8}.[0-9]{6}-' \ - | while read src; do - dst=$ONOS_STAGE/$KARAF_DIST/system/${src#$M2_REPO/*} - mkdir -p $(dirname $dst) - cp $src $dst - done + if [ -d $ONOS_ROOT/tools/package/karaf-assembly/target/repo ]; then + cp -r $ONOS_ROOT/tools/package/karaf-assembly/target/repo/* $ONOS_STAGE/$KARAF_DIST/system + #FIXME we need to add onos-features manually + mkdir -p $ONOS_STAGE/$KARAF_DIST/system/org/onosproject/onos-features/$ONOS_POM_VERSION + cp $M2_REPO/org/onosproject/onos-features/$ONOS_POM_VERSION/onos-features* \ + $ONOS_STAGE/$KARAF_DIST/system/org/onosproject/onos-features/$ONOS_POM_VERSION + else + # TODO: Deprecated so remove when confident staging works. + # Stage the ONOS bundles, but only those that match the version + mkdir -p $ONOS_STAGE/$KARAF_DIST/system/org/onosproject + find $M2_REPO/org/onosproject -type f -path "*/$ONOS_POM_VERSION/*" \ + \( -name '*.jar' -o -name '*.pom' -o -name '*-features.xml' \) \ + | grep -v -Ee '-tests.jar|-[0-9]{8}.[0-9]{6}-' \ + | while read src; do + dst=$ONOS_STAGE/$KARAF_DIST/system/${src#$M2_REPO/*} + mkdir -p $(dirname $dst) + cp $src $dst + done + fi # ONOS Patching ---------------------------------------------------------------- @@ -153,6 +162,11 @@ function build_rpm() { # Bail on any errors set -e +# Run karaf assembly to collect artifacts for off-line installations. +aux=/tmp/assembly-$$.log +trap "rm -f $aux 2>/dev/null" EXIT +cd $ONOS_ROOT/tools/package/karaf-assembly && mvn clean install > $aux 2>&1 + # Before starting make sure the environment is clan - delete onos staging folder rm -fr $ONOS_STAGE diff --git a/framework/src/onos/tools/build/pom.xml b/framework/src/onos/tools/build/pom.xml index ea473ed2..33b3a09b 100644 --- a/framework/src/onos/tools/build/pom.xml +++ b/framework/src/onos/tools/build/pom.xml @@ -81,7 +81,6 @@ org.apache.maven.plugins maven-javadoc-plugin - 2.9.1 attach-javadocs -- cgit 1.2.3-korg