2011-10-27 Ramon Novoa <rnovoa@artica.es>
* build_src.sh: Create symlinks needed to build RPM packages. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5090 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
c56596b943
commit
843c151dce
|
@ -1,3 +1,7 @@
|
|||
2011-10-27 Ramon Novoa <rnovoa@artica.es>
|
||||
|
||||
* build_src.sh: Create symlinks needed to build RPM packages.
|
||||
|
||||
2011-10-27 Ramon Novoa <rnovoa@artica.es>
|
||||
|
||||
* build_src.sh: Include build number in tarballs for nightly builds.
|
||||
|
|
|
@ -8,7 +8,9 @@ KEYGEN_VERSION=$(grep "%define version" $CODEHOME_ENT/updatemanager/keygen/pando
|
|||
|
||||
# Add build string for nightly builds
|
||||
if [ "$1" == "nightly" ]; then
|
||||
VERSION="$VERSION-$BUILD"
|
||||
LOCAL_VERSION="$VERSION-$BUILD"
|
||||
else
|
||||
LOCAL_VERSION=$VERSION
|
||||
fi
|
||||
|
||||
if [ ! -d $RPMHOME/SOURCES ]; then
|
||||
|
@ -18,25 +20,35 @@ fi
|
|||
echo "Creating source tarballs in $RPMHOME/SOURCES"
|
||||
|
||||
# Console
|
||||
cd $CODEHOME && tar zcvf $RPMHOME/SOURCES/pandorafms_console-$VERSION.tar.gz --exclude \.svn --exclude config.php --exclude enterprise pandora_console || exit 1
|
||||
cd $CODEHOME && tar zcvf $RPMHOME/SOURCES/pandorafms_console-$LOCAL_VERSION.tar.gz --exclude \.svn --exclude config.php --exclude enterprise pandora_console || exit 1
|
||||
|
||||
# Server
|
||||
cd $CODEHOME && tar zcvf $RPMHOME/SOURCES/pandorafms_server-$VERSION.tar.gz --exclude \.svn pandora_server || exit 1
|
||||
cd $CODEHOME && tar zcvf $RPMHOME/SOURCES/pandorafms_server-$LOCAL_VERSION.tar.gz --exclude \.svn pandora_server || exit 1
|
||||
|
||||
# Linux agent
|
||||
cd $CODEHOME/pandora_agents/shellscript && tar zcvf $RPMHOME/SOURCES/pandorafms_agent-$VERSION.tar.gz --exclude \.svn --exclude nohup linux || exit 1
|
||||
cd $CODEHOME/pandora_agents/shellscript && tar zcvf $RPMHOME/SOURCES/pandorafms_agent-$LOCAL_VERSION.tar.gz --exclude \.svn --exclude nohup linux || exit 1
|
||||
|
||||
# Unix agent
|
||||
cd $CODEHOME/pandora_agents && tar zvcf $RPMHOME/SOURCES/pandorafms_agent_unix-$VERSION.tar.gz --exclude \.svn --exclude nohup --exclude NT4 unix || exit 1
|
||||
cd $CODEHOME/pandora_agents && tar zvcf $RPMHOME/SOURCES/pandorafms_agent_unix-$LOCAL_VERSION.tar.gz --exclude \.svn --exclude nohup --exclude NT4 unix || exit 1
|
||||
|
||||
# Enterprise console
|
||||
cd $CODEHOME_ENT/pandora/trunk/pandora_console && tar zcvf $RPMHOME/SOURCES/pandorafms_console_enterprise-$VERSION.tar.gz --exclude \.svn enterprise/* || exit 1
|
||||
cd $CODEHOME_ENT/pandora/trunk/pandora_console && tar zcvf $RPMHOME/SOURCES/pandorafms_console_enterprise-$LOCAL_VERSION.tar.gz --exclude \.svn enterprise/* || exit 1
|
||||
|
||||
# Enterprise server
|
||||
cd $CODEHOME_ENT/pandora/trunk/pandora_server/ && tar zcvf $RPMHOME/SOURCES/pandorafms_server_enterprise-$VERSION.tar.gz --exclude \.svn PandoraFMS-Enterprise || exit 1
|
||||
cd $CODEHOME_ENT/pandora/trunk/pandora_server/ && tar zcvf $RPMHOME/SOURCES/pandorafms_server_enterprise-$LOCAL_VERSION.tar.gz --exclude \.svn PandoraFMS-Enterprise || exit 1
|
||||
|
||||
# Updatemanager keygen
|
||||
cd $CODEHOME_ENT/updatemanager/keygen && tar cvzf $RPMHOME/SOURCES/pandorafms_keygen-$KEYGEN_VERSION.tar.gz --exclude .svn --exclude keygen --exclude keygen.i386.static --exclude pandora_keygen.spec pandora || exit 1
|
||||
|
||||
# Create symlinks needed to build RPM packages
|
||||
if [ "$1" == "nightly" ]; then
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_console-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_console-$VERSION.tar.gz || exit 1
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_server-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_server-$VERSION.tar.gz || exit 1
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_agent-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_agent-$VERSION.tar.gz || exit 1
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_agent_unix-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_agent_unix-$VERSION.tar.gz || exit 1
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_console_enterprise-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_console_enterprise-$VERSION.tar.gz || exit 1
|
||||
ln -s $RPMHOME/SOURCES/pandorafms_server_enterprise-$LOCAL_VERSION.tar.gz $RPMHOME/SOURCES/pandorafms_server_enterprise-$VERSION.tar.gz || exit 1
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
|
|
Loading…
Reference in New Issue