knox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kmin...@apache.org
Subject git commit: KNOX-61: Put the RPM in the correct target directory. Sign the RPM via ant task.
Date Fri, 03 May 2013 20:51:18 GMT
Updated Branches:
  refs/heads/master d09c32ee3 -> 7db097623


KNOX-61: Put the RPM in the correct target directory.  Sign the RPM via ant task.


Project: http://git-wip-us.apache.org/repos/asf/incubator-knox/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-knox/commit/7db09762
Tree: http://git-wip-us.apache.org/repos/asf/incubator-knox/tree/7db09762
Diff: http://git-wip-us.apache.org/repos/asf/incubator-knox/diff/7db09762

Branch: refs/heads/master
Commit: 7db097623ecdb11e06e31e812aa1a454edf17ad3
Parents: d09c32e
Author: Kevin Minder <kevin.minder@hortonworks.com>
Authored: Fri May 3 16:51:11 2013 -0400
Committer: Kevin Minder <kevin.minder@hortonworks.com>
Committed: Fri May 3 16:51:11 2013 -0400

----------------------------------------------------------------------
 build.xml                     |    5 +++++
 gateway-rpm/build_knox_rpm.sh |   19 ++++++++++++-------
 gateway-rpm/knox.spec         |    4 ++--
 3 files changed, 19 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-knox/blob/7db09762/build.xml
----------------------------------------------------------------------
diff --git a/build.xml b/build.xml
index 17514b1..7df5725 100644
--- a/build.xml
+++ b/build.xml
@@ -101,6 +101,11 @@
         <exec executable="gpg" dir="target/${gateway-version}">
             <arg value="--armor"/>
             <arg value="--detach-sig"/>
+            <arg value="${gateway-artifact}-${gateway-version}.rpm"/>
+        </exec>
+        <exec executable="gpg" dir="target/${gateway-version}">
+            <arg value="--armor"/>
+            <arg value="--detach-sig"/>
             <arg value="${gateway-artifact}-${gateway-version}.zip"/>
         </exec>
         <exec executable="gpg" dir="target/${gateway-version}">

http://git-wip-us.apache.org/repos/asf/incubator-knox/blob/7db09762/gateway-rpm/build_knox_rpm.sh
----------------------------------------------------------------------
diff --git a/gateway-rpm/build_knox_rpm.sh b/gateway-rpm/build_knox_rpm.sh
old mode 100644
new mode 100755
index b4489c7..339c359
--- a/gateway-rpm/build_knox_rpm.sh
+++ b/gateway-rpm/build_knox_rpm.sh
@@ -22,19 +22,24 @@ KNOX_PACKAGE_TARGET=$1
 # knox
 KNOX_NAME=$2
 # 0.3.0-SNAPSHOT
-KNOX_VERSION=$3
+KNOX_VER=$3
 # target/RPM base directory
-KNOX_RPM_BUILD_ROOT="$(pwd)"/$KNOX_PACKAGE_TARGET/RPM
-
+KNOX_TOPDIR="$(pwd)"/$KNOX_PACKAGE_TARGET/RPM
+# Hardware platform
+KNOX_BUILD_ARCH="$(arch)"
+#RPM name
+KNOX_RPMFILENAME="$KNOX_NAME-$KNOX_VER.rpm"
 
 #SOURCES Contains the original sources, patches, and icon files.
 #SPECS Contains the spec files used to contrl the build process. 
 #The BUILD directory in which the sources are unpacked, and the software is built.
 #RPMS Contains the binary package files created by the build process.
 #SRPMS Contains the source package files created by the build process.
-mkdir -p $KNOX_RPM_BUILD_ROOT/{SOURCES,SPECS,BUILD,RPMS,SRPMS}
+mkdir -p $KNOX_TOPDIR/{SOURCES,SPECS,BUILD,RPMS,SRPMS}
+
+cp ./gateway-rpm/knox.spec $KNOX_TOPDIR/SPECS
+cp ./$KNOX_PACKAGE_TARGET/$KNOX_VER/$KNOX_NAME-$KNOX_VER.tar.gz $KNOX_TOPDIR/SOURCES
 
-cp ./gateway-rpm/knox.spec $KNOX_RPM_BUILD_ROOT/SPECS
-cp ./$KNOX_PACKAGE_TARGET/$KNOX_VERSION/$KNOX_NAME-$KNOX_VERSION.tar.gz $KNOX_RPM_BUILD_ROOT/SOURCES
+rpmbuild --define "_rpmfilename $KNOX_RPMFILENAME" --define "_topdir $KNOX_TOPDIR" --define
"_knox_name $KNOX_NAME" --define "_knox_ver $KNOX_VER" --define "_build_arch $KNOX_BUILD_ARCH"
--bb $KNOX_TOPDIR/SPECS/knox.spec  
 
-rpmbuild --define "_topdir $KNOX_RPM_BUILD_ROOT" --define "_knox_name $KNOX_NAME" --define
"_knox_ver $KNOX_VERSION" -bb $KNOX_RPM_BUILD_ROOT/SPECS/knox.spec 
+cp $KNOX_TOPDIR/RPMS/$KNOX_RPMFILENAME $KNOX_PACKAGE_TARGET/$KNOX_VER

http://git-wip-us.apache.org/repos/asf/incubator-knox/blob/7db09762/gateway-rpm/knox.spec
----------------------------------------------------------------------
diff --git a/gateway-rpm/knox.spec b/gateway-rpm/knox.spec
index c241f9c..2e851e9 100644
--- a/gateway-rpm/knox.spec
+++ b/gateway-rpm/knox.spec
@@ -21,13 +21,13 @@
 
 Summary: Knox
 Name: %_knox_name
-Version: 0.3.0
+Version: 0.0.0
 Release: 1
 License: Apache License, Version 2.0
 Group: Applications/Server
 Vendor: Hortonworks.
 Packager: Hortonworks <packager@hortonworks.com>
-BuildArch: i386
+BuildArch: %_build_arch
 
 #knox-0.3.0-SNAPSHOT.tar.gz
 Source: %{name}-%{_knox_ver}.tar.gz


Mime
View raw message